Class EmbeddedStorageConfiguration
public final class EmbeddedStorageConfiguration extends Object
- Since:
- 05.00.00
- See Also:
EmbeddedStorageConfigurationBuilder
-
Method Summary
Modifier and Type Method Description static EmbeddedStorageConfigurationBuilder
Builder()
Creates a newEmbeddedStorageConfigurationBuilder
instance.static String
DefaultResourceName()
The default name of the storage configuration resource.static EmbeddedStorageFoundation.Creator
FoundationCreator(Configuration configuration)
Creates a newEmbeddedStorageFoundation.Creator
based on aConfiguration
.static EmbeddedStorageConfigurationBuilder
load()
Tries to load the default storage configuration properties file.static EmbeddedStorageConfigurationBuilder
load(String path)
Tries to load the storage configuration file frompath
.static EmbeddedStorageConfigurationBuilder
load(String path, Charset charset)
Tries to load the storage configuration file frompath
.static EmbeddedStorageConfigurationBuilder
load(Charset charset)
Tries to load the default storage configuration properties file.static EmbeddedStorageConfigurationBuilder
load(ConfigurationLoader loader, ConfigurationParser parser)
Tries to load the storage configuration based on a given loader and parser.static String
PathProperty()
The property name which is used to hand the external configuration file path to the application.
-
Method Details
-
PathProperty
The property name which is used to hand the external configuration file path to the application.Either as system property or in the context's configuration, e.g. Spring's application.properties.
- Returns:
- "microstream.storage.configuration.path"
-
DefaultResourceName
The default name of the storage configuration resource.- Returns:
- "microstream-storage.properties"
- See Also:
load()
-
Builder
Creates a newEmbeddedStorageConfigurationBuilder
instance.This is a synonym for
EmbeddedStorageConfigurationBuilder.New()
.- Returns:
- a newly created
EmbeddedStorageConfigurationBuilder
- See Also:
EmbeddedStorageConfigurationBuilder.New()
-
load
Tries to load the default storage configuration properties file.The resource name is either set via the system property "microstream.storage.configuration.path" or the default name "microstream-storage.properties".
The search order is as described in
ConfigurationLoader.New(String)
.- Returns:
- the loaded configuration builder
- Throws:
ConfigurationExceptionNoConfigurationFound
- if no configuration can be found at the given path- See Also:
PathProperty()
,DefaultResourceName()
-
load
Tries to load the storage configuration file frompath
.Depending on the file suffix either the XML or the INI loader is used.
The search order is as described in
ConfigurationLoader.New(String)
.- Returns:
- the loaded configuration builder
- Throws:
ConfigurationExceptionNoConfigurationFound
- if no configuration can be found at the given path- See Also:
PathProperty()
,DefaultResourceName()
-
load
Tries to load the default storage configuration properties file.The resource name is either set via the system property "microstream.storage.configuration.path" or the default name "microstream-storage.properties".
The search order is as described in
ConfigurationLoader.New(String)
.- Parameters:
charset
- the charset used to parse the configuration- Returns:
- the loaded configuration builder
- Throws:
ConfigurationExceptionNoConfigurationFound
- if no configuration can be found at the given path- See Also:
PathProperty()
,DefaultResourceName()
-
load
Tries to load the storage configuration file frompath
.Depending on the file suffix either the XML or the INI loader is used.
The search order is as described in
ConfigurationLoader.New(String)
.- Parameters:
charset
- the charset used to parse the configuration *- Returns:
- the loaded configuration builder
- Throws:
ConfigurationExceptionNoConfigurationFound
- if no configuration can be found at the given path- See Also:
PathProperty()
,DefaultResourceName()
-
load
public static EmbeddedStorageConfigurationBuilder load(ConfigurationLoader loader, ConfigurationParser parser)Tries to load the storage configuration based on a given loader and parser.- Parameters:
loader
-parser
-- Returns:
- the loaded configuration builder
-
FoundationCreator
Creates a newEmbeddedStorageFoundation.Creator
based on aConfiguration
.- Parameters:
configuration
- the configuration the foundation will be based on- Returns:
- a new
EmbeddedStorageFoundation.Creator
-