1
私はravenをravenに取得して、SQLからravenに日付をインポートするようにしようとしています。コンソールアプリからravendb
私はRavenInstallerを持っている:
public class RavenInstaller : IWindsorInstaller
{
public void Install(IWindsorContainer container, IConfigurationStore store)
{
container.Register(
Component.For<IDocumentStore>().ImplementedBy<DocumentStore>()
.DependsOn(new { connectionStringName = "SomeRavenConnectionString" })
.OnCreate(DoInitialisation)
.LifeStyle.Singleton
);
}
static IDocumentSession GetDocumentSesssion(IKernel kernel)
{
var store = kernel.Resolve<IDocumentStore>();
return store.OpenSession();
}
public static void DoInitialisation(IKernel kernel, IDocumentStore store)
{
store.Initialize();
}
}
しかし - 私はアプリはちょうどハング_documentSession.OpenSession()を呼び出すとき。
コンソールアプリケーション環境に指定する必要があるものはありますか?それはそれがタイムアウトだと言い続ける - configのURLはlocalhost:8080は正しいですか?
私は今使用して、それを変更しました:
using (var documentStore = new DocumentStore { Url = "http://localhost:8080" })
{
documentStore.Initialize();
using (var session = documentStore.OpenSession())
{
var mp = _container.Resolve<MainProcess>();
mp.DocumentSession = session;
mp.Execute();
}
}
まだのOpenSessionにぶら下がっ。
私はdll refを使用していますが、ソースにリンクせずにその情報を取得できますか? – iwayneo
が最新のビルドに更新され、すべてがティックティックブームです:) – iwayneo