-
Notifications
You must be signed in to change notification settings - Fork 82
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
chore: move RPCv2CBOR implementation to smithy-swift #1881
Open
dayaffe
wants to merge
28
commits into
main
Choose a base branch
from
day/move-rpcv2
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
28 commits
Select commit
Hold shift + click to select a range
e83bbd0
Add ValidationResponseHeader middleware and RpcV2CborError and create…
dayaffe a41842a
add response integration
dayaffe 2aac33b
Merge branch 'main' into day/rpcv2-cbor
dayaffe 52bbce9
current version only has 3/69 failing protocol tests
dayaffe d1b2522
all tests passing now
dayaffe 22eca82
Merge branch 'main' into day/rpcv2-cbor
dayaffe 7db1681
Merge branch 'main' into day/rpcv2-cbor
dayaffe fd81a61
use getServiceName()
dayaffe ee580c4
fix one set of tests
dayaffe d75bb05
fix another test
dayaffe 44a838c
try to fix ktlint issues
dayaffe 854c28a
Merge branch 'main' into day/rpcv2-cbor
dayaffe 35971c9
remove leftover code
dayaffe 3068334
shorten middleware names due to swiftlint
dayaffe d579676
Merge branch 'main' into day/rpcv2-cbor
dayaffe 9c5123c
address PR comments
dayaffe 0a4e077
Move CBOR implementation to smithy-swift
dayaffe 746a0a9
Merge branch 'main' into day/move-rpcv2
dayaffe 10db612
remove OperationEndpointResolverMiddleware
dayaffe d1c64db
delete stuff that should've been deleted
dayaffe a87de26
add back missing import
dayaffe dd6467d
ktlint fixes
dayaffe 1a6218d
separate AWS vs default versions of operation resolver middleware
dayaffe d5ac13e
Merge branch 'main' into day/move-rpcv2
dayaffe 974f29d
try to ktlint
dayaffe 11988d8
try to ktlint
dayaffe 70887a6
swiftlint new line
dayaffe e0dfd7e
small change in naming
dayaffe File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
47 changes: 0 additions & 47 deletions
47
...time/Sources/AWSClientRuntime/Middlewares/RpcV2CborValidateResponseHeaderMiddleware.swift
This file was deleted.
Oops, something went wrong.
29 changes: 29 additions & 0 deletions
29
...Runtime/Sources/AWSClientRuntime/Protocols/RpcV2Cbor/RpcV2CborError+QueryCompatible.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
// | ||
// Copyright Amazon.com Inc. or its affiliates. | ||
// All Rights Reserved. | ||
// | ||
// SPDX-License-Identifier: Apache-2.0 | ||
// | ||
|
||
@_spi(SmithyReadWrite) import struct ClientRuntime.RpcV2CborError | ||
@_spi(SmithyReadWrite) import class SmithyCBOR.Reader | ||
import class SmithyHTTPAPI.HTTPResponse | ||
|
||
// support awsQueryCompatible trait | ||
extension RpcV2CborError { | ||
@_spi(SmithyReadWrite) | ||
public static func makeQueryCompatibleError( | ||
httpResponse: HTTPResponse, | ||
responseReader: Reader, | ||
noErrorWrapping: Bool, | ||
errorDetails: String? | ||
) throws -> RpcV2CborError { | ||
let errorCode = try AwsQueryCompatibleErrorDetails.parse(errorDetails).code | ||
return try RpcV2CborError( | ||
httpResponse: httpResponse, | ||
responseReader: responseReader, | ||
noErrorWrapping: noErrorWrapping, | ||
code: errorCode | ||
) | ||
} | ||
} |
65 changes: 0 additions & 65 deletions
65
...s/Core/AWSClientRuntime/Sources/AWSClientRuntime/Protocols/RpcV2Cbor/RpcV2CborError.swift
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
since AwsQueryCompatibleErrorDetails logic is aws-specific, remains in aws-sdk-swift