forked from googleapis/google-cloud-cpp
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(generator): merge connection options into client options
Store the Connection options so that they may be made available to merge into the Client options, and then use them to implement the four polling-policy data elements. (This is the generator version of googleapis#8090.) Rules of thumb for `Options` values: - `MergeOptions()` LHS should not include the service defaults - `MergeOptions()` RHS should include service defaults - An `OptionsSpan` should include the service defaults - stored `Options` (data members) should include the service defaults Code can then normally just look at the `CurrentOptions()`, knowing that they will include the service defaults. For example, the policy options will be available. A special exception to this, however, is when testing the connection layer in isolation (without a client), as no one has created an `OptionsSpan` in that case. We could add an `OptionsSpan` to the connection-layer calls, but it would be a no-op in practice. So, tests need to ensure required options are available. Fixes googleapis#8054.
- Loading branch information
Showing
4 changed files
with
35 additions
and
33 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
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