Skip to content

Commit

Permalink
Update docs for cloudevents options (#216)
Browse files Browse the repository at this point in the history
  • Loading branch information
heqianwang authored Feb 21, 2025
1 parent 126f8b6 commit 6acfa8e
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -300,10 +300,18 @@ It can be configured by setting the `MaxRetries` property in the `EventGridSubsc
You can use the [named options pattern](https://learn.microsoft.com/en-us/dotnet/core/extensions/options#named-options-support-using-iconfigurenamedoptions) to configure the behavior of the underlying Event Grid clients. For instance:

```csharp
// Configure options when using EventGridEvents
services.Configure<EventGridPublisherClientOptions>(EventPropagationPublisherOptions.EventGridClientName, options =>
{
options.Retry.NetworkTimeout = TimeSpan.FromSeconds(15);
});

// Configure options when using CloudEvents
services.Configure<EventGridSenderClientOptions>(EventPropagationPublisherOptions.EventGridClientName, options =>
{
options.Retry.NetworkTimeout = TimeSpan.FromSeconds(15);
});

```

## Additional notes
Expand Down

0 comments on commit 6acfa8e

Please sign in to comment.