Class ClickHouseEventSourcingServiceCollectionExtensions
เนื้อหานี้ยังไม่ได้แปลเป็นภาษาไทย แสดงเป็นภาษาอังกฤษแทน
Namespace: Cephalon.EventSourcing.ClickHouse.Hosting
Assembly: Cephalon.EventSourcing.ClickHouse.dll
Registers the ClickHouse event-store provider used by Cephalon hosts.
public static class ClickHouseEventSourcingServiceCollectionExtensionsInheritance
Section titled “Inheritance”object ← ClickHouseEventSourcingServiceCollectionExtensions
Inherited Members
Section titled “Inherited Members”object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.MemberwiseClone(), object.ReferenceEquals(object?, object?), object.ToString()
Methods
Section titled “Methods”AddCephalonClickHouseEventSourcing(IServiceCollection, string, string, string, string, string)
Section titled “ AddCephalonClickHouseEventSourcing(IServiceCollection, string, string, string, string, string)”Adds the ClickHouse event-store provider to the service collection.
public static IServiceCollection AddCephalonClickHouseEventSourcing(this IServiceCollection services, string host, string database, string tableName = "cephalon_event_streams", string username = "default", string password = "")Parameters
Section titled “Parameters”services IServiceCollection
The service collection to extend.
host string
The ClickHouse host address (e.g. “localhost”).
database string
The ClickHouse database that contains the event-streams table.
tableName string
The ClickHouse table name used for event stream rows. Defaults to cephalon_event_streams.
username string
The ClickHouse username. Defaults to “default”.
password string
The ClickHouse password. Defaults to empty.
Returns
Section titled “Returns”The same service collection for fluent registration.
Remarks
Section titled “Remarks”TryAdd semantics — a host that already
registered a shared
Connection behaviour: A new ClickHouseConnection is created per operation.
No long-lived connection object is held. Service resolution is safe without a live ClickHouse server —
connections are only opened when operations are actually invoked.