diff --git a/Equinox.sln b/Equinox.sln index 28a29caf9..6fbef5bef 100644 --- a/Equinox.sln +++ b/Equinox.sln @@ -58,7 +58,7 @@ Project("{6EC3EE1D-3C4E-46DD-8F32-0CC8E7565705}") = "Tutorial", "samples\Tutoria EndProject Project("{6EC3EE1D-3C4E-46DD-8F32-0CC8E7565705}") = "Equinox.Tools.TestHarness", "tools\Equinox.Tools.TestHarness\Equinox.Tools.TestHarness.fsproj", "{C2EE7D8E-6982-41AD-ADCC-E6F586E93524}" EndProject -Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "Equinox.Storage", "src\Equinox.Storage\Equinox.Storage.fsproj", "{3021659A-5CA4-4E06-AF00-2457ED3F105B}" +Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "Equinox.Core", "src\Equinox.Core\Equinox.Core.fsproj", "{3021659A-5CA4-4E06-AF00-2457ED3F105B}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution diff --git a/build.proj b/build.proj index d7533cf46..75c1dcd5a 100644 --- a/build.proj +++ b/build.proj @@ -15,10 +15,10 @@ + - diff --git a/samples/Store/Integration/LogIntegration.fs b/samples/Store/Integration/LogIntegration.fs index 3cbe168b6..053d0786d 100644 --- a/samples/Store/Integration/LogIntegration.fs +++ b/samples/Store/Integration/LogIntegration.fs @@ -1,7 +1,7 @@ module Samples.Store.Integration.LogIntegration +open Equinox.Core open Equinox.Cosmos.Integration -open Equinox.Storage open FSharp.UMX open Swensen.Unquote open System diff --git a/src/Equinox.Storage/AsyncCacheCell.fs b/src/Equinox.Core/AsyncCacheCell.fs similarity index 98% rename from src/Equinox.Storage/AsyncCacheCell.fs rename to src/Equinox.Core/AsyncCacheCell.fs index 26e94a959..d0004a9c9 100644 --- a/src/Equinox.Storage/AsyncCacheCell.fs +++ b/src/Equinox.Core/AsyncCacheCell.fs @@ -1,4 +1,4 @@ -namespace Equinox.Storage +namespace Equinox.Core /// Asynchronous Lazy<'T> that guarantees workflow will be executed at most once. type AsyncLazy<'T>(workflow : Async<'T>) = diff --git a/src/Equinox.Storage/Equinox.Storage.fsproj b/src/Equinox.Core/Equinox.Core.fsproj similarity index 100% rename from src/Equinox.Storage/Equinox.Storage.fsproj rename to src/Equinox.Core/Equinox.Core.fsproj diff --git a/src/Equinox.Storage/Infrastructure.fs b/src/Equinox.Core/Infrastructure.fs similarity index 98% rename from src/Equinox.Storage/Infrastructure.fs rename to src/Equinox.Core/Infrastructure.fs index 75124ec40..99e16d3fd 100644 --- a/src/Equinox.Storage/Infrastructure.fs +++ b/src/Equinox.Core/Infrastructure.fs @@ -1,5 +1,5 @@ [] -module internal Equinox.Storage.Infrastructure +module internal Equinox.Core.Infrastructure open FSharp.Control open System diff --git a/src/Equinox.Storage/Retry.fs b/src/Equinox.Core/Retry.fs similarity index 98% rename from src/Equinox.Storage/Retry.fs rename to src/Equinox.Core/Retry.fs index eaeaf6ccc..a4a4b3bfc 100644 --- a/src/Equinox.Storage/Retry.fs +++ b/src/Equinox.Core/Retry.fs @@ -1,4 +1,4 @@ -namespace Equinox.Storage +namespace Equinox.Core /// Exception yielded by after `count` attempts to complete an operation have taken place type OperationRetriesExceededException(count : int, innerException : exn) = diff --git a/src/Equinox.Storage/Stream.fs b/src/Equinox.Core/Stream.fs similarity index 98% rename from src/Equinox.Storage/Stream.fs rename to src/Equinox.Core/Stream.fs index b82f636c8..8562528c7 100644 --- a/src/Equinox.Storage/Stream.fs +++ b/src/Equinox.Core/Stream.fs @@ -1,5 +1,5 @@ /// Low level stream builders, generally consumed via Store-specific Stream Builders that layer policies such as Caching in at the Category level -module Equinox.Storage.Stream +module Equinox.Core.Stream /// Represents a specific stream in a ICategory type private Stream<'event, 'state, 'streamId>(category : ICategory<'event, 'state, 'streamId>, streamId: 'streamId) = diff --git a/src/Equinox.Storage/Types.fs b/src/Equinox.Core/Types.fs similarity index 99% rename from src/Equinox.Storage/Types.fs rename to src/Equinox.Core/Types.fs index 649d01181..7bf4d1496 100644 --- a/src/Equinox.Storage/Types.fs +++ b/src/Equinox.Core/Types.fs @@ -1,4 +1,4 @@ -namespace Equinox.Storage +namespace Equinox.Core open Serilog open System diff --git a/src/Equinox.Cosmos/Cosmos.fs b/src/Equinox.Cosmos/Cosmos.fs index 9c7cdd6cf..e602c1a9a 100644 --- a/src/Equinox.Cosmos/Cosmos.fs +++ b/src/Equinox.Cosmos/Cosmos.fs @@ -1,6 +1,6 @@ namespace Equinox.Cosmos.Store -open Equinox.Storage +open Equinox.Core open FsCodec open Microsoft.Azure.Documents open Newtonsoft.Json @@ -768,8 +768,8 @@ module Internal = namespace Equinox.Cosmos open Equinox +open Equinox.Core open Equinox.Cosmos.Store -open Equinox.Storage open FsCodec open FSharp.Control open Microsoft.Azure.Documents diff --git a/src/Equinox.Cosmos/Equinox.Cosmos.fsproj b/src/Equinox.Cosmos/Equinox.Cosmos.fsproj index 720d5a61d..7ff9473b8 100644 --- a/src/Equinox.Cosmos/Equinox.Cosmos.fsproj +++ b/src/Equinox.Cosmos/Equinox.Cosmos.fsproj @@ -10,12 +10,12 @@ - + - + diff --git a/src/Equinox.EventStore/Equinox.EventStore.fsproj b/src/Equinox.EventStore/Equinox.EventStore.fsproj index 790ce61c3..e0ac9f92e 100644 --- a/src/Equinox.EventStore/Equinox.EventStore.fsproj +++ b/src/Equinox.EventStore/Equinox.EventStore.fsproj @@ -10,12 +10,12 @@ - + - + diff --git a/src/Equinox.EventStore/EventStore.fs b/src/Equinox.EventStore/EventStore.fs index c05681237..0093cbe0c 100644 --- a/src/Equinox.EventStore/EventStore.fs +++ b/src/Equinox.EventStore/EventStore.fs @@ -1,7 +1,7 @@ namespace Equinox.EventStore open Equinox -open Equinox.Storage +open Equinox.Core open EventStore.ClientAPI open Serilog // NB must shadow EventStore.ClientAPI.ILogger open System diff --git a/src/Equinox.MemoryStore/Equinox.MemoryStore.fsproj b/src/Equinox.MemoryStore/Equinox.MemoryStore.fsproj index 25fe6cdc3..02663ca87 100644 --- a/src/Equinox.MemoryStore/Equinox.MemoryStore.fsproj +++ b/src/Equinox.MemoryStore/Equinox.MemoryStore.fsproj @@ -13,7 +13,7 @@ - + diff --git a/src/Equinox.MemoryStore/MemoryStore.fs b/src/Equinox.MemoryStore/MemoryStore.fs index 64c9a2a5b..97ad9961a 100644 --- a/src/Equinox.MemoryStore/MemoryStore.fs +++ b/src/Equinox.MemoryStore/MemoryStore.fs @@ -4,7 +4,7 @@ namespace Equinox.MemoryStore open Equinox -open Equinox.Storage +open Equinox.Core open Serilog open System.Runtime.InteropServices diff --git a/src/Equinox/Equinox.fs b/src/Equinox/Equinox.fs index 3c97a00a8..7fd0e89c4 100644 --- a/src/Equinox/Equinox.fs +++ b/src/Equinox/Equinox.fs @@ -1,6 +1,6 @@ namespace Equinox -open Equinox.Storage +open Equinox.Core open System.Runtime.InteropServices // Exception yielded by Stream.Transact after `count` attempts have yielded conflicts at the point of syncing with the Store @@ -9,7 +9,7 @@ type MaxResyncsExhaustedException(count) = /// Central Application-facing API. Wraps the handling of decision or query flows in a manner that is store agnostic type Stream<'event, 'state> - ( log, stream : Storage.IStream<'event, 'state>, maxAttempts : int, + ( log, stream : IStream<'event, 'state>, maxAttempts : int, []?mkAttemptsExhaustedException, []?resyncPolicy) = let transact f = diff --git a/src/Equinox/Flow.fs b/src/Equinox/Flow.fs index 2b408f884..c6ca8cc32 100644 --- a/src/Equinox/Flow.fs +++ b/src/Equinox/Flow.fs @@ -1,6 +1,6 @@ /// Internal data structures/impl. While these are intended to be legible, understanding the abstractions involved is only necessary if you are implementing a Store or a decorator thereof. /// i.e., if you're seeking to understand the main usage flows of the Equinox library, that's in Equinox.fs, not here -namespace Equinox.Storage +namespace Equinox.Core open Serilog diff --git a/tests/Equinox.Cosmos.Integration/CacheCellTests.fs b/tests/Equinox.Cosmos.Integration/CacheCellTests.fs index bcde00dd1..06962af47 100644 --- a/tests/Equinox.Cosmos.Integration/CacheCellTests.fs +++ b/tests/Equinox.Cosmos.Integration/CacheCellTests.fs @@ -1,6 +1,6 @@ module Equinox.Cosmos.Integration.CacheCellTests -open Equinox.Storage +open Equinox.Core open Swensen.Unquote open System.Threading open Xunit diff --git a/tests/Equinox.EventStore.Integration/EventStoreTokenTests.fs b/tests/Equinox.EventStore.Integration/EventStoreTokenTests.fs index a29dad3ab..04de4980c 100644 --- a/tests/Equinox.EventStore.Integration/EventStoreTokenTests.fs +++ b/tests/Equinox.EventStore.Integration/EventStoreTokenTests.fs @@ -1,7 +1,7 @@ module Equinox.EventStore.Tests.EventStoreTokenTests +open Equinox.Core open Equinox.EventStore -open Equinox.Storage open FsCheck.Xunit open Swensen.Unquote.Assertions open Xunit