Exemplo n.º 1
0
        private RavenDbConfigurationStoreOptions GetRavenDbConfigurationStoreOptions(X509Certificate2 cert = null)
        {
            var documentStore = GetDocumentStore();

            var options = new RavenDbConfigurationStoreOptions
            {
                ConfigureDocumentStore = store =>
                {
                    store.Database    = documentStore.Database;
                    store.Urls        = documentStore.Urls;
                    store.Certificate = cert;
                }
            };

            return(options);
        }
 public ConfigurationDocumentStoreHolder(RavenDbConfigurationStoreOptions options)
 {
     _documentStore = DocumentStoreHelper.InitializeDocumentStore(options.ConfigureDocumentStore);
     IndexHelper.ExecuteConfigurationStoreIndexes(_documentStore);
 }