java.lang.Object
org.odpi.openmetadata.accessservices.itinfrastructure.server.ITProfileRESTServices

public class ITProfileRESTServices extends Object
The ITProfileRESTServices provides the server-side implementation of the IT Infrastructure Open Metadata Assess Service (OMAS) capability for IT Profile management. This interface provides support for creating IT profiles and associated user roles in order to describe the structure of an organization. It also links the profile to the Asset that is using the profile
  • Constructor Details

    • ITProfileRESTServices

      public ITProfileRESTServices()
      Default constructor
  • Method Details

    • createITProfile

      public GUIDResponse createITProfile(String serverName, String userId, ITProfileRequestBody requestBody)
      Create a definition of an actor profile. This could be for the whole organization, a team, a person or a system.
      Parameters:
      serverName - called server
      userId - calling user
      requestBody - properties for a actor profile
      Returns:
      unique identifier of actor profile InvalidParameterException qualifiedName or userId is null; qualifiedName is not unique PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • updateITProfile

      public VoidResponse updateITProfile(String serverName, String userId, String itProfileGUID, boolean isMergeUpdate, ITProfileRequestBody requestBody)
      Update the definition of an actor profile.
      Parameters:
      serverName - called server
      userId - calling user
      itProfileGUID - unique identifier of actor profile
      isMergeUpdate - are unspecified properties unchanged (true) or replaced with null?
      requestBody - properties to change
      Returns:
      void or InvalidParameterException guid, qualifiedName or userId is null; qualifiedName is not unique; guid is not known PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • deleteITProfile

      public VoidResponse deleteITProfile(String serverName, String userId, String itProfileGUID, MetadataSourceRequestBody requestBody)
      Remove the definition of an actor profile.
      Parameters:
      serverName - called server
      userId - calling user
      itProfileGUID - unique identifier of actor profile
      requestBody - identifiers of the software server capability entity that represented the external source - null for local
      Returns:
      void or InvalidParameterException guid or userId is null; guid is not known PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • addContactMethod

      public GUIDResponse addContactMethod(String serverName, String userId, String itProfileGUID, ContactMethodRequestBody requestBody)
      Add a new contact method to the profile.
      Parameters:
      serverName - called server
      userId - the name of the calling user.
      itProfileGUID - identifier of the profile to update.
      requestBody - properties of contact method.
      Returns:
      unique identifier (guid) for the new contact method. InvalidParameterException the userId is null or invalid. Another property 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.
    • deleteContactMethod

      public VoidResponse deleteContactMethod(String serverName, String userId, String contactMethodGUID, MetadataSourceRequestBody requestBody)
      Remove an obsolete contact method from the profile.
      Parameters:
      serverName - called server
      userId - the name of the calling user.
      contactMethodGUID - unique identifier (guid) for the obsolete contact method.
      requestBody - identifiers of the software server capability entity that represented the external source - null for local
      Returns:
      void or InvalidParameterException the userId is null or invalid. Another property 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.
    • getITProfileByGUID

      public ITProfileResponse getITProfileByGUID(String serverName, String userId, String itProfileGUID)
      Return information about a specific actor profile.
      Parameters:
      serverName - called server
      userId - calling user
      itProfileGUID - unique identifier for the actor profile
      Returns:
      properties of the actor profile InvalidParameterException itProfileGUID or userId is null PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • getITProfileByUserId

      public ITProfileResponse getITProfileByUserId(String serverName, String userId, String actorProfileUserId)
      Return information about a specific actor profile.
      Parameters:
      serverName - called server
      userId - calling user
      actorProfileUserId - unique identifier for the actor profile
      Returns:
      properties of the actor profile InvalidParameterException actorProfileUserId or userId is null PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • getITProfileByName

      public ITProfileListResponse getITProfileByName(String serverName, String userId, int startFrom, int pageSize, NameRequestBody requestBody)
      Return information about a named actor profile.
      Parameters:
      serverName - called server
      userId - calling user
      startFrom - index of the list to start from (0 for start)
      pageSize - maximum number of elements to return.
      requestBody - unique name for the actor profile
      Returns:
      list of matching actor profiles (hopefully only one) InvalidParameterException name or userId is null PropertyServerException problem accessing property server UserNotAuthorizedException security access problem
    • findITProfile

      public ITProfileListResponse findITProfile(String serverName, String userId, int startFrom, int pageSize, SearchStringRequestBody requestBody)
      Retrieve the list of matching profiles for the search string.
      Parameters:
      serverName - called server
      userId - the name of the calling user.
      startFrom - index of the list to start from (0 for start)
      pageSize - maximum number of elements to return.
      requestBody - RegEx string to search for
      Returns:
      list of matching actor profiles InvalidParameterException guid invalid or the external references are not correctly specified, or are null. PropertyServerException the server is not available. UserNotAuthorizedException the calling user is not authorized to issue the call.
    • createUserIdentity

      public GUIDResponse createUserIdentity(String serverName, String userId, UserIdentityRequestBody requestBody)
      Create a UserIdentity. This is not connected to a profile.
      Parameters:
      serverName - name of target server
      userId - the name of the calling user
      requestBody - userId for the new userIdentity
      Returns:
      void or InvalidParameterException - one of the parameters is invalid or PropertyServerException - there is a problem retrieving information from the property server(s) or UserNotAuthorizedException - the requesting user is not authorized to issue this request.
    • updateUserIdentity

      public VoidResponse updateUserIdentity(String serverName, String userId, String userIdentityGUID, boolean isMergeUpdate, UserIdentityRequestBody requestBody)
      Update a UserIdentity.
      Parameters:
      serverName - name of target server
      userId - the name of the calling user
      userIdentityGUID - unique identifier of the UserIdentity
      isMergeUpdate - should the supplied properties be overlaid on the existing properties (true) or replace them (false
      requestBody - updated properties for the new userIdentity
      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.
    • deleteUserIdentity

      public VoidResponse deleteUserIdentity(String serverName, String userId, String userIdentityGUID, MetadataSourceRequestBody requestBody)
      Remove a user identity object.
      Parameters:
      serverName - name of target server
      userId - the name of the calling user.
      userIdentityGUID - unique identifier of the UserIdentity
      requestBody - external source identifiers
      Returns:
      void or InvalidParameterException - one of the parameters is invalid or PropertyServerException - there is a problem retrieving information from the property server(s) or UserNotAuthorizedException - the requesting user is not authorized to issue this request.
    • addIdentityToProfile

      public VoidResponse addIdentityToProfile(String serverName, String userId, String userIdentityGUID, String profileGUID, MetadataSourceRequestBody requestBody)
      Link a user identity to a profile.
      Parameters:
      serverName - name of target server
      userId - the name of the calling user.
      userIdentityGUID - unique identifier of the UserIdentity
      profileGUID - the profile to add the identity to.
      requestBody - external source identifiers
      Returns:
      void or InvalidParameterException - one of the parameters is invalid or PropertyServerException - there is a problem retrieving information from the property server(s) or UserNotAuthorizedException - the requesting user is not authorized to issue this request.
    • removeIdentityFromProfile

      public VoidResponse removeIdentityFromProfile(String serverName, String userId, String userIdentityGUID, String profileGUID, MetadataSourceRequestBody requestBody)
      Remove a user identity object.
      Parameters:
      serverName - name of target server
      userId - the name of the calling user.
      userIdentityGUID - unique identifier of the UserIdentity
      profileGUID - profile to remove it from.
      requestBody - external source identifiers
      Returns:
      void or InvalidParameterException - one of the parameters is invalid or PropertyServerException - there is a problem retrieving information from the property server(s) or UserNotAuthorizedException - the requesting user is not authorized to issue this request.
    • findUserIdentities

      public UserIdentityListResponse findUserIdentities(String serverName, String userId, int startFrom, int pageSize, SearchStringRequestBody requestBody)
      Retrieve the list of user identity metadata elements that contain the search string. The search string is treated as a regular expression.
      Parameters:
      serverName - name of target server
      userId - calling user
      startFrom - paging start point
      pageSize - maximum results that can be returned
      requestBody - 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)
    • getUserIdentitiesByName

      public UserIdentityListResponse getUserIdentitiesByName(String serverName, String userId, int startFrom, int pageSize, NameRequestBody requestBody)
      Retrieve the list of user identity metadata elements with a matching qualified name. There are no wildcards supported on this request.
      Parameters:
      serverName - name of target server
      userId - calling user
      startFrom - paging start point
      pageSize - maximum results that can be returned
      requestBody - name to search for
      Returns:
      list of matching metadata elements 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)
    • getUserIdentityByGUID

      public UserIdentityResponse getUserIdentityByGUID(String serverName, String userId, String userIdentityGUID)
      Retrieve the userIdentity metadata element with the supplied unique identifier.
      Parameters:
      serverName - name of target server
      userId - calling user
      userIdentityGUID - unique identifier of the requested metadata element
      Returns:
      matching metadata element 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)