Class GovernanceMetricsResource
- java.lang.Object
-
- org.odpi.openmetadata.accessservices.governanceprogram.server.spring.GovernanceMetricsResource
-
@RestController @RequestMapping("/servers/{serverName}/open-metadata/access-services/governance-program/users/{userId}") public class GovernanceMetricsResource extends ObjectGovernanceMetricsResource sets up the governance metrics that are part of an organization governance.
-
-
Constructor Summary
Constructors Constructor Description GovernanceMetricsResource()Default constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description VoidResponseclearGovernanceDefinitionMetric(String serverName, String userId, String metricGUID, String governanceDefinitionGUID, RelationshipRequestBody requestBody)Remove the link between a governance metric and a governance definition.VoidResponseclearGovernanceExpectations(String serverName, String userId, String elementGUID, ExternalSourceRequestBody requestBody)Remove the governance expectations classification from the element.VoidResponseclearGovernanceMeasurements(String serverName, String userId, String elementGUID, ExternalSourceRequestBody requestBody)Remove the measurements from the element.VoidResponseclearGovernanceMeasurementsDataSet(String serverName, String userId, String dataSetGUID, ExternalSourceRequestBody requestBody)Remove the governance data designation from the data set.VoidResponseclearGovernanceResults(String serverName, String userId, String metricGUID, String dataSetGUID, RelationshipRequestBody requestBody)Remove the link between a governance metric and a data set.GUIDResponsecreateGovernanceMetric(String serverName, String userId, ReferenceableRequestBody requestBody)Create a new governance metric.VoidResponsedeleteGovernanceMetric(String serverName, String userId, String metricGUID, ExternalSourceRequestBody requestBody)Delete a specific governance metric.GovernanceMetricListResponsefindGovernanceMetrics(String serverName, String userId, int startFrom, int pageSize, SearchStringRequestBody requestBody)Retrieve the list of governance metrics for this search string.GovernanceMetricResponsegetGovernanceMetricByGUID(String serverName, String userId, String metricGUID)Return information about a specific governance metric.VoidResponsesetGovernanceExpectations(String serverName, String userId, String elementGUID, ClassificationRequestBody requestBody)Classify the element to indicate the expected values of the governance measurements.VoidResponsesetGovernanceMeasurements(String serverName, String userId, String elementGUID, ClassificationRequestBody requestBody)Classify the element with relevant governance measurements.VoidResponsesetGovernanceMeasurementsDataSet(String serverName, String userId, String dataSetGUID, ClassificationRequestBody requestBody)Classify the data set to indicate that contains governance measurements.VoidResponsesetupGovernanceDefinitionMetric(String serverName, String userId, String metricGUID, String governanceDefinitionGUID, RelationshipRequestBody requestBody)Create a link to show that a governance metric supports the requirements of one of the governance policies.VoidResponsesetupGovernanceResults(String serverName, String userId, String metricGUID, String dataSetGUID, RelationshipRequestBody requestBody)Create a link to show which data set holds the measurements for a data set.VoidResponseupdateGovernanceMetric(String serverName, String userId, String metricGUID, boolean isMergeUpdate, ReferenceableRequestBody requestBody)Update an existing governance metric.
-
-
-
Method Detail
-
createGovernanceMetric
@PostMapping(path="/governance-metrics") public GUIDResponse createGovernanceMetric(@PathVariable String serverName, @PathVariable String userId, @RequestBody ReferenceableRequestBody requestBody)
Create a new governance metric.- Parameters:
serverName- name of the server instance to connect touserId- calling userrequestBody- properties of the metric- Returns:
- unique identifier of the metric or InvalidParameterException typeName, documentIdentifier or userId is null; documentIdentifier is not unique; typeName is not valid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
updateGovernanceMetric
@PostMapping(path="/governance-metrics/{metricGUID}/update") public VoidResponse updateGovernanceMetric(@PathVariable String serverName, @PathVariable String userId, @PathVariable String metricGUID, @RequestParam boolean isMergeUpdate, @RequestBody ReferenceableRequestBody requestBody)Update an existing governance metric.- Parameters:
serverName- name of the server instance to connect touserId- calling usermetricGUID- unique identifier of the metric to updateisMergeUpdate- are unspecified properties unchanged (true) or replaced with null?requestBody- properties to update- Returns:
- void or InvalidParameterException invalid guid or properties PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
deleteGovernanceMetric
@PostMapping(path="/governance-metrics/{metricGUID}/delete") public VoidResponse deleteGovernanceMetric(@PathVariable String serverName, @PathVariable String userId, @PathVariable String metricGUID, @RequestBody ExternalSourceRequestBody requestBody)Delete a specific governance metric.- Parameters:
serverName- name of the server instance to connect touserId- calling usermetricGUID- unique identifier of the metric to removerequestBody- external source request body- Returns:
- void or InvalidParameterException invalid guid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
setupGovernanceDefinitionMetric
@PostMapping(path="/governance-metrics/{metricGUID}/governance-definitions/{governanceDefinitionGUID}/link") public VoidResponse setupGovernanceDefinitionMetric(@PathVariable String serverName, @PathVariable String userId, @PathVariable String metricGUID, @PathVariable String governanceDefinitionGUID, @RequestBody RelationshipRequestBody requestBody)Create a link to show that a governance metric supports the requirements of one of the governance policies. If the link already exists the rationale is updated.- Parameters:
serverName- name of the server instance to connect touserId- calling usermetricGUID- unique identifier of the governance metricgovernanceDefinitionGUID- unique identifier of the governance definitionrequestBody- description of how the metric supports the metric- Returns:
- void or InvalidParameterException invalid parameter PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
clearGovernanceDefinitionMetric
@PostMapping(path="/governance-metrics/{metricGUID}/governance-definitions/{governanceDefinitionGUID}/unlink") public VoidResponse clearGovernanceDefinitionMetric(@PathVariable String serverName, @PathVariable String userId, @PathVariable String metricGUID, @PathVariable String governanceDefinitionGUID, @RequestBody RelationshipRequestBody requestBody)Remove the link between a governance metric and a governance definition.- Parameters:
serverName- name of the server instance to connect touserId- calling usermetricGUID- unique identifier of the governance metricgovernanceDefinitionGUID- unique identifier of the governance definitionrequestBody- relationship properties- Returns:
- void or InvalidParameterException invalid guid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
setupGovernanceResults
@PostMapping(path="/governance-metrics/{metricGUID}/governance-results/{dataSetGUID}/link") public VoidResponse setupGovernanceResults(@PathVariable String serverName, @PathVariable String userId, @PathVariable String metricGUID, @PathVariable String dataSetGUID, @RequestBody RelationshipRequestBody requestBody)Create a link to show which data set holds the measurements for a data set.- Parameters:
serverName- name of the server instance to connect touserId- calling usermetricGUID- unique identifier of the governance metricdataSetGUID- unique identifier of the governance definitionrequestBody- description of how the data set supports the metric- Returns:
- void or InvalidParameterException invalid guid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
clearGovernanceResults
@PostMapping(path="/governance-metrics/{metricGUID}/governance-results/{dataSetGUID}/unlink") public VoidResponse clearGovernanceResults(@PathVariable String serverName, @PathVariable String userId, @PathVariable String metricGUID, @PathVariable String dataSetGUID, @RequestBody RelationshipRequestBody requestBody)Remove the link between a governance metric and a data set.- Parameters:
serverName- name of the server instance to connect touserId- calling usermetricGUID- unique identifier of the governance metricdataSetGUID- unique identifier of the data setrequestBody- relationship properties- Returns:
- void or InvalidParameterException invalid guid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
setGovernanceMeasurementsDataSet
@PostMapping(path="/data-sets/{dataSetGUID}/classify-as-governance-measurements-set") public VoidResponse setGovernanceMeasurementsDataSet(@PathVariable String serverName, @PathVariable String userId, @PathVariable String dataSetGUID, @RequestBody ClassificationRequestBody requestBody)Classify the data set to indicate that contains governance measurements.- Parameters:
serverName- name of the server instance to connect touserId- calling userdataSetGUID- unique identifier of the metadata element to classifyrequestBody- properties of the data set's measurements- Returns:
- void or InvalidParameterException invalid guid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
clearGovernanceMeasurementsDataSet
@PostMapping(path="/data-sets/{dataSetGUID}/classify-as-governance-measurements-set/delete") public VoidResponse clearGovernanceMeasurementsDataSet(@PathVariable String serverName, @PathVariable String userId, @PathVariable String dataSetGUID, @RequestBody ExternalSourceRequestBody requestBody)Remove the governance data designation from the data set.- Parameters:
serverName- name of the server instance to connect touserId- calling userdataSetGUID- unique identifier of the metadata element to classifyrequestBody- external source properties- Returns:
- void or InvalidParameterException invalid guid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
setGovernanceExpectations
@PostMapping(path="/elements/{elementGUID}/classify-with-governance-expectations") public VoidResponse setGovernanceExpectations(@PathVariable String serverName, @PathVariable String userId, @PathVariable String elementGUID, @RequestBody ClassificationRequestBody requestBody)Classify the element to indicate the expected values of the governance measurements. Can be used to create or update the values.- Parameters:
serverName- name of the server instance to connect touserId- calling userelementGUID- unique identifier of the metadata element to classifyrequestBody- expectation properties- Returns:
- void or InvalidParameterException invalid guid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
clearGovernanceExpectations
@PostMapping(path="/elements/{elementGUID}/classify-with-governance-expectations/delete") public VoidResponse clearGovernanceExpectations(@PathVariable String serverName, @PathVariable String userId, @PathVariable String elementGUID, @RequestBody ExternalSourceRequestBody requestBody)Remove the governance expectations classification from the element.- Parameters:
serverName- name of the server instance to connect touserId- calling userelementGUID- unique identifier of the metadata element to classifyrequestBody- external source properties- Returns:
- void or InvalidParameterException invalid guid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
setGovernanceMeasurements
@PostMapping(path="/elements/{elementGUID}/classify-with-governance-measurements") public VoidResponse setGovernanceMeasurements(@PathVariable String serverName, @PathVariable String userId, @PathVariable String elementGUID, @RequestBody ClassificationRequestBody requestBody)Classify the element with relevant governance measurements. Can be used to create or update the values.- Parameters:
serverName- name of the server instance to connect touserId- calling userelementGUID- unique identifier of the metadata element to classifyrequestBody- measurements- Returns:
- void or InvalidParameterException invalid guid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
clearGovernanceMeasurements
@PostMapping(path="/elements/{elementGUID}/classify-with-governance-measurements/delete") public VoidResponse clearGovernanceMeasurements(@PathVariable String serverName, @PathVariable String userId, @PathVariable String elementGUID, @RequestBody ExternalSourceRequestBody requestBody)Remove the measurements from the element.- Parameters:
serverName- name of the server instance to connect touserId- calling userelementGUID- unique identifier of the metadata element to classifyrequestBody- external source properties- Returns:
- void or InvalidParameterException invalid guid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
getGovernanceMetricByGUID
@GetMapping(path="/governance-metrics/{metricGUID}") public GovernanceMetricResponse getGovernanceMetricByGUID(@PathVariable String serverName, @PathVariable String userId, @PathVariable String metricGUID)Return information about a specific governance metric.- Parameters:
serverName- name of the server instance to connect touserId- calling usermetricGUID- unique identifier for the governance metric- Returns:
- properties of the governance metric or InvalidParameterException typeName, documentIdentifier or userId is null; documentIdentifier is not unique; typeName is not valid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
findGovernanceMetrics
@PostMapping(path="/governance-metrics/by-search-string") public GovernanceMetricListResponse findGovernanceMetrics(@PathVariable String serverName, @PathVariable String userId, @RequestParam int startFrom, @RequestParam int pageSize, @RequestBody SearchStringRequestBody requestBody)
Retrieve the list of governance metrics for this search string.- Parameters:
serverName- name of the server instance to connect touserId- the name of the calling user.requestBody- value to search for (supports wildcards).startFrom- index of the list to start from (0 for start)pageSize- maximum number of elements to return.- Returns:
- list of metrics or InvalidParameterException typeName, documentIdentifier or userId is null; documentIdentifier is not unique; typeName is not valid PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
-
-