Skip to content

Commit

Permalink
Trimmed down Infrastructure.fs for only one client with log emission.
Browse files Browse the repository at this point in the history
  • Loading branch information
ragiano215 committed Jul 22, 2021
1 parent 67c040f commit d7b271d
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions propulsion-cosmos-reactor/Infrastructure.fs
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,5 @@ module ConnectorExtensions =
Equinox.CosmosStore.CosmosStoreClient.Connect(x.CreateAndInitialize, databaseId, containerId)

/// Creates a CosmosClient suitable for running a CFP via CosmosStoreSource
member x.ConnectMonitored(databaseId, containerId, ?connectionName) =
x.LogConfiguration(defaultArg connectionName "Source", databaseId, containerId)
member x.ConnectMonitored(databaseId, containerId) =
x.CreateUninitialized(databaseId, containerId)

/// Connects to a Store as both a ChangeFeedProcessor Monitored Container and a CosmosStoreClient
member x.ConnectStoreAndMonitored(databaseId, containerId) =
let monitored = x.ConnectMonitored(databaseId, containerId, "Main")
let storeClient = Equinox.CosmosStore.CosmosStoreClient(monitored.Database.Client, databaseId, containerId)
storeClient, monitored

0 comments on commit d7b271d

Please sign in to comment.