[Cosmos DB] Suppress output (resourceBody) for successful batch operation
See original GitHub issue- Package Name: @azure/cosmos
- Package Version: 3.9.1
- Operating system: MacOS
- nodejs
- version: 10.16.3
- browser
- name/version:
- typescript
- version:
- Is the bug related to documentation in
- README.md
- source code documentation
- SDK API docs on https://docs.microsoft.com
Describe the bug
Not really a bug but more of a clarification question. When I perform a batch/bulk operation (say Upsert), for all the documents that returned 200 status code, the document content is echoed back in resourceBody
:
{
statusCode: 200,
requestCharge: 12.952380952380953,
eTag: '"2f0079c7-0000-0700-0000-5f5b90960000"',
resourceBody: {
"FirstName": "Blah",
"LastName": "Blah",
"ZipCode": "22222"
}
}
I am wondering if there’s a parameter that I can pass to the operation which essentially does not echo back the resource body? I would very much like the response to look like:
{
statusCode: 200,
requestCharge: 12.952380952380953,
eTag: '"2f0079c7-0000-0700-0000-5f5b90960000"',
}
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Transactional batch operations in Azure Cosmos DB using the ...
Learn how to use TransactionalBatch in the Azure Cosmos DB .NET or Java SDK to perform a group of point operations that either...
Read more >Cosmos DB - TransactionalBatch support #17771 - GitHub
OperationResults contain all the individual operation results, each operation in a batch has its own response. Each operation result exposes: // ...
Read more >azcosmos - Go Packages
Azure Cosmos DB is a globally distributed, multi-model database service. ... operation results for index, operation := range batchResponse.
Read more >How to do bulk and transactional batch operations ... - YouTube
Matías Quaranta shows Donovan Brown how to do bulk operations with the Azure Cosmos DB .NET SDK to maximize throughput, and how to...
Read more >Suppress command line output - batch file - Stack Overflow
ERROR: The process "test.exe" not found. Why does this error message get displayed, even though I have redirected output to NUL? How can...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thanks for the reply @gmantri. Cosmos has support for
Prefer
in the request headers as well, I believe we support it in places in the SDK. I can look into if it already works with Bulk or what we need to do to get it working. Thanks again!Thanks @zfoster! I’ll close this issue now. Hoping to see the support for this in the SDK soon. I do have a clarification question about the bulk operations (basically trying to understand the behavior). I will create a separate issue for that.