Eventuous / eventuous

Event Sourcing library for .NET
https://eventuous.dev
Apache License 2.0
447 stars 71 forks source link

Changing PostgresStreamSubscriptionOptions.Stream to be mutable #236

Closed matt-lethargic closed 1 year ago

matt-lethargic commented 1 year ago

Changing PostgresStreamSubscriptionOptions.Stream to be mutable, this now is more in-line with how the documentation outlines it's usage:

builder.Services.AddSubscription<PostgresStreamSubscription, PostgresStreamSubscriptionOptions>(
    "StreamSubscription",
    builder => builder
        .Configure(x => x.StreamName = "my-stream")
        .AddEventHandler<StreamSubscriptionHander>()
);

but the document should now be:

builder.Services.AddSubscription<PostgresStreamSubscription, PostgresStreamSubscriptionOptions>(
    "StreamSubscription",
    builder => builder
        .Configure(x => x.StreamName = new StreamName("my-stream"))
        .AddEventHandler<StreamSubscriptionHander>()
);

and is now closer to how StreamPersistentSubscriptionOptions is created.

(documentation site will need a PR if this is accepted)

CLAassistant commented 1 year ago

CLA assistant check
All committers have signed the CLA.