Giter Club home page Giter Club logo

orleans.storageprovider.ravendb's Introduction

Orleans StorageProvider for RavenDB

This is a StorageProvider for RavenDB for the Microsoft Research Project Orleans. The storage provider allows to persist stateful grains into RavenDB. The provider offers the following options:

  • Server Mode
  • Embedded Mode
  • InMemory

In order to use the provider you need to add the following provider to your configuration:

<Provider Type="Orleans.StorageProvider.RavenDB.RavenDBStorageProvider" Name="RavenDBStore" ConnectionStringName="RavenDB"/>

and this line to any grain that uses it

[StorageProvider(ProviderName = "RavenDBStore")]

In addition you need an application configuration file (app.config) with a connection string named after the ConnectionStringName in the provider configuration entry.

<?xml version="1.0" encoding="utf-8" ?>
<configuration>
  <connectionStrings>
    <add name="RavenDB" connectionString="YOUR CONNECTION STRING HERE"/>
  </connectionStrings>
</configuration>

All connection string officially supported by RavenDB are also supported by the provider. The mode (Server, Embedded, InMemory) is chosen based on the connection string according to the following strategy:

  • When the connection string is empty the InMemory mode is used
  • When the connection string is an Url the Server mode is used
  • When the connection string is a DataDir the Embedded mode is used

Here are examples of such connection strings:

<?xml version="1.0" encoding="utf-8" ?>
<configuration>
  <connectionStrings>
    <add name="RavenDB" connectionString="Url = http://localhost:8080;Database=RavenDBStorageProviderTests"/>  <!-- Server Mode -->
    <add name="RavenDBLocal" connectionString="DataDir = ~\Data"/> <!-- Embedded Mode -->
  </connectionStrings>
</configuration>	

<Provider Type="Orleans.StorageProvider.RavenDB.RavenDBStorageProvider" Name="RavenDBStore" ConnectionStringName=""/> <!-- InMemory Mode -->

orleans.storageprovider.ravendb's People

Contributors

danielmarbach avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

orleans.storageprovider.ravendb's Issues

Nuget package/s

What would be the best approach for the nuget package/s? Currently there is one assembly supporting full ravendb, embedded and in-memory. Which requires the client code to reference a lot of nugets from RavenDB. I can either do one big nuget package with everything contained or for each supported mode one package. What is your take?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.