@Tracked(value=TRACE) @Activity(value="Multi-REST Service Adapter", category=AdapterActivity.class, icon="com.centurylink.mdw.base/adapter.png", pagelet="com.centurylink.mdw.base/multiRest.pagelet") public class MultiRestServiceAdapter extends RestServiceAdapter
AUTH_APP_ID, AUTH_PASSWORD, AUTH_PROVIDER, AUTH_USER, ENDPOINT_URI, HEADERS_VARIABLE, HTTP_METHOD, REQUEST_VARIABLECONNECT_TIMEOUT, DEFAULT_ERROR_HTTP_CODE, DEFAULT_RETRY_HTTP_CODE, ERROR_HTTP_CODES, PROP_PASS, PROP_USER, READ_TIMEOUT, RETRY_HTTP_CODESDISABLED, GROOVY, JAVA_EL, JAVASCRIPT, logger, OUTPUTDOCSCOMPCODE_AUTO_RETRY, DEFAULT_STUBBER_PORT, DEFAULT_STUBBER_TIMEOUT, DO_LOGGING, MAKE_ACTUAL_CALL, PROP_MAX_TRIES, PROP_RETRY_INTERVAL, PROP_SYNCHRONOUS_RESPONSE, PROP_TIMEOUT, REQUEST_XSD, RESPONSE_VARIABLE, RESPONSE_XSD| Constructor and Description |
|---|
MultiRestServiceAdapter() |
| Modifier and Type | Method and Description |
|---|---|
protected java.util.List<java.lang.Object> |
getConnectionObjs() |
protected java.util.List<java.lang.String> |
getEndpointUris()
Returns the endpoint URLs for the RESTful service.
|
java.lang.String |
invoke(java.lang.Object conn,
java.lang.String request,
int timeout,
java.util.Map<java.lang.String,java.lang.String> headers)
Invokes the RESTful service by submitting an HTTP requests against the configured
endpoint URIs.
|
java.lang.Object |
openConnection()
Open connection
|
java.lang.Object |
openConnection(java.lang.String endpointUri)
Returns an HttpConnection based on the configured endpoint, which
includes the resource path.
|
getAdapterInvocationErrorMessage, getAuthProvider, getEndpointUri, getHttpHelper, getHttpMethod, getRequestData, getRequestHeaders, getRequestMeta, getRequestParameters, getResponseHeaders, getResponseMeta, getStubRequest, getUrlEncoding, invoke, logRequest, openConnection, openConnection, performHttpAction, setResponseHeaderscanBeAsynchronous, canBeSynchronous, closeConnection, getConnectTimeout, getReadTimeout, getResponse, init, setRequestHeadersdirectInvoke, doInvoke, doLogging, execute, executePostScript, executePreScript, filterStubResponse, getAttribute, getErrorCode, getMaxTries, getRetryInterval, getStubbedResponse, getStubResponse, getTimeoutForResponse, handleConnectionException, handleException, handleRetry, hasPostScript, hasPreScript, isRetryable, isStubMode, isSynchronous, logRequest, logResponse, logResponse, onFailure, onSuccess, populateResponseVariableexecutecreateDocument, createDocument, createDocument, createDocument, evaluateExpression, executeScript, getActivityId, getActivityInstance, getActivityInstanceId, getActivityName, getAttribute, getAttribute, getAttribute, getAttribute, getAttributes, getAttributeValue, getAttributeValueSmart, getDocument, getDocumentContent, getDocumentForUpdate, getDocumentType, getEngine, getExternalEventInstanceDetails, getLogger, getMainProcessDefinition, getMasterRequestId, getOutputDocuments, getPackage, getParameterId, getParameters, getParameterStringValue, getParameterType, getParameterValue, getPerformanceLevel, getProcessDefinition, getProcessId, getProcessInstance, getProcessInstanceId, getProcessInstanceOwner, getProcessInstanceOwnerId, getProperty, getRequiredAttribute, getRequiredVariableValue, getReturnCode, getReturnMessage, getRuntimeContext, getScriptEvaluator, getScriptExecClassName, getScriptExecutor, getValue, getValues, getValueSmart, getVariableInstance, getVariableValue, getVariableValueSmart, getWorkTransitionInstanceId, initialize, isDisabled, isLogDebugEnabled, isLogInfoEnabled, isOutputDocument, lockActivityInstance, lockProcessInstance, logdebug, logDebug, logError, logError, logexception, loginfo, logInfo, logsevere, logwarn, logWarn, prepare, setOutputDocuments, setParameterValue, setParameterValueAsDocument, setParameterValues, setProcessInstanceCompletionCode, setReturnCode, setReturnMessage, setValue, setVariableValue, setVariableValue, startTransaction, stopTransaction, translatePlaceHolder, updateDocumentContent, updateDocumentInfo, updateDocumentInfo, valueIsJavaExpression, valueIsVariableclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitexecutepublic java.lang.Object openConnection()
TextAdapteropenConnection in interface TextAdapteropenConnection in class RestServiceAdapterpublic java.lang.Object openConnection(java.lang.String endpointUri)
throws ConnectionException
ConnectionExceptionprotected java.util.List<java.lang.Object> getConnectionObjs()
throws ConnectionException,
AdapterException
ConnectionExceptionAdapterExceptionprotected java.util.List<java.lang.String> getEndpointUris()
throws AdapterException
BaseActivity.getAttribute(String).ActivityExceptionAdapterExceptionpublic java.lang.String invoke(java.lang.Object conn,
java.lang.String request,
int timeout,
java.util.Map<java.lang.String,java.lang.String> headers)
throws ConnectionException,
AdapterException
invoke in interface TextAdapterinvoke in class RestServiceAdapterconn - the object returned by openConnection()
and is typically the adapter activity instance itself.request - request contenttimeout - time out in seconds. Ignored if no response is expected.headers - protocol request data, e.g. correlation IDConnectionExceptionAdapterExceptionTextAdapter.invoke(java.lang.Object, java.lang.String, int, java.util.Map)Copyright © 2019 CenturyLink, Inc.