Enum RestServiceErrorCode

    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      AccessDenied
      An authenticated client is not authorized to access a resource.
      BadRequest
      Generic BadRequest error code when a client provides a request that is not fit for processing.
      Conflict
      Request conflicts with the current state of the server.
      Deleted
      Resource has been deleted or has expired.
      IdConverterServiceError
      Indicates that IdConverter encountered some exception during ID conversion
      InsufficientCapacity
      There is insufficient capacity to service the request.
      InternalServerError
      Generic InternalServerError that is a result of problems on the server side that is not caused by the client and there is nothing that a client can do about it.
      InvalidAccount
      The account is not valid.
      InvalidArgs
      Client has sent arguments (whether in the URI or in the headers) that are not in the format that is expected or if the number of values for an argument expected by the server does not match what the client sent.
      InvalidContainer
      The container is not valid.
      InvalidRequestState
      Client has sent request content without sending request metadata first or has sent content when no content was expected (for e.g.
      MalformedRequest
      Client has sent a request that cannot be decoded using the REST protocol (usually HTTP).
      MissingArgs
      Client has sent a request that is missing some arguments (whether in the URI or in the headers) necessary to service the request.
      NotAllowed
      Action not allowed
      NotFound
      Resource was not found.
      PreconditionFailed
      The conditions given in the request header fields evaluated to false.
      RangeNotSatisfiable
      Range request is not satisfiable (because the provided range is invalid or outside of the bounds of an object.)
      RequestChannelClosed
      Indicates that a RestRequest has been closed and an operation could not be performed on it.
      RequestResponseQueuingFailure
      Indicates that the submitted request or response could not be queued in the AsyncRequestResponseHandler.
      RequestTooLarge
      The request is larger than what the server is willing or is configured to accept.
      ResourceDirty
      Resource scan has deducted that the resource is not safe for serving
      ResourceScanInProgress
      Resource scan still in progress and result not yet available
      ServiceUnavailable
      Indicates that the service is unavailable because one or more of the components is not started, is shutdown, has crashed or is temporarily unable to respond.
      TooManyRequests
      Application rate limit exceeded/Application quota limit exceeded.
      Unauthorized
      Client has sent a request that cannot be processed due to authorization failure.
      UnsupportedHttpMethod
      Client is requesting a HTTP method that is not supported.
      UnsupportedRestMethod
      Indicates a RestMethod is not supported (May also indicate a bug where behaviour for a new RestMethod has not been defined in the implementation).
    • Enum Constant Detail

      • Deleted

        public static final RestServiceErrorCode Deleted
        Resource has been deleted or has expired.
      • ResourceScanInProgress

        public static final RestServiceErrorCode ResourceScanInProgress
        Resource scan still in progress and result not yet available
      • ResourceDirty

        public static final RestServiceErrorCode ResourceDirty
        Resource scan has deducted that the resource is not safe for serving
      • AccessDenied

        public static final RestServiceErrorCode AccessDenied
        An authenticated client is not authorized to access a resource.
      • Unauthorized

        public static final RestServiceErrorCode Unauthorized
        Client has sent a request that cannot be processed due to authorization failure.
      • BadRequest

        public static final RestServiceErrorCode BadRequest
        Generic BadRequest error code when a client provides a request that is not fit for processing.
      • InvalidArgs

        public static final RestServiceErrorCode InvalidArgs
        Client has sent arguments (whether in the URI or in the headers) that are not in the format that is expected or if the number of values for an argument expected by the server does not match what the client sent.
      • InvalidRequestState

        public static final RestServiceErrorCode InvalidRequestState
        Client has sent request content without sending request metadata first or has sent content when no content was expected (for e.g. content with RestMethod.GET).
      • InvalidContainer

        public static final RestServiceErrorCode InvalidContainer
        The container is not valid.
      • MalformedRequest

        public static final RestServiceErrorCode MalformedRequest
        Client has sent a request that cannot be decoded using the REST protocol (usually HTTP).
      • MissingArgs

        public static final RestServiceErrorCode MissingArgs
        Client has sent a request that is missing some arguments (whether in the URI or in the headers) necessary to service the request.
      • UnsupportedHttpMethod

        public static final RestServiceErrorCode UnsupportedHttpMethod
        Client is requesting a HTTP method that is not supported.
      • RangeNotSatisfiable

        public static final RestServiceErrorCode RangeNotSatisfiable
        Range request is not satisfiable (because the provided range is invalid or outside of the bounds of an object.)
      • InternalServerError

        public static final RestServiceErrorCode InternalServerError
        Generic InternalServerError that is a result of problems on the server side that is not caused by the client and there is nothing that a client can do about it.
      • IdConverterServiceError

        public static final RestServiceErrorCode IdConverterServiceError
        Indicates that IdConverter encountered some exception during ID conversion
      • RequestChannelClosed

        public static final RestServiceErrorCode RequestChannelClosed
        Indicates that a RestRequest has been closed and an operation could not be performed on it.
      • RequestResponseQueuingFailure

        public static final RestServiceErrorCode RequestResponseQueuingFailure
        Indicates that the submitted request or response could not be queued in the AsyncRequestResponseHandler.
      • RequestTooLarge

        public static final RestServiceErrorCode RequestTooLarge
        The request is larger than what the server is willing or is configured to accept.
      • ServiceUnavailable

        public static final RestServiceErrorCode ServiceUnavailable
        Indicates that the service is unavailable because one or more of the components is not started, is shutdown, has crashed or is temporarily unable to respond.
      • TooManyRequests

        public static final RestServiceErrorCode TooManyRequests
        Application rate limit exceeded/Application quota limit exceeded.
      • UnsupportedRestMethod

        public static final RestServiceErrorCode UnsupportedRestMethod
        Indicates a RestMethod is not supported (May also indicate a bug where behaviour for a new RestMethod has not been defined in the implementation).
      • InsufficientCapacity

        public static final RestServiceErrorCode InsufficientCapacity
        There is insufficient capacity to service the request.
      • PreconditionFailed

        public static final RestServiceErrorCode PreconditionFailed
        The conditions given in the request header fields evaluated to false.
      • Conflict

        public static final RestServiceErrorCode Conflict
        Request conflicts with the current state of the server.
    • Method Detail

      • values

        public static RestServiceErrorCode[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (RestServiceErrorCode c : RestServiceErrorCode.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static RestServiceErrorCode valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • getRestServiceErrorCode

        public static RestServiceErrorCode getRestServiceErrorCode​(RouterErrorCode routerErrorCode)
        Gets the RestServiceErrorCode that corresponds to the routerErrorCode.
        Parameters:
        routerErrorCode - input RouterErrorCode.
        Returns:
        the RestServiceErrorCode that the routerErrorCode belongs to.
      • getRestServiceErrorCode

        public static RestServiceErrorCode getRestServiceErrorCode​(AccountServiceErrorCode accountServiceErrorCode)
        Gets the RestServiceErrorCode that corresponds to the accountServiceErrorCode.
        Parameters:
        accountServiceErrorCode - input AccountServiceErrorCode.
        Returns:
        the RestServiceErrorCode that the accountServiceErrorCode belongs to.