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
When RaiseEventAsync("NonExistantId", "SomeEvent1", "SomeData");' is called in the HttpTrigger below, we receive an exception of type Grpc.Core.RpcExceptionwith the message:Status(StatusCode="Unknown", Detail="Exception was thrown by handler.")`
Errormessage:
[2024-10-23T09:25:13.418Z] Host lock lease acquired by instance ID '000000000000000000000000430AE0B1'.
[2024-10-23T09:25:18.221Z] Executing 'Functions.FireEvent1' (Reason='This function was programmatically called via the host APIs.', Id=6945c0db-70e1-40c1-bf15-0df2e7e486d7)
[2024-10-23T09:25:18.508Z] dbug: DurableFunctionsIsolated.ExternalTriggers[0]
[2024-10-23T09:25:18.509Z] Firing event from trigger: 'FireEvent1'
[2024-10-23T09:25:31.249Z] Grpc.Core.RpcException: Status(StatusCode="Unknown", Detail="Exception was thrown by handler.")
[2024-10-23T09:25:31.250Z] at Microsoft.DurableTask.Client.Grpc.GrpcDurableTaskClient.RaiseEventAsync(String instanceId, String eventName, Object eventPayload, CancellationToken cancellation)
[2024-10-23T09:25:31.251Z] at DurableFunctionsIsolated.ExternalTriggers.FireEvent1(HttpRequestData request, DurableTaskClient client) in D:\playground\FunctionAppIsolatedDotNet7\DurableFunctionsIsolated\ExternalTriggers.cs:line 25
Example
Example of HttpTrigger used. The catch implementation is just a default here to see in the debugger what kind of exception is thrown:
[Function(nameof(FireEvent1))]publicasyncTask<HttpResponseData>FireEvent1([HttpTrigger(AuthorizationLevel.Anonymous,"get",Route="trigger/event1")]HttpRequestDatarequest,[DurableClient]DurableTaskClientclient){_logger.LogDebug("Firing event from trigger: '{trigger}'",nameof(FireEvent1));try{awaitclient.RaiseEventAsync("NonExistantId","SomeEvent1","SomeData");//Constants.OrchestratorInstanceId, Constants.Event1, "Some data from event 1");}catch(Exceptione){Console.WriteLine(e);throw;}returnrequest.CreateResponse(HttpStatusCode.OK);}
The documentation of the .RaiseEventas stated here says the following: Raised events for a completed or non-existent orchestration instance will be silently discarded.
That is obviously not the case. Some other folks have the same issue. Check this issue
The text was updated successfully, but these errors were encountered:
When
RaiseEventAsync("NonExistantId", "SomeEvent1", "SomeData");' is called in the HttpTrigger below, we receive an exception of type
Grpc.Core.RpcExceptionwith the message:
Status(StatusCode="Unknown", Detail="Exception was thrown by handler.")`Errormessage:
[2024-10-23T09:25:13.418Z] Host lock lease acquired by instance ID '000000000000000000000000430AE0B1'.
[2024-10-23T09:25:18.221Z] Executing 'Functions.FireEvent1' (Reason='This function was programmatically called via the host APIs.', Id=6945c0db-70e1-40c1-bf15-0df2e7e486d7)
[2024-10-23T09:25:18.508Z] dbug: DurableFunctionsIsolated.ExternalTriggers[0]
[2024-10-23T09:25:18.509Z] Firing event from trigger: 'FireEvent1'
[2024-10-23T09:25:31.249Z] Grpc.Core.RpcException: Status(StatusCode="Unknown", Detail="Exception was thrown by handler.")
[2024-10-23T09:25:31.250Z] at Microsoft.DurableTask.Client.Grpc.GrpcDurableTaskClient.RaiseEventAsync(String instanceId, String eventName, Object eventPayload, CancellationToken cancellation)
[2024-10-23T09:25:31.251Z] at DurableFunctionsIsolated.ExternalTriggers.FireEvent1(HttpRequestData request, DurableTaskClient client) in D:\playground\FunctionAppIsolatedDotNet7\DurableFunctionsIsolated\ExternalTriggers.cs:line 25
Example
Example of HttpTrigger used. The catch implementation is just a default here to see in the debugger what kind of exception is thrown:
The documentation of the
.RaiseEvent
as stated here says the following:Raised events for a completed or non-existent orchestration instance will be silently discarded.
That is obviously not the case. Some other folks have the same issue. Check this issue
The text was updated successfully, but these errors were encountered: