question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Cosmos DB Trigger] Null _ts, _etag etc. properties from IReadOnlyList parameters.

See original GitHub issue

Hi,

It appears that I can’t read _ts, _etag etc. properties from the change feed, even though I have them set in my entity like so:

[JsonConverter(typeof(UnixDateTimeConverter))]
[JsonProperty("_ts")]
public DateTime? LastModified {get;set;}

[JsonProperty("_etag")]
public string? Etag {get;set;}

I need this properties for processing my dead letter queue.

Thanks

Edit: This started working when I switch to the system text json custom serializer.

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:19 (11 by maintainers)

github_iconTop GitHub Comments

1reaction
ealsurcommented, May 27, 2022

The 2 Nugets I mention are the ones I authored, I’m not sure what the Worker version of the Nuget includes (the Dependencies section is empty) but looking at the Versions, it’s a mirror with the other ones.

So assuming that, it should work the same way (3.X uses the V2 SDK and Document, 4.X uses V3 SDK and can use your custom <T>), but since I didn’t author or work on those, I cannot confirm.

@Ved2806 - I cannot comment on the Worker packages as I don’t know who authored them or what they contain. I tried to repro the scenario with the packages we author and the scenario is simply not possible (using Entity instead of Document with version 3.0.9). Whoever owns the Worker packages might be able to comment on what do they actually include and work.

0reactions
msftbot[bot]commented, Nov 8, 2022

This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Azure Function App CosmosDbTrigger Gives Null ...
Running the Function manually works for things like HttpTrigger. The error you are seeing is because, when you use the Run in the...
Read more >
TriggerProperties.ETag Property
Gets the entity tag associated with the resource from the Azure Cosmos DB service. C# Copy. [Newtonsoft.Json.JsonProperty(NullValueHandling=Newtonsoft.Json.
Read more >
Troubleshoot issues with the Azure Functions trigger for ...
This error means that one or both of the Azure Cosmos DB containers that are required for the trigger to work either: Don't...
Read more >
functions-bindings-cosmosdb-v2-trigger.md
Learn to use the Azure Cosmos DB trigger in Azure Functions. reference ... true)]IReadOnlyList<ToDoItem> input, ILogger log) { if (input != null &&...
Read more >
Azure Cosmos DB bindings for Functions 1.x
This binding was originally named DocumentDB. In Azure Functions version 1.x, only the trigger was renamed Azure Cosmos DB; the input binding, output...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found