Class GovernanceConfigRESTServices

java.lang.Object
org.odpi.openmetadata.accessservices.governanceengine.server.GovernanceConfigRESTServices

public class GovernanceConfigRESTServices extends Object
The GovernanceConfigRESTServices provides the server-side implementation of the configuration services from the Open Governance Framework (ODF). These services configure governance engines and governance services.
  • Constructor Details

    • GovernanceConfigRESTServices

      public GovernanceConfigRESTServices()
      Default constructor
  • Method Details

    • createGovernanceEngine

      public GUIDResponse createGovernanceEngine(String serverName, String userId, String typeName, NewGovernanceEngineRequestBody requestBody)
      Create a new governance engine definition.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      typeName - type of governance engine
      requestBody - containing: qualifiedName - unique name for the governance engine; displayName - display name for messages and user interfaces; description - description of the types of governance services that wil be associated with this governance engine.
      Returns:
      unique identifier (guid) of the governance engine definition or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • getGovernanceEngineByGUID

      public GovernanceEngineElementResponse getGovernanceEngineByGUID(String serverName, String userId, String guid)
      Return the properties from a governance engine definition.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      guid - unique identifier (guid) of the governance engine definition.
      Returns:
      properties from the governance engine definition or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • getGovernanceEngineByName

      public GovernanceEngineElementResponse getGovernanceEngineByName(String serverName, String userId, String name)
      Return the properties from a governance engine definition.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      name - qualified name or display name (if unique).
      Returns:
      properties from the governance engine definition or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • getAllGovernanceEngines

      public GovernanceEngineElementsResponse getAllGovernanceEngines(String serverName, String userId, int startingFrom, int maximumResults)
      Return the list of governance engine definitions that are stored.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      startingFrom - initial position in the stored list.
      maximumResults - maximum number of definitions to return on this call.
      Returns:
      list of governance engine definitions or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • updateGovernanceEngine

      public VoidResponse updateGovernanceEngine(String serverName, String userId, String guid, UpdateGovernanceEngineRequestBody requestBody)
      Update the properties of an existing governance engine definition. Use the current value to keep a property value the same, or use the new value. Null means remove the property from the definition.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      guid - unique identifier of the governance engine - used to locate the definition.
      requestBody - containing the new properties of the governance engine.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • deleteGovernanceEngine

      public VoidResponse deleteGovernanceEngine(String serverName, String userId, String guid, DeleteRequestBody requestBody)
      Remove the properties of the governance engine. Both the guid and the qualified name is supplied to validate that the correct governance engine is being deleted.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      guid - unique identifier of the governance engine - used to locate the definition.
      requestBody - containing the unique name for the governance engine.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • createGovernanceService

      public GUIDResponse createGovernanceService(String serverName, String userId, String typeName, NewGovernanceServiceRequestBody requestBody)
      Create a governance service definition. The same governance service can be associated with multiple governance engines.
      Parameters:
      serverName - name of the service to route the request to
      userId - identifier of calling user
      typeName - type of governance service
      requestBody - containing: qualifiedName - unique name for the governance service; displayName - display name for the governance service; description - description of the analysis provided by the governance service; connection - connection to instantiate the governance service implementation.
      Returns:
      unique identifier of the governance service or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • getGovernanceServiceByGUID

      public GovernanceServiceElementResponse getGovernanceServiceByGUID(String serverName, String userId, String guid)
      Return the properties from a governance service definition.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      guid - unique identifier (guid) of the governance service definition.
      Returns:
      properties of the governance service or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • getGovernanceServiceByName

      public GovernanceServiceElementResponse getGovernanceServiceByName(String serverName, String userId, String name)
      Return the properties from a governance service definition.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      name - qualified name or display name (if unique).
      Returns:
      properties from the governance engine definition or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • getAllGovernanceServices

      public GovernanceServiceElementsResponse getAllGovernanceServices(String serverName, String userId, int startingFrom, int maximumResults)
      Return the list of governance services definitions that are stored.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      startingFrom - initial position in the stored list.
      maximumResults - maximum number of definitions to return on this call.
      Returns:
      list of governance service definitions or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • getGovernanceServiceRegistrations

      public GUIDListResponse getGovernanceServiceRegistrations(String serverName, String userId, String governanceServiceGUID)
      Return the list of governance engines that a specific governance service is registered with.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      governanceServiceGUID - governance service to search for.
      Returns:
      list of governance engine unique identifiers (guids) or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • updateGovernanceService

      public VoidResponse updateGovernanceService(String serverName, String userId, String guid, UpdateGovernanceServiceRequestBody requestBody)
      Update the properties of an existing governance service definition. Use the current value to keep a property value the same, or use the new value. Null means remove the property from the definition.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      guid - unique identifier of the governance service - used to locate the definition.
      requestBody - containing the new parameters for the governance service.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • deleteGovernanceService

      public VoidResponse deleteGovernanceService(String serverName, String userId, String guid, DeleteRequestBody requestBody)
      Remove the properties of the governance service. Both the guid and the qualified name is supplied to validate that the correct governance service is being deleted. The governance service is also unregistered from its governance engines.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      guid - unique identifier of the governance service - used to locate the definition.
      requestBody - containing the unique name for the governance service.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • registerGovernanceServiceWithEngine

      public VoidResponse registerGovernanceServiceWithEngine(String serverName, String userId, String governanceEngineGUID, GovernanceServiceRegistrationRequestBody requestBody)
      Register a governance service with a specific governance engine.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      governanceEngineGUID - unique identifier of the governance engine.
      requestBody - containing: governanceServiceGUID - unique identifier of the governance service; governanceRequestTypes - list of asset types that this governance service is able to process.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • getRegisteredGovernanceService

      public RegisteredGovernanceServiceResponse getRegisteredGovernanceService(String serverName, String userId, String governanceEngineGUID, String governanceServiceGUID)
      Retrieve a specific governance service registered with a governance engine.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      governanceEngineGUID - unique identifier of the governance engine.
      governanceServiceGUID - unique identifier of the governance service.
      Returns:
      details of the governance service and the asset types it is registered for or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • getRegisteredGovernanceServices

      public RegisteredGovernanceServicesResponse getRegisteredGovernanceServices(String serverName, String userId, String governanceEngineGUID, int startingFrom, int maximumResults)
      Retrieve the identifiers of the governance services registered with a governance engine.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      governanceEngineGUID - unique identifier of the governance engine.
      startingFrom - initial position in the stored list.
      maximumResults - maximum number of definitions to return on this call.
      Returns:
      list of unique identifiers or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • unregisterGovernanceServiceRequestFromEngine

      public VoidResponse unregisterGovernanceServiceRequestFromEngine(String serverName, String userId, String requestType, String governanceEngineGUID, String governanceServiceGUID, NullRequestBody requestBody)
      Remove a request type for a governance service from the governance engine.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      requestType - calling request
      governanceEngineGUID - unique identifier of the governance engine.
      governanceServiceGUID - unique identifier of the governance service.
      requestBody - null request body.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.
    • unregisterGovernanceServiceFromEngine

      public VoidResponse unregisterGovernanceServiceFromEngine(String serverName, String userId, String governanceEngineGUID, String governanceServiceGUID, NullRequestBody requestBody)
      Unregister a governance service from the governance engine.
      Parameters:
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      governanceEngineGUID - unique identifier of the governance engine.
      governanceServiceGUID - unique identifier of the governance service.
      requestBody - null request body.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem storing the governance engine definition.