We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
This issue has been transferred from the Azure SDK for .NET repository, #35762.
Microsoft.Azure.WebJobs.Extensions.SignalRService ( 1.9.0 ), Microsoft.Azure.WebJobs.Extensions.CosmosDB ( 4.2.0), Microsoft.NET.Sdk.Functions ( 4.1.3)
Given a generic ServerlessHub that successfully negotiates I have the following function invoked from the signalR client
[FunctionName(nameof(InitialPlayerData))] public Task InitialPlayerData( [SignalRTrigger] InvocationContext invocationContext, [CosmosDB("Crib", "Players", Connection = "CosmosConnectionString", Id = "{UserId}", PartitionKey = "{UserId}")] Player player, ILogger logger) { ..... }
Can I bind the UserId parameter ?
I checked with ChatGPT and it agreed that the CosmosDB attribute appeared correct.
If I change to using the CosmosClient directly the function is executed
[FunctionName(nameof(InitialPlayerData))] async public Task InitialPlayerData( [SignalRTrigger] InvocationContext invocationContext, [CosmosDB(Connection = "CosmosConnectionString")] CosmosClient cosmosClient, ILogger logger) { //.......
Should bind.
Does not bind.
Not the easiest thing to reproduce given that requires an authentication service, a client app and azure configuration.
I can provide further details but I would just like to know if it is possible to bind to the UserId property.
[CosmosDB("Crib", "Players", Connection = "CosmosConnectionString", Id = "{UserId}", PartitionKey = "{UserId}")]
Azure Functions.
<Project Sdk="Microsoft.NET.Sdk"> <PropertyGroup> <TargetFramework>net6.0</TargetFramework> <AzureFunctionsVersion>v4</AzureFunctionsVersion> </PropertyGroup> <ItemGroup> <PackageReference Include="Microsoft.Azure.WebJobs.Extensions.CosmosDB" Version="4.2.0" /> <PackageReference Include="Microsoft.Azure.WebJobs.Extensions.SignalRService" Version="1.9.0" /> <PackageReference Include="Microsoft.NET.Sdk.Functions" Version="4.1.3" /> </ItemGroup>
Visual Studio 17.5.1
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Issue Transfer
This issue has been transferred from the Azure SDK for .NET repository, #35762.
Please be aware that @tonyhallett is the author of the original issue and include them for any questions or replies.
Details
Library name and version
Microsoft.Azure.WebJobs.Extensions.SignalRService ( 1.9.0 ), Microsoft.Azure.WebJobs.Extensions.CosmosDB ( 4.2.0), Microsoft.NET.Sdk.Functions ( 4.1.3)
Describe the bug
Given a generic ServerlessHub that successfully negotiates I have the following function invoked from the signalR client
Can I bind the UserId parameter ?
I checked with ChatGPT and it agreed that the CosmosDB attribute appeared correct.
If I change to using the CosmosClient directly the function is executed
Expected behavior
Should bind.
Actual behavior
Does not bind.
Reproduction Steps
Not the easiest thing to reproduce given that requires an authentication service, a client app and azure configuration.
I can provide further details but I would just like to know if it is possible to bind to the UserId property.
Environment
Azure Functions.
Visual Studio 17.5.1
The text was updated successfully, but these errors were encountered: