You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm encountering an issue with the CosmosDBTrigger in an Azure Function using the isolated process model. When documents are triggered by changes in a Cosmos DB collection, the CosmosDBTrigger seems to alter the format of DateTimeOffset fields in the JSON payload.
Repro steps
Set up an Azure Function with a CosmosDBTrigger to monitor changes in a Cosmos DB collection.
This seems related to Date Time Handling. When the raw JSON comes from the service, in order to bind it to string (the type on your trigger), it gets serialized through Newtonsoft.Json (the default engine for Cosmos DB SDK).
Newtonsoft.Json has a default Json serialization behavior for dates which does DateTime conversion with timezones.
I'm encountering an issue with the CosmosDBTrigger in an Azure Function using the isolated process model. When documents are triggered by changes in a Cosmos DB collection, the CosmosDBTrigger seems to alter the format of DateTimeOffset fields in the JSON payload.
Repro steps
Set up an Azure Function with a CosmosDBTrigger to monitor changes in a Cosmos DB collection.
Expected behavior
The CosmosDBTrigger should pass the document as-is without altering the format or values.
Actual behavior
The date field in the JSON document is modified.
Known workarounds
none.
Related information
Microsoft.Azure.Functions.Worker, Version="1.22.0"
Microsoft.Azure.Functions.Worker.Extensions.CosmosDB, Version="4.9.0"
Microsoft.Azure.Functions.Worker.Extensions.Http, Version="3.2.0"
Microsoft.Azure.Functions.Worker.Extensions.Http.AspNetCore, Version="1.3.2"
Microsoft.Azure.Functions.Worker.Sdk, Version="1.17.2"
Microsoft.ApplicationInsights.WorkerService, Version="2.22.0"
Microsoft.Azure.Functions.Worker.ApplicationInsights, Version="1.2.0"
The text was updated successfully, but these errors were encountered: