Skip to content

Commit

Permalink
warn about custom error queue when doing integration
Browse files Browse the repository at this point in the history
  • Loading branch information
tmasternak authored Jan 13, 2025
1 parent 0a4757f commit c2fe525
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@ static async Task Main()
endpointConfiguration.UseSerialization<NewtonsoftJsonSerializer>();
endpointConfiguration.EnableInstallers();
endpointConfiguration.UsePersistence<InMemoryPersistence>();
endpointConfiguration.SendFailedMessagesTo("error");

#region ServiceControlEventsMonitorCustomErrorQueue
endpointConfiguration.SendFailedMessagesTo("error-monitoring");
#endregion

var transport = endpointConfiguration.UseTransport<LearningTransport>();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@ static async Task Main()
endpointConfiguration.UseSerialization<NewtonsoftJsonSerializer>();
endpointConfiguration.EnableInstallers();
endpointConfiguration.UsePersistence<NonDurablePersistence>();
endpointConfiguration.SendFailedMessagesTo("error");

#region ServiceControlEventsMonitorCustomErrorQueue
endpointConfiguration.SendFailedMessagesTo("error-monitoring");
#endregion

var transport = endpointConfiguration.UseTransport<LearningTransport>();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@ static async Task Main()
endpointConfiguration.UseSerialization<NewtonsoftJsonSerializer>();
endpointConfiguration.EnableInstallers();
endpointConfiguration.UsePersistence<NonDurablePersistence>();
endpointConfiguration.SendFailedMessagesTo("error");

#region ServiceControlEventsMonitorCustomErrorQueue
endpointConfiguration.SendFailedMessagesTo("error-monitoring");
#endregion

var transport = endpointConfiguration.UseTransport<LearningTransport>();

Expand Down
4 changes: 4 additions & 0 deletions samples/servicecontrol/events-subscription/sample.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,10 @@ In order to get notifications when the exposed ServiceControl events occur, crea

snippet: ServiceControlEventsHandlers

> [!IMPORTANT]
> In order to prevent infinate message loops (processing of an integration event fails, the faulting message is moved to the ServiceControl error queue and triggers yet another integration event) the monitoring endpoint must use a dedicated error queue, separte from the ServiceControl one.
snippet: ServiceControlEventsMonitorCustomErrorQueue

## Notes on other transports

Expand Down

0 comments on commit c2fe525

Please sign in to comment.