Class GovernanceOfficerResource
java.lang.Object
org.odpi.openmetadata.viewservices.governanceofficer.server.spring.GovernanceOfficerResource
@RestController
@RequestMapping("/servers/{serverName}/api/open-metadata/{urlMarker}")
public class GovernanceOfficerResource
extends Object
The GovernanceOfficerResource provides part of the server-side implementation of the Governance Officer OMVS.
=
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionattachSupportingDefinition
(String serverName, String urlMarker, String governanceDefinitionOneGUID, String relationshipTypeName, String governanceDefinitionTwoGUID, SupportingDefinitionRequestBody requestBody) Attach a supporting governance definition.createGovernanceDefinition
(String serverName, String urlMarker, NewGovernanceDefinitionRequestBody requestBody) Create a governance definition.createGovernanceDefinitionFromTemplate
(String serverName, String urlMarker, TemplateRequestBody requestBody) Create a new metadata element to represent a governance definition using an existing metadata element as a template.deleteGovernanceDefinition
(String serverName, String urlMarker, String governanceDefinitionGUID, boolean cascadedDelete, MetadataSourceRequestBody requestBody) Delete a governance definition.detachDefinitionImplementation
(String serverName, String urlMarker, String technicalControlGUID, String relationshipTypeName, String implementationGUID, MetadataSourceRequestBody requestBody) Detach a governance definition from its implementation.detachPeerDefinitions
(String serverName, String urlMarker, String governanceDefinitionOneGUID, String relationshipTypeName, String governanceDefinitionTwoGUID, MetadataSourceRequestBody requestBody) Detach a governance definition from one of its peers.detachSupportingDefinition
(String serverName, String urlMarker, String governanceDefinitionOneGUID, String relationshipTypeName, String governanceDefinitionTwoGUID, MetadataSourceRequestBody requestBody) Detach a governance definition from a supporting governance definition.findGovernanceDefinitions
(String serverName, String urlMarker, int startFrom, int pageSize, boolean startsWith, boolean endsWith, boolean ignoreCase, FilterRequestBody requestBody) Retrieve the list of governance definition metadata elements that contain the search string.getGovernanceDefinitionByGUID
(String serverName, String urlMarker, String governanceDefinitionGUID, AnyTimeRequestBody requestBody) Return the properties of a specific governance definition.getGovernanceDefinitionInContext
(String serverName, String urlMarker, String governanceDefinitionGUID, int startFrom, int pageSize, ResultsRequestBody requestBody) Return the governance definition associated with a unique identifier and the other governance definitions linked to it.getGovernanceDefinitionsByName
(String serverName, String urlMarker, int startFrom, int pageSize, FilterRequestBody requestBody) Returns the list of governance definitions with a particular name.linkDefinitionImplementation
(String serverName, String urlMarker, String technicalControlGUID, String relationshipTypeName, String implementationGUID, GovernanceImplementationRequestBody requestBody) Attach a governance definition to its implementation.linkPeerDefinitions
(String serverName, String urlMarker, String governanceDefinitionOneGUID, String relationshipTypeName, String governanceDefinitionTwoGUID, PeerDefinitionRequestBody requestBody) Attach two peer governance definitions.updateGovernanceDefinition
(String serverName, String urlMarker, String governanceDefinitionGUID, boolean replaceAllProperties, UpdateGovernanceDefinitionRequestBody requestBody) Update the properties of a governance definition.updateGovernanceDefinitionStatus
(String serverName, String urlMarker, String governanceDefinitionGUID, GovernanceDefinitionStatusRequestBody requestBody) Update the status of a governance definition.
-
Constructor Details
-
GovernanceOfficerResource
public GovernanceOfficerResource()Default constructor
-
-
Method Details
-
createGovernanceDefinition
@PostMapping(path="/governance-definitions") public GUIDResponse createGovernanceDefinition(@PathVariable String serverName, @PathVariable String urlMarker, @RequestBody(required=false) NewGovernanceDefinitionRequestBody requestBody) Create a governance definition.- Parameters:
serverName
- name of called server.urlMarker
- view service URL markerrequestBody
- properties for the governance definition.- Returns:
- unique identifier of the newly created element InvalidParameterException one of the parameters is invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
createGovernanceDefinitionFromTemplate
@PostMapping(path="/governance-definitions/from-template") public GUIDResponse createGovernanceDefinitionFromTemplate(@PathVariable String serverName, @PathVariable String urlMarker, @RequestBody(required=false) TemplateRequestBody requestBody) Create a new metadata element to represent a governance definition using an existing metadata element as a template. The template defines additional classifications and relationships that should be added to the new element.- Parameters:
serverName
- calling userurlMarker
- view service URL markerrequestBody
- properties that override the template- Returns:
- unique identifier of the new metadata element InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException there is a problem reported in the open metadata server(s)
-
updateGovernanceDefinition
@PostMapping(path="/governance-definitions/{governanceDefinitionGUID}/update") public VoidResponse updateGovernanceDefinition(@PathVariable String serverName, @PathVariable String urlMarker, @PathVariable String governanceDefinitionGUID, @RequestParam(required=false,defaultValue="false") boolean replaceAllProperties, @RequestBody(required=false) UpdateGovernanceDefinitionRequestBody requestBody) Update the properties of a governance definition.- Parameters:
serverName
- name of called server.urlMarker
- view service URL markergovernanceDefinitionGUID
- unique identifier of the governance definition (returned from create)replaceAllProperties
- flag to indicate whether to completely replace the existing properties with the new properties, or just update the individual properties specified on the request.requestBody
- properties for the new element.- Returns:
- void or InvalidParameterException one of the parameters is invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
updateGovernanceDefinitionStatus
@PostMapping(path="/governance-definitions/{governanceDefinitionGUID}/update-status") public VoidResponse updateGovernanceDefinitionStatus(@PathVariable String serverName, @PathVariable String urlMarker, @PathVariable String governanceDefinitionGUID, @RequestBody(required=false) GovernanceDefinitionStatusRequestBody requestBody) Update the status of a governance definition.- Parameters:
serverName
- name of called server.urlMarker
- view service URL markergovernanceDefinitionGUID
- unique identifier of the governance definition (returned from create)requestBody
- properties for the new element.- Returns:
- void or InvalidParameterException one of the parameters is invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
linkPeerDefinitions
@PostMapping(path="/governance-definitions/{governanceDefinitionOneGUID}/peer-definitions/{relationshipTypeName}/{governanceDefinitionTwoGUID}/attach") public VoidResponse linkPeerDefinitions(@PathVariable String serverName, @PathVariable String urlMarker, @PathVariable String governanceDefinitionOneGUID, @PathVariable String relationshipTypeName, @PathVariable String governanceDefinitionTwoGUID, @RequestBody(required=false) PeerDefinitionRequestBody requestBody) Attach two peer governance definitions.- Parameters:
serverName
- name of called serverurlMarker
- view service URL markergovernanceDefinitionOneGUID
- unique identifier of the first governance definitiongovernanceDefinitionTwoGUID
- unique identifier of the second governance definitionrelationshipTypeName
- name of the relationship to userequestBody
- description of the relationship.- Returns:
- void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
detachPeerDefinitions
@PostMapping(path="/governance-definitions/{governanceDefinitionOneGUID}/peer-definitions/{relationshipTypeName}/{governanceDefinitionTwoGUID}/detach") public VoidResponse detachPeerDefinitions(@PathVariable String serverName, @PathVariable String urlMarker, @PathVariable String governanceDefinitionOneGUID, @PathVariable String relationshipTypeName, @PathVariable String governanceDefinitionTwoGUID, @RequestBody(required=false) MetadataSourceRequestBody requestBody) Detach a governance definition from one of its peers.- Parameters:
serverName
- name of called serverurlMarker
- view service URL markergovernanceDefinitionOneGUID
- unique identifier of the first governance definitiongovernanceDefinitionTwoGUID
- unique identifier of the second governance definitionrelationshipTypeName
- name of the relationship to userequestBody
- description of the relationship.- Returns:
- void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
attachSupportingDefinition
@PostMapping(path="/governance-definitions/{governanceDefinitionOneGUID}/supporting-definitions/{relationshipTypeName}/{governanceDefinitionTwoGUID}/attach") public VoidResponse attachSupportingDefinition(@PathVariable String serverName, @PathVariable String urlMarker, @PathVariable String governanceDefinitionOneGUID, @PathVariable String relationshipTypeName, @PathVariable String governanceDefinitionTwoGUID, @RequestBody(required=false) SupportingDefinitionRequestBody requestBody) Attach a supporting governance definition.- Parameters:
serverName
- name of called serverurlMarker
- view service URL markergovernanceDefinitionOneGUID
- unique identifier of the first governance definitiongovernanceDefinitionTwoGUID
- unique identifier of the second governance definitionrelationshipTypeName
- name of the relationship to userequestBody
- description of the relationship.- Returns:
- void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
detachSupportingDefinition
@PostMapping(path="/governance-definitions/{governanceDefinitionOneGUID}/supporting-definitions/{relationshipTypeName}/{governanceDefinitionTwoGUID}/detach") public VoidResponse detachSupportingDefinition(@PathVariable String serverName, @PathVariable String urlMarker, @PathVariable String governanceDefinitionOneGUID, @PathVariable String relationshipTypeName, @PathVariable String governanceDefinitionTwoGUID, @RequestBody(required=false) MetadataSourceRequestBody requestBody) Detach a governance definition from a supporting governance definition.- Parameters:
serverName
- name of called serverurlMarker
- view service URL markergovernanceDefinitionOneGUID
- unique identifier of the first governance definitiongovernanceDefinitionTwoGUID
- unique identifier of the second governance definitionrelationshipTypeName
- name of the relationship to userequestBody
- description of the relationship.- Returns:
- void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
linkDefinitionImplementation
@PostMapping(path="/governance-definitions/{technicalControlGUID}/governance-implementation/{relationshipTypeName}/{implementationGUID}/attach") public VoidResponse linkDefinitionImplementation(@PathVariable String serverName, @PathVariable String urlMarker, @PathVariable String technicalControlGUID, @PathVariable String relationshipTypeName, @PathVariable String implementationGUID, @RequestBody(required=false) GovernanceImplementationRequestBody requestBody) Attach a governance definition to its implementation.- Parameters:
serverName
- name of called serverurlMarker
- view service URL markertechnicalControlGUID
- unique identifier of the first governance definitionimplementationGUID
- unique identifier of the second governance definitionrelationshipTypeName
- name of the relationship to userequestBody
- description of the relationship.- Returns:
- void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
detachDefinitionImplementation
@PostMapping(path="/governance-definitions/{technicalControlGUID}/governance-implementation/{relationshipTypeName}/{implementationGUID}/detach") public VoidResponse detachDefinitionImplementation(@PathVariable String serverName, @PathVariable String urlMarker, @PathVariable String technicalControlGUID, @PathVariable String relationshipTypeName, @PathVariable String implementationGUID, @RequestBody(required=false) MetadataSourceRequestBody requestBody) Detach a governance definition from its implementation.- Parameters:
serverName
- name of called serverurlMarker
- view service URL markertechnicalControlGUID
- unique identifier of the first governance definitionimplementationGUID
- unique identifier of the second governance definitionrelationshipTypeName
- name of the relationship to userequestBody
- description of the relationship.- Returns:
- void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
deleteGovernanceDefinition
@PostMapping(path="/governance-definitions/{governanceDefinitionGUID}/delete") public VoidResponse deleteGovernanceDefinition(@PathVariable String serverName, @PathVariable String urlMarker, @PathVariable String governanceDefinitionGUID, @RequestParam(required=false,defaultValue="false") boolean cascadedDelete, @RequestBody(required=false) MetadataSourceRequestBody requestBody) Delete a governance definition.- Parameters:
serverName
- name of called serverurlMarker
- view service URL markergovernanceDefinitionGUID
- unique identifier of the element to deletecascadedDelete
- can governance definitions be deleted if data fields are attached?requestBody
- description of the relationship.- Returns:
- void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
-
getGovernanceDefinitionsByName
@PostMapping(path="/governance-definitions/by-name") public GovernanceDefinitionsResponse getGovernanceDefinitionsByName(@PathVariable String serverName, @PathVariable String urlMarker, @RequestParam(required=false,defaultValue="0") int startFrom, @RequestParam(required=false,defaultValue="0") int pageSize, @RequestBody(required=false) FilterRequestBody requestBody) Returns the list of governance definitions with a particular name.- Parameters:
serverName
- name of the service to route the request tourlMarker
- view service URL markerstartFrom
- paging start pointpageSize
- maximum results that can be returnedrequestBody
- string to find in the properties- Returns:
- list of matching metadata elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException there is a problem reported in the open metadata server(s)
-
findGovernanceDefinitions
@PostMapping(path="/governance-definitions/by-search-string") public GovernanceDefinitionsResponse findGovernanceDefinitions(@PathVariable String serverName, @PathVariable String urlMarker, @RequestParam(required=false,defaultValue="0") int startFrom, @RequestParam(required=false,defaultValue="0") int pageSize, @RequestParam(required=false,defaultValue="false") boolean startsWith, @RequestParam(required=false,defaultValue="false") boolean endsWith, @RequestParam(required=false,defaultValue="false") boolean ignoreCase, @RequestBody(required=false) FilterRequestBody requestBody) Retrieve the list of governance definition metadata elements that contain the search string.- Parameters:
serverName
- name of the service to route the request tourlMarker
- view service URL markerstartsWith
- does the value start with the supplied string?endsWith
- does the value end with the supplied string?ignoreCase
- should the search ignore case?startFrom
- paging start pointpageSize
- maximum results that can be returnedrequestBody
- string to find in the properties- Returns:
- list of matching metadata elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException there is a problem reported in the open metadata server(s)
-
getGovernanceDefinitionByGUID
@PostMapping(path="/governance-definitions/{governanceDefinitionGUID}/retrieve") public GovernanceDefinitionResponse getGovernanceDefinitionByGUID(@PathVariable String serverName, @PathVariable String urlMarker, @PathVariable String governanceDefinitionGUID, @RequestBody(required=false) AnyTimeRequestBody requestBody) Return the properties of a specific governance definition.- Parameters:
serverName
- name of the service to route the request tourlMarker
- view service URL markergovernanceDefinitionGUID
- unique identifier of the required elementrequestBody
- string to find in the properties- Returns:
- list of matching metadata elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException there is a problem reported in the open metadata server(s)
-
getGovernanceDefinitionInContext
@PostMapping(path="/governance-definitions/{governanceDefinitionGUID}/in-context") public GovernanceDefinitionGraphResponse getGovernanceDefinitionInContext(@PathVariable String serverName, @PathVariable String urlMarker, @PathVariable String governanceDefinitionGUID, @RequestParam(required=false,defaultValue="0") int startFrom, @RequestParam(required=false,defaultValue="0") int pageSize, @RequestBody(required=false) ResultsRequestBody requestBody) Return the governance definition associated with a unique identifier and the other governance definitions linked to it.- Parameters:
serverName
- name of the server instance to connect tourlMarker
- view service URL markergovernanceDefinitionGUID
- unique identifier of the governance definitionstartFrom
- paging startpageSize
- max elements that can be returnedrequestBody
- additional query parameters- Returns:
- governance definition and its linked elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the caller is not authorized to issue the request PropertyServerException the metadata service has problems
-