Allow reuse client for external GRPC services#3208
Merged
crosbymichael merged 1 commit intocontainerd:masterfrom Apr 16, 2019
Merged
Allow reuse client for external GRPC services#3208crosbymichael merged 1 commit intocontainerd:masterfrom
crosbymichael merged 1 commit intocontainerd:masterfrom
Conversation
Codecov Report
@@ Coverage Diff @@
## master #3208 +/- ##
=======================================
Coverage 44.63% 44.63%
=======================================
Files 113 113
Lines 12161 12161
=======================================
Hits 5428 5428
Misses 5898 5898
Partials 835 835
Continue to review full report at Codecov.
|
13 tasks
Member
|
I'd rather just export the Conn() on the client than make a public func like this. Can we do that? |
Member
Author
|
@crosbymichael that works too. Done. |
Signed-off-by: Maksym Pavlenko <[email protected]>
Member
|
LGTM |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
In firecracker-containerd project we use GRPC plugins to extend containerd's functionality and we have to manage a separate client in order to make calls.
It would be great if we could reuse existing containerd's client (e.g. reuse connection object, namespace handling, reconnect logic, etc) to invoke external grpc services as well.
The proposed solution adds
ExternalServiceand looks as follows:Signed-off-by: Maksym Pavlenko [email protected]