-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adopt new bag-of-bytes protocol (#55)
Motivation: The core package added a bag-of-bytes protocol which transports must be generic over. We need to adopt those changes here. Modifications: - Add a `GRPCNIOTransportBytes` type which wraps `ByteBuffer` and implements the `GRPCContiguousBytes` protocol. - Use this as the bytes type for client/server transports. - Update the appropriate state machines to deal in terms of `ByteBuffer` - Update the compressor/decompressor to deal in terms of `ByteBuffer` - Update tests Result: Avoid unconditonal copying of messages to/from `[UInt8]`/`ByteBuffer`
- Loading branch information
Showing
42 changed files
with
789 additions
and
354 deletions.
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
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
24 changes: 24 additions & 0 deletions
24
IntegrationTests/grpc-performance-tests/Sources/Generated/grpc_testing_control.grpc.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,24 @@ | ||
// Copyright 2015 gRPC authors. | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// DO NOT EDIT. | ||
// swift-format-ignore-file | ||
// | ||
// Generated by the gRPC Swift generator plugin for the protocol buffer compiler. | ||
// Source: grpc/testing/control.proto | ||
// | ||
// For information on using the generated types, please see the documentation: | ||
// https://github.com/grpc/grpc-swift | ||
|
||
// This file contained no services. |
26 changes: 26 additions & 0 deletions
26
IntegrationTests/grpc-performance-tests/Sources/Generated/grpc_testing_messages.grpc.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,26 @@ | ||
// Copyright 2015-2016 gRPC authors. | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Message definitions to be used by integration test service definitions. | ||
|
||
// DO NOT EDIT. | ||
// swift-format-ignore-file | ||
// | ||
// Generated by the gRPC Swift generator plugin for the protocol buffer compiler. | ||
// Source: grpc/testing/messages.proto | ||
// | ||
// For information on using the generated types, please see the documentation: | ||
// https://github.com/grpc/grpc-swift | ||
|
||
// This file contained no services. |
24 changes: 24 additions & 0 deletions
24
IntegrationTests/grpc-performance-tests/Sources/Generated/grpc_testing_payloads.grpc.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,24 @@ | ||
// Copyright 2015 gRPC authors. | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// DO NOT EDIT. | ||
// swift-format-ignore-file | ||
// | ||
// Generated by the gRPC Swift generator plugin for the protocol buffer compiler. | ||
// Source: grpc/testing/payloads.proto | ||
// | ||
// For information on using the generated types, please see the documentation: | ||
// https://github.com/grpc/grpc-swift | ||
|
||
// This file contained no services. |
24 changes: 24 additions & 0 deletions
24
IntegrationTests/grpc-performance-tests/Sources/Generated/grpc_testing_stats.grpc.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,24 @@ | ||
// Copyright 2015 gRPC authors. | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// DO NOT EDIT. | ||
// swift-format-ignore-file | ||
// | ||
// Generated by the gRPC Swift generator plugin for the protocol buffer compiler. | ||
// Source: grpc/testing/stats.proto | ||
// | ||
// For information on using the generated types, please see the documentation: | ||
// https://github.com/grpc/grpc-swift | ||
|
||
// This file contained no services. |
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
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
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.