Skip to content

Commit c56f370

Browse files
committed
Add nascent document type support for rpcv2Cbor
As the compatibility of document types across protocols that use different wire serialization formats (JSON, CBOR) is built, it must be possible to specify them together. Using documents with rpcv2Cbor is still a DANGER level event, as it won't work in most cases.
1 parent bed9664 commit c56f370

File tree

4 files changed

+3
-2
lines changed

4 files changed

+3
-2
lines changed

smithy-protocol-traits/src/main/resources/META-INF/smithy/smithy.protocols.rpcv2.smithy

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ use smithy.api#httpError
1818
@traitValidators(
1919
"rpcv2Cbor.NoDocuments": {
2020
selector: "service ~> member :test(> document)"
21-
message: "This protocol does not support document types"
21+
message: "This protocol does not support document types in most possible scenarios."
22+
severity: "DANGER"
2223
}
2324
)
2425
structure rpcv2Cbor {
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
[DANGER] smithy.example#DocumentOperationInput$document: Found an incompatible shape when validating the constraints of the `smithy.protocols#rpcv2Cbor` trait attached to `smithy.example#DocumentService`: This protocol does not support document types in most possible scenarios. | rpcv2Cbor.NoDocuments

smithy-protocol-traits/src/test/resources/software/amazon/smithy/protocol/traits/errorfiles/no-document-support.smithy renamed to smithy-protocol-traits/src/test/resources/software/amazon/smithy/protocol/traits/errorfiles/nascent-document-support.smithy

File renamed without changes.

smithy-protocol-traits/src/test/resources/software/amazon/smithy/protocol/traits/errorfiles/no-document-support.errors

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)