joliver/EventStore — pull request #116 by scottlowe (2012-07-04 17:43:15+00:00)
Title: Allow Mongo persistance wireup to take a raw connection string, as well as a connection name

Hello. Whilst this code revision may seem like an odd thing to suggest, we have run up against the problem that this solves, in the real world.

Using the `connectionStrings` config section is usually the correct way to configure data stores, but in our case we are deploying to a PaaS and have no control over the location of where the connection string is stored; In our case, the connection string is held within `appSettings` and it is replaced during deployment by the PaaS provider.

In our case, our only option is for us to load the MongoDB connection string ourselves before passing it to the Mongo persistence wireup, rather than let the EventStore plugin find it for us.

I hope this makes sense.

I admit that the solution offered here has a a slight smell of compromise, but allows for backwards compatibility, it's simple and it works!