Skip to content
New issue

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

How to bind function return value to trigger in isolated worker? #3095

Open
Y-Sindo opened this issue Sep 18, 2024 · 0 comments
Open

How to bind function return value to trigger in isolated worker? #3095

Y-Sindo opened this issue Sep 18, 2024 · 0 comments

Comments

@Y-Sindo
Copy link
Member

Y-Sindo commented Sep 18, 2024

Original issue: Azure/azure-functions-dotnet-worker#1496

Repro steps

Provide the steps required to reproduce the problem

Expected behavior

The client code as follows should get the return value from the function, instead of a null.

var responseFromServer = await connection.InvokeAsync<string>("SendMessage", "Hello from client");

And the client should print out the return value "This is message from SignalRTrigger" returned by function app code

Actual behavior

The variable responseFromServer is always null.

Known workarounds

No

Related information

Provide any related information

The return value works if the function app is in C# in-process mode.

During debug, I've found that the SignalR Microsoft.Azure.WebJobs.Host.Triggers.ITriggerData.ReturnValueProvider.SetValueAsync(object value, CancellationToken cancellationToken) is always invoked with parameter value=null with isolated worker.

Anyone could provide some hints on how to troubleshoot the problem? @brettsam @fabiocav

@Y-Sindo Y-Sindo changed the title With isolated worker, value passed to ITriggerData.ReturnValueProvider.SetValueAsync() is always null even though $return is defined in binding data contract In isolated worker, value passed to ITriggerData.ReturnValueProvider.SetValueAsync() is always null even though $return is defined in binding data contract Sep 18, 2024
@Y-Sindo Y-Sindo changed the title In isolated worker, value passed to ITriggerData.ReturnValueProvider.SetValueAsync() is always null even though $return is defined in binding data contract How to bind function return value to trigger in isolated worker? Sep 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant