public class MicrometerConfiguration extends DiContainer
このクラスはDiContainerの仕組みを流用して、設定ファイルの情報をロードする。
デフォルトではクラスパス配下のnablarch/integration/micrometer/micrometer.xmlを読み込む。
このファイルはデフォルトコンフィギュレーションのモジュールに含まれており、
クラスパスルートのmicrometer.propertiesを読み込むように定義されている。
したがって、利用者はアプリケーションのクラスパスルートにmicrometer.propertiesを
配置することでMicrometerの設定を指定できる。
また、ExternalizedComponentDefinitionLoaderとしてOsEnvironmentVariableExternalizedLoaderと
SystemPropertyExternalizedLoaderを使用している。
これにより、OS環境変数またはシステムプロパティで設定値を上書きすることができる。
| Constructor and Description |
|---|
MicrometerConfiguration()
デフォルトコンフィギュレーションに含まれる設定ファイルを読み込んでインスタンスを生成する。
|
MicrometerConfiguration(java.lang.String xmlFilePath)
読み込む設定ファイルのパスを指定してインスタンスを生成する。
|
| Modifier and Type | Method and Description |
|---|---|
protected ExternalizedComponentDefinitionLoader |
loadExternalizedComponentDefinitionLoader()
ExternalizedComponentDefinitionLoaderをServiceLoaderを使って読み込む。
ExternalizedComponentDefinitionLoaderのサービスプロバイダが設定されていない場合は、
後方互換を維持するためにSystemPropertyExternalizedLoaderが使用されます。 |
generateId, getComponentById, getComponentByName, getComponentByType, load, reloadpublic MicrometerConfiguration()
public MicrometerConfiguration(java.lang.String xmlFilePath)
xmlFilePath - 読み込む設定ファイルのパスprotected ExternalizedComponentDefinitionLoader loadExternalizedComponentDefinitionLoader()
DiContainerExternalizedComponentDefinitionLoaderをServiceLoaderを使って読み込む。
ExternalizedComponentDefinitionLoaderのサービスプロバイダが設定されていない場合は、
後方互換を維持するためにSystemPropertyExternalizedLoaderが使用されます。loadExternalizedComponentDefinitionLoader in class DiContainerExternalizedComponentDefinitionLoader