-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Set resourceResponse in CosmosResponse #6076
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
Set resourceResponse in CosmosResponse #6076
Conversation
…parent CosmosResponse class
|
|
||
| CosmosContainerResponse(CosmosAsyncContainerResponse response, CosmosDatabase database, CosmosClient client) { | ||
| super(response.getProperties()); | ||
| super(response.resourceResponseWrapper, response.getProperties()); |
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.
Won't sending wrapper out break design abstractions?
Or what should be the right abstraction.
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.
wrapper is already being used in all the public API classes as to fetch the properties. This won't break out the abstraction design.
This will just make sure to assign the wrapper in the parent class from the response object.
|
/azp run java - cosmos - tests |
|
Azure Pipelines successfully started running 1 pipeline(s). |
mbhaskar
left a comment
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.
Can we add tests for these?
|
/azp run java - cosmos - tests |
|
Azure Pipelines successfully started running 1 pipeline(s). |
mbhaskar
left a comment
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.
Thanks. LGTM
Sync responses were not setting resourceResponse in parent class
CosmosResponseThis was causing sync responses to throw NPE in a bunch of methods like
getRequestLatency()getRequestCharge()and almost every other method.