Class IntegrationServiceHandler
java.lang.Object
org.odpi.openmetadata.governanceservers.integrationdaemonservices.handlers.IntegrationServiceHandler
IntegrationServiceHandler provides the support for a specific integration service running in the
integration daemon. This handler is responsible for setting up its connectors and responding to
REST API calls. The management of the threads where the connectors are running is handled by the
IntegrationConnectorHandler.
-
Constructor Summary
ConstructorDescriptionIntegrationServiceHandler
(String localServerName, String localServerUserId, IntegrationServiceConfig serviceConfig, IntegrationContextManager contextManager, AuditLog auditLog) Constructor passes the service config. -
Method Summary
Modifier and TypeMethodDescriptionReturn the context manager for this service.Return the full name of the service.Retrieve the status of this integration service.Create connector handlers for each of the connections listed in the configuration and return them to the caller.void
refreshService
(String connectorName) Refresh all the connectors, or a specific connector if a connector name is supplied in a service.void
restartService
(String connectorName) Restart all the connectors, or a specific connector if a connector name is supplied.
-
Constructor Details
-
IntegrationServiceHandler
public IntegrationServiceHandler(String localServerName, String localServerUserId, IntegrationServiceConfig serviceConfig, IntegrationContextManager contextManager, AuditLog auditLog) Constructor passes the service config. It is just saved at this point. Interesting things start to happen on initialize().- Parameters:
localServerName
- name of the local serverlocalServerUserId
- userId for server requestsserviceConfig
- configuration for this specific integration servicecontextManager
- context manager instance for this integration serviceauditLog
- logging destination
-
-
Method Details
-
getContextManager
Return the context manager for this service. Each integration service has its own implementation.- Returns:
- supplied context manager
-
getIntegrationServiceFullName
Return the full name of the service.- Returns:
- string name
-
initialize
Create connector handlers for each of the connections listed in the configuration and return them to the caller. When the connector handlers are returned, the integration connectors within them are fully initialized and have their context set. They are ready to be called for start() which is done by the integration daemon handler when they are on the correct thread.- Returns:
- list of initialized connection handlers or empty list of no working connectors
-
getIntegrationServiceSummary
Retrieve the status of this integration service.- Returns:
- Status summary for this integration service
-
refreshService
Refresh all the connectors, or a specific connector if a connector name is supplied in a service.- Parameters:
connectorName
- name of a specific connector or null for all connectors- Throws:
InvalidParameterException
- the connector name is not recognized
-
restartService
Restart all the connectors, or a specific connector if a connector name is supplied.- Parameters:
connectorName
- name of a specific connector or null for all connectors- Throws:
InvalidParameterException
- the connector name is not recognized
-