Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error_model_alignment #213

Merged
merged 19 commits into from
Jun 11, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
240 changes: 149 additions & 91 deletions artifacts/CAMARA_common.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ info:
license:
name: Apache 2.0
url: https://www.apache.org/licenses/LICENSE-2.0.html
version: 0.4.0
version: 0.4.0-wip
paths: {}
components:
schemas:
Expand Down Expand Up @@ -124,27 +124,7 @@ components:
example:
status: 400
code: INVALID_ARGUMENT
message: Client specified an invalid argument, request body or query param
Conflict:
description: Conflict
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 409
code: CONFLICT
message: Request could not be processed due to a conflict
FailedPrecondition:
description: Failed precondition
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 412
code: FAILED_PRECONDITION
message: Request cannot be executed in the current system state.
message: Client specified an invalid argument, request body or query param.
OutOfRange:
description: Out of Range
content:
Expand All @@ -154,7 +134,7 @@ components:
example:
status: 400
code: OUT_OF_RANGE
message: Client specified an invalid range
message: Client specified an invalid range.
Unauthenticated:
description: Not Authenticated
content:
Expand All @@ -164,7 +144,17 @@ components:
example:
status: 401
code: UNAUTHENTICATED
message: Request not authenticated due to missing, invalid, or expired
message: Request not authenticated due to missing, invalid, or expired credentials.
AuthenticationRequired:
description: Authentication Required
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 401
code: AUTHENTICATION_REQUIRED
message: New authentication is required.
PermissionDenied:
description: Permission denied
content:
Expand All @@ -174,7 +164,17 @@ components:
example:
status: 403
code: PERMISSION_DENIED
message: Client does not have sufficient permissions to perform
message: Client does not have sufficient permissions to perform this action.
InvalidTokenContext:
description: Invalid Token Context
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 403
code: INVALID_TOKEN_CONTEXT
message: \`{{field}}\` is not consistent with access token.
NotFound:
description: Not Found
content:
Expand All @@ -185,6 +185,53 @@ components:
status: 404
code: NOT_FOUND
message: The specified resource is not found.
DeviceNotFound:
description: Device Not Found
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 404
code: DEVICE_NOT_FOUND
message: Device identifier not found.
NotFoundAndOutOfRange:
description: Out Of Range and Not Found
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
examples:
OutOfRange:
value:
status: 404
code: OUT_OF_RANGE
message: Out Of Range.
NotFound:
value:
status: 404
code: NOT_FOUND
message: Not found.
MethodNotAllowed:
description: Method not allowed
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 405
code: METHOD_NOT_ALLOWED
message: The requested method is not allowed/supported on the target resource.
NotAcceptable:
description: Not Acceptable
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 406
code: NOT_ACCEPTABLE
message: The server cannot produce a response matching the content requested by the client through `Accept-*` headers.
Aborted:
description: Aborted
content:
Expand All @@ -194,7 +241,7 @@ components:
example:
status: 409
code: ABORTED
message: Request aborted.
message: Concurrency conflict.
AlreadyExists:
description: Already Exists
content:
Expand All @@ -205,122 +252,133 @@ components:
status: 409
code: ALREADY_EXISTS
message: The resource that a client tried to create already exists.
TooManyRequests:
description: Too Many Requests
Conflict:
description: Conflict
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 429
code: TOO_MANY_REQUESTS
message: Either out of resource quota or reaching rate limiting.
Internal:
description: Internal Error
status: 409
code: CONFLICT
message: A specified resource duplicate entry found.
Gone:
description: Gone
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 500
code: INTERNAL
message: Unknown server error.Typically a server bug.
BadGateway:
description: Bad Gateway
status: 410
code: GONE
message: Access to the target resource is no longer available.
FailedPrecondition:
description: Failed precondition
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 502
code: BAD_GATEWAY
message: Couldn't reach an upstream internal service.
Unavailable:
description: Service Unavailable
status: 412
code: FAILED_PRECONDITION
message: Request cannot be executed in the current system state.
UnsupportedMediaType:
description: Unsupported Media Type
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 503
code: UNAVAILABLE
message: Service unavailable
Timeout:
description: Timeout
status: 415
code: UNSUPPORTED_MEDIA_TYPE
message: The server refuses to accept the request because the payload format is in an unsupported format.
DeviceIdentifiersMismatch:
description: Device Identifiers mismatch
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 504
code: TIMEOUT
message: Request timeout exceeded
NotImplemented:
description: Not Implemented
status: 422
code: DEVICE_IDENTIFIERS_MISMATCH
message: Provided device identifiers are not consistent.
DeviceNotApplicable:
description: Device not applicable for the service
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 501
code: NOT_IMPLEMENTED
message: This functionality is not implemented yet
AuthenticationRequired:
description: Authentication Required
status: 422
code: DEVICE_NOT_APPLICABLE
message: The service is not available for the provided device.
TooManyRequests:
description: Too Many Requests
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 401
code: AUTHENTICATION_REQUIRED
message: New authentication is required
NotFoundAndOutOfRange:
description: Out Of Range and Not Found
status: 429
code: TOO_MANY_REQUESTS
message: Either out of resource quota or reaching rate limiting.
Internal:
description: Internal Error
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
examples:
OutOfRange:
value:
status: 404
code: OUT_OF_RANGE
message: Out Of Range
NotFound:
value:
status: 404
code: NOT_FOUND
message: Not found
MethodNotAllowed:
description: Method not allowed
example:
status: 500
code: INTERNAL
message: Unknown server error. Typically a server bug.
DataLoss:
description: Data Loss
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 405
code: METHOD_NOT_ALLOWED
message: The requested method is not allowed/supported on the target
NotAcceptable:
description: Not Acceptable
status: 500
code: DATA_LOSS
message: Unrecoverable data loss or data corruption.
NotImplemented:
description: Not Implemented
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 406
code: NOT_ACCEPTABLE
message: The server can't produce a response matching the content requested
by the client through Accept-* headers
UnsupportedMediaType:
description: Unsupported Media Type
status: 501
code: NOT_IMPLEMENTED
message: This functionality is not implemented yet.
BadGateway:
description: Bad Gateway
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 415
code: UNSUPPORTED_MEDIA_TYPE
message: The server refuses to accept the request because the payload format
is in an unsupported format.
status: 502
code: BAD_GATEWAY
message: An upstream internal service cannot be reached.
Unavailable:
description: Service Unavailable
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 503
code: UNAVAILABLE
message: Service unavailable.
Timeout:
description: Timeout
content:
application/json:
schema:
$ref: "#/components/schemas/ErrorInfo"
example:
status: 504
code: TIMEOUT
message: Request timeout exceeded.
Loading