Class AdminServicesRESTClient
java.lang.Object
org.odpi.openmetadata.adminservices.client.rest.AdminServicesRESTClient
AssetOwnerRESTClient is responsible for issuing calls to the Admin Services REST APIs.
-
Constructor Summary
ConstructorDescriptionAdminServicesRESTClient
(String serverName, String serverPlatformURLRoot) Constructor for no authentication.AdminServicesRESTClient
(String serverName, String serverPlatformURLRoot, String userId, String password) Constructor for simple userId and password authentication. -
Method Summary
Modifier and TypeMethodDescriptioncallAccessServicesGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a AccessServicesResponse object.callBasicServerPropertiesGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a BasicServerPropertiesResponse object.callConnectionGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a OCFConnectionResponse object.callDedicatedTopicListGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a DedicatedTopicListResponse object.protected <T> T
callDeleteRESTCall
(String methodName, Class<T> returnClass, String urlTemplate, Object requestBody, Object... params) Issue a DELETE REST call that returns a response object.protected <T> T
callDeleteRESTCallNoParams
(String methodName, Class<T> returnClass, String urlTemplate, Object requestBody) Issue a DELETE REST call that returns a response object.callEngineHostServicesGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a EngineHostServicesResponse object.callEngineServiceConfigGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a EngineServiceConfigResponse object.callGetAllServerConfigurationsRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a OMAGServerConfigsResponse object.protected <T> T
callGetRESTCall
(String methodName, Class<T> returnClass, String urlTemplate, Object... params) Issue a GET REST call that returns a response object.protected <T> T
callGetRESTCallNoParams
(String methodName, Class<T> returnClass, String urlTemplate) Issue a GET REST call that returns a response object.callGUIDGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a GUIDResponse object.callIntegrationGroupsGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a IntegrationServicesResponse object.callIntegrationServiceConfigGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a IntegrationServiceConfigResponse object.callIntegrationServicesGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a IntegrationServicesResponse object.callOMAGServerConfigGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a OMAGServerConfigResponse object.callOMAGServerStatusGetRESTCall
(String methodName, String urlTemplate, Object... params) Deprecated.protected <T> T
callPostRESTCall
(String methodName, Class<T> returnClass, String urlTemplate, Object requestBody, Object... params) Issue a POST REST call that returns a response object.protected <T> T
callPostRESTCallNoParams
(String methodName, Class<T> returnClass, String urlTemplate, Object requestBody) Issue a POST REST call that returns a response object.callRegisteredOMAGServicesGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a RegisteredOMAGServicesResponse object.callServerClassificationGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a ServerTypeClassificationResponse object.callStringGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a StringResponse object.callStringMapGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a StringMapResponse object.callSuccessMessagePostRESTCall
(String methodName, String urlTemplate, Object requestBody, Object... params) Issue a POST REST call that returns a SuccessMessageResponse object.callViewServicesGetRESTCall
(String methodName, String urlTemplate, Object... params) Issue a GET REST call that returns a ViewServicesResponse object.callVoidDeleteRESTCall
(String methodName, String urlTemplate, Object... params) Issue a DELETE REST call that returns a VoidResponse object.callVoidPostRESTCall
(String methodName, String urlTemplate, Object requestBody, Object... params) Issue a POST REST call that returns a VoidResponse object.
-
Constructor Details
-
AdminServicesRESTClient
public AdminServicesRESTClient(String serverName, String serverPlatformURLRoot) throws OMAGInvalidParameterException Constructor for no authentication.- Parameters:
serverName
- name of the OMAG Server to callserverPlatformURLRoot
- URL root of the server platform where the OMAG Server is running.- Throws:
OMAGInvalidParameterException
- there is a problem creating the client-side components to issue any REST API calls.
-
AdminServicesRESTClient
public AdminServicesRESTClient(String serverName, String serverPlatformURLRoot, String userId, String password) throws OMAGInvalidParameterException Constructor for simple userId and password authentication.- Parameters:
serverName
- name of the OMAG Server to callserverPlatformURLRoot
- URL root of the server platform where the OMAG Server is running.userId
- user id for the HTTP requestpassword
- password for the HTTP request- Throws:
OMAGInvalidParameterException
- there is a problem creating the client-side components to issue any REST API calls.
-
-
Method Details
-
callVoidPostRESTCall
public VoidResponse callVoidPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a POST REST call that returns a VoidResponse object. This is typically a create- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.requestBody
- request body for the request.params
- a list of parameters that are slotted into the url template.- Returns:
- VoidResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callVoidDeleteRESTCall
public VoidResponse callVoidDeleteRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a DELETE REST call that returns a VoidResponse object. This is typically a delete- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- VoidResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callSuccessMessagePostRESTCall
public SuccessMessageResponse callSuccessMessagePostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a POST REST call that returns a SuccessMessageResponse object. This is typically a server start.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.requestBody
- request body for the request.params
- a list of parameters that are slotted into the url template.- Returns:
- SuccessMessageResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callStringGetRESTCall
public StringResponse callStringGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a StringResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- StringResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callBasicServerPropertiesGetRESTCall
public BasicServerPropertiesResponse callBasicServerPropertiesGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a BasicServerPropertiesResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- BasicServerPropertiesResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callDedicatedTopicListGetRESTCall
public DedicatedTopicListResponse callDedicatedTopicListGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a DedicatedTopicListResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- DedicatedTopicListResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callGUIDGetRESTCall
public GUIDResponse callGUIDGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a GUIDResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- GUIDResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callStringMapGetRESTCall
public StringMapResponse callStringMapGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a StringMapResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- StringMapResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callOMAGServerConfigGetRESTCall
public OMAGServerConfigResponse callOMAGServerConfigGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a OMAGServerConfigResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- OMAGServerConfigResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callGetAllServerConfigurationsRESTCall
public OMAGServerConfigsResponse callGetAllServerConfigurationsRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a OMAGServerConfigsResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- OMAGServerConfigResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callOMAGServerStatusGetRESTCall
@Deprecated public OMAGServerStatusResponse callOMAGServerStatusGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Deprecated.Issue a GET REST call that returns a OMAGServerStatusResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- OMAGServerStatusResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callConnectionGetRESTCall
public ConnectionResponse callConnectionGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a OCFConnectionResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- OCFConnectionResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callServerClassificationGetRESTCall
public ServerTypeClassificationResponse callServerClassificationGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a ServerTypeClassificationResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- ServerTypeClassificationResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callRegisteredOMAGServicesGetRESTCall
public RegisteredOMAGServicesResponse callRegisteredOMAGServicesGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a RegisteredOMAGServicesResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- RegisteredOMAGServicesResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callAccessServicesGetRESTCall
public AccessServicesResponse callAccessServicesGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a AccessServicesResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- AccessServicesResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callEngineHostServicesGetRESTCall
public EngineHostServicesResponse callEngineHostServicesGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a EngineHostServicesResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- EngineHostServicesResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callEngineServiceConfigGetRESTCall
public EngineServiceConfigResponse callEngineServiceConfigGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a EngineServiceConfigResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- EngineServiceConfigResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callIntegrationServicesGetRESTCall
public IntegrationServicesResponse callIntegrationServicesGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a IntegrationServicesResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- IntegrationServicesResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callIntegrationServiceConfigGetRESTCall
public IntegrationServiceConfigResponse callIntegrationServiceConfigGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a IntegrationServiceConfigResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- IntegrationServiceConfigResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callIntegrationGroupsGetRESTCall
public IntegrationGroupsResponse callIntegrationGroupsGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a IntegrationServicesResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- IntegrationServicesResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callViewServicesGetRESTCall
public ViewServicesResponse callViewServicesGetRESTCall(String methodName, String urlTemplate, Object... params) throws OMAGInvalidParameterException, OMAGNotAuthorizedException, OMAGConfigurationErrorException Issue a GET REST call that returns a ViewServicesResponse object.- Parameters:
methodName
- name of the method being called.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- ViewServicesResponse
- Throws:
OMAGInvalidParameterException
- one of the parameters is invalid.OMAGNotAuthorizedException
- the user is not authorized to make this request.OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callGetRESTCallNoParams
protected <T> T callGetRESTCallNoParams(String methodName, Class<T> returnClass, String urlTemplate) throws OMAGConfigurationErrorException Issue a GET REST call that returns a response object.- Type Parameters:
T
- return type- Parameters:
methodName
- name of the method being called.returnClass
- class of the response object.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.- Returns:
- response object
- Throws:
OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callGetRESTCall
protected <T> T callGetRESTCall(String methodName, Class<T> returnClass, String urlTemplate, Object... params) throws OMAGConfigurationErrorException Issue a GET REST call that returns a response object.- Type Parameters:
T
- return type- Parameters:
methodName
- name of the method being called.returnClass
- class of the response object.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.params
- a list of parameters that are slotted into the url template.- Returns:
- response object
- Throws:
OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callPostRESTCallNoParams
protected <T> T callPostRESTCallNoParams(String methodName, Class<T> returnClass, String urlTemplate, Object requestBody) throws OMAGConfigurationErrorException Issue a POST REST call that returns a response object. This is typically a create, update, or find with complex parameters.- Type Parameters:
T
- return type- Parameters:
methodName
- name of the method being called.returnClass
- class of the response object.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.requestBody
- request body for the request.- Returns:
- response object
- Throws:
OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callPostRESTCall
protected <T> T callPostRESTCall(String methodName, Class<T> returnClass, String urlTemplate, Object requestBody, Object... params) throws OMAGConfigurationErrorException Issue a POST REST call that returns a response object. This is typically a create, update, or find with complex parameters.- Type Parameters:
T
- return type- Parameters:
methodName
- name of the method being called.returnClass
- class of the response object.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.requestBody
- request body for the request.params
- a list of parameters that are slotted into the url template.- Returns:
- response object
- Throws:
OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callDeleteRESTCallNoParams
protected <T> T callDeleteRESTCallNoParams(String methodName, Class<T> returnClass, String urlTemplate, Object requestBody) throws OMAGConfigurationErrorException Issue a DELETE REST call that returns a response object.- Type Parameters:
T
- return type- Parameters:
methodName
- name of the method being called.returnClass
- class of the response object.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.requestBody
- request body for the request.- Returns:
- response object
- Throws:
OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-
callDeleteRESTCall
protected <T> T callDeleteRESTCall(String methodName, Class<T> returnClass, String urlTemplate, Object requestBody, Object... params) throws OMAGConfigurationErrorException Issue a DELETE REST call that returns a response object.- Type Parameters:
T
- return type- Parameters:
methodName
- name of the method being called.returnClass
- class of the response object.urlTemplate
- template of the URL for the REST API call with place-holders for the parameters.requestBody
- request body for the request.params
- a list of parameters that are slotted into the url template.- Returns:
- response object
- Throws:
OMAGConfigurationErrorException
- something went wrong with the REST call stack.
-