Class FeedbackManagerRESTServices

java.lang.Object
org.odpi.openmetadata.tokencontroller.TokenController
org.odpi.openmetadata.viewservices.feedbackmanager.server.FeedbackManagerRESTServices

public class FeedbackManagerRESTServices extends TokenController
The FeedbackManagerRESTServices provides the implementation of the Feedback Manager Open Metadata View Service (OMVS). This interface provides view interfaces for glossary UIs.
  • Constructor Details

    • FeedbackManagerRESTServices

      public FeedbackManagerRESTServices()
      Default constructor
  • Method Details

    • addRatingToElement

      public VoidResponse addRatingToElement(String serverName, String urlMarker, String guid, UpdateElementRequestBody requestBody)
      Adds a star rating and optional review text to the element. If the user has already attached a rating then the original one is over-ridden.
      Parameters:
      serverName - name of the server instances for this request
      guid - String - unique id for the element.
      urlMarker - view service URL marker
      requestBody - provides a structure for the additional options when updating an element.
      Returns:
      void or InvalidParameterException - one of the parameters is null or invalid or PropertyServerException - there is a problem adding the element properties to the metadata repository or UserNotAuthorizedException - the requesting user is not authorized to issue this request.
    • removeRatingFromElement

      public VoidResponse removeRatingFromElement(String serverName, String urlMarker, String guid, DeleteRequestBody requestBody)
      Removes a star rating that was added to the element by this user.
      Parameters:
      serverName - name of the server instances for this request
      guid - String - unique id for the rating object
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      void or InvalidParameterException - one of the parameters is null or invalid or PropertyServerException - there is a problem updating the element properties in the metadata repository or UserNotAuthorizedException - the requesting user is not authorized to issue this request.
    • getAttachedRatings

      public OpenMetadataRootElementsResponse getAttachedRatings(String serverName, String urlMarker, String elementGUID, ResultsRequestBody requestBody)
      Return the comments attached to an element.
      Parameters:
      serverName - name of the server instances for this request
      elementGUID - unique identifier for the element that the comments are connected to (maybe a comment too).
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      list of ratings or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem updating the element properties in the property server. UserNotAuthorizedException the user does not have permission to perform this request.
    • addLikeToElement

      public VoidResponse addLikeToElement(String serverName, String urlMarker, String guid, UpdateElementRequestBody requestBody)
      Adds a "LikeProperties" to the element.
      Parameters:
      serverName - name of the server instances for this request
      guid - String - unique id for the element.
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      void or InvalidParameterException - one of the parameters is null or invalid or PropertyServerException - there is a problem adding the element properties to the metadata repository or UserNotAuthorizedException - the requesting user is not authorized to issue this request.
    • removeLikeFromElement

      public VoidResponse removeLikeFromElement(String serverName, String urlMarker, String guid, DeleteRequestBody requestBody)
      Removes a "LikeProperties" added to the element by this user.
      Parameters:
      serverName - name of the server instances for this request
      guid - String - unique id for the like object
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      void or InvalidParameterException - one of the parameters is null or invalid or PropertyServerException - there is a problem updating the element properties in the metadata repository or UserNotAuthorizedException - the requesting user is not authorized to issue this request.
    • getAttachedLikes

      public OpenMetadataRootElementsResponse getAttachedLikes(String serverName, String urlMarker, String elementGUID, ResultsRequestBody requestBody)
      Return the likes attached to an element.
      Parameters:
      serverName - name of the server instances for this request
      elementGUID - unique identifier for the element that the comments are connected to (maybe a comment too).
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      list of likes or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem updating the element properties in the property server. UserNotAuthorizedException the user does not have permission to perform this request.
    • addCommentToElement

      public GUIDResponse addCommentToElement(String serverName, String urlMarker, String elementGUID, NewFeedbackRequestBody requestBody)
      Adds a comment to the element.
      Parameters:
      serverName - name of the server instances for this request
      elementGUID - String - unique id for the element.
      urlMarker - view service URL marker
      requestBody - containing type of comment enum and the text of the comment.
      Returns:
      elementGUID for new comment object or InvalidParameterException - one of the parameters is null or invalid or PropertyServerException - there is a problem adding the element properties to the metadata repository or UserNotAuthorizedException - the requesting user is not authorized to issue this request.
    • addCommentReply

      public GUIDResponse addCommentReply(String serverName, String urlMarker, String elementGUID, String commentGUID, NewFeedbackRequestBody requestBody)
      Adds a reply to a comment.
      Parameters:
      serverName - name of the server instances for this request
      elementGUID - String - unique id for the anchor element.
      commentGUID - String - unique id for an existing comment. Used to add a reply to a comment.
      urlMarker - view service URL marker
      requestBody - containing type of comment enum and the text of the comment.
      Returns:
      guid for new comment object or InvalidParameterException - one of the parameters is null or invalid or PropertyServerException - there is a problem adding the element properties to the metadata repository or UserNotAuthorizedException - the requesting user is not authorized to issue this request.
    • updateComment

      public VoidResponse updateComment(String serverName, String urlMarker, String commentGUID, UpdateElementRequestBody requestBody)
      Update an existing comment.
      Parameters:
      serverName - name of the server instances for this request.
      commentGUID - unique identifier for the comment to change.
      urlMarker - view service URL marker
      requestBody - containing type of comment enum and the text of the comment.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException There is a problem updating the element properties in the metadata repository. UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • setupAcceptedAnswer

      public VoidResponse setupAcceptedAnswer(String serverName, String urlMarker, String questionCommentGUID, String answerCommentGUID, NewRelationshipRequestBody requestBody)
      Link a comment that contains the best answer to a question posed in another comment.
      Parameters:
      serverName - name of the server to route the request to
      questionCommentGUID - unique identifier of the comment containing the question
      answerCommentGUID - unique identifier of the comment containing the accepted answer
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      void 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)
    • clearAcceptedAnswer

      public VoidResponse clearAcceptedAnswer(String serverName, String urlMarker, String questionCommentGUID, String answerCommentGUID, DeleteRequestBody requestBody)
      Unlink a comment that contains an answer to a question posed in another comment.
      Parameters:
      serverName - name of the server to route the request to
      questionCommentGUID - unique identifier of the comment containing the question
      answerCommentGUID - unique identifier of the comment containing the accepted answer
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      void 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)
    • removeCommentFromElement

      public VoidResponse removeCommentFromElement(String serverName, String urlMarker, String commentGUID, DeleteRequestBody requestBody)
      Removes a comment added to the element by this user.
      Parameters:
      serverName - name of the server instances for this request
      commentGUID - String - unique id for the comment object
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      void or InvalidParameterException - one of the parameters is null or invalid or PropertyServerException - there is a problem updating the element properties in the metadata repository or UserNotAuthorizedException - the requesting user is not authorized to issue this request.
    • getCommentByGUID

      public OpenMetadataRootElementResponse getCommentByGUID(String serverName, String urlMarker, String commentGUID, GetRequestBody requestBody)
      Return the requested comment.
      Parameters:
      serverName - name of the server instances for this request
      commentGUID - unique identifier for the comment object.
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      comment properties or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem updating the element properties in the property server. UserNotAuthorizedException the user does not have permission to perform this request.
    • getAttachedComments

      public OpenMetadataRootElementsResponse getAttachedComments(String serverName, String urlMarker, String elementGUID, ResultsRequestBody requestBody)
      Return the comments attached to an element.
      Parameters:
      serverName - name of the server instances for this request
      elementGUID - unique identifier for the element that the comments are connected to (maybe a comment too).
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      list of comments or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem updating the element properties in the property server. UserNotAuthorizedException the user does not have permission to perform this request.
    • findComments

      public OpenMetadataRootElementsResponse findComments(String serverName, String urlMarker, SearchStringRequestBody requestBody)
      Retrieve the list of comment metadata elements that contain the search string. The search string is treated as a regular expression.
      Parameters:
      serverName - name of the server to route the request to
      urlMarker - view service URL marker
      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)
    • createInformalTag

      public GUIDResponse createInformalTag(String serverName, String urlMarker, NewElementRequestBody requestBody)
      Creates a new informal tag and returns the unique identifier for it.
      Parameters:
      serverName - name of the server instances for this request
      urlMarker - view service URL marker
      requestBody - contains the name of the tag and (optional) description of the tag
      Returns:
      guid for new tag 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.
    • updateTagDescription

      public VoidResponse updateTagDescription(String serverName, String urlMarker, String tagGUID, UpdateElementRequestBody requestBody)
      Updates the description of an existing tag (either private or public).
      Parameters:
      serverName - name of the server instances for this request
      tagGUID - unique id for the tag.
      urlMarker - view service URL marker
      requestBody - contains the name of the tag and (optional) description of the tag.
      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.
    • deleteTag

      public VoidResponse deleteTag(String serverName, String urlMarker, String tagGUID, DeleteRequestBody requestBody)
      Removes a tag from the repository. All the relationships to referenceables are lost.
      Parameters:
      serverName - name of the server instances for this request
      tagGUID - unique id for the tag.
      urlMarker - view service URL marker
      requestBody - optional effective time.
      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.
    • getTag

      public OpenMetadataRootElementResponse getTag(String serverName, String urlMarker, String guid, GetRequestBody requestBody)
      Return the tag for the supplied unique identifier (guid).
      Parameters:
      serverName - name of the server instances for this request
      guid - unique identifier of the tag.
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      Tag object 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.
    • getTagsByName

      public OpenMetadataRootElementsResponse getTagsByName(String serverName, String urlMarker, FilterRequestBody requestBody)
      Return the list of tags exactly matching the supplied name.
      Parameters:
      serverName - name of the server instances for this request
      urlMarker - view service URL marker
      requestBody - name of tag.
      Returns:
      tag list 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.
    • findTags

      public OpenMetadataRootElementsResponse findTags(String serverName, String urlMarker, SearchStringRequestBody requestBody)
      Return the list of tags containing the supplied string in either the name or description.
      Parameters:
      serverName - name of the server to route the request to
      urlMarker - view service URL marker
      requestBody - string to find in the properties
      Returns:
      tag list 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.
    • findMyTags

      public OpenMetadataRootElementsResponse findMyTags(String serverName, String urlMarker, SearchStringRequestBody requestBody)
      Return the list of the calling user's private tags containing the supplied string in either the name or description.
      Parameters:
      serverName - name of the server to route the request to
      urlMarker - view service URL marker
      requestBody - string to find in the properties
      Returns:
      tag list 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.
    • addTagToElement

      public VoidResponse addTagToElement(String serverName, String urlMarker, String elementGUID, String tagGUID, MetadataSourceRequestBody requestBody)
      Adds a tag (either private of public) to an element.
      Parameters:
      serverName - name of the server instances for this request
      elementGUID - unique id for the element.
      tagGUID - unique id of the tag.
      urlMarker - view service URL marker
      requestBody - feedback request body.
      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.
    • removeTagFromElement

      public VoidResponse removeTagFromElement(String serverName, String urlMarker, String elementGUID, String tagGUID, DeleteRequestBody requestBody)
      Removes a tag from the element that was added by this user.
      Parameters:
      serverName - name of the server instances for this request
      elementGUID - unique id for the element.
      tagGUID - unique id for the tag.
      urlMarker - view service URL marker
      requestBody - optional effective time
      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.
    • getElementsByTag

      public OpenMetadataRootElementsResponse getElementsByTag(String serverName, String urlMarker, String tagGUID, ResultsRequestBody requestBody)
      Return the list of unique identifiers for elements that are linked to a specific tag either directly, or via one of its schema elements.
      Parameters:
      serverName - name of the server instances for this request
      tagGUID - unique identifier of tag.
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      element stubs list or InvalidParameterException the userId is null or 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.
    • getAttachedTags

      public OpenMetadataRootElementsResponse getAttachedTags(String serverName, String urlMarker, String elementGUID, ResultsRequestBody requestBody)
      Return the informal tags attached to an element.
      Parameters:
      serverName - name of the server instances for this request
      urlMarker - view service URL marker
      elementGUID - unique identifier for the element that the comments are connected to (maybe a comment too).
      requestBody - optional effective time
      Returns:
      list of tags or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem updating the element properties in the property server. UserNotAuthorizedException the user does not have permission to perform this request.
    • createNoteLog

      public GUIDResponse createNoteLog(String serverName, String urlMarker, String elementGUID, NewFeedbackRequestBody requestBody)
      Creates a new noteLog and returns the unique identifier for it.
      Parameters:
      serverName - name of the server instances for this request
      elementGUID - unique identifier of the element where the note log is located
      urlMarker - view service URL marker
      requestBody - contains the name of the tag and (optional) description of the tag
      Returns:
      guid for new tag 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.
    • updateNoteLog

      public VoidResponse updateNoteLog(String serverName, String urlMarker, String noteLogGUID, UpdateElementRequestBody requestBody)
      Update an existing note log.
      Parameters:
      serverName - name of the server instances for this request.
      noteLogGUID - unique identifier for the note log to change.
      urlMarker - view service URL marker
      requestBody - containing type of comment enum and the text of the comment.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException There is a problem updating the element properties in the metadata repository. UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • deleteNoteLog

      public VoidResponse deleteNoteLog(String serverName, String urlMarker, String noteLogGUID, DeleteRequestBody requestBody)
      Removes a note log from the repository. All the relationships to referenceables are lost.
      Parameters:
      serverName - name of the server instances for this request
      noteLogGUID - unique id for the note log.
      urlMarker - view service URL marker
      requestBody - optional effective time
      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.
    • findNoteLogs

      public OpenMetadataRootElementsResponse findNoteLogs(String serverName, String urlMarker, SearchStringRequestBody requestBody)
      Retrieve the list of note log metadata elements that contain the search string. The search string is treated as a regular expression.
      Parameters:
      serverName - name of the server to route the request to
      urlMarker - view service URL marker
      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)
    • getNoteLogsByName

      public OpenMetadataRootElementsResponse getNoteLogsByName(String serverName, String urlMarker, FilterRequestBody requestBody)
      Retrieve the list of note log metadata elements with a matching qualified or display name. There are no wildcards supported on this request.
      Parameters:
      serverName - name of the server instances for this request
      urlMarker - view service URL marker
      requestBody - name to search for and correlators
      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)
    • getNoteLogsForElement

      public OpenMetadataRootElementsResponse getNoteLogsForElement(String serverName, String urlMarker, String elementGUID, ResultsRequestBody requestBody)
      Retrieve the list of note log metadata elements attached to the element.
      Parameters:
      serverName - name of the server instances for this request
      urlMarker - view service URL marker
      elementGUID - unique identifier of the note log of interest
      requestBody - optional effective time
      Returns:
      list of associated 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)
    • getNoteLogByGUID

      public OpenMetadataRootElementResponse getNoteLogByGUID(String serverName, String urlMarker, String noteLogGUID, GetRequestBody requestBody)
      Retrieve the note log metadata element with the supplied unique identifier.
      Parameters:
      serverName - name of the server instances for this request
      noteLogGUID - unique identifier of the requested metadata element
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      requested 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)
    • getNotesForNoteLog

      public OpenMetadataRootElementsResponse getNotesForNoteLog(String serverName, String urlMarker, String noteLogGUID, ResultsRequestBody requestBody)
      Retrieve the list of notes associated with a note log.
      Parameters:
      serverName - name of the server instances for this request
      noteLogGUID - unique identifier of the note log of interest
      urlMarker - view service URL marker
      requestBody - optional effective time
      Returns:
      list of associated 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)