Class OpenMetadataStoreRESTClient
- java.lang.Object
-
- org.odpi.openmetadata.commonservices.ffdc.rest.FFDCRESTClientBase
-
- org.odpi.openmetadata.commonservices.ffdc.rest.FFDCRESTClient
-
- org.odpi.openmetadata.commonservices.ocf.metadatamanagement.client.OCFRESTClient
-
- org.odpi.openmetadata.commonservices.gaf.client.rest.OpenMetadataStoreRESTClient
-
public class OpenMetadataStoreRESTClient extends OCFRESTClient
OpenMetadataStoreRESTClient is responsible for issuing calls to the OMAS REST APIs.
-
-
Field Summary
-
Fields inherited from class org.odpi.openmetadata.commonservices.ffdc.rest.FFDCRESTClientBase
auditLog, exceptionHandler, serverName, serverPlatformURLRoot
-
-
Constructor Summary
Constructors Constructor Description OpenMetadataStoreRESTClient(String serverName, String serverPlatformURLRoot)Constructor for no authentication.OpenMetadataStoreRESTClient(String serverName, String serverPlatformURLRoot, String userId, String password)Constructor for simple userId and password authentication.OpenMetadataStoreRESTClient(String serverName, String serverPlatformURLRoot, String userId, String password, AuditLog auditLog)Constructor for simple userId and password authentication with audit log.OpenMetadataStoreRESTClient(String serverName, String serverPlatformURLRoot, AuditLog auditLog)Constructor for no authentication with audit log.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BooleanResponsecallBooleanGetRESTCall(String methodName, String urlTemplate, Object... params)Issue a GET REST call that returns a BooleanResponse object.ElementHeaderResponsecallElementHeaderPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params)Issue a POST REST call that returns a ElementHeaderResponse object.ElementHeadersResponsecallElementHeadersPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params)Issue a POST REST call that returns a ElementHeadersResponse object.OpenMetadataElementResponsecallOpenMetadataElementGetRESTCall(String methodName, String urlTemplate, Object... params)Issue a GET REST call that returns a OpenMetadataElementResponse object.OpenMetadataElementResponsecallOpenMetadataElementPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params)Issue a POST REST call that returns a OpenMetadataElementResponse object.OpenMetadataElementsResponsecallOpenMetadataElementsPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params)Issue a POST REST call that returns a OpenMetadataElementsResponse object.RelatedMetadataElementListResponsecallRelatedMetadataElementListGetRESTCall(String methodName, String urlTemplate, Object... params)Issue a GET REST call that returns a RelatedMetadataElementListResponse object.RelatedMetadataElementListResponsecallRelatedMetadataElementListPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params)Issue a POST REST call that returns a RelatedMetadataElementListResponse object.RelatedMetadataElementsListResponsecallRelatedMetadataElementsListGetRESTCall(String methodName, String urlTemplate, Object... params)Issue a GET REST call that returns a RelatedMetadataElementsListResponse object.RelatedMetadataElementsListResponsecallRelatedMetadataElementsListPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params)Issue a POST REST call that returns a RelatedMetadataElementsListResponse object.TranslationDetailResponsecallTranslationDetailGetRESTCall(String methodName, String urlTemplate, Object... params)Issue a GET REST call that returns a TranslationDetailResponse object.TranslationListResponsecallTranslationListGetRESTCall(String methodName, String urlTemplate, Object... params)Issue a GET REST call that returns a TranslationListResponse object.ValidMetadataValueResponsecallValidMetadataValueGetRESTCall(String methodName, String urlTemplate, Object... params)Issue a GET REST call that returns a ValidMetadataValueResponse object.ValidMetadataValueListResponsecallValidMetadataValueListGetRESTCall(String methodName, String urlTemplate, Object... params)Issue a GET REST call that returns a ValidMetadataValueListResponse object.-
Methods inherited from class org.odpi.openmetadata.commonservices.ocf.metadatamanagement.client.OCFRESTClient
callOCFAssetGetRESTCall, callOCFAssetsGetRESTCall, callOCFAssetsPostRESTCall, callOCFConnectionGetRESTCall, callOCFTagGetRESTCall, callOCFTagListGetRESTCall, callOCFTagListPostRESTCall
-
Methods inherited from class org.odpi.openmetadata.commonservices.ffdc.rest.FFDCRESTClient
callCountGetRESTCall, callGUIDGetRESTCall, callGUIDListGetRESTCall, callGUIDListPostRESTCall, callGUIDPostRESTCall, callNameListGetRESTCall, callOCFConnectorTypeGetRESTCall, callStringMapGetRESTCall, callVoidGetRESTCall, callVoidPostRESTCall
-
Methods inherited from class org.odpi.openmetadata.commonservices.ffdc.rest.FFDCRESTClientBase
callDeleteRESTCall, callDeleteRESTCall, callGetRESTCall, callGetRESTCall, callGetRESTCallNoParams, callPostRESTCall, callPostRESTCall, callPostRESTCallNoParams, callPutRESTCall, callPutRESTCall
-
-
-
-
Constructor Detail
-
OpenMetadataStoreRESTClient
public OpenMetadataStoreRESTClient(String serverName, String serverPlatformURLRoot, AuditLog auditLog) throws InvalidParameterException
Constructor for no authentication with audit log.- Parameters:
serverName- name of the OMAG Server to callserverPlatformURLRoot- URL root of the server manager where the OMAG Server is running.auditLog- destination for log messages.- Throws:
InvalidParameterException- there is a problem creating the client-side components to issue any REST API calls.
-
OpenMetadataStoreRESTClient
public OpenMetadataStoreRESTClient(String serverName, String serverPlatformURLRoot) throws InvalidParameterException
Constructor for no authentication.- Parameters:
serverName- name of the OMAG Server to callserverPlatformURLRoot- URL root of the server manager where the OMAG Server is running.- Throws:
InvalidParameterException- there is a problem creating the client-side components to issue any REST API calls.
-
OpenMetadataStoreRESTClient
public OpenMetadataStoreRESTClient(String serverName, String serverPlatformURLRoot, String userId, String password, AuditLog auditLog) throws InvalidParameterException
Constructor for simple userId and password authentication with audit log.- Parameters:
serverName- name of the OMAG Server to callserverPlatformURLRoot- URL root of the server manager where the OMAG Server is running.userId- user id for the HTTP requestpassword- password for the HTTP requestauditLog- destination for log messages.- Throws:
InvalidParameterException- there is a problem creating the client-side components to issue any REST API calls.
-
OpenMetadataStoreRESTClient
public OpenMetadataStoreRESTClient(String serverName, String serverPlatformURLRoot, String userId, String password) throws InvalidParameterException
Constructor for simple userId and password authentication.- Parameters:
serverName- name of the OMAG Server to callserverPlatformURLRoot- URL root of the server manager where the OMAG Server is running.userId- user id for the HTTP requestpassword- password for the HTTP request- Throws:
InvalidParameterException- there is a problem creating the client-side components to issue any REST API calls.
-
-
Method Detail
-
callElementHeaderPostRESTCall
public ElementHeaderResponse callElementHeaderPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a POST REST call that returns a ElementHeaderResponse 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.requestBody- object that passes additional parametersparams- a list of parameters that are slotted into the url template.- Returns:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callElementHeadersPostRESTCall
public ElementHeadersResponse callElementHeadersPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a POST REST call that returns a ElementHeadersResponse 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.requestBody- object that passes additional parametersparams- a list of parameters that are slotted into the url template.- Returns:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callOpenMetadataElementsPostRESTCall
public OpenMetadataElementsResponse callOpenMetadataElementsPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a POST REST call that returns a OpenMetadataElementsResponse 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.requestBody- object that passes additional parametersparams- a list of parameters that are slotted into the url template.- Returns:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callOpenMetadataElementPostRESTCall
public OpenMetadataElementResponse callOpenMetadataElementPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a POST REST call that returns a OpenMetadataElementResponse 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.requestBody- object that passes additional parametersparams- a list of parameters that are slotted into the url template.- Returns:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callOpenMetadataElementGetRESTCall
public OpenMetadataElementResponse callOpenMetadataElementGetRESTCall(String methodName, String urlTemplate, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a GET REST call that returns a OpenMetadataElementResponse 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:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callRelatedMetadataElementsListPostRESTCall
public RelatedMetadataElementsListResponse callRelatedMetadataElementsListPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a POST REST call that returns a RelatedMetadataElementsListResponse 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.requestBody- object that passes additional parametersparams- a list of parameters that are slotted into the url template.- Returns:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callRelatedMetadataElementsListGetRESTCall
public RelatedMetadataElementsListResponse callRelatedMetadataElementsListGetRESTCall(String methodName, String urlTemplate, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a GET REST call that returns a RelatedMetadataElementsListResponse 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:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callRelatedMetadataElementListPostRESTCall
public RelatedMetadataElementListResponse callRelatedMetadataElementListPostRESTCall(String methodName, String urlTemplate, Object requestBody, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a POST REST call that returns a RelatedMetadataElementListResponse 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.requestBody- object that passes additional parametersparams- a list of parameters that are slotted into the url template.- Returns:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callRelatedMetadataElementListGetRESTCall
public RelatedMetadataElementListResponse callRelatedMetadataElementListGetRESTCall(String methodName, String urlTemplate, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a GET REST call that returns a RelatedMetadataElementListResponse 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:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callTranslationDetailGetRESTCall
public TranslationDetailResponse callTranslationDetailGetRESTCall(String methodName, String urlTemplate, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a GET REST call that returns a TranslationDetailResponse 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:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callTranslationListGetRESTCall
public TranslationListResponse callTranslationListGetRESTCall(String methodName, String urlTemplate, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a GET REST call that returns a TranslationListResponse 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:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callValidMetadataValueListGetRESTCall
public ValidMetadataValueListResponse callValidMetadataValueListGetRESTCall(String methodName, String urlTemplate, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a GET REST call that returns a ValidMetadataValueListResponse 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:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callValidMetadataValueGetRESTCall
public ValidMetadataValueResponse callValidMetadataValueGetRESTCall(String methodName, String urlTemplate, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a GET REST call that returns a ValidMetadataValueResponse 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:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
callBooleanGetRESTCall
public BooleanResponse callBooleanGetRESTCall(String methodName, String urlTemplate, Object... params) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Issue a GET REST call that returns a BooleanResponse 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:
- response object
- Throws:
InvalidParameterException- one of the parameters is invalid.UserNotAuthorizedException- the user is not authorized to make this request.PropertyServerException- the repository is not available or not working properly.
-
-