diff --git a/.config/dotnet-tools.json b/.config/dotnet-tools.json
new file mode 100644
index 000000000..18bae550c
--- /dev/null
+++ b/.config/dotnet-tools.json
@@ -0,0 +1,13 @@
+{
+ "version": 1,
+ "isRoot": true,
+ "tools": {
+ "gitversion.tool": {
+ "version": "6.1.0",
+ "commands": [
+ "dotnet-gitversion"
+ ],
+ "rollForward": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/.gitignore b/.gitignore
index b5fc713bc..6cbd591e0 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,15 +1,119 @@
-obj
-bin
-*.user
+# Build Folders (you can keep bin if you'd like, to store dlls and pdbs)
+[Bb]in/
+[Oo]bj/
+build/
+
+# mstest test results
+TestResults
+
+## Ignore Visual Studio temporary files, build results, and
+## files generated by popular Visual Studio add-ons.
+
+# User-specific files
*.suo
-*.orig
-output
-publish-*
+*.user
+*.sln.docstates
+
+# Build results
+[Dd]ebug/
+[Rr]elease/
+x64/
+*_i.c
+*_p.c
+*.ilk
+*.meta
+*.obj
+*.pch
+*.pdb
+*.pgc
+*.pgd
+*.rsp
+*.sbr
+*.tlb
+*.tli
+*.tlh
+*.tmp
+*.log
+*.vspscc
+*.vssscc
+.builds
+
+# Visual C++ cache files
+ipch/
+*.aps
+*.ncb
+*.opensdf
+*.sdf
+
+# Visual Studio profiler
+*.psess
+*.vsp
+*.vspx
+
+# Guidance Automation Toolkit
+*.gpState
+
+# ReSharper is a .NET coding add-in
+_ReSharper*
+
+# NCrunch
+*.ncrunch*
+.*crunch*.local.xml
+
+# Installshield output folder
+[Ee]xpress
+
+# DocProject is a documentation generator add-in
+DocProject/buildhelp/
+DocProject/Help/*.HxT
+DocProject/Help/*.HxC
+DocProject/Help/*.hhc
+DocProject/Help/*.hhk
+DocProject/Help/*.hhp
+DocProject/Help/Html2
+DocProject/Help/html
+
+# Click-Once directory
+publish
+
+# Publish Web Output
+*.Publish.xml
+
+# NuGet Packages Directory
packages
-_ReSharper.*
-_dotCover.*
-*.Resharper
+
+# Windows Azure Build Output
+csx
+*.build.csdef
+
+# Windows Store app package directory
+AppPackages/
+
+# Others
+[Bb]in
+[Oo]bj
+sql
+TestResults
+[Tt]est[Rr]esult*
*.Cache
-*.cache
-~$*
-[Pp]ublish
\ No newline at end of file
+ClientBin
+[Ss]tyle[Cc]op.*
+~$*
+*.dbmdl
+Generated_Code #added for RIA/Silverlight projects
+
+# Backup & report files from converting an old project file to a newer
+# Visual Studio version. Backup files are not needed, because we have git ;-)
+_UpgradeReport_Files/
+Backup*/
+UpgradeLog*.XML
+publish-net40/
+nunit.TestResult.*
+/output
+
+# Visual Studio options and artifacts
+.vs/
+*.lock.json
+
+# Custom
+artifacts/
\ No newline at end of file
diff --git a/Build.RunTask.bat b/Build.RunTask.bat
deleted file mode 100644
index 5bc0b2f0e..000000000
--- a/Build.RunTask.bat
+++ /dev/null
@@ -1,2 +0,0 @@
-@echo off
-powershell -NoProfile -ExecutionPolicy unrestricted -Command "& .\build\Build.RunTask.ps1 %*"
\ No newline at end of file
diff --git a/Changelog.md b/Changelog.md
new file mode 100644
index 000000000..f1c4c8d0d
--- /dev/null
+++ b/Changelog.md
@@ -0,0 +1,200 @@
+# NEventStore Versions
+
+## 10.1.1
+
+### BugFix
+
+- Fixed Assemblies Version Numbers (AssemblyInfo files).
+
+## 10.1.0
+
+- Improved `IEventStream` interface: `CommitChanges()` and `CommitChangesAsync()` now return `ICommit` instead of `void`.
+- Updated MessagePack serializer to 3.1.3
+
+### Breaking Changes
+
+- `IEventStream.CommitChanges()` and `IEventStream.CommitChangesAsync()` now return `ICommit` instead of `void`.
+
+## 10.0.1
+
+### BugFix
+
+- Async Pipeline Hooks: initialization and PreCommit/PostCommit invocation bugs [#516](https://github.com/NEventStore/NEventStore/issues/516)
+
+## 10.0.0
+
+- Async Methods to read from and write to streams (IStoreEvents, IEventStream, IPersistStreams, IPersistStreamsAsync, ICommitEventsAsync, IAccessSnapshotsAsync). [#513](https://github.com/NEventStore/NEventStore/issues/513)
+ - methods that read from a stream in an async way follow the Observer pattern and requires you to pass in an `IAsyncObservable` that will receive data as soon as they are available.
+- Async Pipeline Hooks (IPipelineHookAsync). [#515](https://github.com/NEventStore/NEventStore/issues/515)
+- AsyncPollingClient: a new polling client implementation that uses Async interfaces. [#505](https://github.com/NEventStore/NEventStore/issues/505)
+- Removed the BinarySerializer (BinaryFormatter) from the core package and moved it to its own package [#510](https://github.com/NEventStore/NEventStore/issues/510)
+- Improved comments and added more nullability checks.
+- Minor performance improvements.
+- Updated Testing Packages (NUnit, FluentAssertions, Microsoft.NET.Test and so on...).
+
+### Breaking Changes
+
+- `PersistStreamsExtensions.GetFrom(IPersistStreams, DateTime)` and `PersistStreamsExtensions.GetFromTo(IPersistStreams, DateTime, DateTime)` extension methods have been removed: they had inconsistent behavior with the other GetFrom(checkpointToken) methods,
+ they were getting data from the default bucket only.
+- `PipelineHooksAwarePersistanceDecorator` renamed to `PipelineHooksAwarePersistStreamsDecorator`.
+- `IPipelineHook.Select` method renamed to `IPipelineHook.SelectCommit`.
+- `BinarySerializer` moved to its own package: `NEventStore.Serialization.Binary`.
+ - for net8.0+ call `AppContext.SetSwitch("System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization", true);` to enable unsafe BinaryFormatter usage.
+- Improved many method signature with nullability annotations.
+- `Wireup.With()` renamed `Wireup.Register()`.
+- `OptimisticEventStream` constructors replaced by initialization functions:
+ - `new OptimisticEventStream(string bucketId, string streamId, ICommitEvents persistence, int minRevision, int maxRevision)` -> `new OptimisticEventStream(string bucketId, string streamId, ICommitEvents persistence).Initialize(int minRevision, int maxRevision)`.
+ - `new OptimisticEventStream(ISnapshot snapshot, ICommitEvents persistence, int maxRevision)` -> `new OptimisticEventStream(string bucketId, string streamId, ICommitEvents persistence).Initialize(ISnapshot snapshot, int maxRevision)`.
+
+## 9.2.0
+
+- Updated nuget packages to include symbol packages and more information.
+- Updated Newtonsoft.Bson 13.0.3
+- Added MessagePack serializer, thanks to [@pvagnozzi](https://github.com/pvagnozzi)
+- Improved comments and removed some compilation warnings.
+
+## 9.1.1
+
+- Fixed `build.ps1` script to correctly update Assembly Version number before building.
+- Updated Readme with how Versioning works.
+
+## 9.1.0
+
+- Support the following Target Frameworks only: netstandard2.0, net462.
+- Updated Newtonsoft.Json 13.0.3
+
+## 9.0.1
+
+- Added documentation files to NuGet packages (improved intellisense support) [#496](https://github.com/NEventStore/NEventStore/issues/496)
+
+## 9.0.0
+
+- Added support for .net 6 [#493](https://github.com/NEventStore/NEventStore/issues/493).
+- Change / Optimization: Commit and CommitAttempt do not create internal read-only collections anymore, it can be useless given that we can change properties of events.
+- NEventStore.Serialization.Json: accepts a JsonSerializerSettings to configure the serializer.
+
+## 8.0.0
+
+- Added support for .net 5 [#489](https://github.com/NEventStore/NEventStore/issues/489).
+- Added support for .net framework 4.6.1.
+- Fixed InMemoryPersistenceEngine.AddSnapshot() behavior: adding multiple snapshots for the same tuple bucketId, streamId, streamRevision is not allowed; the updated snapshot will be ignored [#484](https://github.com/NEventStore/NEventStore/pull/484).
+- Logging infrastructure switched to [Microsoft.Extensions.Logging](https://docs.microsoft.com/en-us/dotnet/core/extensions/logging) [#454](https://github.com/NEventStore/NEventStore/issues/454), [#488](https://github.com/NEventStore/NEventStore/pull/488).
+- Reviewed Exception (and logging) messages: many of those that refer to a StreamId should also provide BucketId information [#480](https://github.com/NEventStore/NEventStore/issues/480)
+
+### Breaking Changes
+
+- Dropped support for .NET Framework 4.5, only .NET 4.6.1+ will be supported in 8.x. .NET Framework support will be dropped in a future revision.
+- Logging switched to Microsoft.Extensions.Logging, old logging code and configuration functions have been removed.
+
+## 7.0.0
+
+- The IPersistStreams interface got some major changes:
+ - Added new `GetFromTo(Int64, Int64)` and `GetFromTo(string, Int64, Int64)` methods to the IPersistStreams interface.
+ - Extension methods `PersistStreamsExtensions.GetFrom(DateTime)` and `PersistStreamsExtensions.GetFromTo(DateTime, DateTime)` were marked obsolete and will be removed.
+ - A new PersistStreamsExtensions.GetCommit(Int64) method was added to retrieve a single commit [#445](https://github.com/NEventStore/NEventStore/issues/445).
+- PollingClient was moved to its own NEventStore.PollingClient NuGet package [#467](https://github.com/NEventStore/NEventStore/issues/467).
+- Added more information to the DuplicateCommitException error message (StreamId and BucketId), also the information provided by the Persistence providers will be reviewed [#372](https://github.com/NEventStore/NEventStore/issues/372).
+
+### Breaking Changes
+
+- The default value of 0 has been removed from the `IPersistStreams.GetFrom(Int64)` method.
+- Removed the almost useless `GetFromStart()` extension method: use `IPersistStream.GetFrom(0)`.
+- Bson serializer was moved from NEventStore.Serialization.Json to its own package: `NEventStore.Serialization.Bson`. Closes: [#479](https://github.com/NEventStore/NEventStore/issues/479).
+- PollingClient was moved to its own package: add a reference to NEventStore.PollingClient NuGet package. Also the namespace was changed from NEventStore.Client to NEventStorePollingClient.
+
+## 6.1.0
+
+Enlist in ambient transaction has been removed from the mail library and added to the persistence drivers implementations, each driver has its own way to support, enable or disable the feature. As of now this change will mainly impact Microsoft SQL Server users, because all other persistence plugins didn't use transactions at all.
+
+All the transactions (or their suppression) should be explicitly managed by the user.
+
+Minor optimizations were made if no pipeline hooks are used.
+
+### Breaking Changes
+
+- `PipelineHookBase`: changed the way the Dispose pattern was implemented to be compliant with the framework guidelines. Move all the Dispose logic to the overridden Dispose(bool disposing) method of your pipeline hook class.
+- `OptimisticPipelineHook` optimization is not configured and enabled by default (if not enlisting in ambient transactions) anymore; it now must be explicitly enabled calling UseOptimisticPipelineHook() when configuring NEventStore. Do not use it if you plan to use transactions. To restore the previous behavior call .UseOptimisticPipelineHook() when configuring NEventStore.
+- `EnlistInAmbientTransaction` has been removed from the core NEventStore library. It will be added to specific persistence drivers implementations.
+
+## 6.0.0
+
+__Version 6.x is not backwards compatible with version 5.x.__ Updating to NEventStore 6.x without doing some preparation work will result in problems.
+
+### New Features
+
+- dotnet standard 2.0 , dotnet core 2.0 are now supported for the following projects: NEventStore, NEventStore.Domain, NEventStore.Persistence.Sql, NEventStore.Persistence.MongoDb
+
+### Breaking Changes
+
+- **Removed Dispatcher and dispatching mechanic, use the PollingClient**: it was marked obsolete in the version 5.x, you should dispatch events with other mechanisms, like using a PollingClient.
+More information on this topic in the issue: [Race condition in sync and async dispatchers can result in subscribers getting commits / events out of order](https://github.com/NEventStore/NEventStore/issues/360).
+- **Removed LongCheckpoint class**: checkpoint now is a plain Int64, there is no need to keep a LongCheckpoint class anymore.
+- **PollingClient was removed because it used to depend on Rx**: you can [read more information here](src/NEventStore/Client/README.MD). The new polling client class is called PollingClient2, this however should be considered as a sample implementation you can use to derive your own.
+- **JsonSerializer and BsonSerializer were moved in a separate assembly**: if you need them, you should reference the NEventStore.Serialization.Json assembly or implement your own serializers that depend on the Json.Net version you need.
+- **EventMessage** class is now sealed.
+- **`OptimisticEventStream` throws exceptions if a null message or a message with null body is added to the stream**. Previously if you called Add with null event message or add with an event message with null body, the add operation was ignored without any warning or error.
+
+## 6.0.0-rc-1
+
+New features:
+
+- improved logging performances ([#468](https://github.com/NEventStore/NEventStore/issues/468)).
+
+Bug fixed:
+
+- adding events in the middle of a commit should throw ConcurrencyException ([#420](https://github.com/NEventStore/NEventStore/issues/420)).
+
+## 6.0.0-rc-0
+
+__Version 6.x is not backwards compatible with version 5.x.__ Updating to NEventStore 6.x without doing some preparation work will result in problems.
+
+### New Features
+
+- dotnet standard 2.0 , dotnet core 2.0 are now supported for the following projects: NEventStore, NEventStore.Domain, NEventStore.Persistence.Sql, NEventStore.Persistence.MongoDb
+
+### Breaking changes
+
+- **Removed Dispatcher and dispatching mechanic, use the PollingClient**: it was marked obsolete in the version 5.x, you should dispatch events with other mechanisms, like using a PollingClient.
+More information on this topic in the issue: [Race condition in sync and async dispatchers can result in subscribers getting commits / events out of order](https://github.com/NEventStore/NEventStore/issues/360).
+- **Removed LongCheckpoint class**: checkpoint now is a plain Int64, there is no need to keep a LongCheckpoint class anymore.
+- **PollingClient was removed because it used to depend on Rx**: you can [read more information here](src/NEventStore/Client/README.MD). The new polling client class is called PollingClient2, this however should be considered as a sample implementation you can use to derive your own.
+- **JsonSerializer and BsonSerializer were moved in a separate assembly**: if you need them, you should reference the NEventStore.Serialization.Json assembly or implement your own serializers that depend on the Json.Net version you need.
+- **EventMessage** class is now sealed.
+- **OptimisticEventStream throws exceptions if a null message or a message with null body is added to the stream**. Previously if you called Add with null event message or add with an event message with null body, the add operation was ignored without any warning or error.
+
+### Other Notes
+
+All persistence providers:
+
+- [MongoDb](https://github.com/NEventStore/NEventStore.Persistence.MongoDB)
+- [Sql](https://github.com/NEventStore/NEventStore.Persistence.SQL)
+- [RavenDb](https://github.com/NEventStore/NEventStore.Persistence.RavenDB) - currently not maintained anymore.
+
+are now hosted in their own project.
+
+Common Domain is now moved in its [own repository](https://github.com/NEventStore/NEventStore.Domain).
+
+## 5.x.x
+
+Note: Version 5 is not backwards compatible with v4. Updating to v5 without doing some preparation work will result in problems.
+
+### Breaking Changes
+
+1. Underlying schema has changed for all v5 storage engines. In order to migrate a store from v4 to v5 use NEventStore.Migrations
+1.The concept of a 'Bucket' has been added as a container for streams allowing multi-tenancy, partitions, multiple-bounded contexts, sagas, etc to be stored in the one store. The API changes have been such that, using extension methods, operations will work on the default bucket, unless a bucket Id has been explicitly supplied. This should mean minimal code changes for the user.
+1.Stream Ids are now string based and are limited to 1000 characters.
+In the SQL engines the stream Id's are limited to 40 characters and are hashed versions of the actual StreamId.
+The hashing function can be overridden during wire-up.
+
+### New Features
+
+#### Polling Client
+
+As an alternative to the dispatcher mechanism and improved replay / catch-up story we have implemented a CheckpointNumber in the stores that guarantees ordering across the streams. This number is guaranteed to increment but not guaranteed to be sequential. This allows you to get all Commits from a specific checkpoint and observe new ones. This implementation is polling based (and thus works for all engines) so it doesn't have the same low-latency attributes of the dispatcher mechanism. You can see how to use it here: [https://gist.github.com/damianh/6370328](https://gist.github.com/damianh/6370328) .In this, instead of the store tracking what has been dispatched, the onus is on the client to track what it has seen. And upon restart, start subscribing from what it last saw.
+
+In the future I'd like to see / implement reactive clients that leverage stores that are observable.
+
+### Other Notes
+
+1. Only SQL and MongoDB persistence engines are supported in this release. RavenDB engine will be shipped later.
+1. RavenDB and MongoDB persistence engines are now in their own repositories and will have be shipped independently.
diff --git a/GitVersion.yml b/GitVersion.yml
new file mode 100644
index 000000000..27f681df6
--- /dev/null
+++ b/GitVersion.yml
@@ -0,0 +1,5 @@
+mode: ContinuousDeployment
+branches: {}
+ignore:
+ sha: []
+merge-message-formats: {}
diff --git a/Readme.md b/Readme.md
new file mode 100644
index 000000000..aae0b792f
--- /dev/null
+++ b/Readme.md
@@ -0,0 +1,62 @@
+NEventStore
+===
+
+NEventStore is a persistence library used to abstract different storage implementations when using event sourcing as storage mechanism.
+
+This library is developed with a specific focus on [DDD](http://en.wikipedia.org/wiki/Domain-driven_design)/[CQRS](https://en.wikipedia.org/wiki/Command%E2%80%93query_separation#Command_query_responsibility_segregation) applications.
+
+NEventStore currently supports:
+
+- .net standard 2.0
+- .net framework 4.6.2
+
+Starting from Version 6.0.0 NEventStore will use [Semantic Versioning](https://semver.org/) to track the version numbers.
+
+Build Status (AppVeyor)
+===
+
+Branches:
+
+- master [](https://ci.appveyor.com/project/AGiorgetti/neventstore/branch/master)
+- develop [](https://ci.appveyor.com/project/AGiorgetti/neventstore/branch/develop)
+
+Main Library Packages
+===
+
+- NEventStore - the core library package.
+- NEventStore.Serialization.Json - Json serialization to be used with an IDocumentSerializer.
+- NEventStore.Serialization.Bson - BSon serialization to be used with an IDocumentSerializer.
+- NEventStore.Serialization.MsgPack - Message Pack serialization to be used with an IDocumentSerializer.
+- NEventStore.PollingClient - provides an implementation for a PollingClient.
+
+Documentation
+===
+
+Please see the [documentation](https://github.com/NEventStore/NEventStore/wiki) to get started and for more information.
+
+ChangeLog can be [found here](https://github.com/NEventStore/NEventStore/blob/master/Changelog.md)
+
+### Developed with:
+
+[](http://www.jetbrains.com/resharper/)
+[](http://www.jetbrains.com/teamcity/)
+[](http://www.jetbrains.com/dotcover/)
+[](http://www.jetbrains.com/dottrace/)
+
+# How to build (Windows OS)
+
+To build the project locally on a Windows Machine:
+
+- Open a Powershell console in Administrative mode and run the build script `build.ps1` in the root of the repository.
+
+## Versioning
+
+Versioning is done automatically by the build script updating the
+AssemblyInfo.cs file (false in .csproj files)
+before the build starts. The version number is retrieved
+from the git repository tags using "gitversion" tool.
+
+Things are handled this way because NEventStore is used a submodule in other projects and it
+need to have it's own version number when building other projects.
+
+You should not update the version number manually, not commit the updated AssemblyInfo files.
\ No newline at end of file
diff --git a/appveyor.yml b/appveyor.yml
new file mode 100644
index 000000000..b1d022cbf
--- /dev/null
+++ b/appveyor.yml
@@ -0,0 +1,59 @@
+version: 1.0.{build}
+image: Visual Studio 2022
+configuration: Release
+assembly_info:
+ patch: true
+ file: '**\AssemblyInfo.*'
+ assembly_version: '{version}'
+ assembly_file_version: '{version}'
+ assembly_informational_version: '{version}'
+dotnet_csproj:
+ patch: true
+ file: '**\*.csproj'
+ version: '{version}'
+ version_prefix: '{version}'
+ package_version: '{version}'
+ assembly_version: '{version}'
+ file_version: '{version}'
+ informational_version: '{version}'
+install:
+- ps: choco install gitversion.portable -y
+before_build:
+- ps: >-
+ # Display .NET Core version
+
+ dotnet --version
+
+ # Display minimal restore text
+
+ dotnet restore ./src/NEventStore.Core.sln --verbosity m
+
+ gitversion /l console /output buildserver /updateAssemblyInfo
+build:
+ project: src/NEventStore.Core.sln
+ verbosity: minimal
+after_build:
+- cmd: >-
+ dotnet pack ./src/NEventStore/NEventStore.Core.csproj -c %CONFIGURATION% --no-build -o artifacts /p:PackageVersion=%GitVersion_SemVer%
+
+ dotnet pack ./src/NEventStore.PollingClient/NEventStore.PollingClient.csproj -c %CONFIGURATION% --no-build -o artifacts /p:PackageVersion=%GitVersion_SemVer%
+
+ dotnet pack ./src/NEventStore.Serialization.Json/NEventStore.Serialization.Json.Core.csproj -c %CONFIGURATION% --no-build -o artifacts /p:PackageVersion=%GitVersion_SemVer%
+
+ dotnet pack ./src/NEventStore.Serialization.Bson/NEventStore.Serialization.Bson.Core.csproj -c %CONFIGURATION% --no-build -o artifacts /p:PackageVersion=%GitVersion_SemVer%
+
+ dotnet pack ./src/NEventStore.Serialization.MsgPack/NEventStore.Serialization.MsgPack.Core.csproj -c %CONFIGURATION% --no-build -o artifacts /p:PackageVersion=%GitVersion_SemVer%
+
+ dotnet pack ./src/NEventStore.Serialization.Binary/NEventStore.Serialization.Binary.Core.csproj -c %CONFIGURATION% --no-build -o artifacts /p:PackageVersion=%GitVersion_SemVer%
+test:
+ assemblies:
+ except:
+ - NEventStore.Persistence.AcceptanceTests.dll
+ - NEventStore.dll
+ - NEventStore.Serialization.Json.dll
+ - NEventStore.Serialization.Bson.dll
+ - NEventStore.Serialization.MsgPack.dll
+ - NEventStore.Serialization.Binary.dll
+artifacts:
+- path: '**\artifacts\**\*.*'
+deploy: off
\ No newline at end of file
diff --git a/bin/7zip-bin/7za.exe b/bin/7zip-bin/7za.exe
deleted file mode 100644
index 7f6bf86bc..000000000
Binary files a/bin/7zip-bin/7za.exe and /dev/null differ
diff --git a/bin/7zip-bin/license.txt b/bin/7zip-bin/license.txt
deleted file mode 100644
index 530ff3684..000000000
--- a/bin/7zip-bin/license.txt
+++ /dev/null
@@ -1,29 +0,0 @@
- 7-Zip Command line version
- ~~~~~~~~~~~~~~~~~~~~~~~~~~
- License for use and distribution
- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-
- 7-Zip Copyright (C) 1999-2010 Igor Pavlov.
-
- 7za.exe is distributed under the GNU LGPL license
-
- Notes:
- You can use 7-Zip on any computer, including a computer in a commercial
- organization. You don't need to register or pay for 7-Zip.
-
-
- GNU LGPL information
- --------------------
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- This library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You can receive a copy of the GNU Lesser General Public License from
- http://www.gnu.org/
diff --git a/bin/ilmerge-bin/ILMerge.exe b/bin/ilmerge-bin/ILMerge.exe
deleted file mode 100644
index e36b0c14f..000000000
Binary files a/bin/ilmerge-bin/ILMerge.exe and /dev/null differ
diff --git a/build.ps1 b/build.ps1
new file mode 100644
index 000000000..702f56acb
--- /dev/null
+++ b/build.ps1
@@ -0,0 +1,39 @@
+$configurationdefault = "Release"
+$artifacts = "../../artifacts"
+
+$configuration = Read-Host 'Configuration to build [default: Release] ?'
+if ($configuration -eq '') {
+ $configuration = $configurationdefault
+}
+$runtests = Read-Host 'Run Tests (y / n) [default:n] ?'
+
+# Install gitversion tool
+dotnet tool restore
+
+# Display minimal restore information
+dotnet restore ./src/NEventStore.Core.sln --verbosity m
+
+# GitVersion
+$str = dotnet tool run dotnet-gitversion /updateAssemblyInfo | out-string
+$json = convertFrom-json $str
+$nugetversion = $json.SemVer
+
+# Build
+Write-Host "Building: "$nugetversion
+dotnet build ./src/NEventStore.Core.sln -c $configuration --no-restore -p:ContinuousIntegrationBuild=True
+
+# Testing
+if ($runtests -eq "y") {
+ Write-Host "Executing Tests"
+ dotnet test ./src/NEventStore.Core.sln -c $configuration --no-build
+ Write-Host "Tests Execution Complated"
+}
+
+# NuGet packages
+Write-Host "NuGet Packages creation"
+dotnet pack ./src/NEventStore/NEventStore.Core.csproj -c $configuration --no-build -o $artifacts /p:PackageVersion=$nugetversion
+dotnet pack ./src/NEventStore.PollingClient/NEventStore.PollingClient.csproj -c $configuration --no-build -o $artifacts /p:PackageVersion=$nugetversion
+dotnet pack ./src/NEventStore.Serialization.Json/NEventStore.Serialization.Json.Core.csproj -c $configuration --no-build -o $artifacts /p:PackageVersion=$nugetversion
+dotnet pack ./src/NEventStore.Serialization.Bson/NEventStore.Serialization.Bson.Core.csproj -c $configuration --no-build -o $artifacts /p:PackageVersion=$nugetversion
+dotnet pack ./src/NEventStore.Serialization.MsgPack/NEventStore.Serialization.MsgPack.Core.csproj -c $configuration --no-build -o $artifacts /p:PackageVersion=$nugetversion
+dotnet pack ./src/NEventStore.Serialization.Binary/NEventStore.Serialization.Binary.Core.csproj -c $configuration --no-build -o $artifacts /p:PackageVersion=$nugetversion
\ No newline at end of file
diff --git a/build/Build.RunTask.ps1 b/build/Build.RunTask.ps1
deleted file mode 100644
index cc886354a..000000000
--- a/build/Build.RunTask.ps1
+++ /dev/null
@@ -1,11 +0,0 @@
-Param(
- [string]$task,
- [string]$version = "0.0.0.0")
-
-if($task -eq $null) {
- $task = read-host "Enter Task"
-}
-
-$scriptPath = $(Split-Path -parent $MyInvocation.MyCommand.path)
-
-. .\build\psake.ps1 -scriptPath $scriptPath -t $task -properties @{ version=$version }
\ No newline at end of file
diff --git a/build/Modules/ILMerge.psm1 b/build/Modules/ILMerge.psm1
deleted file mode 100644
index 10509c9f0..000000000
--- a/build/Modules/ILMerge.psm1
+++ /dev/null
@@ -1,37 +0,0 @@
-$script:ilMergeModule = @{}
-$script:ilMergeModule.ilMergePath = $null
-
-function Merge-Assemblies {
- Param(
- $files,
- $outputFile,
- $exclude,
- $keyfile,
- $targetPlatform="v4,C:/WINDOWS/Microsoft.NET/Framework/v4.0.30319"
- )
-
- $exclude | out-file ".\exclude.txt"
-
- $args = @(
- "/keyfile:$keyfile",
- "/internalize:exclude.txt",
- "/xmldocs",
- "/wildcards",
- "/targetplatform:$targetPlatform",
- "/out:$outputFile") + $files
-
- if($ilMergeModule.ilMergePath -eq $null)
- {
- write-error "IlMerge Path is not defined. Please set variable `$ilMergeModule.ilMergePath"
- }
-
- & $ilMergeModule.ilMergePath $args
-
- if($LastExitCode -ne 0) {
- write-error "Merge Failed"
- }
-
- remove-item ".\exclude.txt"
-}
-
-Export-ModuleMember -Variable "ilMergeModule" -Function "Merge-Assemblies"
\ No newline at end of file
diff --git a/build/Modules/IO.psm1 b/build/Modules/IO.psm1
deleted file mode 100644
index ee554beb0..000000000
--- a/build/Modules/IO.psm1
+++ /dev/null
@@ -1,64 +0,0 @@
-function Clean-Item {
- Param(
- [parameter(Mandatory=$true, Position=0, ValueFromPipeline=$true)]
- [string] $path
- )
- Process
- {
- if(($path -ne $null) -and (test-path $path))
- {
- write-verbose ("Removing {0}" -f $path)
- remove-item -force -recurse $path | Out-Null
- }
- }
-}
-
-function Remove-Directory {
- Param(
- [parameter(Mandatory=$true, Position=0, ValueFromPipeline=$true)]
- [string] $path
- )
- rd $path -recurse -force -ErrorAction SilentlyContinue | out-null
-}
-
-function New-Directory
-{
- Param(
- [parameter(Mandatory=$true, Position=0, ValueFromPipeline=$true)]
- [string] $path
- )
-
- mkdir $path -ErrorAction SilentlyContinue | out-null
-}
-
-function Copy-Files {
- Param(
- [parameter(Mandatory=$true, Position=0, ValueFromPipeline=$true)]
- [string] $source,
- [string] $destination,
- [alias("exclude")]
- [string[]] $excludeFiles=@(),
- [string[]] $excludeDirectories=@()
- )
-
- New-Directory $destination
-
- #Get-ChildItem $source -Recurse -Exclude $exclude | Copy-Item -Destination {Join-Path $destination $_.FullName.Substring($source.length)}
-
-
- $arguments = @($source, $destination, "*.*", "/e")
-
- if(($excludeFiles -ne $null) -and ($excludeFiles.Length -gt 0)) {
- $arguments += "/xf"
- $arguments += $excludeFiles
- }
-
- if(($excludeDirectories -ne $null) -and ($excludeFiles.Length -gt 0)) {
- $arguments += "/xd"
- $arguments += $excludeDirectories
- }
-
- robocopy.exe $arguments | out-null
-
- Expect-ExitCode -expectedExitCode 0,1 -formatMessage { param($taskName) "Copy was not successful" }
-}
\ No newline at end of file
diff --git a/build/default.ps1 b/build/default.ps1
deleted file mode 100644
index 51f99ad8b..000000000
--- a/build/default.ps1
+++ /dev/null
@@ -1,149 +0,0 @@
-properties {
- $base_directory = Resolve-Path ..
- $publish_directory = "$base_directory\publish-net40"
- $build_directory = "$base_directory\build"
- $src_directory = "$base_directory\src"
- $output_directory = "$base_directory\output"
- $packages_directory = "$src_directory\packages"
-
- $sln_file = "$src_directory\EventStore.sln"
- $keyfile = "$src_directory/EventStore.snk"
- $target_config = "Release"
- $framework_version = "v4.0"
- $version = "0.0.0.0"
-
- $mspec_path = "$src_directory\packages\Machine.Specifications.0.5.8\tools\mspec-x86-clr4.exe"
- $ilMergeModule.ilMergePath = "$base_directory\bin\ilmerge-bin\ILMerge.exe"
- $nuget_dir = "$src_directory\.nuget"
-
- if($runPersistenceTests -eq $null) {
- $runPersistenceTests = $false
- }
-}
-
-task default -depends Build
-
-task Build -depends Clean, UpdateVersion, Compile, Test
-
-task UpdateVersion {
- $versionAssemblyInfoFile = "$src_directory/proj/VersionAssemblyInfo.cs"
- "using System.Reflection;" > $versionAssemblyInfoFile
- "" >> $versionAssemblyInfoFile
- "[assembly: AssemblyVersion(""$version"")]" >> $versionAssemblyInfoFile
- "[assembly: AssemblyFileVersion(""$version"")]" >> $versionAssemblyInfoFile
-}
-
-task Compile {
- exec { msbuild /nologo /verbosity:quiet $sln_file /p:Configuration=$target_config /t:Clean }
-
- exec { msbuild /nologo /verbosity:quiet $sln_file /p:Configuration=$target_config /p:TargetFrameworkVersion=v4.0 }
-}
-
-task Test -depends RunUnitTests, RunPersistenceTests, RunSerializationTests
-
-task RunUnitTests {
- write-host "Unit Tests"
-
- exec { &$mspec_path "$src_directory/tests/EventStore.Core.UnitTests/bin/$target_config/EventStore.Core.UnitTests.dll" }
-}
-
-task RunPersistenceTests -precondition { $runPersistenceTests } {
- write-host "Acceptance Tests: Persistence Tests"
-
- exec { &$mspec_path "$src_directory/tests/EventStore.Persistence.AcceptanceTests/bin/$target_config/EventStore.Persistence.AcceptanceTests.dll" }
-}
-
-task RunSerializationTests {
- exec { &$mspec_path "$src_directory\tests\EventStore.Serialization.AcceptanceTests\bin\$target_config\EventStore.Serialization.AcceptanceTests.dll" }
-}
-
-task Package -depends Build, PackageEventStore, PackageMongoPersistence, PackageRavenPersistence, PackageJsonSerialization, PackageServiceStackSerialization, PackageNLogLogging, PackageLog4NetLogging {
- move $output_directory $publish_directory
-}
-
-task PackageEventStore -depends Clean, Compile {
- mkdir "$output_directory\bin" | out-null
- Merge-Assemblies -outputFile "$output_directory\bin\EventStore.dll" -exclude "EventStore.*" -keyfile $keyFile -files @(
- "$src_directory\proj\EventStore\bin\$target_config\EventStore.dll",
- "$src_directory\proj\EventStore.Core\bin\$target_config\EventStore.Core.dll",
- "$src_directory\proj\EventStore.Serialization\bin\$target_config\EventStore.Serialization.dll",
- "$src_directory\proj\EventStore.Persistence.SqlPersistence\bin\$target_config\EventStore.Persistence.SqlPersistence.dll",
- "$src_directory\proj\EventStore.Wireup\bin\$target_config\EventStore.Wireup.dll"
- )
-
- write-host Rereferencing Merged Assembly
- exec { msbuild /nologo /verbosity:quiet $sln_file /p:Configuration=$target_config /t:Clean }
-
- exec { msbuild /nologo /verbosity:quiet $sln_file /p:Configuration=$target_config /p:ILMerged=true /p:TargetFrameworkVersion=v4.0 }
-}
-
-task PackageMongoPersistence -depends Clean, Compile,PackageEventStore {
- mkdir $output_directory\plugins\persistence\mongo | out-null
-
- Merge-Assemblies -outputFile "$output_directory/plugins/persistence/mongo/EventStore.Persistence.MongoPersistence.dll" -exclude "MongoDB.*" -keyfile $keyFile -files @(
- "$src_directory/proj/EventStore.Persistence.MongoPersistence/bin/$target_config/EventStore.Persistence.MongoPersistence.dll",
- "$src_directory/proj/EventStore.Persistence.MongoPersistence.Wireup/bin/$target_config/EventStore.Persistence.MongoPersistence.Wireup.dll"
- )
-
- copy "$src_directory\proj\EventStore.Persistence.MongoPersistence\bin\$target_config\MongoDB*.dll" "$output_directory\plugins\persistence\mongo"
-}
-
-task PackageRavenPersistence -depends Clean, Compile, PackageEventStore {
- mkdir $output_directory\plugins\persistence\raven | out-null
-
- Merge-Assemblies -outputFile "$output_directory/plugins/persistence/raven/EventStore.Persistence.RavenPersistence.dll" -exclude "Raven.*" -keyfile $keyFile -files @(
- "$src_directory/proj/EventStore.Persistence.RavenPersistence/bin/$target_config/EventStore.Persistence.RavenPersistence.dll",
- "$src_directory/proj/EventStore.Persistence.RavenPersistence.Wireup/bin/$target_config/EventStore.Persistence.RavenPersistence.Wireup.dll"
- )
-
- copy "$src_directory\proj\EventStore.Persistence.RavenPersistence\bin\$target_config\Raven*.dll" "$output_directory\plugins\persistence\raven"
-}
-
-task PackageJsonSerialization -depends Clean, Compile, PackageEventStore {
- mkdir $output_directory\plugins\serialization\json-net | out-null
-
- Merge-Assemblies -outputFile "$output_directory/plugins/serialization/json-net/EventStore.Serialization.Json.dll" -exclude "EventStore.*" -keyfile $keyFile -files @(
- "$src_directory/proj/EventStore.Serialization.Json/bin/$target_config/EventStore.Serialization.Json.dll",
- "$src_directory/proj/EventStore.Serialization.Json/bin/$target_config/Newtonsoft.Json*.dll",
- "$src_directory/proj/EventStore.Serialization.Json.Wireup/bin/$target_config/EventStore.Serialization.Json.Wireup.dll"
- )
-}
-
-task PackageServiceStackSerialization -depends Clean, Compile, PackageEventStore {
- mkdir $output_directory\plugins\serialization\servicestack | out-null
-
- Merge-Assemblies -outputFile "$output_directory/plugins/serialization/servicestack/EventStore.Serialization.ServiceStack.dll" -exclude "EventStore.*" -keyfile $keyFile -files @(
- "$src_directory/proj/EventStore.Serialization.ServiceStack/bin/$target_config/EventStore.Serialization.ServiceStack.dll",
- "$src_directory/proj/EventStore.Serialization.ServiceStack/bin/$target_config/ServiceStack.Text.dll",
- "$src_directory/proj/EventStore.Serialization.ServiceStack.Wireup/bin/$target_config/EventStore.Serialization.ServiceStack.Wireup.dll"
- )
-}
-
-task PackageNLogLogging -depends Clean, Compile, PackageEventStore {
- mkdir $output_directory\plugins\logging\nlog | out-null
- copy "$src_directory\proj\EventStore.Logging.NLog\bin\$target_config\EventStore.Logging.NLog.*" "$output_directory\plugins\logging\nlog"
-
- copy "$src_directory\proj\EventStore.Logging.NLog\bin\$target_config\NLog.dll" "$output_directory\plugins\logging\nlog"
-}
-
-task PackageLog4NetLogging -depends Clean, Compile, PackageEventStore {
- mkdir $output_directory\plugins\logging\log4net | out-null
-
- copy "$src_directory\proj\EventStore.Logging.Log4Net\bin\$target_config\EventStore.Logging.Log4Net.*" "$output_directory\plugins\logging\log4net"
-
- copy "$src_directory\proj\EventStore.Logging.Log4Net\bin\$target_config\log4net.dll" "$output_directory\plugins\logging\log4net"
-}
-
-task PackageDocs {
- mkdir "$output_directory\doc"
- copy "$base_directory\doc\*.*" "$output_directory\doc"
-}
-
-task Clean {
- Clean-Item $publish_directory -ea SilentlyContinue
- Clean-Item $output_directory -ea SilentlyContinue
-}
-
-task NuGetPack -depends Package {
- gci -r -i *.nuspec "$nuget_dir" |% { .$nuget_dir\nuget.exe pack $_ -basepath $base_directory -o $publish_directory -version $version }
-}
\ No newline at end of file
diff --git a/build/psake-config.ps1 b/build/psake-config.ps1
deleted file mode 100644
index dd5044d2b..000000000
--- a/build/psake-config.ps1
+++ /dev/null
@@ -1,2 +0,0 @@
-$config.modules=(".\build\modules\*.psm1")
-$config.moduleScope="global"
\ No newline at end of file
diff --git a/build/psake.cmd b/build/psake.cmd
deleted file mode 100644
index 58b9371f7..000000000
--- a/build/psake.cmd
+++ /dev/null
@@ -1,11 +0,0 @@
-@echo off
-
-if '%1'=='/?' goto help
-if '%1'=='-help' goto help
-if '%1'=='-h' goto help
-
-powershell -NoProfile -ExecutionPolicy Bypass -Command "& '%~dp0\psake.ps1' %*; if ($psake.build_success -eq $false) { exit 1 } else { exit 0 }"
-goto :eof
-
-:help
-powershell -NoProfile -ExecutionPolicy Bypass -Command "& '%~dp0\psake.ps1' -help"
diff --git a/build/psake.ps1 b/build/psake.ps1
deleted file mode 100644
index 4055c03b3..000000000
--- a/build/psake.ps1
+++ /dev/null
@@ -1,47 +0,0 @@
-# Helper script for those who want to run psake without importing the module.
-# Example:
-# .\psake.ps1 "default.ps1" "BuildHelloWord" "4.0"
-
-# Must match parameter definitions for psake.psm1/invoke-psake
-# otherwise named parameter binding fails
-param(
- [Parameter(Position=0,Mandatory=0)]
- [string]$buildFile = 'default.ps1',
- [Parameter(Position=1,Mandatory=0)]
- [string[]]$taskList = @(),
- [Parameter(Position=2,Mandatory=0)]
- [string]$framework,
- [Parameter(Position=3,Mandatory=0)]
- [switch]$docs = $false,
- [Parameter(Position=4,Mandatory=0)]
- [System.Collections.Hashtable]$parameters = @{},
- [Parameter(Position=5, Mandatory=0)]
- [System.Collections.Hashtable]$properties = @{},
- [Parameter(Position=6, Mandatory=0)]
- [alias("init")]
- [scriptblock]$initialization = {},
- [Parameter(Position=7, Mandatory=0)]
- [switch]$nologo = $false,
- [Parameter(Position=8, Mandatory=0)]
- [switch]$help = $false,
- [Parameter(Position=9, Mandatory=0)]
- [string]$scriptPath = $(Split-Path -parent $MyInvocation.MyCommand.path)
-)
-
-# '[p]sake' is the same as 'psake' but $Error is not polluted
-remove-module [p]sake
-import-module (join-path $scriptPath psake.psm1)
-if ($help) {
- Get-Help Invoke-psake -full
- return
-}
-
-if (-not(test-path $buildFile)) {
- $absoluteBuildFile = (join-path $scriptPath $buildFile)
- if (test-path $absoluteBuildFile) {
- $buildFile = $absoluteBuildFile
- }
-}
-
-$psake.use_exit_on_error = $true
-invoke-psake $buildFile $taskList $framework $docs $parameters $properties $initialization $nologo
diff --git a/build/psake.psm1 b/build/psake.psm1
deleted file mode 100644
index fb84cbdce..000000000
--- a/build/psake.psm1
+++ /dev/null
@@ -1,709 +0,0 @@
-# psake
-# Copyright (c) 2010 James Kovacs
-# Permission is hereby granted, free of charge, to any person obtaining a copy
-# of this software and associated documentation files (the "Software"), to deal
-# in the Software without restriction, including without limitation the rights
-# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-# copies of the Software, and to permit persons to whom the Software is
-# furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice shall be included in
-# all copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-# THE SOFTWARE.
-
-#Requires -Version 2.0
-
-#-- Public Module Functions --#
-
-# .ExternalHelp psake.psm1-help.xml
-function Invoke-Task
-{
- [CmdletBinding()]
- param(
- [Parameter(Position=0,Mandatory=1)] [string]$taskName
- )
-
- Assert $taskName ($msgs.error_invalid_task_name)
-
- $taskKey = $taskName.ToLower()
-
- if ($currentContext.aliases.Contains($taskKey)) {
- $taskName = $currentContext.aliases.$taskKey.Name
- $taskKey = $taskName.ToLower()
- }
-
- $currentContext = $psake.context.Peek()
-
- Assert ($currentContext.tasks.Contains($taskKey)) ($msgs.error_task_name_does_not_exist -f $taskName)
-
- if ($currentContext.executedTasks.Contains($taskKey)) { return }
-
- Assert (!$currentContext.callStack.Contains($taskKey)) ($msgs.error_circular_reference -f $taskName)
-
- $currentContext.callStack.Push($taskKey)
-
- $task = $currentContext.tasks.$taskKey
-
- $precondition_is_valid = & $task.Precondition
-
- if (!$precondition_is_valid) {
- Write-ColoredOutput ($msgs.precondition_was_false -f $taskName) -foregroundcolor Cyan
- } else {
- if ($taskKey -ne 'default') {
-
- if ($task.PreAction -or $task.PostAction) {
- Assert ($task.Action -ne $null) ($msgs.error_missing_action_parameter -f $taskName)
- }
-
- if ($task.Action) {
- try {
- foreach($childTask in $task.DependsOn) {
- Invoke-Task $childTask
- }
-
- $stopwatch = [System.Diagnostics.Stopwatch]::StartNew()
- $currentContext.currentTaskName = $taskName
-
- & $currentContext.taskSetupScriptBlock
-
- if ($task.PreAction) {
- & $task.PreAction
- }
-
- if ($currentContext.config.taskNameFormat -is [ScriptBlock]) {
- & $currentContext.config.taskNameFormat $taskName
- } else {
- Write-ColoredOutput ($currentContext.config.taskNameFormat -f $taskName) -foregroundcolor Cyan
- }
-
- foreach ($variable in $task.requiredVariables) {
- Assert ((test-path "variable:$variable") -and ((get-variable $variable).Value -ne $null)) ($msgs.required_variable_not_set -f $variable, $taskName)
- }
-
- & $task.Action
-
- if ($task.PostAction) {
- & $task.PostAction
- }
-
- & $currentContext.taskTearDownScriptBlock
- $task.Duration = $stopwatch.Elapsed
- } catch {
- if ($task.ContinueOnError) {
- "-"*70
- Write-ColoredOutput ($msgs.continue_on_error -f $taskName,$_) -foregroundcolor Yellow
- "-"*70
- $task.Duration = $stopwatch.Elapsed
- } else {
- throw $_
- }
- }
- } else {
- # no action was specified but we still execute all the dependencies
- foreach($childTask in $task.DependsOn) {
- Invoke-Task $childTask
- }
- }
- } else {
- foreach($childTask in $task.DependsOn) {
- Invoke-Task $childTask
- }
- }
-
- Assert (& $task.Postcondition) ($msgs.postcondition_failed -f $taskName)
- }
-
- $poppedTaskKey = $currentContext.callStack.Pop()
- Assert ($poppedTaskKey -eq $taskKey) ($msgs.error_corrupt_callstack -f $taskKey,$poppedTaskKey)
-
- $currentContext.executedTasks.Push($taskKey)
-}
-
-# .ExternalHelp psake.psm1-help.xml
-function Exec
-{
- [CmdletBinding()]
- param(
- [Parameter(Position=0,Mandatory=1)][scriptblock]$cmd,
- [Parameter(Position=1,Mandatory=0)][string]$errorMessage = ($msgs.error_bad_command -f $cmd)
- )
- & $cmd
- if ($lastexitcode -ne 0) {
- throw ("Exec: " + $errorMessage)
- }
-}
-
-# .ExternalHelp psake.psm1-help.xml
-function Assert
-{
- [CmdletBinding()]
- param(
- [Parameter(Position=0,Mandatory=1)]$conditionToCheck,
- [Parameter(Position=1,Mandatory=1)]$failureMessage
- )
- if (!$conditionToCheck) {
- throw ("Assert: " + $failureMessage)
- }
-}
-
-# .ExternalHelp psake.psm1-help.xml
-function Task
-{
- [CmdletBinding()]
- param(
- [Parameter(Position=0,Mandatory=1)][string]$name = $null,
- [Parameter(Position=1,Mandatory=0)][scriptblock]$action = $null,
- [Parameter(Position=2,Mandatory=0)][scriptblock]$preaction = $null,
- [Parameter(Position=3,Mandatory=0)][scriptblock]$postaction = $null,
- [Parameter(Position=4,Mandatory=0)][scriptblock]$precondition = {$true},
- [Parameter(Position=5,Mandatory=0)][scriptblock]$postcondition = {$true},
- [Parameter(Position=6,Mandatory=0)][switch]$continueOnError = $false,
- [Parameter(Position=7,Mandatory=0)][string[]]$depends = @(),
- [Parameter(Position=8,Mandatory=0)][string[]]$requiredVariables = @(),
- [Parameter(Position=9,Mandatory=0)][string]$description = $null,
- [Parameter(Position=10,Mandatory=0)][string]$alias = $null
- )
- if ($name -eq 'default') {
- Assert (!$action) ($msgs.error_default_task_cannot_have_action)
- }
-
- $newTask = @{
- Name = $name
- DependsOn = $depends
- PreAction = $preaction
- Action = $action
- PostAction = $postaction
- Precondition = $precondition
- Postcondition = $postcondition
- ContinueOnError = $continueOnError
- Description = $description
- Duration = [System.TimeSpan]::Zero
- RequiredVariables = $requiredVariables
- Alias = $alias
- }
-
- $taskKey = $name.ToLower()
-
- $currentContext = $psake.context.Peek()
-
- Assert (!$currentContext.tasks.ContainsKey($taskKey)) ($msgs.error_duplicate_task_name -f $name)
-
- $currentContext.tasks.$taskKey = $newTask
-
- if($alias)
- {
- $aliasKey = $alias.ToLower()
-
- Assert (!$currentContext.aliases.ContainsKey($aliasKey)) ($msgs.error_duplicate_alias_name -f $alias)
-
- $currentContext.aliases.$aliasKey = $newTask
- }
-}
-
-# .ExternalHelp psake.psm1-help.xml
-function Properties {
- [CmdletBinding()]
- param(
- [Parameter(Position=0,Mandatory=1)][scriptblock]$properties
- )
- $psake.context.Peek().properties += $properties
-}
-
-# .ExternalHelp psake.psm1-help.xml
-function Include {
- [CmdletBinding()]
- param(
- [Parameter(Position=0,Mandatory=1)][string]$fileNamePathToInclude
- )
- Assert (test-path $fileNamePathToInclude -pathType Leaf) ($msgs.error_invalid_include_path -f $fileNamePathToInclude)
- $psake.context.Peek().includes.Enqueue((Resolve-Path $fileNamePathToInclude));
-}
-
-# .ExternalHelp psake.psm1-help.xml
-function FormatTaskName {
- [CmdletBinding()]
- param(
- [Parameter(Position=0,Mandatory=1)]$format
- )
- $psake.context.Peek().config.taskNameFormat = $format
-}
-
-# .ExternalHelp psake.psm1-help.xml
-function TaskSetup {
- [CmdletBinding()]
- param(
- [Parameter(Position=0,Mandatory=1)][scriptblock]$setup
- )
- $psake.context.Peek().taskSetupScriptBlock = $setup
-}
-
-# .ExternalHelp psake.psm1-help.xml
-function TaskTearDown {
- [CmdletBinding()]
- param(
- [Parameter(Position=0,Mandatory=1)][scriptblock]$teardown
- )
- $psake.context.Peek().taskTearDownScriptBlock = $teardown
-}
-
-# .ExternalHelp psake.psm1-help.xml
-function Framework {
- [CmdletBinding()]
- param(
- [Parameter(Position=0,Mandatory=1)][string]$framework
- )
- $psake.context.Peek().config.framework = $framework
-}
-
-# .ExternalHelp psake.psm1-help.xml
-function Invoke-psake {
- [CmdletBinding()]
- param(
- [Parameter(Position = 0, Mandatory = 0)][string] $buildFile,
- [Parameter(Position = 1, Mandatory = 0)][string[]] $taskList = @(),
- [Parameter(Position = 2, Mandatory = 0)][string] $framework,
- [Parameter(Position = 3, Mandatory = 0)][switch] $docs = $false,
- [Parameter(Position = 4, Mandatory = 0)][hashtable] $parameters = @{},
- [Parameter(Position = 5, Mandatory = 0)][hashtable] $properties = @{},
- [Parameter(Position = 6, Mandatory = 0)][alias("init")][scriptblock] $initialization = {},
- [Parameter(Position = 7, Mandatory = 0)][switch] $nologo = $false
- )
- try {
- if (-not $nologo) {
- "psake version {0}`nCopyright (c) 2010 James Kovacs`n" -f $psake.version
- }
-
- # If the default.ps1 file exists and the given "buildfile" isn 't found assume that the given
- # $buildFile is actually the target Tasks to execute in the default.ps1 script.
- if ($buildFile -and !(test-path $buildFile -pathType Leaf) -and (test-path $psake.config_default.buildFileName -pathType Leaf)) {
- $taskList = $buildFile.Split(', ')
- $buildFile = $psake.config_default.buildFileName
- }
-
- # Execute the build file to set up the tasks and defaults
- Assert (test-path $buildFile -pathType Leaf) ($msgs.error_build_file_not_found -f $buildFile)
-
- $psake.build_script_file = get-item $buildFile
- $psake.build_script_dir = $psake.build_script_file.DirectoryName
- $psake.build_success = $false
-
- $psake.context.push(@{
- "taskSetupScriptBlock" = {};
- "taskTearDownScriptBlock" = {};
- "executedTasks" = new-object System.Collections.Stack;
- "callStack" = new-object System.Collections.Stack;
- "originalEnvPath" = $env:path;
- "originalDirectory" = get-location;
- "originalErrorActionPreference" = $global:ErrorActionPreference;
- "tasks" = @{};
- "aliases" = @{};
- "properties" = @();
- "includes" = new-object System.Collections.Queue;
- "config" = Create-ConfigurationForNewContext $buildFile $framework
- })
-
- Load-Configuration $psake.build_script_dir
-
- Load-Modules
-
- $stopwatch = [System.Diagnostics.Stopwatch]::StartNew()
-
- set-location $psake.build_script_dir
-
- $frameworkOldValue = $framework
- . $psake.build_script_file.FullName
-
- $currentContext = $psake.context.Peek()
-
- if ($framework -ne $frameworkOldValue) {
- write-coloredoutput $msgs.warning_deprecated_framework_variable -foregroundcolor Yellow
- $currentContext.config.framework = $framework
- }
-
- if ($docs) {
- Write-Documentation
- Cleanup-Environment
- return
- }
-
- Configure-BuildEnvironment
-
- while ($currentContext.includes.Count -gt 0) {
- $includeFilename = $currentContext.includes.Dequeue()
- . $includeFilename
- }
-
- foreach ($key in $parameters.keys) {
- if (test-path "variable:\$key") {
- set-item -path "variable:\$key" -value $parameters.$key | out-null
- } else {
- new-item -path "variable:\$key" -value $parameters.$key | out-null
- }
- }
-
- # The initial dot (.) indicates that variables initialized/modified in the propertyBlock are available in the parent scope.
- foreach ($propertyBlock in $currentContext.properties) {
- . $propertyBlock
- }
-
- foreach ($key in $properties.keys) {
- if (test-path "variable:\$key") {
- set-item -path "variable:\$key" -value $properties.$key | out-null
- }
- }
-
- # Simple dot sourcing will not work. We have to force the script block into our
- # module's scope in order to initialize variables properly.
- . $MyInvocation.MyCommand.Module $initialization
-
- # Execute the list of tasks or the default task
- if ($taskList) {
- foreach ($task in $taskList) {
- invoke-task $task
- }
- } elseif ($currentContext.tasks.default) {
- invoke-task default
- } else {
- throw $msgs.error_no_default_task
- }
-
- Write-ColoredOutput ("`n" + $msgs.build_success + "`n") -foregroundcolor Green
-
- Write-TaskTimeSummary $stopwatch.Elapsed
-
- $psake.build_success = $true
- } catch {
- $currentConfig = Get-CurrentConfigurationOrDefault
- if ($currentConfig.verboseError) {
- $error_message = "{0}: An Error Occurred. See Error Details Below: `n" -f (Get-Date)
- $error_message += ("-" * 70) + "`n"
- $error_message += Resolve-Error $_
- $error_message += ("-" * 70) + "`n"
- $error_message += "Script Variables" + "`n"
- $error_message += ("-" * 70) + "`n"
- $error_message += get-variable -scope script | format-table | out-string
- } else {
- # ($_ | Out-String) gets error messages with source information included.
- $error_message = "{0}: An Error Occurred: `n{1}" -f (Get-Date), ($_ | Out-String)
- }
-
- $psake.build_success = $false
-
- if (!$psake.run_by_psake_build_tester) {
- # if we are running in a nested scope (i.e. running a psake script from a psake script) then we need to re-throw the exception
- # so that the parent script will fail otherwise the parent script will report a successful build
- $inNestedScope = ($psake.context.count -gt 1)
- if ( $inNestedScope ) {
- throw $_
- } else {
- Write-ColoredOutput $error_message -foregroundcolor Red
- }
-
- }
- } finally {
- Cleanup-Environment
- }
-}
-
-#-- Private Module Functions --#
-function Write-ColoredOutput {
- param(
- [string] $message,
- [System.ConsoleColor] $foregroundcolor
- )
-
- $currentConfig = Get-CurrentConfigurationOrDefault
- if ($currentConfig.coloredOutput -eq $true) {
- if (($Host.UI -ne $null) -and ($Host.UI.RawUI -ne $null)) {
- $previousColor = $Host.UI.RawUI.ForegroundColor
- $Host.UI.RawUI.ForegroundColor = $foregroundcolor
- }
- }
-
- $message
-
- if ($previousColor -ne $null) {
- $Host.UI.RawUI.ForegroundColor = $previousColor
- }
-}
-
-function Load-Modules {
- $currentConfig = $psake.context.peek().config
- if ($currentConfig.modules) {
-
- $scope = $currentConfig.moduleScope
-
- $global = [string]::Equals($scope, "global", [StringComparison]::CurrentCultureIgnoreCase)
-
- $currentConfig.modules | foreach {
- resolve-path $_ | foreach {
- "Loading module: $_"
- $module = import-module $_ -passthru -DisableNameChecking -global:$global
- if (!$module) {
- throw ($msgs.error_loading_module -f $_.Name)
- }
- }
- }
- ""
- }
-}
-
-function Load-Configuration {
- param(
- [string] $configdir = $PSScriptRoot
- )
-
- $psakeConfigFilePath = (join-path $configdir "psake-config.ps1")
-
- if (test-path $psakeConfigFilePath -pathType Leaf) {
- try {
- $config = Get-CurrentConfigurationOrDefault
- . $psakeConfigFilePath
- } catch {
- throw "Error Loading Configuration from psake-config.ps1: " + $_
- }
- }
-}
-
-function Get-CurrentConfigurationOrDefault() {
- if ($psake.context.count -gt 0) {
- return $psake.context.peek().config
- } else {
- return $psake.config_default
- }
-}
-
-function Create-ConfigurationForNewContext {
- param(
- [string] $buildFile,
- [string] $framework
- )
-
- $previousConfig = Get-CurrentConfigurationOrDefault
-
- $config = new-object psobject -property @{
- buildFileName = $previousConfig.buildFileName;
- framework = $previousConfig.framework;
- taskNameFormat = $previousConfig.taskNameFormat;
- verboseError = $previousConfig.verboseError;
- coloredOutput = $previousConfig.coloredOutput;
- modules = $previousConfig.modules;
- moduleScope = $previousConfig.moduleScope;
- }
-
- if ($framework) {
- $config.framework = $framework;
- }
-
- if ($buildFile) {
- $config.buildFileName = $buildFile;
- }
-
- return $config
-}
-
-function Configure-BuildEnvironment {
- $framework = $psake.context.peek().config.framework
- if ($framework.Length -ne 3 -and $framework.Length -ne 6) {
- throw ($msgs.error_invalid_framework -f $framework)
- }
- $versionPart = $framework.Substring(0, 3)
- $bitnessPart = $framework.Substring(3)
- $versions = $null
- switch ($versionPart) {
- '1.0' {
- $versions = @('v1.0.3705')
- }
- '1.1' {
- $versions = @('v1.1.4322')
- }
- '2.0' {
- $versions = @('v2.0.50727')
- }
- '3.0' {
- $versions = @('v2.0.50727')
- }
- '3.5' {
- $versions = @('v3.5', 'v2.0.50727')
- }
- '4.0' {
- $versions = @('v4.0.30319')
- }
- default {
- throw ($msgs.error_unknown_framework -f $versionPart, $framework)
- }
- }
-
- $bitness = 'Framework'
- if ($versionPart -ne '1.0' -and $versionPart -ne '1.1') {
- switch ($bitnessPart) {
- 'x86' {
- $bitness = 'Framework'
- }
- 'x64' {
- $bitness = 'Framework64'
- }
- { [string]::IsNullOrEmpty($_) } {
- $ptrSize = [System.IntPtr]::Size
- switch ($ptrSize) {
- 4 {
- $bitness = 'Framework'
- }
- 8 {
- $bitness = 'Framework64'
- }
- default {
- throw ($msgs.error_unknown_pointersize -f $ptrSize)
- }
- }
- }
- default {
- throw ($msgs.error_unknown_bitnesspart -f $bitnessPart, $framework)
- }
- }
- }
- $frameworkDirs = $versions | foreach { "$env:windir\Microsoft.NET\$bitness\$_\" }
-
- $frameworkDirs | foreach { Assert (test-path $_ -pathType Container) ($msgs.error_no_framework_install_dir_found -f $_)}
-
- $env:path = ($frameworkDirs -join ";") + ";$env:path"
- # if any error occurs in a PS function then "stop" processing immediately
- # this does not effect any external programs that return a non-zero exit code
- $global:ErrorActionPreference = "Stop"
-}
-
-function Cleanup-Environment {
- if ($psake.context.Count -gt 0) {
- $currentContext = $psake.context.Peek()
- $env:path = $currentContext.originalEnvPath
- Set-Location $currentContext.originalDirectory
- $global:ErrorActionPreference = $currentContext.originalErrorActionPreference
- [void] $psake.context.Pop()
- }
-}
-
-# borrowed from Jeffrey Snover http://blogs.msdn.com/powershell/archive/2006/12/07/resolve-error.aspx
-function Resolve-Error($ErrorRecord = $Error[0]) {
- $error_message = "`nErrorRecord:{0}ErrorRecord.InvocationInfo:{1}Exception:{2}"
- $formatted_errorRecord = $ErrorRecord | format-list * -force | out-string
- $formatted_invocationInfo = $ErrorRecord.InvocationInfo | format-list * -force | out-string
- $formatted_exception = ""
- $Exception = $ErrorRecord.Exception
- for ($i = 0; $Exception; $i++, ($Exception = $Exception.InnerException)) {
- $formatted_exception += ("$i" * 70) + "`n"
- $formatted_exception += $Exception | format-list * -force | out-string
- $formatted_exception += "`n"
- }
-
- return $error_message -f $formatted_errorRecord, $formatted_invocationInfo, $formatted_exception
-}
-
-function Write-Documentation {
- $currentContext = $psake.context.Peek()
-
- if ($currentContext.tasks.default) {
- $defaultTaskDependencies = $currentContext.tasks.default.DependsOn
- } else {
- $defaultTaskDependencies = @()
- }
-
- $currentContext.tasks.Keys | foreach-object {
- if ($_ -eq "default") {
- return
- }
-
- $task = $currentContext.tasks.$_
- new-object PSObject -property @{
- Name = $task.Name;
- Description = $task.Description;
- "Depends On" = $task.DependsOn -join ", "
- Default = if ($defaultTaskDependencies -contains $task.Name) { $true }
- }
- } | sort 'Name' | format-table -autoSize -property Name,Description,"Depends On",Default
-}
-
-function Write-TaskTimeSummary($invokePsakeDuration) {
- "-" * 70
- "Build Time Report"
- "-" * 70
- $list = @()
- $currentContext = $psake.context.Peek()
- while ($currentContext.executedTasks.Count -gt 0) {
- $taskKey = $currentContext.executedTasks.Pop()
- $task = $currentContext.tasks.$taskKey
- if ($taskKey -eq "default") {
- continue
- }
- $list += new-object PSObject -property @{
- Name = $task.Name;
- Duration = $task.Duration
- }
- }
- [Array]::Reverse($list)
- $list += new-object PSObject -property @{
- Name = "Total:";
- Duration = $invokePsakeDuration
- }
- # using "out-string | where-object" to filter out the blank line that format-table prepends
- $list | format-table -autoSize -property Name,Duration | out-string -stream | where-object { $_ }
-}
-
-DATA msgs {
-convertfrom-stringdata @'
- error_invalid_task_name = Task name should not be null or empty string.
- error_task_name_does_not_exist = Task {0} does not exist.
- error_circular_reference = Circular reference found for task {0}.
- error_missing_action_parameter = Action parameter must be specified when using PreAction or PostAction parameters for task {0}.
- error_corrupt_callstack = Call stack was corrupt. Expected {0}, but got {1}.
- error_invalid_framework = Invalid .NET Framework version, {0} specified.
- error_unknown_framework = Unknown .NET Framework version, {0} specified in {1}.
- error_unknown_pointersize = Unknown pointer size ({0}) returned from System.IntPtr.
- error_unknown_bitnesspart = Unknown .NET Framework bitness, {0}, specified in {1}.
- error_no_framework_install_dir_found = No .NET Framework installation directory found at {0}.
- error_bad_command = Error executing command {0}.
- error_default_task_cannot_have_action = 'default' task cannot specify an action.
- error_duplicate_task_name = Task {0} has already been defined.
- error_duplicate_alias_name = Alias {0} has already been defined.
- error_invalid_include_path = Unable to include {0}. File not found.
- error_build_file_not_found = Could not find the build file {0}.
- error_no_default_task = 'default' task required.
- error_loading_module = Error loading module {0}.
- warning_deprecated_framework_variable = Warning: Using global variable $framework to set .NET framework version used is deprecated. Instead use Framework function or configuration file psake-config.ps1.
- required_variable_not_set = Variable {0} must be set to run task {1}.
- postcondition_failed = Postcondition failed for task {0}.
- precondition_was_false = Precondition was false, not executing task {0}.
- continue_on_error = Error in task {0}. {1}
- build_success = Build Succeeded!
-'@
-}
-
-import-localizeddata -bindingvariable msgs -erroraction silentlycontinue
-
-$script:psake = @{}
-$psake.version = "4.1.0" # contains the current version of psake
-$psake.context = new-object system.collections.stack # holds onto the current state of all variables
-$psake.run_by_psake_build_tester = $false # indicates that build is being run by psake-BuildTester
-$psake.config_default = new-object psobject -property @{
- buildFileName = "default.ps1";
- framework = "4.0";
- taskNameFormat = "Executing {0}";
- verboseError = $false;
- coloredOutput = $true;
- modules = $null;
- moduleScope = "local";
-} # contains default configuration, can be overriden in psake-config.ps1 in directory with psake.psm1 or in directory with current build script
-
-$psake.build_success = $false # indicates that the current build was successful
-$psake.build_script_file = $null # contains a System.IO.FileInfo for the current build script
-$psake.build_script_dir = "" # contains a string with fully-qualified path to current build script
-
-Load-Configuration
-
-export-modulemember -function invoke-psake, invoke-task, task, properties, include, formattaskname, tasksetup, taskteardown, framework, assert, exec -variable psake
diff --git a/doc/EventStore - Architectural Overview.docx b/doc/EventStore - Architectural Overview.docx
deleted file mode 100644
index 1904d181a..000000000
Binary files a/doc/EventStore - Architectural Overview.docx and /dev/null differ
diff --git a/doc/EventStore - Transactional Integrity.docx b/doc/EventStore - Transactional Integrity.docx
deleted file mode 100644
index 9a7f80b29..000000000
Binary files a/doc/EventStore - Transactional Integrity.docx and /dev/null differ
diff --git a/doc/EventStore.Example/AggregateMemento.cs b/doc/EventStore.Example/AggregateMemento.cs
deleted file mode 100644
index 8d7997675..000000000
--- a/doc/EventStore.Example/AggregateMemento.cs
+++ /dev/null
@@ -1,12 +0,0 @@
-namespace EventStore.Example
-{
- internal class AggregateMemento
- {
- public string Value { get; set; }
-
- public override string ToString()
- {
- return this.Value;
- }
- }
-}
\ No newline at end of file
diff --git a/doc/EventStore.Example/App.config b/doc/EventStore.Example/App.config
deleted file mode 100644
index 9757d19c5..000000000
--- a/doc/EventStore.Example/App.config
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/doc/EventStore.Example/AuthorizationPipelineHook.cs b/doc/EventStore.Example/AuthorizationPipelineHook.cs
deleted file mode 100644
index 581743025..000000000
--- a/doc/EventStore.Example/AuthorizationPipelineHook.cs
+++ /dev/null
@@ -1,32 +0,0 @@
-namespace EventStore.Example
-{
- using System;
-
- public class AuthorizationPipelineHook : IPipelineHook
- {
- public void Dispose()
- {
- this.Dispose(true);
- GC.SuppressFinalize(this);
- }
- protected virtual void Dispose(bool disposing)
- {
- // no op
- }
-
- public Commit Select(Commit committed)
- {
- // return null if the user isn't authorized to see this commit
- return committed;
- }
- public bool PreCommit(Commit attempt)
- {
- // Can easily do logging or other such activities here
- return true; // true == allow commit to continue, false = stop.
- }
- public void PostCommit(Commit committed)
- {
- // anything to do after the commit has been persisted.
- }
- }
-}
\ No newline at end of file
diff --git a/doc/EventStore.Example/EventStore.Example.csproj b/doc/EventStore.Example/EventStore.Example.csproj
deleted file mode 100644
index c4c3ccab3..000000000
--- a/doc/EventStore.Example/EventStore.Example.csproj
+++ /dev/null
@@ -1,115 +0,0 @@
-
-
-
- Debug
- AnyCPU
- 8.0.30703
- 2.0
- {0143B48E-25AF-4CE0-BD49-A52267D359D3}
- Exe
- Properties
- EventStore.Example
- EventStore.Example
- v4.0
- 512
- true
- ..\..\src\EventStore.snk
- ..\..\src\
- true
-
-
- true
- full
- false
- bin\Debug\
- DEBUG;TRACE
- prompt
- 4
-
-
- pdbonly
- true
- bin\Release\
- TRACE
- prompt
- 4
-
-
-
-
-
-
- Properties\GlobalAssemblyInfo.cs
-
-
- Properties\GlobalSuppressions.cs
-
-
- Properties\VersionAssemblyInfo.cs
-
-
-
-
-
-
- True
- True
- Resources.resx
-
-
-
-
-
- ..\..\output\bin\EventStore.dll
-
-
- {03946843-F343-419C-88EF-3E446D08DFA6}
- EventStore
-
-
- {D6413244-42F5-4233-B347-D0A804B09CC9}
- EventStore.Core
-
-
- {DAFD3F38-33F3-4F53-BFEA-44E51BD1E8F1}
- EventStore.Persistence.SqlPersistence
-
-
- {DEFFE0C3-2988-4C58-9E36-1302842FFDBD}
- EventStore.Serialization.Json.Wireup
-
-
- {CFD895BD-7CB2-4811-A6FA-1851DF769B67}
- EventStore.Serialization.Json
-
-
- {A5BF4B86-26F6-418D-BE35-C6CC3A623D27}
- EventStore.Serialization
-
-
- {421664DB-C18D-4499-ABC1-C9086D525F80}
- EventStore.Wireup
-
-
-
-
-
-
-
-
- ResXFileCodeGenerator
- Resources.Designer.cs
- Designer
-
-
-
-
- Properties\CustomDictionary.xml
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/doc/EventStore.Example/MainProgram.cs b/doc/EventStore.Example/MainProgram.cs
deleted file mode 100644
index ab985b975..000000000
--- a/doc/EventStore.Example/MainProgram.cs
+++ /dev/null
@@ -1,109 +0,0 @@
-using EventStore.Persistence.SqlPersistence.SqlDialects;
-
-namespace EventStore.Example
-{
- using System;
- using System.Transactions;
- using Dispatcher;
-
- internal static class MainProgram
- {
- private static readonly Guid StreamId = Guid.NewGuid(); // aggregate identifier
- private static readonly byte[] EncryptionKey = new byte[]
- {
- 0x0, 0x1, 0x2, 0x3, 0x4, 0x5, 0x6, 0x7, 0x8, 0x9, 0xa, 0xb, 0xc, 0xd, 0xe, 0xf
- };
- private static IStoreEvents store;
-
- private static void Main()
- {
- using (var scope = new TransactionScope())
- using (store = WireupEventStore())
- {
- OpenOrCreateStream();
- AppendToStream();
- TakeSnapshot();
- LoadFromSnapshotForwardAndAppend();
- scope.Complete();
- }
-
- Console.WriteLine(Resources.PressAnyKey);
- Console.ReadKey();
- }
-
- private static IStoreEvents WireupEventStore()
- {
- return Wireup.Init()
- .LogToOutputWindow()
- .UsingInMemoryPersistence()
- .UsingSqlPersistence("EventStore") // Connection string is in app.config
- .WithDialect(new MsSqlDialect())
- .EnlistInAmbientTransaction() // two-phase commit
- .InitializeStorageEngine()
- .TrackPerformanceInstance("example")
- .UsingJsonSerialization()
- .Compress()
- .EncryptWith(EncryptionKey)
- .HookIntoPipelineUsing(new[] { new AuthorizationPipelineHook() })
- .UsingSynchronousDispatchScheduler()
- .DispatchTo(new DelegateMessageDispatcher(DispatchCommit))
- .Build();
- }
- private static void DispatchCommit(Commit commit)
- {
- // This is where we'd hook into our messaging infrastructure, such as NServiceBus,
- // MassTransit, WCF, or some other communications infrastructure.
- // This can be a class as well--just implement IDispatchCommits.
- try
- {
- foreach (var @event in commit.Events)
- Console.WriteLine(Resources.MessagesDispatched + ((SomeDomainEvent)@event.Body).Value);
- }
- catch (Exception)
- {
- Console.WriteLine(Resources.UnableToDispatch);
- }
- }
-
- private static void OpenOrCreateStream()
- {
- // we can call CreateStream(StreamId) if we know there isn't going to be any data.
- // or we can call OpenStream(StreamId, 0, int.MaxValue) to read all commits,
- // if no commits exist then it creates a new stream for us.
- using (var stream = store.OpenStream(StreamId, 0, int.MaxValue))
- {
- var @event = new SomeDomainEvent { Value = "Initial event." };
-
- stream.Add(new EventMessage { Body = @event });
- stream.CommitChanges(Guid.NewGuid());
- }
- }
- private static void AppendToStream()
- {
- using (var stream = store.OpenStream(StreamId, int.MinValue, int.MaxValue))
- {
- var @event = new SomeDomainEvent { Value = "Second event." };
-
- stream.Add(new EventMessage { Body = @event });
- stream.CommitChanges(Guid.NewGuid());
- }
- }
- private static void TakeSnapshot()
- {
- var memento = new AggregateMemento { Value = "snapshot" };
- store.Advanced.AddSnapshot(new Snapshot(StreamId, 2, memento));
- }
- private static void LoadFromSnapshotForwardAndAppend()
- {
- var latestSnapshot = store.Advanced.GetSnapshot(StreamId, int.MaxValue);
-
- using (var stream = store.OpenStream(latestSnapshot, int.MaxValue))
- {
- var @event = new SomeDomainEvent { Value = "Third event (first one after a snapshot)." };
-
- stream.Add(new EventMessage { Body = @event });
- stream.CommitChanges(Guid.NewGuid());
- }
- }
- }
-}
\ No newline at end of file
diff --git a/doc/EventStore.Example/Settings.StyleCop b/doc/EventStore.Example/Settings.StyleCop
deleted file mode 100644
index 7587c6958..000000000
--- a/doc/EventStore.Example/Settings.StyleCop
+++ /dev/null
@@ -1,184 +0,0 @@
-
-
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
-
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
-
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
-
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
-
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
-
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
-
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
- False
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/doc/EventStore.Example/SomeDomainEvent.cs b/doc/EventStore.Example/SomeDomainEvent.cs
deleted file mode 100644
index d0defd8de..000000000
--- a/doc/EventStore.Example/SomeDomainEvent.cs
+++ /dev/null
@@ -1,7 +0,0 @@
-namespace EventStore.Example
-{
- internal class SomeDomainEvent
- {
- public string Value { get; set; }
- }
-}
\ No newline at end of file
diff --git a/doc/EventStore.FileSystemPersistenceEngine.txt b/doc/EventStore.FileSystemPersistenceEngine.txt
deleted file mode 100644
index c4fc1a090..000000000
--- a/doc/EventStore.FileSystemPersistenceEngine.txt
+++ /dev/null
@@ -1,33 +0,0 @@
-ID 16
-Revision 4
-Position 4
-
-24 bytes per index entry = 43,690 entries per MB of index
-
-ID 16
-entry + position 8
-entry + position 8
-entry + position 8
-entry + position 8
-entry + position 8
-
-2K = 256 entries
-256 * 8 - 16
-2032 = 2048
-
-16 byte header (for ID)
-
-ID[16] + Entries[126 * 8 bytes] = 1024 bytes
-
-(KB - 16) / 8 = # of entries per "index"
-
-
-100 MB = 4,369,066 entries (and just as many aggregates)
-100 MB = 13,107,198 entries (but a limited # of aggregates) @ 1K block size filled to capacity = 3x increase in # of commits
-
-easiest and fastest = ID/revision/position
-
-ID 16
-Rev 4
-Pos 4 - 1 bit
-Disp 1 bit
\ No newline at end of file
diff --git a/doc/FileSystemPersistence Record Layout.txt b/doc/FileSystemPersistence Record Layout.txt
deleted file mode 100644
index ca29fe9cb..000000000
--- a/doc/FileSystemPersistence Record Layout.txt
+++ /dev/null
@@ -1,21 +0,0 @@
-Index
-Stream id 16
-# of events 2
-Size of commit 4 (- 1 bit)
-Dispatched 1 bit
---------------- 22
-
-Commit header
-Stream id 16
-# of events 2 (commit sequence is derived)
-commit id 16
-commit stamp dif4
-Length of body 4
-Checksum 16 (*including* header)--MD5
---------------- 58
-
-Commit body ?
-
-
-
-Engine should track "head" for each stream and head of file stream...
diff --git a/doc/acknowledgments.txt b/doc/acknowledgments.txt
deleted file mode 100644
index 55b9a87e4..000000000
--- a/doc/acknowledgments.txt
+++ /dev/null
@@ -1,13 +0,0 @@
-Jonathan Oliver @jonathan_oliver https://github.com/joliver http://blog.jonathanoliver.com
-Greg Young @gregyoung https://github.com/gregoryyoung http://codebetter.com/gregyoung
-Andreas Ohlund @andreas_ohlund https://github.com/andreasohlund http://andreasohlund.net
-Jonathan Matheus @kblooie https://github.com/kblooie
-Aaron Navarro @aaron_navarro https://github.com/anavarro9731
-Simon Green https://github.com/CaptainCodeman http://www.captaincodeman.com
-Chris Nicola @lucisferre https://github.com/lucisferre http://www.lucisferre.net
-Pieter Joost @pjvds https://github.com/pjvds http://ncqrs.org
-Daniel Hoelbling @tigraine https://github.com/Tigraine http://www.tigraine.at
-Damian Hickey @randompunter https://github.com/damianh http://dhickey.ie/
-John Downey @jtdowney https://github.com/jtdowney http://jtdowney.com
-Jimit Ndiaye @jimitndiaye https://github.com/jimitndiaye
-Mikael Östberg @MikaelOstberg https://github.com/MikeEast http://www.inloop.se/
\ No newline at end of file
diff --git a/doc/roadmap.txt b/doc/roadmap.txt
deleted file mode 100644
index 502376c56..000000000
--- a/doc/roadmap.txt
+++ /dev/null
@@ -1,37 +0,0 @@
-3.1
- - Add additional documentation using GitHub wikis and more complete quickstart examples
- - .NET 4.0 only?
- - Merge CommonDomain
- - Amazon S3/Tables persistence
- - CouchDB persistence
- - Sybase ASE persistence
- - Sybase SQL Anywhere persistence
- - Potentially split "Commits" table for SQL, e.g. Commits and Dispatch. The Dispatch would hold the commit until it
- was dispatched and then it would be moved into the Commits table along with the Streams being updated. We could
- use uNION ALL to make it feel like it's a single table for the EventStore on top. This would eliminate the need
- for complex joins and it would make updating the stream heads async as well. The only "loss" is the double write
- that would occur when moving the data between commits and dispatch. This could also potentially eliminate the need
- for the 'Dispatched' bit column. Migration to the new schema wouldn't be particularly difficult and would require
- a small script.
- - Polling Dispatch Scheduler which polls the event store at the specified frequency and dispatches and new
- commits which have been added.
- - Multi-format Deserializer which attempts a number of internal deserializers (JSON, BSON, PB, Binary, XML, etc)
- before giving up. This would allow people to change their serialization in production if necessary
- for things like encryption, etc. For example, we're changing the encryption on all commits and we need to
- support several keys simultaenously for a period of time...
-
-3.2:
- - FileSystem persistence
- - Redis
- - Azure Tables persistence
- - Oracle persistence
- - ProtocolBuffers serializer
- - Official website
-
-4.0:
- - Master/slave replication "helper"
- * When failing over from master to slave, ensure that the most recent commits are in the slave.
- * If not, push the commits to the slave to help avoid a split brain condition.
- - Create a PersistenceEngine implementation that can be exposed as an endpoint, e.g. REST or HTTP, etc. such that
- the OptimisticEventStore could use that endpoint as the underlying storage. This would create a logical layering
- point which could then be separated into physical layers more easily.
\ No newline at end of file
diff --git a/docs/Testing.md b/docs/Testing.md
new file mode 100644
index 000000000..1613ea91c
--- /dev/null
+++ b/docs/Testing.md
@@ -0,0 +1,23 @@
+# Testing And Test Frameworks in NEventStore
+
+While upgrading the solution to support dotnet core, we also tried to migrate the tests to other test frameworks
+(because not all of them supported dotnet core correctly when the migration job started).
+
+Several trial and errors were made, but in the end we were able to implement the tests using all the 3 major testing frameworks available in the dotnet world:
+
+- XUnit
+- NUnit
+- MSTest
+
+We had to write 3 version of the `SpecificationBase` class and adapt the testing attributes to each framework.
+
+I you inspect the code you'll see a lot of `#if NUNIT` (and the like) lines of code.
+
+The actual implementation compiles all the projects to use NUnit.
+
+You can change the behavior following these steps:
+
+- go through all the .csproj files and change the compilation constant from NUNIT to XUNIT or MSTEST.
+- in the assemblies that contain tests you need to reference the correct Test Framework assemblies and TestAdapter for the framework you are going to use.
+
+Having more than one test runner might not be a good idea because some CI tools (like Appveyor) might autodetect them and execute the tests for a framework you are not using, and it will surely endup with failures and errors of your build.
\ No newline at end of file
diff --git a/icon.png b/icon.png
new file mode 100644
index 000000000..c6c977dab
Binary files /dev/null and b/icon.png differ
diff --git a/doc/license.txt b/license.txt
similarity index 76%
rename from doc/license.txt
rename to license.txt
index 4393ddaca..6a5550266 100644
--- a/doc/license.txt
+++ b/license.txt
@@ -1,25 +1,21 @@
-Copyright (c) 2011-2012 Jonathan Oliver
-
-MIT License
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
-
-NOTE: Various optional and subordinate components carry their own licensing
-requirements and restrictions. Use of those components is subject to the terms
-and conditions outlined the respective license of each component.
\ No newline at end of file
+The MIT License
+
+Copyright (c) 2013 Jonathan Oliver, Jonathan Matheus, Damian Hickey and contributors
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
\ No newline at end of file
diff --git a/readme.markdown b/readme.markdown
deleted file mode 100644
index 9d9701eb7..000000000
--- a/readme.markdown
+++ /dev/null
@@ -1,191 +0,0 @@
-EventStore
-======================================================================
-
- - The most recent stable release is avaiable on [NuGet.org](https://nuget.org/packages/EventStore)
- - CI builds can be viewed on [Codebetter's TeamCity server](http://teamcity.codebetter.com/project.html?projectId=project247&tab=projectOverview).
- - CI package are availble on [myget.org](http://www.myget.org/gallery/eventstore).
-
- CI builds and packages are to be considered unstable.
-
-## Overview
-The EventStore is a persistence library used to abstract different storage implementations
-when using event sourcing as storage mechanism. Event sourcing is most closely associated
-with a concept known as [CQRS](http://cqrsinfo.com).
-
-### Need Help? Have a Question?
-Ask your question on [Stack Overflow](http://stackoverflow.com/search?q=[cqrs]+eventstore) and tag your question with
-the CQRS tag and the word "EventStore" in the title.
-
-### Purpose and Theory
-The purpose of the EventStore is to represent a series of events as a stream. Furthermore,
-it provides hooks whereby any events committed to the stream can be dispatched to interested
-parties.
-
-Guided by a number strategic design decisions based upon the needs of applications using event sourcing,
-the EventStore is able to liberate applications from the stringent requirements often imposed by
-infrastructure components. Specifically, most CQRS-style applications read from a message queue
-and perform some processing. When processing is complete, the application then commits the work
-to storage and publishes the completed work. In almost all cases, this requires a two-phase commit
-managed by a distributed transaction coordinator (MSDTC in .NET) along with various security settings
-and firewall ports opened and avaiable whereby such components can communicate, not to mention a
-ubiquitous requirement for Microsoft Windows on all machines in .NET environments.
-
-When using two-phase commit in .NET, there are very few database drivers that support this scenario
-and even fewer message queues that support it. In essence, if you want to implement a typical
-CQRS-style application, you're stuck with MSMQ and SQL Server using MSDTC. Granted, there are
-other choices, but the constraints imposed by a two-phase commit are burdensome. This also
-creates additional issues when utilizing shared hosting or running on Mono as support in frameworks
-and drivers is either poor, buggy, or unavailable.
-
-The EventStore liberates application developers from this level of infrastructure awareness and
-concern by committing all work within a separate isolated atomic unit--all without using transactions.
-Furthermore, it does this outside of any ambient transaction from a message queue or other
-persistence mechanisms. In other words, application developers are free to use virtually any
-messaging queuing infrastructure, message bus (if at all), and storage engine. Each will perform
-its own specific task in an isolated manner with full transactional integrity all without
-enlisting any resources (other than a message queue) in some form of transaction.
-
-Interestingly enough, even without the presence of distributed transactions across the various resources
-involved, such as a message queue and persistent storage, the EventStore is able to ensure a fully
-transactional experience. This is achieved by breaking apart a distributed transaction into smaller
-pieces and performing each one individually. This is one of the primary goals and motivations in the
-underlying model found in the EventStore. Thus each message delivered by the queuing infrastructure is
-made to be idempotent, even though the message may be delivered multiple times, as per message queue
-"at-least-once" guarantees. Following this, the EventStore is able to ensure that all events committed
-are always dispatched to any messaging infrastructure.
-
-**New in v3.0:** I knew you guys couldn't live without it, so for those storage engines and message systems
-which support and participate two-phase commits, there now exists the ability to specify a
-TransactionScopeOption of 'Required'. Simply indicate this using the following wireup overload:
-
- var store = Wireup.Init()
- .UsingSqlPersistence("connection-name-here") // also works with UsingRavenPersistence()
- .EnlistInAmbientTransaction()
-
-## Supported Storage Engines
-
-### Relational Databases
-[Complete] Microsoft SQL Server 2005 (or later)
-[Complete] MySQL 5.0 (or later)
-
-* [Complete] InnoDB
-* [Complete] NDB/MySQL Cluster
-* [Complete] Drizzle
-* [Complete] MariaDB
-* [Complete] XtraDB
-* [Complete] PBXT
-* [Complete] Xeround
-* [Complete] Galera
-* [Complete] Percona
-* [Complete] OurDelta
-* [Untested] MyISAM
-* [Untested] BerkleyDB
-
-[Complete] PostgreSQL 8.0 (or later)
-[Complete] Firebird 2.0 (or later)
-[In progress] Sybase (ASE)
-[In progress] Sybase (SQL Anywhere)
-[Planned] Oracle 8.0 (or later)
-[TBA] IBM DB2
-[TBA] Informix
-
-### Embedded Relational Databases
-[Complete] SQLite 3.0 (or later)
-[Complete] Microsoft SQL Server Compact Edition 3.5 (or later)
-[Complete] Microsoft Access 2000 (or later)
-
-### Cloud-based Databases (relational or otherwise)
-[Complete] Microsoft SQL Azure
-[Complete] Amazon RDS (MySQL)
-[Planned] Amazon RDS (Oracle)
-[In progress] Azure Tables/Blobs
-[In progress] Amazon SimpleDB/S3
-
-### Document Databases
-[Complete] RavenDB r322 (or later)
-[Complete] MongoDB 1.6 (or later)
-[Planned] CouchDB 1.0 (or later)
-[TBA] OrientDB
-
-### File System
-[Planned] .NET Managed System.IO APIs
-
-### Dynamo Clones
-[Planned] Cassandra
-[Planned] Riak
-[TBA] Voldemort
-[TBA] Dynomite
-
-### KV Stores / NoSQL
-[Planned] Redis
-[Planned] Memcached (Membase, Gear6, etc.)
-[Planned] HBase
-[TBA] HyperTable
-[TBA] Tokyo Cabinet
-[TBA] Microsoft Velocity
-[TBA] SharedCache
-[TBA] Hibari
-[TBA] Scalaris
-[TBA] Keyspace
-[TBA] OrientKV
-[TBA] VoltDB
-[TBA] BerkleyDB
-[TBA] Hazelcast
-[TBA] HampsterDB
-
-## Project Goals
-* Mono 2.4 support
-* Medium-trust support
-* Support more storage engines than any other event storage implementation
-* Easily support virtually any storage engine (NoSQL, etc.)
-* Avoid dependence upon TransactionScope or Transactions while maintaining full data integrity
-* Full test coverage of storage implementations
-* Easily hook into any bus implementation (NServiceBus, MassTransit, etc.)
-* Synchronous and asynchronous dispatching of events
-* Extreme performance
-* Multi-thread safe
-* Fluent builder
-
-## Building
-Simply run **build.cmd** from the command line. Once built, the files will be placed in the "publish-net40" subdirectory.
-
-## Using the EventStore
-
- var store = Wireup.Init()
- .UsingSqlPersistence("Name Of EventStore ConnectionString In Config File")
- .InitializeStorageEngine()
- .UsingJsonSerialization()
- .Compress()
- .EncryptWith(EncryptionKey)
- .HookIntoPipelineUsing(new[] { new AuthorizationPipelineHook() })
- .UsingAsynchronousDispatchScheduler()
- // Example of NServiceBus dispatcher: https://gist.github.com/1311195
- .DispatchTo(new My_NServiceBus_Or_MassTransit_OrEven_WCF_Adapter_Code())
- .Build();
-
- /* NOTE: This following is merely *example* code. */
-
- using (store)
- {
- // some business code here
- using (var stream = store.CreateStream(myMessage.CustomerId))
- {
- stream.Add(new EventMessage { Body = myMessage });
- stream.CommitChanges(myMessage.MessageId);
- }
-
- using (var stream = store.OpenStream(myMessage.CustomerId, 0, int.MaxValue))
- {
- foreach (var @event in stream.CommittedEvents)
- {
- // business processing...
- }
- }
- }
-
-For a more complete example, please see [EventStore.Example](https://github.com/joliver/EventStore/blob/master/doc/EventStore.Example/MainProgram.cs) project in the doc subdirectory.
-
-## Running the Example
-The EventStore.Example project is configured by default to use a SQL event store. To run the example
-program, either change the SQL connection string in the app.config file to connect to a existing SQL database
-or change WireupEventStore() to call UsingInMemoryPersistence() rather than UsingSqlPersistence().
diff --git a/src/.editorconfig b/src/.editorconfig
new file mode 100644
index 000000000..3c456a6e5
--- /dev/null
+++ b/src/.editorconfig
@@ -0,0 +1,30 @@
+[*]
+end_of_line = crlf
+indent_style = space
+indent_size = 4
+
+[*.xml]
+indent_style = space
+
+[*.cs]
+csharp_new_line_before_open_brace = all
+
+# RCS1229: Use async/await when necessary.
+dotnet_diagnostic.RCS1229.severity = error
+
+# IDE0290: Use primary constructor
+csharp_style_prefer_primary_constructors = false
+
+# IDE0028: Simplify collection initialization
+dotnet_style_collection_initializer = false
+
+# IDE0305: Simplify collection initialization
+dotnet_diagnostic.IDE0305.severity = none
+
+# Logging Warnings: temporary disabled, enable them again later on
+
+# CA1848: Use the LoggerMessage delegates
+dotnet_diagnostic.CA1848.severity = none
+
+# CA2254: Template should be a static expression
+dotnet_diagnostic.CA2254.severity = none
\ No newline at end of file
diff --git a/src/.nuget/EventStore.Logging.Log4Net.nuspec b/src/.nuget/EventStore.Logging.Log4Net.nuspec
deleted file mode 100644
index bcec9f52e..000000000
--- a/src/.nuget/EventStore.Logging.Log4Net.nuspec
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
- EventStore.Logging.Log4Net
- 3.1
- EventStore Log4Net Logging Plugin
- Jonathan Oliver
- Jonathan Oliver
- https://github.com/joliver/EventStore
- false
- Additional logging provider for EventStore using Log4Net.
- Log4Net logging provider for EventStore.
- es-US
- events, event sourcing, cqrs, storage, persistence, database, logging, log4net
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/.nuget/EventStore.Logging.NLog.nuspec b/src/.nuget/EventStore.Logging.NLog.nuspec
deleted file mode 100644
index e69d8c227..000000000
--- a/src/.nuget/EventStore.Logging.NLog.nuspec
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
- EventStore.Logging.NLog
- 3.1
- EventStore NLog Logging Plugin
- Jonathan Oliver
- Jonathan Oliver
- https://github.com/joliver/EventStore
- false
- Additional logging provider for EventStore using NLog.
- NLog logging provider for EventStore.
- es-US
- events, event sourcing, cqrs, storage, persistence, database, logging, nlog
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/.nuget/EventStore.Persistence.MongoPersistence.nuspec b/src/.nuget/EventStore.Persistence.MongoPersistence.nuspec
deleted file mode 100644
index 2da112825..000000000
--- a/src/.nuget/EventStore.Persistence.MongoPersistence.nuspec
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
- EventStore.Persistence.MongoPersistence
- 3.1
- EventStore MongoDB Persistence Plugin
- Simon Green, Jonathan Oliver
- Jonathan Oliver
- https://github.com/joliver/EventStore
- false
- Additional persistence provider for EventStore using MongoDB.
- MongoDB persistence provider for EventStore.
- es-US
- events, event sourcing, cqrs, storage, persistence, database, mongodb
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/.nuget/EventStore.Persistence.RavenPersistence.nuspec b/src/.nuget/EventStore.Persistence.RavenPersistence.nuspec
deleted file mode 100644
index d723e802a..000000000
--- a/src/.nuget/EventStore.Persistence.RavenPersistence.nuspec
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
- EventStore.Persistence.RavenPersistence
- 3.1
- EventStore RavenDB Persistence Plugin
- Simon Green, Jonathan Oliver
- Jonathan Oliver
- https://github.com/joliver/EventStore
- false
- Additional persistence provider for EventStore using RavenDB.
- RavenDB persistence provider for EventStore.
- es-US
- events, event sourcing, cqrs, storage, persistence, database, ravendb
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/.nuget/EventStore.Serialization.Json.nuspec b/src/.nuget/EventStore.Serialization.Json.nuspec
deleted file mode 100644
index babf77536..000000000
--- a/src/.nuget/EventStore.Serialization.Json.nuspec
+++ /dev/null
@@ -1,23 +0,0 @@
-
-
-
- EventStore.Serialization.Json
- 3.1
- EventStore Newtonsoft JSON Serialization Plugin
- Simon Green, Jonathan Oliver
- Jonathan Oliver
- https://github.com/joliver/EventStore
- false
- Additional serialization provider for EventStore based on the Newtonsoft JSON.NET library.
- Newtonsoft JSON.NET Serializer for EventStore.
- es-US
- events, event sourcing, cqrs, storage, persistence, database, newtonsoft, json, serialization
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/.nuget/EventStore.Serialization.ServiceStack.nuspec b/src/.nuget/EventStore.Serialization.ServiceStack.nuspec
deleted file mode 100644
index c70c7d2b1..000000000
--- a/src/.nuget/EventStore.Serialization.ServiceStack.nuspec
+++ /dev/null
@@ -1,23 +0,0 @@
-
-
-
- EventStore.Serialization.ServiceStack
- 3.1
- EventStore ServiceStack JSON Serialization Plugin
- Simon Green, Jonathan Oliver
- Jonathan Oliver
- https://github.com/joliver/EventStore
- false
- Additional serialization provider for EventStore based on ServiceStack JSON library.
- ServiceStack JSON Serializer for EventStore.
- es-US
- events, event sourcing, cqrs, storage, persistence, database, servicestack, json, serialization
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/.nuget/EventStore.nuspec b/src/.nuget/EventStore.nuspec
deleted file mode 100644
index 22da0878e..000000000
--- a/src/.nuget/EventStore.nuspec
+++ /dev/null
@@ -1,19 +0,0 @@
-
-
-
- EventStore
- 3.1
- EventStore
- Simon Green, Jonathan Oliver
- Jonathan Oliver
- https://github.com/joliver/EventStore
- false
- The purpose of the EventStore is to represent a series of events as a stream. Furthermore, it provides hooks whereby any events committed to the stream can be dispatched to interested parties.
- The EventStore is a persistence library used to abstract different storage implementations when using event sourcing as storage mechanism. The primary use is most often associated with CQRS.
- es-US
- events, event sourcing, cqrs, storage, persistence, database
-
-
-
-
-
\ No newline at end of file
diff --git a/src/.nuget/NuGet.Config b/src/.nuget/NuGet.Config
deleted file mode 100644
index 6a318ad9b..000000000
--- a/src/.nuget/NuGet.Config
+++ /dev/null
@@ -1,6 +0,0 @@
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/.nuget/NuGet.exe b/src/.nuget/NuGet.exe
deleted file mode 100644
index f4fe4abdf..000000000
Binary files a/src/.nuget/NuGet.exe and /dev/null differ
diff --git a/src/.nuget/NuGet.targets b/src/.nuget/NuGet.targets
deleted file mode 100644
index 67c1fb1e3..000000000
--- a/src/.nuget/NuGet.targets
+++ /dev/null
@@ -1,143 +0,0 @@
-
-
-
- $(MSBuildProjectDirectory)\..\
-
-
- false
-
-
- false
-
-
- true
-
-
- false
-
-
-
-
-
-
-
-
-
-
- $([System.IO.Path]::Combine($(SolutionDir), ".nuget"))
- $([System.IO.Path]::Combine($(ProjectDir), "packages.config"))
- $([System.IO.Path]::Combine($(SolutionDir), "packages"))
-
-
-
-
- $(SolutionDir).nuget
- packages.config
- $(SolutionDir)packages
-
-
-
-
- $(NuGetToolsPath)\nuget.exe
- @(PackageSource)
-
- "$(NuGetExePath)"
- mono --runtime=v4.0.30319 $(NuGetExePath)
-
- $(TargetDir.Trim('\\'))
-
- -RequireConsent
-
- $(NuGetCommand) install "$(PackagesConfig)" -source "$(PackageSources)" $(RequireConsentSwitch) -o "$(PackagesDir)"
- $(NuGetCommand) pack "$(ProjectPath)" -p Configuration=$(Configuration) -o "$(PackageOutputDir)" -symbols
-
-
-
- RestorePackages;
- $(BuildDependsOn);
-
-
-
-
- $(BuildDependsOn);
- BuildPackage;
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/AssemblyInfo.cs b/src/AssemblyInfo.cs
new file mode 100644
index 000000000..a2d615453
--- /dev/null
+++ b/src/AssemblyInfo.cs
@@ -0,0 +1,6 @@
+using System.Reflection;
+using System.Runtime.CompilerServices;
+
+[assembly: AssemblyVersion("0.0.0.0")]
+[assembly: AssemblyFileVersion("0.0.0.0")]
+[assembly: AssemblyInformationalVersion("0.0.0.0")]
diff --git a/src/proj/CustomDictionary.xml b/src/CustomDictionary.xml
similarity index 92%
rename from src/proj/CustomDictionary.xml
rename to src/CustomDictionary.xml
index 1a27f5179..a13c808b0 100644
--- a/src/proj/CustomDictionary.xml
+++ b/src/CustomDictionary.xml
@@ -1,34 +1,33 @@
-
-
-
-
- wireup
- undispatched
- bson
- untyped
- param
- shard
- sharding
- sqlite
- postgre
- rds
- nano
- smallint
- tinyint
- datetime
- dbo
- uniqueidentifier
- varbinary
- xtype
- bigint
- bytea
- uuid
- precommit
- changeset
- nonpositive
- sysobjects
- gzip
- precommit
-
-
+
+
+
+
+ wireup
+ bson
+ untyped
+ param
+ shard
+ sharding
+ sqlite
+ postgre
+ rds
+ nano
+ smallint
+ tinyint
+ datetime
+ dbo
+ uniqueidentifier
+ varbinary
+ xtype
+ bigint
+ bytea
+ uuid
+ precommit
+ changeset
+ nonpositive
+ sysobjects
+ gzip
+ precommit
+
+
\ No newline at end of file
diff --git a/src/Directory.Build.props b/src/Directory.Build.props
new file mode 100644
index 000000000..dff21ee33
--- /dev/null
+++ b/src/Directory.Build.props
@@ -0,0 +1,7 @@
+
+
+ 13.0
+ enable
+ enable
+
+
\ No newline at end of file
diff --git a/src/EventStore.sln b/src/EventStore.sln
deleted file mode 100644
index 601596ef0..000000000
--- a/src/EventStore.sln
+++ /dev/null
@@ -1,179 +0,0 @@
-
-Microsoft Visual Studio Solution File, Format Version 11.00
-# Visual Studio 2010
-Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "proj", "proj", "{9DE51CC0-6902-49F5-9B69-B29454DE7164}"
-EndProject
-Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tests", "tests", "{D3C17830-A461-4BA5-A672-461B19B33936}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore", "proj\EventStore\EventStore.csproj", "{03946843-F343-419C-88EF-3E446D08DFA6}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Core", "proj\EventStore.Core\EventStore.Core.csproj", "{D6413244-42F5-4233-B347-D0A804B09CC9}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Core.UnitTests", "tests\EventStore.Core.UnitTests\EventStore.Core.UnitTests.csproj", "{3B5F8277-F29E-4114-AE81-4A4FBF2D7FA5}"
-EndProject
-Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "doc", "doc", "{CD37080A-F48D-4E5D-B7C6-B9F86BB05A38}"
- ProjectSection(SolutionItems) = preProject
- ..\doc\acknowledgments.txt = ..\doc\acknowledgments.txt
- ..\doc\EventStore - Architectural Overview.docx = ..\doc\EventStore - Architectural Overview.docx
- ..\doc\EventStore - Transactional Integrity.docx = ..\doc\EventStore - Transactional Integrity.docx
- ..\doc\license.txt = ..\doc\license.txt
- ..\readme.markdown = ..\readme.markdown
- ..\doc\roadmap.txt = ..\doc\roadmap.txt
- EndProjectSection
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Serialization", "proj\EventStore.Serialization\EventStore.Serialization.csproj", "{A5BF4B86-26F6-418D-BE35-C6CC3A623D27}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Serialization.Json", "proj\EventStore.Serialization.Json\EventStore.Serialization.Json.csproj", "{CFD895BD-7CB2-4811-A6FA-1851DF769B67}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Serialization.AcceptanceTests", "tests\EventStore.Serialization.AcceptanceTests\EventStore.Serialization.AcceptanceTests.csproj", "{FCCBA30F-738D-4C82-BAE4-906B88399AA2}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Persistence.SqlPersistence", "proj\EventStore.Persistence.SqlPersistence\EventStore.Persistence.SqlPersistence.csproj", "{DAFD3F38-33F3-4F53-BFEA-44E51BD1E8F1}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Persistence.AcceptanceTests", "tests\EventStore.Persistence.AcceptanceTests\EventStore.Persistence.AcceptanceTests.csproj", "{B56FDCEA-086F-40A2-92E1-867CE506CBE3}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Persistence.MongoPersistence", "proj\EventStore.Persistence.MongoPersistence\EventStore.Persistence.MongoPersistence.csproj", "{32ADD8CE-0F3F-41D8-BFA1-6E5D685E64DD}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Example", "..\doc\EventStore.Example\EventStore.Example.csproj", "{0143B48E-25AF-4CE0-BD49-A52267D359D3}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Persistence.RavenPersistence", "proj\EventStore.Persistence.RavenPersistence\EventStore.Persistence.RavenPersistence.csproj", "{F9E7FD69-0818-48CA-9249-5387739E1B6A}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Wireup", "proj\EventStore.Wireup\EventStore.Wireup.csproj", "{421664DB-C18D-4499-ABC1-C9086D525F80}"
-EndProject
-Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "wireup", "wireup", "{52F7988F-452D-46C2-A144-D85E0CF371C6}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Serialization.Json.Wireup", "proj\EventStore.Serialization.Json.Wireup\EventStore.Serialization.Json.Wireup.csproj", "{DEFFE0C3-2988-4C58-9E36-1302842FFDBD}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Persistence.MongoPersistence.Wireup", "proj\EventStore.Persistence.MongoPersistence.Wireup\EventStore.Persistence.MongoPersistence.Wireup.csproj", "{E95780CB-3114-4925-A38A-1FA4CC4EC213}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Persistence.RavenPersistence.Wireup", "proj\EventStore.Persistence.RavenPersistence.Wireup\EventStore.Persistence.RavenPersistence.Wireup.csproj", "{A99B2B16-B6BE-4B83-ACE0-56A734DB9AEF}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Serialization.ServiceStack", "proj\EventStore.Serialization.ServiceStack\EventStore.Serialization.ServiceStack.csproj", "{2BA8B905-65D5-4BBA-A76B-58EC49F26018}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Serialization.ServiceStack.Wireup", "proj\EventStore.Serialization.ServiceStack.Wireup\EventStore.Serialization.ServiceStack.Wireup.csproj", "{33B78974-7867-4C10-90AD-F31352BF0EEC}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Logging.NLog", "proj\EventStore.Logging.NLog\EventStore.Logging.NLog.csproj", "{4A336666-825A-49BA-B6F7-2156E3877A34}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EventStore.Logging.Log4Net", "proj\EventStore.Logging.Log4Net\EventStore.Logging.Log4Net.csproj", "{EBCACF9E-7FE2-4C39-917E-2DD60EEE8C80}"
-EndProject
-Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".nuget", ".nuget", "{08A28C69-B04C-4622-8BF7-C9C4C410E64C}"
- ProjectSection(SolutionItems) = preProject
- .nuget\EventStore.Logging.Log4Net.nuspec = .nuget\EventStore.Logging.Log4Net.nuspec
- .nuget\EventStore.Logging.NLog.nuspec = .nuget\EventStore.Logging.NLog.nuspec
- .nuget\EventStore.nuspec = .nuget\EventStore.nuspec
- .nuget\EventStore.Persistence.MongoPersistence.nuspec = .nuget\EventStore.Persistence.MongoPersistence.nuspec
- .nuget\EventStore.Persistence.RavenPersistence.nuspec = .nuget\EventStore.Persistence.RavenPersistence.nuspec
- .nuget\EventStore.Serialization.Json.nuspec = .nuget\EventStore.Serialization.Json.nuspec
- .nuget\EventStore.Serialization.ServiceStack.nuspec = .nuget\EventStore.Serialization.ServiceStack.nuspec
- .nuget\NuGet.Config = .nuget\NuGet.Config
- .nuget\NuGet.exe = .nuget\NuGet.exe
- .nuget\NuGet.targets = .nuget\NuGet.targets
- EndProjectSection
-EndProject
-Global
- GlobalSection(SolutionConfigurationPlatforms) = preSolution
- Debug|Any CPU = Debug|Any CPU
- Release|Any CPU = Release|Any CPU
- EndGlobalSection
- GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {03946843-F343-419C-88EF-3E446D08DFA6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {03946843-F343-419C-88EF-3E446D08DFA6}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {03946843-F343-419C-88EF-3E446D08DFA6}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {03946843-F343-419C-88EF-3E446D08DFA6}.Release|Any CPU.Build.0 = Release|Any CPU
- {D6413244-42F5-4233-B347-D0A804B09CC9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {D6413244-42F5-4233-B347-D0A804B09CC9}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {D6413244-42F5-4233-B347-D0A804B09CC9}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {D6413244-42F5-4233-B347-D0A804B09CC9}.Release|Any CPU.Build.0 = Release|Any CPU
- {3B5F8277-F29E-4114-AE81-4A4FBF2D7FA5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {3B5F8277-F29E-4114-AE81-4A4FBF2D7FA5}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {3B5F8277-F29E-4114-AE81-4A4FBF2D7FA5}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {3B5F8277-F29E-4114-AE81-4A4FBF2D7FA5}.Release|Any CPU.Build.0 = Release|Any CPU
- {A5BF4B86-26F6-418D-BE35-C6CC3A623D27}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {A5BF4B86-26F6-418D-BE35-C6CC3A623D27}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {A5BF4B86-26F6-418D-BE35-C6CC3A623D27}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {A5BF4B86-26F6-418D-BE35-C6CC3A623D27}.Release|Any CPU.Build.0 = Release|Any CPU
- {CFD895BD-7CB2-4811-A6FA-1851DF769B67}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {CFD895BD-7CB2-4811-A6FA-1851DF769B67}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {CFD895BD-7CB2-4811-A6FA-1851DF769B67}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {CFD895BD-7CB2-4811-A6FA-1851DF769B67}.Release|Any CPU.Build.0 = Release|Any CPU
- {FCCBA30F-738D-4C82-BAE4-906B88399AA2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {FCCBA30F-738D-4C82-BAE4-906B88399AA2}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {FCCBA30F-738D-4C82-BAE4-906B88399AA2}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {FCCBA30F-738D-4C82-BAE4-906B88399AA2}.Release|Any CPU.Build.0 = Release|Any CPU
- {DAFD3F38-33F3-4F53-BFEA-44E51BD1E8F1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {DAFD3F38-33F3-4F53-BFEA-44E51BD1E8F1}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {DAFD3F38-33F3-4F53-BFEA-44E51BD1E8F1}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {DAFD3F38-33F3-4F53-BFEA-44E51BD1E8F1}.Release|Any CPU.Build.0 = Release|Any CPU
- {B56FDCEA-086F-40A2-92E1-867CE506CBE3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {B56FDCEA-086F-40A2-92E1-867CE506CBE3}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {B56FDCEA-086F-40A2-92E1-867CE506CBE3}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {B56FDCEA-086F-40A2-92E1-867CE506CBE3}.Release|Any CPU.Build.0 = Release|Any CPU
- {32ADD8CE-0F3F-41D8-BFA1-6E5D685E64DD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {32ADD8CE-0F3F-41D8-BFA1-6E5D685E64DD}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {32ADD8CE-0F3F-41D8-BFA1-6E5D685E64DD}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {32ADD8CE-0F3F-41D8-BFA1-6E5D685E64DD}.Release|Any CPU.Build.0 = Release|Any CPU
- {0143B48E-25AF-4CE0-BD49-A52267D359D3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {0143B48E-25AF-4CE0-BD49-A52267D359D3}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {0143B48E-25AF-4CE0-BD49-A52267D359D3}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {0143B48E-25AF-4CE0-BD49-A52267D359D3}.Release|Any CPU.Build.0 = Release|Any CPU
- {F9E7FD69-0818-48CA-9249-5387739E1B6A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {F9E7FD69-0818-48CA-9249-5387739E1B6A}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {F9E7FD69-0818-48CA-9249-5387739E1B6A}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {F9E7FD69-0818-48CA-9249-5387739E1B6A}.Release|Any CPU.Build.0 = Release|Any CPU
- {421664DB-C18D-4499-ABC1-C9086D525F80}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {421664DB-C18D-4499-ABC1-C9086D525F80}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {421664DB-C18D-4499-ABC1-C9086D525F80}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {421664DB-C18D-4499-ABC1-C9086D525F80}.Release|Any CPU.Build.0 = Release|Any CPU
- {DEFFE0C3-2988-4C58-9E36-1302842FFDBD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {DEFFE0C3-2988-4C58-9E36-1302842FFDBD}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {DEFFE0C3-2988-4C58-9E36-1302842FFDBD}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {DEFFE0C3-2988-4C58-9E36-1302842FFDBD}.Release|Any CPU.Build.0 = Release|Any CPU
- {E95780CB-3114-4925-A38A-1FA4CC4EC213}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {E95780CB-3114-4925-A38A-1FA4CC4EC213}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {E95780CB-3114-4925-A38A-1FA4CC4EC213}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {E95780CB-3114-4925-A38A-1FA4CC4EC213}.Release|Any CPU.Build.0 = Release|Any CPU
- {A99B2B16-B6BE-4B83-ACE0-56A734DB9AEF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {A99B2B16-B6BE-4B83-ACE0-56A734DB9AEF}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {A99B2B16-B6BE-4B83-ACE0-56A734DB9AEF}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {A99B2B16-B6BE-4B83-ACE0-56A734DB9AEF}.Release|Any CPU.Build.0 = Release|Any CPU
- {2BA8B905-65D5-4BBA-A76B-58EC49F26018}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {2BA8B905-65D5-4BBA-A76B-58EC49F26018}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {2BA8B905-65D5-4BBA-A76B-58EC49F26018}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {2BA8B905-65D5-4BBA-A76B-58EC49F26018}.Release|Any CPU.Build.0 = Release|Any CPU
- {33B78974-7867-4C10-90AD-F31352BF0EEC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {33B78974-7867-4C10-90AD-F31352BF0EEC}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {33B78974-7867-4C10-90AD-F31352BF0EEC}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {33B78974-7867-4C10-90AD-F31352BF0EEC}.Release|Any CPU.Build.0 = Release|Any CPU
- {4A336666-825A-49BA-B6F7-2156E3877A34}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {4A336666-825A-49BA-B6F7-2156E3877A34}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {4A336666-825A-49BA-B6F7-2156E3877A34}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {4A336666-825A-49BA-B6F7-2156E3877A34}.Release|Any CPU.Build.0 = Release|Any CPU
- {EBCACF9E-7FE2-4C39-917E-2DD60EEE8C80}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {EBCACF9E-7FE2-4C39-917E-2DD60EEE8C80}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {EBCACF9E-7FE2-4C39-917E-2DD60EEE8C80}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {EBCACF9E-7FE2-4C39-917E-2DD60EEE8C80}.Release|Any CPU.Build.0 = Release|Any CPU
- EndGlobalSection
- GlobalSection(SolutionProperties) = preSolution
- HideSolutionNode = FALSE
- EndGlobalSection
- GlobalSection(NestedProjects) = preSolution
- {03946843-F343-419C-88EF-3E446D08DFA6} = {9DE51CC0-6902-49F5-9B69-B29454DE7164}
- {D6413244-42F5-4233-B347-D0A804B09CC9} = {9DE51CC0-6902-49F5-9B69-B29454DE7164}
- {A5BF4B86-26F6-418D-BE35-C6CC3A623D27} = {9DE51CC0-6902-49F5-9B69-B29454DE7164}
- {CFD895BD-7CB2-4811-A6FA-1851DF769B67} = {9DE51CC0-6902-49F5-9B69-B29454DE7164}
- {DAFD3F38-33F3-4F53-BFEA-44E51BD1E8F1} = {9DE51CC0-6902-49F5-9B69-B29454DE7164}
- {32ADD8CE-0F3F-41D8-BFA1-6E5D685E64DD} = {9DE51CC0-6902-49F5-9B69-B29454DE7164}
- {F9E7FD69-0818-48CA-9249-5387739E1B6A} = {9DE51CC0-6902-49F5-9B69-B29454DE7164}
- {2BA8B905-65D5-4BBA-A76B-58EC49F26018} = {9DE51CC0-6902-49F5-9B69-B29454DE7164}
- {4A336666-825A-49BA-B6F7-2156E3877A34} = {9DE51CC0-6902-49F5-9B69-B29454DE7164}
- {EBCACF9E-7FE2-4C39-917E-2DD60EEE8C80} = {9DE51CC0-6902-49F5-9B69-B29454DE7164}
- {3B5F8277-F29E-4114-AE81-4A4FBF2D7FA5} = {D3C17830-A461-4BA5-A672-461B19B33936}
- {FCCBA30F-738D-4C82-BAE4-906B88399AA2} = {D3C17830-A461-4BA5-A672-461B19B33936}
- {B56FDCEA-086F-40A2-92E1-867CE506CBE3} = {D3C17830-A461-4BA5-A672-461B19B33936}
- {0143B48E-25AF-4CE0-BD49-A52267D359D3} = {CD37080A-F48D-4E5D-B7C6-B9F86BB05A38}
- {421664DB-C18D-4499-ABC1-C9086D525F80} = {52F7988F-452D-46C2-A144-D85E0CF371C6}
- {DEFFE0C3-2988-4C58-9E36-1302842FFDBD} = {52F7988F-452D-46C2-A144-D85E0CF371C6}
- {E95780CB-3114-4925-A38A-1FA4CC4EC213} = {52F7988F-452D-46C2-A144-D85E0CF371C6}
- {A99B2B16-B6BE-4B83-ACE0-56A734DB9AEF} = {52F7988F-452D-46C2-A144-D85E0CF371C6}
- {33B78974-7867-4C10-90AD-F31352BF0EEC} = {52F7988F-452D-46C2-A144-D85E0CF371C6}
- EndGlobalSection
-EndGlobal
diff --git a/src/EventStore.snk b/src/EventStore.snk
deleted file mode 100644
index 0d386c107..000000000
Binary files a/src/EventStore.snk and /dev/null differ
diff --git a/src/proj/GlobalAssemblyInfo.cs b/src/GlobalAssemblyInfo.cs
similarity index 55%
rename from src/proj/GlobalAssemblyInfo.cs
rename to src/GlobalAssemblyInfo.cs
index 2c354eeec..2b7d4963a 100644
--- a/src/proj/GlobalAssemblyInfo.cs
+++ b/src/GlobalAssemblyInfo.cs
@@ -3,17 +3,21 @@
// Copyright (c) Jonathan Oliver. All rights reserved.
//
//-----------------------------------------------------------------------
+
using System;
using System.Reflection;
using System.Resources;
+using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
-[assembly: AssemblyCompany("Jonathan Oliver")]
-[assembly: AssemblyProduct("EventStore")]
-[assembly: AssemblyCopyright("Copyright © Jonathan Oliver 2011")]
+[assembly: AssemblyCompany("NEventStore")]
+[assembly: AssemblyProduct("NEventStore")]
+[assembly: AssemblyCopyright("Copyright © Jonathan Oliver, Jonathan Mathius, Damian Hickey and Contributors 2011")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCulture("")]
[assembly: ComVisible(false)]
[assembly: CLSCompliant(false)]
-[assembly: NeutralResourcesLanguage("en-US")]
\ No newline at end of file
+[assembly: NeutralResourcesLanguage("en-US")]
+[assembly: InternalsVisibleTo("NEventStore.Tests")]
+[assembly: InternalsVisibleTo("NEventStore.Core.Tests")]
diff --git a/src/proj/GlobalSuppressions.cs b/src/GlobalSuppressions.cs
similarity index 94%
rename from src/proj/GlobalSuppressions.cs
rename to src/GlobalSuppressions.cs
index d408fd263..fe8e858ee 100644
--- a/src/proj/GlobalSuppressions.cs
+++ b/src/GlobalSuppressions.cs
@@ -1,5 +1,5 @@
-//-----------------------------------------------------------------------
-//
-// Copyright (c) Jonathan Oliver. All rights reserved.
-//
-//-----------------------------------------------------------------------
+//-----------------------------------------------------------------------
+//
+// Copyright (c) Jonathan Oliver. All rights reserved.
+//
+//-----------------------------------------------------------------------
\ No newline at end of file
diff --git a/src/NEventStore.Benchmark/Benchmarks/PersistenceBenchmarks.cs b/src/NEventStore.Benchmark/Benchmarks/PersistenceBenchmarks.cs
new file mode 100644
index 000000000..d57749da9
--- /dev/null
+++ b/src/NEventStore.Benchmark/Benchmarks/PersistenceBenchmarks.cs
@@ -0,0 +1,124 @@
+using BenchmarkDotNet.Attributes;
+using NEventStore.Benchmark.Support;
+
+namespace NEventStore.Benchmark.Benchmarks
+{
+ [Config(typeof(AllowNonOptimized))]
+ [SimpleJob(launchCount: 3, warmupCount: 3, iterationCount: 3, invocationCount: 1)]
+ [MemoryDiagnoser]
+ [MeanColumn, StdErrorColumn, StdDevColumn, MinColumn, MaxColumn, IterationsColumn]
+ public class PersistenceBenchmarks
+ {
+ private static readonly Guid StreamId = Guid.NewGuid(); // aggregate identifier
+ private readonly IStoreEvents _eventStore;
+
+ public PersistenceBenchmarks()
+ {
+ _eventStore = EventStoreHelpers.WireupEventStore();
+ }
+
+ [Params(100, 1000, 10000, 100000)]
+ public int CommitsToWrite { get; set; }
+
+ [Benchmark]
+ public void WriteToStream()
+ {
+ // we can call CreateStream(StreamId) if we know there isn't going to be any data.
+ // or we can call OpenStream(StreamId, 0, int.MaxValue) to read all commits,
+ // if no commits exist then it creates a new stream for us.
+ using var stream = _eventStore.OpenStream(StreamId, 0, int.MaxValue);
+ for (int i = 0; i < CommitsToWrite; i++)
+ {
+ var @event = new SomeDomainEvent { Value = i.ToString() };
+ stream.Add(new EventMessage { Body = @event });
+ stream.CommitChanges(Guid.NewGuid());
+ }
+ }
+
+ [Benchmark]
+ public async Task WriteToStreamAsync()
+ {
+ // we can call CreateStream(StreamId) if we know there isn't going to be any data.
+ // or we can call OpenStream(StreamId, 0, int.MaxValue) to read all commits,
+ // if no commits exist then it creates a new stream for us.
+ using var stream = await _eventStore.OpenStreamAsync(StreamId, 0, int.MaxValue, CancellationToken.None).ConfigureAwait(false);
+ for (int i = 0; i < CommitsToWrite; i++)
+ {
+ var @event = new SomeDomainEvent { Value = i.ToString() };
+ stream.Add(new EventMessage { Body = @event });
+ await stream.CommitChangesAsync(Guid.NewGuid(), CancellationToken.None).ConfigureAwait(false);
+ }
+ }
+
+ [GlobalSetup(Targets = new string[] { nameof(ReadFromStream), nameof(ReadFromEventStore) })]
+ public void ReadSetup()
+ {
+ using var stream = _eventStore.OpenStream(StreamId, 0, int.MaxValue);
+ for (int i = 0; i < CommitsToWrite; i++)
+ {
+ var @event = new SomeDomainEvent { Value = i.ToString() };
+ stream.Add(new EventMessage { Body = @event });
+ stream.CommitChanges(Guid.NewGuid());
+ }
+ }
+
+ [Benchmark]
+ public void ReadFromStream()
+ {
+ // we can call CreateStream(StreamId) if we know there isn't going to be any data.
+ // or we can call OpenStream(StreamId, 0, int.MaxValue) to read all commits,
+ // if no commits exist then it creates a new stream for us.
+ using var stream = _eventStore.OpenStream(StreamId, 0, int.MaxValue);
+ // the whole stream has been read
+ // Console.WriteLine(stream.CommittedEvents.First().Body);
+ }
+
+ [Benchmark]
+ public void ReadFromEventStore()
+ {
+ var commits = _eventStore.Advanced.GetFrom(Bucket.Default, 0);
+ foreach (var _ in commits)
+ {
+ // just iterate through all the commits
+ // Console.WriteLine(c);
+ }
+ }
+
+ [GlobalSetup(Targets = new string[] { nameof(ReadFromStreamAsync), nameof(ReadFromEventStoreAsync) })]
+ public async Task ReadSetupAsync()
+ {
+ using var stream = await _eventStore.OpenStreamAsync(StreamId, 0, int.MaxValue, CancellationToken.None).ConfigureAwait(false);
+ for (int i = 0; i < CommitsToWrite; i++)
+ {
+ var @event = new SomeDomainEvent { Value = i.ToString() };
+ stream.Add(new EventMessage { Body = @event });
+ await stream.CommitChangesAsync(Guid.NewGuid(), CancellationToken.None).ConfigureAwait(false);
+ }
+ }
+
+ [Benchmark]
+ public async Task ReadFromStreamAsync()
+ {
+ // we can call CreateStream(StreamId) if we know there isn't going to be any data.
+ // or we can call OpenStream(StreamId, 0, int.MaxValue) to read all commits,
+ // if no commits exist then it creates a new stream for us.
+ using var stream = await _eventStore.OpenStreamAsync(StreamId, 0, int.MaxValue, CancellationToken.None).ConfigureAwait(false);
+ // the whole stream has been read
+ // Console.WriteLine(stream.CommittedEvents.First().Body);
+ }
+
+ [Benchmark]
+ public Task ReadFromEventStoreAsync()
+ {
+ // just iterate through all the commits
+#pragma warning disable RCS1163 // Unused parameter
+ return _eventStore.Advanced.GetFromAsync(Bucket.Default, 0, new LambdaAsyncObserver(
+ (c, _) =>
+ {
+ // Console.WriteLine(c.Events.First().Body);
+ return Task.FromResult(true);
+ }), CancellationToken.None);
+#pragma warning restore RCS1163 // Unused parameter
+ }
+ }
+}
diff --git a/src/NEventStore.Benchmark/NEventStore.Benchmark.csproj b/src/NEventStore.Benchmark/NEventStore.Benchmark.csproj
new file mode 100644
index 000000000..35fb58158
--- /dev/null
+++ b/src/NEventStore.Benchmark/NEventStore.Benchmark.csproj
@@ -0,0 +1,24 @@
+
+
+
+ net8.0;net472
+ false
+
+ exe
+
+ Exe
+
+
+
+ TRACE;DEBUG
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/NEventStore.Benchmark/Program.cs b/src/NEventStore.Benchmark/Program.cs
new file mode 100644
index 000000000..941e55bae
--- /dev/null
+++ b/src/NEventStore.Benchmark/Program.cs
@@ -0,0 +1,13 @@
+using BenchmarkDotNet.Running;
+using NEventStore.Benchmark.Benchmarks;
+
+namespace NEventStore.Benchmark
+{
+ public static class Program
+ {
+ public static void Main(string[] _)
+ {
+ BenchmarkRunner.Run();
+ }
+ }
+}
diff --git a/src/NEventStore.Benchmark/Support/AllowNonOptimized.cs b/src/NEventStore.Benchmark/Support/AllowNonOptimized.cs
new file mode 100644
index 000000000..91a0caeb5
--- /dev/null
+++ b/src/NEventStore.Benchmark/Support/AllowNonOptimized.cs
@@ -0,0 +1,18 @@
+using BenchmarkDotNet.Configs;
+using BenchmarkDotNet.Validators;
+using System.Linq;
+
+namespace NEventStore.Benchmark.Support
+{
+ public class AllowNonOptimized : ManualConfig
+ {
+ public AllowNonOptimized()
+ {
+ AddValidator(JitOptimizationsValidator.DontFailOnError); // ALLOW NON-OPTIMIZED DLLS
+
+ AddLogger(DefaultConfig.Instance.GetLoggers().ToArray()); // manual config has no loggers by default
+ AddExporter(DefaultConfig.Instance.GetExporters().ToArray()); // manual config has no exporters by default
+ AddColumnProvider(DefaultConfig.Instance.GetColumnProviders().ToArray()); // manual config has no columns by default
+ }
+ }
+}
diff --git a/src/NEventStore.Benchmark/Support/EventStoreHelpers.cs b/src/NEventStore.Benchmark/Support/EventStoreHelpers.cs
new file mode 100644
index 000000000..1bed8ce2d
--- /dev/null
+++ b/src/NEventStore.Benchmark/Support/EventStoreHelpers.cs
@@ -0,0 +1,19 @@
+namespace NEventStore.Benchmark.Support
+{
+ internal static class EventStoreHelpers
+ {
+ internal static IStoreEvents WireupEventStore()
+ {
+ return Wireup.Init()
+ // .LogToOutputWindow(LogLevel.Verbose)
+ // .LogToConsoleWindow(LogLevel.Verbose)
+ .UsingInMemoryPersistence()
+ .InitializeStorageEngine()
+#if NET462
+ .TrackPerformanceInstance("example")
+#endif
+ // .HookIntoPipelineUsing(new[] { new AuthorizationPipelineHook() })
+ .Build();
+ }
+ }
+}
diff --git a/src/NEventStore.Benchmark/Support/SomeDomainEvent.cs b/src/NEventStore.Benchmark/Support/SomeDomainEvent.cs
new file mode 100644
index 000000000..7b36d365b
--- /dev/null
+++ b/src/NEventStore.Benchmark/Support/SomeDomainEvent.cs
@@ -0,0 +1,7 @@
+namespace NEventStore.Benchmark.Support
+{
+ internal class SomeDomainEvent
+ {
+ public string? Value { get; set; }
+ }
+}
diff --git a/src/NEventStore.Core.sln b/src/NEventStore.Core.sln
new file mode 100644
index 000000000..746933f4b
--- /dev/null
+++ b/src/NEventStore.Core.sln
@@ -0,0 +1,303 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.12.35521.163
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".test", ".test", "{D3C17830-A461-4BA5-A672-461B19B33936}"
+ ProjectSection(SolutionItems) = preProject
+ NEventStore.Persistence.AcceptanceTests\PersistenceTests.Async.cs = NEventStore.Persistence.AcceptanceTests\PersistenceTests.Async.cs
+ NEventStore.Persistence.AcceptanceTests\PersistenceTests.cs = NEventStore.Persistence.AcceptanceTests\PersistenceTests.cs
+ NEventStore.Persistence.AcceptanceTests\PersistenceTests.Transactions.cs = NEventStore.Persistence.AcceptanceTests\PersistenceTests.Transactions.cs
+ NEventStore.Persistence.AcceptanceTests\SerializationTests.cs = NEventStore.Persistence.AcceptanceTests\SerializationTests.cs
+ EndProjectSection
+EndProject
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "serialization", "serialization", "{52F7988F-452D-46C2-A144-D85E0CF371C6}"
+EndProject
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "core", "core", "{D35087BF-941A-49EA-96A8-B10457C4D169}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.Core", "NEventStore\NEventStore.Core.csproj", "{EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.Persistence.AcceptanceTests.Core", "NEventStore.Persistence.AcceptanceTests\NEventStore.Persistence.AcceptanceTests.Core.csproj", "{608A1D85-0999-4A9B-956A-11B91A1CB065}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.Serialization.Json.Core", "NEventStore.Serialization.Json\NEventStore.Serialization.Json.Core.csproj", "{9A46374D-029C-4B87-88E3-0BE5D1D44C35}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.Serialization.Json.Core.Tests", "NEventStore.Serialization.Json.Tests\NEventStore.Serialization.Json.Core.Tests.csproj", "{D7029339-3794-4275-893A-E705D872BFBE}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.Serialization.Bson.Core.Tests", "NEventStore.Serialization.Bson.Tests\NEventStore.Serialization.Bson.Core.Tests.csproj", "{2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.Serialization.GZip.Core.Tests", "NEventStore.Serialization.Gzip.Tests\NEventStore.Serialization.GZip.Core.Tests.csproj", "{BCCDD838-8368-418D-82B5-5389FDDF0ADD}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.Core.Tests", "NEventStore.Tests\NEventStore.Core.Tests.csproj", "{8860810C-5E46-4E60-8924-C6C77BBC6EB2}"
+EndProject
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{407B4AC0-6C11-4123-9BBA-094B2CADCD3A}"
+ ProjectSection(SolutionItems) = preProject
+ .editorconfig = .editorconfig
+ ..\appveyor.yml = ..\appveyor.yml
+ ..\build.ps1 = ..\build.ps1
+ ..\Changelog.md = ..\Changelog.md
+ Directory.Build.props = Directory.Build.props
+ ..\license.txt = ..\license.txt
+ ..\Readme.md = ..\Readme.md
+ EndProjectSection
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.Serialization.Binary.Core.Tests", "NEventStore.Serialization.Binary.Tests\NEventStore.Serialization.Binary.Core.Tests.csproj", "{9F0BFA49-8711-4143-B813-ACD0D0B003FD}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.Serialization.Rijndael.Core.Tests", "NEventStore.Serialization.Rijndael.Tests\NEventStore.Serialization.Rijndael.Core.Tests.csproj", "{56B15268-DEBC-4E9F-8554-03737A39D71B}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.Benchmark", "NEventStore.Benchmark\NEventStore.Benchmark.csproj", "{2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.Example", "NEventStore.Example\NEventStore.Example.csproj", "{04174210-4A5D-4F26-883E-B52B7B167EAC}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.PollingClientExample", "NEventStore.PollingClientExample\NEventStore.PollingClientExample.csproj", "{310733D1-2BF4-44D7-9947-93E29FA44310}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.Serialization.Bson.Core", "NEventStore.Serialization.Bson\NEventStore.Serialization.Bson.Core.csproj", "{C45058FC-A657-4D13-AF2A-6E0B30C444A6}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NEventStore.PollingClient", "NEventStore.PollingClient\NEventStore.PollingClient.csproj", "{1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NEventStore.Serialization.MsgPack.Core", "NEventStore.Serialization.MsgPack\NEventStore.Serialization.MsgPack.Core.csproj", "{187E9876-28EC-43D7-B70E-2C09E66D59BD}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NEventStore.Serialization.MsgPack.Core.Tests", "NEventStore.Serialization.MsgPack.Tests\NEventStore.Serialization.MsgPack.Core.Tests.csproj", "{7FD67842-0549-4062-ACAB-3C417BD218C1}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NEventStore.Serialization.Binary.Core", "NEventStore.Serialization.Binary\NEventStore.Serialization.Binary.Core.csproj", "{26297E78-023D-4F3C-4F39-A7CC4FA9AF21}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Debug|x64 = Debug|x64
+ Debug|x86 = Debug|x86
+ Release|Any CPU = Release|Any CPU
+ Release|x64 = Release|x64
+ Release|x86 = Release|x86
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}.Debug|x64.Build.0 = Debug|Any CPU
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}.Debug|x86.Build.0 = Debug|Any CPU
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}.Release|Any CPU.Build.0 = Release|Any CPU
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}.Release|x64.ActiveCfg = Release|Any CPU
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}.Release|x64.Build.0 = Release|Any CPU
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}.Release|x86.ActiveCfg = Release|Any CPU
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C}.Release|x86.Build.0 = Release|Any CPU
+ {608A1D85-0999-4A9B-956A-11B91A1CB065}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {608A1D85-0999-4A9B-956A-11B91A1CB065}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {608A1D85-0999-4A9B-956A-11B91A1CB065}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {608A1D85-0999-4A9B-956A-11B91A1CB065}.Debug|x64.Build.0 = Debug|Any CPU
+ {608A1D85-0999-4A9B-956A-11B91A1CB065}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {608A1D85-0999-4A9B-956A-11B91A1CB065}.Debug|x86.Build.0 = Debug|Any CPU
+ {608A1D85-0999-4A9B-956A-11B91A1CB065}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {608A1D85-0999-4A9B-956A-11B91A1CB065}.Release|Any CPU.Build.0 = Release|Any CPU
+ {608A1D85-0999-4A9B-956A-11B91A1CB065}.Release|x64.ActiveCfg = Release|Any CPU
+ {608A1D85-0999-4A9B-956A-11B91A1CB065}.Release|x64.Build.0 = Release|Any CPU
+ {608A1D85-0999-4A9B-956A-11B91A1CB065}.Release|x86.ActiveCfg = Release|Any CPU
+ {608A1D85-0999-4A9B-956A-11B91A1CB065}.Release|x86.Build.0 = Release|Any CPU
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35}.Debug|x64.Build.0 = Debug|Any CPU
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35}.Debug|x86.Build.0 = Debug|Any CPU
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35}.Release|Any CPU.Build.0 = Release|Any CPU
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35}.Release|x64.ActiveCfg = Release|Any CPU
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35}.Release|x64.Build.0 = Release|Any CPU
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35}.Release|x86.ActiveCfg = Release|Any CPU
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35}.Release|x86.Build.0 = Release|Any CPU
+ {D7029339-3794-4275-893A-E705D872BFBE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {D7029339-3794-4275-893A-E705D872BFBE}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {D7029339-3794-4275-893A-E705D872BFBE}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {D7029339-3794-4275-893A-E705D872BFBE}.Debug|x64.Build.0 = Debug|Any CPU
+ {D7029339-3794-4275-893A-E705D872BFBE}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {D7029339-3794-4275-893A-E705D872BFBE}.Debug|x86.Build.0 = Debug|Any CPU
+ {D7029339-3794-4275-893A-E705D872BFBE}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {D7029339-3794-4275-893A-E705D872BFBE}.Release|Any CPU.Build.0 = Release|Any CPU
+ {D7029339-3794-4275-893A-E705D872BFBE}.Release|x64.ActiveCfg = Release|Any CPU
+ {D7029339-3794-4275-893A-E705D872BFBE}.Release|x64.Build.0 = Release|Any CPU
+ {D7029339-3794-4275-893A-E705D872BFBE}.Release|x86.ActiveCfg = Release|Any CPU
+ {D7029339-3794-4275-893A-E705D872BFBE}.Release|x86.Build.0 = Release|Any CPU
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}.Debug|x64.Build.0 = Debug|Any CPU
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}.Debug|x86.Build.0 = Debug|Any CPU
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}.Release|Any CPU.Build.0 = Release|Any CPU
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}.Release|x64.ActiveCfg = Release|Any CPU
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}.Release|x64.Build.0 = Release|Any CPU
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}.Release|x86.ActiveCfg = Release|Any CPU
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A}.Release|x86.Build.0 = Release|Any CPU
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD}.Debug|x64.Build.0 = Debug|Any CPU
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD}.Debug|x86.Build.0 = Debug|Any CPU
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD}.Release|Any CPU.Build.0 = Release|Any CPU
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD}.Release|x64.ActiveCfg = Release|Any CPU
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD}.Release|x64.Build.0 = Release|Any CPU
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD}.Release|x86.ActiveCfg = Release|Any CPU
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD}.Release|x86.Build.0 = Release|Any CPU
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2}.Debug|x64.Build.0 = Debug|Any CPU
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2}.Debug|x86.Build.0 = Debug|Any CPU
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2}.Release|Any CPU.Build.0 = Release|Any CPU
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2}.Release|x64.ActiveCfg = Release|Any CPU
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2}.Release|x64.Build.0 = Release|Any CPU
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2}.Release|x86.ActiveCfg = Release|Any CPU
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2}.Release|x86.Build.0 = Release|Any CPU
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD}.Debug|x64.Build.0 = Debug|Any CPU
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD}.Debug|x86.Build.0 = Debug|Any CPU
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD}.Release|Any CPU.Build.0 = Release|Any CPU
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD}.Release|x64.ActiveCfg = Release|Any CPU
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD}.Release|x64.Build.0 = Release|Any CPU
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD}.Release|x86.ActiveCfg = Release|Any CPU
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD}.Release|x86.Build.0 = Release|Any CPU
+ {56B15268-DEBC-4E9F-8554-03737A39D71B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {56B15268-DEBC-4E9F-8554-03737A39D71B}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {56B15268-DEBC-4E9F-8554-03737A39D71B}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {56B15268-DEBC-4E9F-8554-03737A39D71B}.Debug|x64.Build.0 = Debug|Any CPU
+ {56B15268-DEBC-4E9F-8554-03737A39D71B}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {56B15268-DEBC-4E9F-8554-03737A39D71B}.Debug|x86.Build.0 = Debug|Any CPU
+ {56B15268-DEBC-4E9F-8554-03737A39D71B}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {56B15268-DEBC-4E9F-8554-03737A39D71B}.Release|Any CPU.Build.0 = Release|Any CPU
+ {56B15268-DEBC-4E9F-8554-03737A39D71B}.Release|x64.ActiveCfg = Release|Any CPU
+ {56B15268-DEBC-4E9F-8554-03737A39D71B}.Release|x64.Build.0 = Release|Any CPU
+ {56B15268-DEBC-4E9F-8554-03737A39D71B}.Release|x86.ActiveCfg = Release|Any CPU
+ {56B15268-DEBC-4E9F-8554-03737A39D71B}.Release|x86.Build.0 = Release|Any CPU
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}.Debug|x64.Build.0 = Debug|Any CPU
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}.Debug|x86.Build.0 = Debug|Any CPU
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}.Release|Any CPU.Build.0 = Release|Any CPU
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}.Release|x64.ActiveCfg = Release|Any CPU
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}.Release|x64.Build.0 = Release|Any CPU
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}.Release|x86.ActiveCfg = Release|Any CPU
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7}.Release|x86.Build.0 = Release|Any CPU
+ {04174210-4A5D-4F26-883E-B52B7B167EAC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {04174210-4A5D-4F26-883E-B52B7B167EAC}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {04174210-4A5D-4F26-883E-B52B7B167EAC}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {04174210-4A5D-4F26-883E-B52B7B167EAC}.Debug|x64.Build.0 = Debug|Any CPU
+ {04174210-4A5D-4F26-883E-B52B7B167EAC}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {04174210-4A5D-4F26-883E-B52B7B167EAC}.Debug|x86.Build.0 = Debug|Any CPU
+ {04174210-4A5D-4F26-883E-B52B7B167EAC}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {04174210-4A5D-4F26-883E-B52B7B167EAC}.Release|Any CPU.Build.0 = Release|Any CPU
+ {04174210-4A5D-4F26-883E-B52B7B167EAC}.Release|x64.ActiveCfg = Release|Any CPU
+ {04174210-4A5D-4F26-883E-B52B7B167EAC}.Release|x64.Build.0 = Release|Any CPU
+ {04174210-4A5D-4F26-883E-B52B7B167EAC}.Release|x86.ActiveCfg = Release|Any CPU
+ {04174210-4A5D-4F26-883E-B52B7B167EAC}.Release|x86.Build.0 = Release|Any CPU
+ {310733D1-2BF4-44D7-9947-93E29FA44310}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {310733D1-2BF4-44D7-9947-93E29FA44310}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {310733D1-2BF4-44D7-9947-93E29FA44310}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {310733D1-2BF4-44D7-9947-93E29FA44310}.Debug|x64.Build.0 = Debug|Any CPU
+ {310733D1-2BF4-44D7-9947-93E29FA44310}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {310733D1-2BF4-44D7-9947-93E29FA44310}.Debug|x86.Build.0 = Debug|Any CPU
+ {310733D1-2BF4-44D7-9947-93E29FA44310}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {310733D1-2BF4-44D7-9947-93E29FA44310}.Release|Any CPU.Build.0 = Release|Any CPU
+ {310733D1-2BF4-44D7-9947-93E29FA44310}.Release|x64.ActiveCfg = Release|Any CPU
+ {310733D1-2BF4-44D7-9947-93E29FA44310}.Release|x64.Build.0 = Release|Any CPU
+ {310733D1-2BF4-44D7-9947-93E29FA44310}.Release|x86.ActiveCfg = Release|Any CPU
+ {310733D1-2BF4-44D7-9947-93E29FA44310}.Release|x86.Build.0 = Release|Any CPU
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6}.Debug|x64.Build.0 = Debug|Any CPU
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6}.Debug|x86.Build.0 = Debug|Any CPU
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6}.Release|Any CPU.Build.0 = Release|Any CPU
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6}.Release|x64.ActiveCfg = Release|Any CPU
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6}.Release|x64.Build.0 = Release|Any CPU
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6}.Release|x86.ActiveCfg = Release|Any CPU
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6}.Release|x86.Build.0 = Release|Any CPU
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}.Debug|x64.Build.0 = Debug|Any CPU
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}.Debug|x86.Build.0 = Debug|Any CPU
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}.Release|Any CPU.Build.0 = Release|Any CPU
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}.Release|x64.ActiveCfg = Release|Any CPU
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}.Release|x64.Build.0 = Release|Any CPU
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}.Release|x86.ActiveCfg = Release|Any CPU
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6}.Release|x86.Build.0 = Release|Any CPU
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD}.Debug|x64.Build.0 = Debug|Any CPU
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD}.Debug|x86.Build.0 = Debug|Any CPU
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD}.Release|Any CPU.Build.0 = Release|Any CPU
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD}.Release|x64.ActiveCfg = Release|Any CPU
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD}.Release|x64.Build.0 = Release|Any CPU
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD}.Release|x86.ActiveCfg = Release|Any CPU
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD}.Release|x86.Build.0 = Release|Any CPU
+ {7FD67842-0549-4062-ACAB-3C417BD218C1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {7FD67842-0549-4062-ACAB-3C417BD218C1}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {7FD67842-0549-4062-ACAB-3C417BD218C1}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {7FD67842-0549-4062-ACAB-3C417BD218C1}.Debug|x64.Build.0 = Debug|Any CPU
+ {7FD67842-0549-4062-ACAB-3C417BD218C1}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {7FD67842-0549-4062-ACAB-3C417BD218C1}.Debug|x86.Build.0 = Debug|Any CPU
+ {7FD67842-0549-4062-ACAB-3C417BD218C1}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {7FD67842-0549-4062-ACAB-3C417BD218C1}.Release|Any CPU.Build.0 = Release|Any CPU
+ {7FD67842-0549-4062-ACAB-3C417BD218C1}.Release|x64.ActiveCfg = Release|Any CPU
+ {7FD67842-0549-4062-ACAB-3C417BD218C1}.Release|x64.Build.0 = Release|Any CPU
+ {7FD67842-0549-4062-ACAB-3C417BD218C1}.Release|x86.ActiveCfg = Release|Any CPU
+ {7FD67842-0549-4062-ACAB-3C417BD218C1}.Release|x86.Build.0 = Release|Any CPU
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21}.Debug|x64.Build.0 = Debug|Any CPU
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21}.Debug|x86.Build.0 = Debug|Any CPU
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21}.Release|Any CPU.Build.0 = Release|Any CPU
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21}.Release|x64.ActiveCfg = Release|Any CPU
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21}.Release|x64.Build.0 = Release|Any CPU
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21}.Release|x86.ActiveCfg = Release|Any CPU
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21}.Release|x86.Build.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(NestedProjects) = preSolution
+ {EB3ABF3B-295C-4BDD-8EA2-B60F30BC5E6C} = {D35087BF-941A-49EA-96A8-B10457C4D169}
+ {608A1D85-0999-4A9B-956A-11B91A1CB065} = {D3C17830-A461-4BA5-A672-461B19B33936}
+ {9A46374D-029C-4B87-88E3-0BE5D1D44C35} = {D35087BF-941A-49EA-96A8-B10457C4D169}
+ {D7029339-3794-4275-893A-E705D872BFBE} = {52F7988F-452D-46C2-A144-D85E0CF371C6}
+ {2C6CE3D7-D2DF-49F7-B3AF-5767E1C3705A} = {52F7988F-452D-46C2-A144-D85E0CF371C6}
+ {BCCDD838-8368-418D-82B5-5389FDDF0ADD} = {52F7988F-452D-46C2-A144-D85E0CF371C6}
+ {8860810C-5E46-4E60-8924-C6C77BBC6EB2} = {D35087BF-941A-49EA-96A8-B10457C4D169}
+ {9F0BFA49-8711-4143-B813-ACD0D0B003FD} = {52F7988F-452D-46C2-A144-D85E0CF371C6}
+ {56B15268-DEBC-4E9F-8554-03737A39D71B} = {52F7988F-452D-46C2-A144-D85E0CF371C6}
+ {2D3523BB-CF07-47D0-82F4-6B5621A8C1D7} = {D35087BF-941A-49EA-96A8-B10457C4D169}
+ {04174210-4A5D-4F26-883E-B52B7B167EAC} = {D35087BF-941A-49EA-96A8-B10457C4D169}
+ {310733D1-2BF4-44D7-9947-93E29FA44310} = {D35087BF-941A-49EA-96A8-B10457C4D169}
+ {C45058FC-A657-4D13-AF2A-6E0B30C444A6} = {D35087BF-941A-49EA-96A8-B10457C4D169}
+ {1F03D5F0-238E-48B0-BAE4-88B1E60B69C6} = {D35087BF-941A-49EA-96A8-B10457C4D169}
+ {187E9876-28EC-43D7-B70E-2C09E66D59BD} = {D35087BF-941A-49EA-96A8-B10457C4D169}
+ {7FD67842-0549-4062-ACAB-3C417BD218C1} = {52F7988F-452D-46C2-A144-D85E0CF371C6}
+ {26297E78-023D-4F3C-4F39-A7CC4FA9AF21} = {D35087BF-941A-49EA-96A8-B10457C4D169}
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {9397EEB2-E3A3-4748-A106-3DE17F40E698}
+ EndGlobalSection
+EndGlobal
diff --git a/src/NEventStore.Example/AggregateMemento.cs b/src/NEventStore.Example/AggregateMemento.cs
new file mode 100644
index 000000000..208491aa3
--- /dev/null
+++ b/src/NEventStore.Example/AggregateMemento.cs
@@ -0,0 +1,12 @@
+namespace NEventStore.Example
+{
+ internal class AggregateMemento
+ {
+ public string? Value { get; set; }
+
+ public override string? ToString()
+ {
+ return Value;
+ }
+ }
+}
\ No newline at end of file
diff --git a/src/NEventStore.Example/AuthorizationPipelineHook.cs b/src/NEventStore.Example/AuthorizationPipelineHook.cs
new file mode 100644
index 000000000..6563205ba
--- /dev/null
+++ b/src/NEventStore.Example/AuthorizationPipelineHook.cs
@@ -0,0 +1,22 @@
+namespace NEventStore.Example
+{
+ public class AuthorizationPipelineHook : PipelineHookBase
+ {
+ public override ICommit? SelectCommit(ICommit committed)
+ {
+ // return null if the user isn't authorized to see this commit
+ return committed;
+ }
+
+ public override void PostCommit(ICommit committed)
+ {
+ // anything to do after the commit has been persisted.
+ }
+
+ public override bool PreCommit(CommitAttempt attempt)
+ {
+ // Can easily do logging or other such activities here
+ return true; // true == allow commit to continue, false = stop.
+ }
+ }
+}
\ No newline at end of file
diff --git a/src/NEventStore.Example/MainProgram.cs b/src/NEventStore.Example/MainProgram.cs
new file mode 100644
index 000000000..1197b095a
--- /dev/null
+++ b/src/NEventStore.Example/MainProgram.cs
@@ -0,0 +1,157 @@
+using Microsoft.Extensions.Logging;
+
+namespace NEventStore.Example
+{
+ internal static class MainProgram
+ {
+ private static readonly Guid StreamId = Guid.NewGuid(); // aggregate identifier
+
+ private static IStoreEvents? store;
+
+ private static void Main()
+ {
+ // Console.WindowWidth = Console.LargestWindowWidth - 20;
+
+ Console.WriteLine("------------------");
+ Console.WriteLine("Using Sync Methods");
+ Console.WriteLine("------------------");
+ Console.WriteLine();
+
+ using (store = WireupEventStore())
+ {
+ OpenOrCreateStream();
+ AppendToStream();
+ TakeSnapshot();
+ LoadFromSnapshotForwardAndAppend();
+ }
+
+ Console.WriteLine();
+ Console.WriteLine("-------------------");
+ Console.WriteLine("Using Async Methods");
+ Console.WriteLine("-------------------");
+ Console.WriteLine();
+
+ Task.Run(async () =>
+ {
+ using (store = WireupEventStore())
+ {
+ await OpenOrCreateStreamAsync();
+ await AppendToStreamAsync();
+ await TakeSnapshotAsync();
+ await LoadFromSnapshotForwardAndAppendAsync();
+ }
+ }).GetAwaiter().GetResult();
+
+ Console.WriteLine("Press any key to continue...");
+ Console.ReadKey();
+ }
+
+ private static IStoreEvents WireupEventStore()
+ {
+ var loggerFactory = LoggerFactory.Create(logging =>
+ {
+ logging
+ .AddConsole()
+ .AddDebug()
+ .SetMinimumLevel(Microsoft.Extensions.Logging.LogLevel.Trace);
+ });
+
+ return Wireup.Init()
+ .WithLoggerFactory(loggerFactory)
+ .UseOptimisticPipelineHook()
+ .UsingInMemoryPersistence()
+ .InitializeStorageEngine()
+#if NET462
+ .TrackPerformanceInstance("example")
+#endif
+ .HookIntoPipelineUsing(new AuthorizationPipelineHook())
+ .Build();
+ }
+
+ #region Sync Methods
+
+ private static void OpenOrCreateStream()
+ {
+ // we can call CreateStream(StreamId) if we know there isn't going to be any data.
+ // or we can call OpenStream(StreamId, 0, int.MaxValue) to read all commits,
+ // if no commits exist then it creates a new stream for us.
+ using var stream = store!.OpenStream(StreamId, 0, int.MaxValue);
+ var @event = new SomeDomainEvent { Value = "Initial event." };
+
+ stream.Add(new EventMessage { Body = @event });
+ stream.CommitChanges(Guid.NewGuid());
+ }
+
+ private static void AppendToStream()
+ {
+ using var stream = store!.OpenStream(StreamId);
+ var @event = new SomeDomainEvent { Value = "Second event." };
+
+ stream.Add(new EventMessage { Body = @event });
+ stream.CommitChanges(Guid.NewGuid());
+ }
+
+ private static void TakeSnapshot()
+ {
+ var memento = new AggregateMemento { Value = "snapshot" };
+ store!.Advanced.AddSnapshot(new Snapshot(StreamId.ToString(), 2, memento));
+ }
+
+ private static void LoadFromSnapshotForwardAndAppend()
+ {
+ var latestSnapshot = store!.Advanced.GetSnapshot(StreamId, int.MaxValue)
+ ?? throw new InvalidOperationException("No snapshot found.");
+
+ using var stream = store.OpenStream(latestSnapshot, int.MaxValue);
+ var @event = new SomeDomainEvent { Value = "Third event (first one after a snapshot)." };
+
+ stream.Add(new EventMessage { Body = @event });
+ stream.CommitChanges(Guid.NewGuid());
+ }
+
+ #endregion
+
+ #region Async Methods
+
+ private static async Task OpenOrCreateStreamAsync()
+ {
+ // we can call CreateStream(StreamId) if we know there isn't going to be any data.
+ // or we can call OpenStream(StreamId, 0, int.MaxValue) to read all commits,
+ // if no commits exist then it creates a new stream for us.
+ using var stream = await store!.OpenStreamAsync(StreamId, 0, int.MaxValue, cancellationToken: CancellationToken.None);
+ var @event = new SomeDomainEvent { Value = "Initial event." };
+
+ stream.Add(new EventMessage { Body = @event });
+ await stream.CommitChangesAsync(Guid.NewGuid(), CancellationToken.None);
+ }
+
+ private static async Task AppendToStreamAsync()
+ {
+ using var stream = await store!.OpenStreamAsync(StreamId, cancellationToken: CancellationToken.None);
+ var @event = new SomeDomainEvent { Value = "Second event." };
+
+ stream.Add(new EventMessage { Body = @event });
+ await stream.CommitChangesAsync(Guid.NewGuid(), CancellationToken.None);
+ }
+
+ private static Task TakeSnapshotAsync()
+ {
+ var memento = new AggregateMemento { Value = "snapshot" };
+ return store!.Advanced.AddSnapshotAsync(new Snapshot(StreamId.ToString(), 2, memento), CancellationToken.None);
+ }
+
+ private static async Task LoadFromSnapshotForwardAndAppendAsync()
+ {
+ var latestSnapshot = await store!.Advanced.GetSnapshotAsync(StreamId, int.MaxValue, CancellationToken.None)
+ ?? throw new InvalidOperationException("No snapshot found.");
+
+ using var stream = await store.OpenStreamAsync(latestSnapshot, int.MaxValue, CancellationToken.None);
+ var @event = new SomeDomainEvent { Value = "Third event (first one after a snapshot)." };
+
+ stream.Add(new EventMessage { Body = @event });
+ await stream.CommitChangesAsync(Guid.NewGuid(), CancellationToken.None);
+ }
+
+ #endregion
+ }
+}
\ No newline at end of file
diff --git a/src/NEventStore.Example/NEventStore.Example.csproj b/src/NEventStore.Example/NEventStore.Example.csproj
new file mode 100644
index 000000000..5873988cc
--- /dev/null
+++ b/src/NEventStore.Example/NEventStore.Example.csproj
@@ -0,0 +1,31 @@
+
+
+
+ net8.0;net472
+ false
+
+ exe
+
+ Exe
+
+
+
+ TRACE;DEBUG
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/doc/EventStore.Example/Properties/AssemblyInfo.cs b/src/NEventStore.Example/Properties/ProjectAssemblyInfo.cs
similarity index 76%
rename from doc/EventStore.Example/Properties/AssemblyInfo.cs
rename to src/NEventStore.Example/Properties/ProjectAssemblyInfo.cs
index adf4d7f30..33cbc2e74 100644
--- a/doc/EventStore.Example/Properties/AssemblyInfo.cs
+++ b/src/NEventStore.Example/Properties/ProjectAssemblyInfo.cs
@@ -1,6 +1,6 @@
using System.Reflection;
using System.Runtime.InteropServices;
-[assembly: AssemblyTitle("EventStore.Example")]
+[assembly: AssemblyTitle("NEventStore.Example")]
[assembly: AssemblyDescription("")]
[assembly: Guid("6fd621e0-9047-4449-b136-249383936d5c")]
\ No newline at end of file
diff --git a/src/NEventStore.Example/SomeDomainEvent.cs b/src/NEventStore.Example/SomeDomainEvent.cs
new file mode 100644
index 000000000..b83e751f9
--- /dev/null
+++ b/src/NEventStore.Example/SomeDomainEvent.cs
@@ -0,0 +1,7 @@
+namespace NEventStore.Example
+{
+ internal class SomeDomainEvent
+ {
+ public string? Value { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/src/NEventStore.Persistence.AcceptanceTests/BDD/MSTest/SpecificationBase.cs b/src/NEventStore.Persistence.AcceptanceTests/BDD/MSTest/SpecificationBase.cs
new file mode 100644
index 000000000..43f014b67
--- /dev/null
+++ b/src/NEventStore.Persistence.AcceptanceTests/BDD/MSTest/SpecificationBase.cs
@@ -0,0 +1,108 @@
+#if MSTEST
+
+using Microsoft.VisualStudio.TestTools.UnitTesting;
+
+namespace NEventStore.Persistence.AcceptanceTests.BDD
+{
+ ///
+ ///
+ /// base class for BDD testing in a Given-When-Then style
+ /// using MSTest
+ ///
+ /// in MSTest each test will be executed by a new instance of the test class.
+ ///
+ /// this will be used to implement a class that will test a single
+ /// action or behavior and multiple result conditions
+ ///
+ ///
+ /// - a class will represent a single scenario
+ /// - the class name will describe the scenario name
+ ///
+ ///
+ [TestClass]
+ public abstract class SpecificationBase
+ {
+ Exception? testFixtureSetupException = null;
+
+ ///
+ ///
+ /// there's a problem with error / exception reporting in here, test fixture setup is not well suited for
+ /// exception handling
+ /// workaround:
+ /// http://stackoverflow.com/questions/1411676/how-to-diagnose-testfixturesetup-failed
+ ///
+ ///
+ /// a good idea on how to catch and test for exceptions:
+ /// http://www.planetgeek.ch/2015/06/22/machine-specifications-the-alternative-nunit/
+ ///
+ ///
+ /// maybe catch the generated exception with something like: Catch.Exception() shown here and save it to a local variable
+ /// in the when() function, then test for the exception in the 'then' tests
+ ///
+ ///
+ [TestInitialize] // I cannot have something like a OnTimeTestInitialize in MsTest, ClassInitialize requires static methods
+ public async Task SetUp()
+ {
+ try
+ {
+ Context();
+ await ContextAsync();
+ Because();
+ await BecauseAsync();
+ }
+ catch (Exception ex)
+ {
+ testFixtureSetupException = ex;
+ }
+ }
+
+ [TestInitialize]
+ // NUnit doesn't support very useful logging of failures from a OneTimeSetUp method. We'll do the logging here.
+ public void CheckForTestFixtureFailure()
+ {
+ if (testFixtureSetupException != null)
+ {
+ string msg = string.Format("There was a failure during Context() or Because() phases.\n\rException: {0}\n\rStackTrace: {1}",
+ testFixtureSetupException.Message, testFixtureSetupException.StackTrace);
+ Assert.Fail(msg);
+ }
+ }
+
+ protected virtual void Context() { }
+ protected virtual Task ContextAsync() { return Task.CompletedTask; }
+ protected virtual void Because() { }
+ protected virtual Task BecauseAsync() { return Task.CompletedTask; }
+
+ [ClassCleanup]
+ protected virtual void Cleanup() { }
+ }
+
+ ///
+ /// Attribute used to identify the tests
+ ///
+ /// for custom actions:
+ /// http://nunit.org/index.php?p=actionAttributes&r=2.6.3
+ ///
+ ///
+ [AttributeUsage(AttributeTargets.Method)]
+ public class ThenAttribute : LogTestMethod;
+
+ [AttributeUsage(AttributeTargets.Method)]
+ public class FactAttribute : LogTestMethod;
+
+ public class LogTestMethod : TestMethodAttribute
+ {
+ public override TestResult[] Execute(ITestMethod testMethod)
+ {
+ Console.WriteLine("Scenario: {0}", testMethod.TestClassName);
+
+ var result = base.Execute(testMethod);
+
+ Console.WriteLine(" - {0} - {1}", testMethod.TestMethodName, result[0].Outcome == UnitTestOutcome.Passed);
+
+ return result;
+ }
+ }
+}
+
+#endif
\ No newline at end of file
diff --git a/src/NEventStore.Persistence.AcceptanceTests/BDD/NUnit/SpecificationBase.cs b/src/NEventStore.Persistence.AcceptanceTests/BDD/NUnit/SpecificationBase.cs
new file mode 100644
index 000000000..7f75e85e6
--- /dev/null
+++ b/src/NEventStore.Persistence.AcceptanceTests/BDD/NUnit/SpecificationBase.cs
@@ -0,0 +1,145 @@
+#if NUNIT
+
+using NUnit.Framework;
+using NUnit.Framework.Interfaces;
+
+namespace NEventStore.Persistence.AcceptanceTests.BDD
+{
+ ///
+ ///
+ /// base class for BDD testing in a Given-When-Then style
+ /// using NUnit
+ ///
+ ///
+ /// this will be used to implement a class that will test a single
+ /// action or behavior and multiple result conditions:
+ /// - a class will represent a single scenario
+ /// - the class name will describe the scenario name
+ ///
+ ///
+ [TestFixture]
+ [LogSuiteAttribute]
+ [LogTestAttribute]
+ public abstract class SpecificationBase
+ {
+ private Exception? testFixtureSetupException = null;
+
+ ///
+ ///
+ /// there's a problem with error / exception reporting in here, test fixture setup is not well suited for
+ /// exception handling
+ /// workaround:
+ /// http://stackoverflow.com/questions/1411676/how-to-diagnose-testfixturesetup-failed
+ ///
+ ///
+ /// a good idea on how to catch and test for exceptions:
+ /// http://www.planetgeek.ch/2015/06/22/machine-specifications-the-alternative-nunit/
+ ///
+ ///
+ /// maybe catch the generated exception with something like: Catch.Exception() shown here and save it to a local variable
+ /// in the when() function, then test for the exception in the 'then' tests
+ ///
+ ///
+ [OneTimeSetUp]
+ public async Task SetUp()
+ {
+ try
+ {
+ Context();
+ await ContextAsync();
+ Because();
+ await BecauseAsync();
+ }
+ catch (Exception ex)
+ {
+ testFixtureSetupException = ex;
+ }
+ }
+
+ [SetUp]
+ // NUnit doesn't support very useful logging of failures from a OneTimeSetUp method. We'll do the logging here.
+ public void CheckForTestFixtureFailure()
+ {
+ if (testFixtureSetupException != null)
+ {
+ string msg = string.Format("There was a failure during Context() or Because() phases.\n\rException: {0}\n\rStackTrace: {1}",
+ testFixtureSetupException.Message, testFixtureSetupException.StackTrace);
+ Assert.Fail(msg);
+ }
+ }
+
+ protected virtual void Context() { }
+ protected virtual Task ContextAsync() { return Task.CompletedTask; }
+ protected virtual void Because() { }
+ protected virtual Task BecauseAsync() { return Task.CompletedTask; }
+
+ [OneTimeTearDown]
+ protected virtual void Cleanup() { }
+ }
+
+ ///
+ ///
+ /// Attribute used to identify the tests
+ ///
+ ///
+ /// for custom actions:
+ /// http://nunit.org/index.php?p=actionAttributes&r=2.6.3
+ ///
+ ///
+ [AttributeUsage(AttributeTargets.Method)]
+ public class ThenAttribute : TestAttribute;
+
+ [AttributeUsage(AttributeTargets.Method)]
+ public class FactAttribute : TestAttribute;
+
+ [AttributeUsageAttribute(AttributeTargets.Class)]
+ public class LogSuiteAttribute : Attribute, ITestAction
+ {
+ public void AfterTest(ITest test)
+ {
+ // Method intentionally left empty.
+ }
+
+ public void BeforeTest(ITest test)
+ {
+ Console.WriteLine("Scenario: {0}", test?.Fixture?.GetType().Name);
+ }
+
+ public ActionTargets Targets
+ {
+ get { return ActionTargets.Suite; }
+ }
+ }
+
+ ///
+ ///
+ /// Attribute used to identify the tests
+ /// and describe them
+ ///
+ ///
+ /// for custom actions:
+ /// http://nunit.org/index.php?p=actionAttributes&r=2.6.3
+ /// http://nunit.org/index.php?p=testContext&r=2.6.3
+ ///
+ ///
+ [AttributeUsageAttribute(AttributeTargets.Class, AllowMultiple = false)]
+ public class LogTestAttribute : Attribute, ITestAction
+ {
+ public void AfterTest(ITest test)
+ {
+ Console.WriteLine(" - {0} - {1}", test?.Method?.Name, TestContext.CurrentContext.Result.Outcome.Status);
+ }
+
+ public void BeforeTest(ITest test)
+ {
+ Console.WriteLine(test?.Fixture?.GetType().Name);
+ }
+
+ public ActionTargets Targets
+ {
+ get { return ActionTargets.Test; }
+ }
+ }
+}
+
+#endif
\ No newline at end of file
diff --git a/src/NEventStore.Persistence.AcceptanceTests/BDD/SpecificationBase.cs b/src/NEventStore.Persistence.AcceptanceTests/BDD/SpecificationBase.cs
new file mode 100644
index 000000000..58832237c
--- /dev/null
+++ b/src/NEventStore.Persistence.AcceptanceTests/BDD/SpecificationBase.cs
@@ -0,0 +1,34 @@
+#if XUNIT
+
+namespace NEventStore.Persistence.AcceptanceTests.BDD
+{
+
+ using Xunit;
+
+
+ [RunWith(typeof (SpecificationBaseRunner))]
+ public abstract class SpecificationBase
+ {
+ protected virtual void Because()
+ {}
+
+ protected virtual void Cleanup()
+ {}
+
+ protected virtual void Context()
+ {}
+
+ public void OnFinish()
+ {
+ Cleanup();
+ }
+
+ public void OnStart()
+ {
+ Context();
+ Because();
+ }
+ }
+}
+
+#endif
\ No newline at end of file
diff --git a/src/NEventStore.Persistence.AcceptanceTests/BDD/SpecificationBaseRunner.cs b/src/NEventStore.Persistence.AcceptanceTests/BDD/SpecificationBaseRunner.cs
new file mode 100644
index 000000000..a46340a13
--- /dev/null
+++ b/src/NEventStore.Persistence.AcceptanceTests/BDD/SpecificationBaseRunner.cs
@@ -0,0 +1,168 @@
+#if XUNIT
+
+namespace NEventStore.Persistence.AcceptanceTests.BDD
+{
+ using System;
+ using System.Collections.Generic;
+ using System.Reflection;
+ using Xunit;
+ using Xunit.Sdk;
+
+ internal class SpecificationBaseRunner : ITestClassCommand
+ {
+ private readonly List