Class OMAGServerAdminStoreServices
java.lang.Object
org.odpi.openmetadata.tokencontroller.TokenController
org.odpi.openmetadata.adminservices.server.OMAGServerAdminStoreServices
OMAGServerAdminStoreServices provides the capability to store and retrieve configuration documents.
A configuration document provides the configuration information for a server. By default, a
server's configuration document is stored in its own file. However, it is possible to override
the default location using setConfigurationStoreConnection. This override affects all
server instances in this process.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionClear the connection object for the configuration store.Clear the default configuration document.Clear the placeholder variables.Return the connection object for the configuration store.Return the default server configuration document.Return the placeholder variables that will be used on each server start up.getServerConfigForStartUp(String userId, String serverName, String methodName) Retrieve any saved configuration for this server.voidsaveServerConfig(String serverName, String methodName, OMAGServerConfig serverConfig) Save the server's config ...voidsetConfigurationStoreConnection(String userId, Connection connection) Override the default location of the configuration documents.setConfigurationStoreConnection(Connection connection) Override the default location of the configuration documents.setDefaultOMAGServerConfig(String userId, OMAGServerConfig defaultServerConfig) Override the default server configuration document.setDefaultOMAGServerConfig(OMAGServerConfig defaultServerConfig) Override the default server configuration document.voidsetPlaceholderVariables(String userId, Map<String, String> placeholderVariables) Set up the placeholder variables that will be used on each server start up.setPlaceholderVariables(Map<String, String> placeholderVariables) Set up the placeholder variables that will be used on each server start up.Methods inherited from class org.odpi.openmetadata.tokencontroller.TokenController
getUser
-
Constructor Details
-
OMAGServerAdminStoreServices
public OMAGServerAdminStoreServices()
-
-
Method Details
-
setDefaultOMAGServerConfig
Override the default server configuration document.- Parameters:
userId- calling user.defaultServerConfig- values to include in every new configured server.- Returns:
- void response
-
setDefaultOMAGServerConfig
Override the default server configuration document.- Parameters:
defaultServerConfig- values to include in every new configured server.- Returns:
- void response
-
getDefaultOMAGServerConfig
Return the default server configuration document.- Returns:
- OMAGServerConfig response
-
clearDefaultOMAGServerConfig
Clear the default configuration document.- Returns:
- void response
-
setPlaceholderVariables
Set up the placeholder variables that will be used on each server start up.- Parameters:
userId- calling user.placeholderVariables- map of variable name to value.
-
setPlaceholderVariables
Set up the placeholder variables that will be used on each server start up.- Parameters:
placeholderVariables- map of variable name to value.- Returns:
- void response
-
getPlaceholderVariables
Return the placeholder variables that will be used on each server start up.- Returns:
- string map response
-
clearPlaceholderVariables
Clear the placeholder variables.- Returns:
- void response
-
setConfigurationStoreConnection
Override the default location of the configuration documents.- Parameters:
userId- calling user.connection- connection used to create and configure the connector that interacts with the real store.
-
setConfigurationStoreConnection
Override the default location of the configuration documents.- Parameters:
connection- connection used to create and configure the connector that interacts with the real store.- Returns:
- void response
-
getConfigurationStoreConnection
Return the connection object for the configuration store. Null is returned if the server should use the default store.- Returns:
- connection response
-
clearConfigurationStoreConnection
Clear the connection object for the configuration store.- Returns:
- connection response
-
getServerConfigForStartUp
public OMAGServerConfig getServerConfigForStartUp(String userId, String serverName, String methodName) throws InvalidParameterException, UserNotAuthorizedException, OMAGConfigurationErrorException Retrieve any saved configuration for this server.- Parameters:
userId- calling userserverName- name of the servermethodName- method requesting the server details- Returns:
- configuration properties
- Throws:
InvalidParameterException- problem with the configuration fileUserNotAuthorizedException- user not authorized to make these changesOMAGConfigurationErrorException- unable to parse the OMAGServerConfig
-
saveServerConfig
public void saveServerConfig(String serverName, String methodName, OMAGServerConfig serverConfig) throws InvalidParameterException Save the server's config ...- Parameters:
serverName- name of the servermethodName- method requesting the server detailsserverConfig- properties to save- Throws:
InvalidParameterException- problem with the config file
-