RavenDB C#客户端抛出错误为无效的节点标记字符:n

loading...


1

我试图删除RavenDB中的文档,该文档在一台机器上运行3个节点(开发设置) . 以下是删除文档的代码 .

public bool Remove<T>(string id) where T : new()
{
    bool bResult = false;
    using (var session = _session.OpenSession())
    {
        session.Delete(id);
        session.SaveChanges();
        bResult = true;
    }
    return bResult;
}

但它在行上抛出错误 session.SaveChanges();

节点标记字符无效:n ...

堆栈跟踪:

System.ArgumentException: Invalid node tag character: n
   at Raven.Server.Documents.Replication.ChangeVectorParser.ThrowInvalidNodeTag(Char ch) in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Documents\Replication\ChangeVectorParser.cs:line 71
   at Raven.Server.Documents.Replication.ChangeVectorParser.ParseNodeTag(String changeVector, Int32 start, Int32 end) in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Documents\Replication\ChangeVectorParser.cs:line 52
   at Raven.Server.Documents.Replication.ChangeVectorParser.MergeChangeVector(String changeVector, List`1 entries) in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Documents\Replication\ChangeVectorParser.cs:line 186
   at Raven.Server.Utils.ChangeVectorUtils.MergeVectors(String vectorAstring, String vectorBstring) in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Utils\ChangeVectorUtils.cs:line 213
   at Raven.Server.Documents.DocumentsStorage.CreateTombstone(DocumentsOperationContext context, Slice lowerId, Int64 documentEtag, CollectionName collectionName, String docChangeVector, Int64 lastModifiedTicks, String changeVector, DocumentFlags flags, NonPersistentDocumentFlags nonPersistentFlags) in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Documents\DocumentsStorage.cs:line 1378
   at Raven.Server.Documents.DocumentsStorage.Delete(DocumentsOperationContext context, Slice lowerId, String id, LazyStringValue expectedChangeVector, Nullable`1 lastModifiedTicks, String changeVector, CollectionName collectionName, NonPersistentDocumentFlags nonPersistentFlags, DocumentFlags documentFlags) in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Documents\DocumentsStorage.cs:line 1195
   at Raven.Server.Documents.DocumentsStorage.Delete(DocumentsOperationContext context, String id, String expectedChangeVector) in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Documents\DocumentsStorage.cs:line 1091
   at Raven.Server.Documents.Handlers.BatchHandler.MergedBatchCommand.ExecuteCmd(DocumentsOperationContext context) in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Documents\Handlers\BatchHandler.cs:line 706
   at Raven.Server.Documents.TransactionOperationsMerger.ExecutePendingOperationsInTransaction(List`1 pendingOps, DocumentsOperationContext context, Task previousOperation, DurationMeasurement& meter) in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Documents\TransactionOperationsMerger.cs:line 825
   at Raven.Server.Documents.TransactionOperationsMerger.MergeTransactionsOnce() in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Documents\TransactionOperationsMerger.cs:line 500
--- End of stack trace from previous location where exception was thrown ---
   at Raven.Server.Documents.TransactionOperationsMerger.Enqueue(MergedTransactionCommand cmd) in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Documents\TransactionOperationsMerger.cs:line 124
   at Raven.Server.Documents.Handlers.BatchHandler.BulkDocs() in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Documents\Handlers\BatchHandler.cs:line 96
   at Raven.Server.Routing.RequestRouter.HandlePath(RequestHandlerContext reqCtx) in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\Routing\RequestRouter.cs:line 124
   at Raven.Server.RavenServerStartup.RequestHandler(HttpContext context) in C:\Builds\RavenDB-Stable-4.1\src\Raven.Server\RavenServerStartup.cs:line 172

loading...

0回答

No Data

评论

暂时没有评论!