Exception Raven DB批量插入的奇数异常

Exception Raven DB批量插入的奇数异常,exception,ravendb,ravendb-http,Exception,Ravendb,Ravendb Http,目前我正在试用RavenDB(3.0),并尝试使用批量插入功能。然而,尽管大容量插入看起来很有效,但在它完成后,我始终会遇到一个异常: An exception of type 'System.IO.EndOfStreamException' occurred in Raven.Client.Lightweight.dll but was not handled in user code Additional information: Attempted to read past the en

目前我正在试用RavenDB(3.0),并尝试使用批量插入功能。然而,尽管大容量插入看起来很有效,但在它完成后,我始终会遇到一个异常:

An exception of type 'System.IO.EndOfStreamException' occurred in Raven.Client.Lightweight.dll but was not handled in user code

Additional information: Attempted to read past the end of the stream.
堆栈跟踪是

   at Raven.Client.Connection.ObservableLineStream.<Start>b__1(Task`1 task) in c:\Builds\RavenDB-Stable-3.0\Raven.Client.Lightweight\Connection\ObservableLineStream.cs:line 39
   at System.Threading.Tasks.ContinuationTaskFromResultTask`1.InnerInvoke()
   at System.Threading.Tasks.Task.Execute()
在c:\Builds\RavenDB-Stable-3.0\Raven.Client.Lightweight\Connection\observelineRestream.cs中的Raven.Client.Connection.observelineRestream.1(任务'1 Task'):第39行
位于System.Threading.Tasks.ContinuationTaskFromResultTask`1.InnerInvoke()
在System.Threading.Tasks.Task.Execute()中
这是我的代码:

 static void Main(string[] args)
 {
     try
     {
        using (var store = new DocumentStore {
                     Url = "http://localhost:8080/", 
                     DefaultDatabase = "Northwind" })
         {
             store.Initialize();
             int total = 10000;
             using (var bulkInsert = store.BulkInsert())
             {
                for (int i = 0; i < total; i++){
                     bulkInsert.Store(new Employee{
                             FirstName = "FirstName #" + i,
                             LastName = "LastName #" + i});
                        }                           
                    }
                }
            }
     catch (Exception ex)
     {
         Console.WriteLine(ex);
     }
     finally
     {
         Console.ReadLine();
     }
 }
static void Main(字符串[]args)
{
尝试
{
使用(var存储=新文档存储){
Url=”http://localhost:8080/", 
DefaultDatabase=“Northwind”})
{
store.Initialize();
总数=10000;
使用(var bulkInsert=store.bulkInsert())
{
对于(int i=0;i
奇怪的是,数据正在写入数据库(我可以在数据库浏览器中查看它),但我的代码中也没有捕获异常-它被标记为未处理,尽管有
try/catch


我很困惑为什么会发生这种情况,更重要的是,我如何才能预防它。有人有什么想法吗?

例外是我们用于批量插入的手表。完成后,我们关闭手表,抛出异常。
它是内部处理的,不会对您的应用程序产生任何影响

谢谢您的澄清,我将忽略它:)