Class OMAGServerOperationsClient
java.lang.Object
org.odpi.openmetadata.adminservices.client.OMAGServerOperationsClient
OMAGServerOperationsClient provides services to start and stop an OMAG Server.
-
Constructor Summary
ConstructorsConstructorDescriptionOMAGServerOperationsClient(String adminUserId, String serverName, String serverPlatformRootURL) Create a new client with no authentication embedded in the HTTP request.OMAGServerOperationsClient(String adminUserId, String serverName, String serverPlatformRootURL, String connectionUserId, String connectionPassword) Create a new client that passes a connection userId and password in each HTTP request. -
Method Summary
Modifier and TypeMethodDescriptionActivate the Open Metadata and Governance (OMAG) server using the configuration document stored for this server.activateWithSuppliedConfig(org.odpi.openmetadata.adminservices.configuration.properties.OMAGServerConfig configuration) Activate the open metadata and governance services using the supplied configuration document.voidaddOpenMetadataArchive(org.odpi.openmetadata.frameworks.connectors.properties.beans.Connection connection) Add a new open metadata archive to running repository.voidaddOpenMetadataArchiveFile(String fileName) Add a new open metadata archive to running repository.voidPermanently deactivate any open metadata and governance services and unregister from any cohorts.voidTemporarily deactivate any open metadata and governance services.org.odpi.openmetadata.adminservices.configuration.properties.OMAGServerConfigReturn the configuration used for the current active instance of the server.org.odpi.openmetadata.adminservices.properties.ServerServicesStatusReturn the status of a running server (use platform services to find out if the server is running).
-
Constructor Details
-
OMAGServerOperationsClient
public OMAGServerOperationsClient(String adminUserId, String serverName, String serverPlatformRootURL) throws org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException Create a new client with no authentication embedded in the HTTP request.- Parameters:
adminUserId- administrator's (end user's) userId to associate with calls.serverName- name of the server to connect toserverPlatformRootURL- the network address of the server running the admin services- Throws:
org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException- there is a problem creating the client-side components to issue any REST API calls.
-
OMAGServerOperationsClient
public OMAGServerOperationsClient(String adminUserId, String serverName, String serverPlatformRootURL, String connectionUserId, String connectionPassword) throws org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException Create a new client that passes a connection userId and password in each HTTP request. This is the userId/password of the calling server. The end user's userId is passed as the admin userId.- Parameters:
adminUserId- administrator's (end user's) userId to associate with calls.serverName- name of the server to connect toserverPlatformRootURL- the network address of the server running the admin servicesconnectionUserId- caller's system userId embedded in all HTTP requestsconnectionPassword- caller's system password embedded in all HTTP requests- Throws:
org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException- there is a problem creating the client-side components to issue any REST API calls.
-
-
Method Details
-
activateWithStoredConfig
public String activateWithStoredConfig() throws org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorExceptionActivate the Open Metadata and Governance (OMAG) server using the configuration document stored for this server.- Returns:
- success message
- Throws:
org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException- the supplied userId is not authorized to issue this command.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException- invalid parameter.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorException- unusual state in the admin server.
-
activateWithSuppliedConfig
public String activateWithSuppliedConfig(org.odpi.openmetadata.adminservices.configuration.properties.OMAGServerConfig configuration) throws org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorException Activate the open metadata and governance services using the supplied configuration document.- Parameters:
configuration- properties used to initialize the services- Returns:
- success message
- Throws:
org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException- the supplied userId is not authorized to issue this command.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException- invalid parameter.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorException- unusual state in the admin server.
-
deactivateTemporarily
public void deactivateTemporarily() throws org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorExceptionTemporarily deactivate any open metadata and governance services.- Throws:
org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException- the supplied userId is not authorized to issue this command.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException- invalid parameter.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorException- unusual state in the admin server.
-
deactivatePermanently
public void deactivatePermanently() throws org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorExceptionPermanently deactivate any open metadata and governance services and unregister from any cohorts.- Throws:
org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException- the supplied userId is not authorized to issue this command.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException- invalid parameter.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorException- unusual state in the admin server.
-
getActiveConfiguration
public org.odpi.openmetadata.adminservices.configuration.properties.OMAGServerConfig getActiveConfiguration() throws org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorExceptionReturn the configuration used for the current active instance of the server. Null is returned if the server instance is not running.- Returns:
- configuration properties used to initialize the server or null if not running
- Throws:
org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException- the supplied userId is not authorized to issue this command.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException- invalid parameter.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorException- unusual state in the admin server.
-
getServerStatus
public org.odpi.openmetadata.adminservices.properties.ServerServicesStatus getServerStatus() throws org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorExceptionReturn the status of a running server (use platform services to find out if the server is running).- Returns:
- status of the server
- Throws:
org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException- the supplied userId is not authorized to issue this command.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException- invalid parameter.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorException- unusual state in the admin server.
-
addOpenMetadataArchiveFile
public void addOpenMetadataArchiveFile(String fileName) throws org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorException Add a new open metadata archive to running repository.- Parameters:
fileName- name of the open metadata archive file.- Throws:
org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException- the supplied userId is not authorized to issue this command.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException- invalid parameter.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorException- unusual state in the admin server.
-
addOpenMetadataArchive
public void addOpenMetadataArchive(org.odpi.openmetadata.frameworks.connectors.properties.beans.Connection connection) throws org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException, org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorException Add a new open metadata archive to running repository.- Parameters:
connection- connection for the open metadata archive.- Throws:
org.odpi.openmetadata.adminservices.ffdc.exception.OMAGNotAuthorizedException- the supplied userId is not authorized to issue this command.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGInvalidParameterException- invalid parameter.org.odpi.openmetadata.adminservices.ffdc.exception.OMAGConfigurationErrorException- unusual state in the admin server.
-