Cosmos DB & Azure Functions differences #9829
Replies: 3 comments 1 reply
-
|
it would appear that there is a difference in functionality with a functions project and other aspire projects. For the functions project it would appear that the connection strings aren't setup in the builder for the functions project but are for others. The 'workaround' appears to be to create a different connection string in the host, and reference that instead in the functions project. and then use 'container2' in the functions project. At least the Container instance can now be created. I'm not sure if this is by design, or an issue. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
|
I am curious about this, but I got 404 not found for https://github.com/VistianOpenSource/AspireCosmosDb/tree/master link. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Are there any documented differences in the way Aspire & Azure functions projects work/interact?
I have a simple solution whereby the Cosmos DB setup occurs correctly within the App Host, and I can get an Api Service solution to correctly reference the Cosmos Db Container, but when I try and repeat the same code within the Azure Functions project, it results in an exception.
The 'nub' of the exception appears to be
Yet the 'registration within both the host project, the web api project and the azure functions project appears to be identical.
See https://github.com/VistianOpenSource/AspireCosmosDb/tree/master
Beta Was this translation helpful? Give feedback.
All reactions