public interface Connector extends Plugin
Modifier and Type | Method and Description |
---|---|
void |
addStateListener(ConnectorStateListener listener)
Listen for state change events from the connector.
|
void |
destroy()
Destroys and cleanups connector threads and tokens.
|
String |
getStatus()
Returns a summary of the the current state of the connector.
|
String |
getVersion()
Gets version.
|
ApiException |
handleException(Throwable t)
Used by ConnectorProxyInvocationHandler in order to map exceptions thrown by connector implementation
classes into exceptions as exposed by the published SDK.
|
void |
init(String encryptedCredentials,
ConnectorInfo connectorInfo)
Initializes the connector with a set of credentials and configuration data.
|
void |
init(String encryptedCredentials,
ConnectorInfo connectorInfo,
ConnectorConfiguration connectionConfig)
Initializes the connector with a set of credentials, connector information and configuration data.
|
void |
removeStateListener(ConnectorStateListener listener)
Stop listening for state change events
|
void |
updateAndReloadConfigAsync(String connectionDataString,
ConnectorInfo connectorInfo,
ConnectorConfiguration connectionConfig,
ReloadListener reloadListener)
Update and reload the configuration.
|
void |
updateAndReloadConfigSync(String connectionDataString,
ConnectorInfo connectorInfo,
ConnectorConfiguration connectionConfig)
Update and reload the configuration.
|
void init(String encryptedCredentials, ConnectorInfo connectorInfo)
encryptedCredentials
- the encrypted credentialsconnectorInfo
- the connector infovoid init(String encryptedCredentials, ConnectorInfo connectorInfo, ConnectorConfiguration connectionConfig)
encryptedCredentials
- a JSON string containing connection dataconnectorInfo
- used to describe the state of the connector. This state will be used by the Atlas dashboard
to display the state of this connector.connectionConfig
- configure how connections are made to the context service including retries and
time outsvoid updateAndReloadConfigAsync(String connectionDataString, ConnectorInfo connectorInfo, ConnectorConfiguration connectionConfig, ReloadListener reloadListener)
connectionDataString
- connection dataconnectorInfo
- connectorconnectionConfig
- configuration parametersreloadListener
- listener that will receive a notification when the reload attempt completes (successfully or not).
set to null if no callback is desiredvoid updateAndReloadConfigSync(String connectionDataString, ConnectorInfo connectorInfo, ConnectorConfiguration connectionConfig)
connectionDataString
- connection dataconnectorInfo
- connectorconnectionConfig
- configuration parametersvoid destroy()
void addStateListener(ConnectorStateListener listener)
listener
- callback for state change eventsConnectorState
void removeStateListener(ConnectorStateListener listener)
listener
- the listener to removeString getVersion()
ApiException handleException(Throwable t)
t
- Exception thrown by the connector implementationString getStatus()
Copyright © 2018. All rights reserved.