diff options
Diffstat (limited to 'searchcore')
6 files changed, 47 insertions, 47 deletions
diff --git a/searchcore/src/apps/proton/downpersistence.cpp b/searchcore/src/apps/proton/downpersistence.cpp index 33ad4bc5024..4b911eb6d2b 100644 --- a/searchcore/src/apps/proton/downpersistence.cpp +++ b/searchcore/src/apps/proton/downpersistence.cpp @@ -10,7 +10,7 @@ namespace storage::spi { namespace { -Result errorResult(Result::FATAL_ERROR, "Node is down"); +Result errorResult(Result::ErrorType::FATAL_ERROR, "Node is down"); } diff --git a/searchcore/src/tests/proton/documentdb/feedhandler/feedhandler_test.cpp b/searchcore/src/tests/proton/documentdb/feedhandler/feedhandler_test.cpp index 39fc93d5725..4b3b68a85ea 100644 --- a/searchcore/src/tests/proton/documentdb/feedhandler/feedhandler_test.cpp +++ b/searchcore/src/tests/proton/documentdb/feedhandler/feedhandler_test.cpp @@ -684,7 +684,7 @@ TEST_F("require that put is rejected if resource limit is reached", FeedHandlerF FeedTokenContext token; f.handler.performOperation(std::move(token.token), std::move(op)); EXPECT_EQUAL(0, f.feedView.put_count); - EXPECT_EQUAL(Result::RESOURCE_EXHAUSTED, token.getResult()->getErrorCode()); + EXPECT_EQUAL(Result::ErrorType::RESOURCE_EXHAUSTED, token.getResult()->getErrorCode()); EXPECT_EQUAL("Put operation rejected for document 'id:test:searchdocument::foo' of type 'searchdocument': 'Attribute resource limit reached'", token.getResult()->getErrorMessage()); } @@ -700,7 +700,7 @@ TEST_F("require that update is rejected if resource limit is reached", FeedHandl f.handler.performOperation(std::move(token.token), std::move(op)); EXPECT_EQUAL(0, f.feedView.update_count); EXPECT_TRUE(dynamic_cast<const UpdateResult *>(token.getResult())); - EXPECT_EQUAL(Result::RESOURCE_EXHAUSTED, token.getResult()->getErrorCode()); + EXPECT_EQUAL(Result::ErrorType::RESOURCE_EXHAUSTED, token.getResult()->getErrorCode()); EXPECT_EQUAL("Update operation rejected for document 'id:test:searchdocument::foo' of type 'searchdocument': 'Attribute resource limit reached'", token.getResult()->getErrorMessage()); } @@ -715,7 +715,7 @@ TEST_F("require that remove is NOT rejected if resource limit is reached", FeedH FeedTokenContext token; f.handler.performOperation(std::move(token.token), std::move(op)); EXPECT_EQUAL(1, f.feedView.remove_count); - EXPECT_EQUAL(Result::NONE, token.getResult()->getErrorCode()); + EXPECT_EQUAL(Result::ErrorType::NONE, token.getResult()->getErrorCode()); EXPECT_EQUAL("", token.getResult()->getErrorMessage()); } @@ -738,7 +738,7 @@ checkUpdate(FeedHandlerFixture &f, SchemaContext &schemaContext, EXPECT_TRUE(dynamic_cast<const UpdateResult *>(token.getResult())); if (expectReject) { TEST_DO(f.feedView.checkCounts(0, 0u, 0, 0u)); - EXPECT_EQUAL(Result::TRANSIENT_ERROR, token.getResult()->getErrorCode()); + EXPECT_EQUAL(Result::ErrorType::TRANSIENT_ERROR, token.getResult()->getErrorCode()); if (fieldName == "tensor2") { EXPECT_EQUAL("Update operation rejected for document 'id:test:searchdocument::foo' of type 'searchdocument': 'Wrong tensor type: Field tensor type is 'tensor(x{},y{})' but other tensor type is 'tensor(x{})''", token.getResult()->getErrorMessage()); @@ -752,7 +752,7 @@ checkUpdate(FeedHandlerFixture &f, SchemaContext &schemaContext, } else { TEST_DO(f.feedView.checkCounts(0, 0u, 1, 16u)); } - EXPECT_EQUAL(Result::NONE, token.getResult()->getErrorCode()); + EXPECT_EQUAL(Result::ErrorType::NONE, token.getResult()->getErrorCode()); EXPECT_EQUAL("", token.getResult()->getErrorMessage()); } } diff --git a/searchcore/src/tests/proton/persistenceengine/persistenceengine_test.cpp b/searchcore/src/tests/proton/persistenceengine/persistenceengine_test.cpp index 5484b8eacf0..cdc0e8656d8 100644 --- a/searchcore/src/tests/proton/persistenceengine/persistenceengine_test.cpp +++ b/searchcore/src/tests/proton/persistenceengine/persistenceengine_test.cpp @@ -469,7 +469,7 @@ TEST_F("require that puts are routed to handler", SimpleFixture) assertHandler(bucket1, tstamp1, docId1, f.hset.handler1); assertHandler(bucket1, tstamp1, docId2, f.hset.handler2); - EXPECT_EQUAL(Result(Result::PERMANENT_ERROR, "No handler for document type 'type3'"), + EXPECT_EQUAL(Result(Result::ErrorType::PERMANENT_ERROR, "No handler for document type 'type3'"), f.engine.put(bucket1, tstamp1, doc3, context)); } @@ -477,7 +477,7 @@ TEST_F("require that puts are routed to handler", SimpleFixture) TEST_F("require that puts with old id scheme are rejected", SimpleFixture) { storage::spi::LoadType loadType(0, "default"); Context context(loadType, storage::spi::Priority(0), storage::spi::Trace::TraceLevel(0)); - EXPECT_EQUAL(Result(Result::PERMANENT_ERROR, "Old id scheme not supported in elastic mode (doc:old:id-scheme)"), + EXPECT_EQUAL(Result(Result::ErrorType::PERMANENT_ERROR, "Old id scheme not supported in elastic mode (doc:old:id-scheme)"), f.engine.put(bucket1, tstamp1, old_doc, context)); } @@ -490,7 +490,7 @@ TEST_F("require that put is rejected if resource limit is reached", SimpleFixtur storage::spi::LoadType loadType(0, "default"); Context context(loadType, storage::spi::Priority(0), storage::spi::Trace::TraceLevel(0)); EXPECT_EQUAL( - Result(Result::RESOURCE_EXHAUSTED, + Result(Result::ErrorType::RESOURCE_EXHAUSTED, "Put operation rejected for document 'doc:old:id-scheme': 'Disk is full'"), f.engine.put(bucket1, tstamp1, old_doc, context)); } @@ -512,7 +512,7 @@ TEST_F("require that updates are routed to handler", SimpleFixture) assertHandler(bucket1, tstamp1, docId2, f.hset.handler2); EXPECT_EQUAL(tstamp3, ur.getExistingTimestamp()); - EXPECT_EQUAL(Result(Result::PERMANENT_ERROR, "No handler for document type 'type3'"), + EXPECT_EQUAL(Result(Result::ErrorType::PERMANENT_ERROR, "No handler for document type 'type3'"), f.engine.update(bucket1, tstamp1, upd3, context)); } @@ -522,7 +522,7 @@ TEST_F("require that updates with old id scheme are rejected", SimpleFixture) storage::spi::LoadType loadType(0, "default"); Context context(loadType, storage::spi::Priority(0), storage::spi::Trace::TraceLevel(0)); - EXPECT_EQUAL(UpdateResult(Result::PERMANENT_ERROR, "Old id scheme not supported in elastic mode (doc:old:id-scheme)"), + EXPECT_EQUAL(UpdateResult(Result::ErrorType::PERMANENT_ERROR, "Old id scheme not supported in elastic mode (doc:old:id-scheme)"), f.engine.update(bucket1, tstamp1, old_upd, context)); } @@ -531,7 +531,7 @@ TEST_F("require that updates with bad ids are rejected", SimpleFixture) storage::spi::LoadType loadType(0, "default"); Context context(loadType, storage::spi::Priority(0), storage::spi::Trace::TraceLevel(0)); - EXPECT_EQUAL(UpdateResult(Result::PERMANENT_ERROR, "Update operation rejected due to bad id (id:type2:type2::1, type1)"), + EXPECT_EQUAL(UpdateResult(Result::ErrorType::PERMANENT_ERROR, "Update operation rejected due to bad id (id:type2:type2::1, type1)"), f.engine.update(bucket1, tstamp1, bad_id_upd, context)); } @@ -544,7 +544,7 @@ TEST_F("require that update is rejected if resource limit is reached", SimpleFix Context context(loadType, storage::spi::Priority(0), storage::spi::Trace::TraceLevel(0)); EXPECT_EQUAL( - Result(Result::RESOURCE_EXHAUSTED, + Result(Result::ErrorType::RESOURCE_EXHAUSTED, "Update operation rejected for document 'id:type1:type1::1': 'Disk is full'"), f.engine.update(bucket1, tstamp1, upd1, context)); } @@ -559,7 +559,7 @@ TEST_F("require that removes are routed to handlers", SimpleFixture) assertHandler(bucket0, tstamp0, docId0, f.hset.handler2); EXPECT_FALSE(rr.wasFound()); EXPECT_TRUE(rr.hasError()); - EXPECT_EQUAL(Result(Result::PERMANENT_ERROR, "No handler for document type 'type3'"), rr); + EXPECT_EQUAL(Result(Result::ErrorType::PERMANENT_ERROR, "No handler for document type 'type3'"), rr); f.hset.handler1.setExistingTimestamp(tstamp2); rr = f.engine.remove(bucket1, tstamp1, docId1, context); @@ -590,7 +590,7 @@ TEST_F("require that removes with old id scheme are rejected", SimpleFixture) storage::spi::LoadType loadType(0, "default"); Context context(loadType, storage::spi::Priority(0), storage::spi::Trace::TraceLevel(0)); - EXPECT_EQUAL(RemoveResult(Result::PERMANENT_ERROR, "Old id scheme not supported in elastic mode (doc:old:id-scheme)"), + EXPECT_EQUAL(RemoveResult(Result::ErrorType::PERMANENT_ERROR, "Old id scheme not supported in elastic mode (doc:old:id-scheme)"), f.engine.remove(bucket1, tstamp1, old_docId, context)); } @@ -626,11 +626,11 @@ TEST_F("require that setClusterState() is routed to handlers", SimpleFixture) TEST_F("require that setActiveState() is routed to handlers and merged", SimpleFixture) { - f.hset.handler1.bucketStateResult = Result(Result::TRANSIENT_ERROR, "err1"); - f.hset.handler2.bucketStateResult = Result(Result::PERMANENT_ERROR, "err2"); + f.hset.handler1.bucketStateResult = Result(Result::ErrorType::TRANSIENT_ERROR, "err1"); + f.hset.handler2.bucketStateResult = Result(Result::ErrorType::PERMANENT_ERROR, "err2"); Result result = f.engine.setActiveState(bucket1, storage::spi::BucketInfo::NOT_ACTIVE); - EXPECT_EQUAL(Result::PERMANENT_ERROR, result.getErrorCode()); + EXPECT_EQUAL(Result::ErrorType::PERMANENT_ERROR, result.getErrorCode()); EXPECT_EQUAL("err1, err2", result.getErrorMessage()); EXPECT_EQUAL(storage::spi::BucketInfo::NOT_ACTIVE, f.hset.handler1.lastBucketState); EXPECT_EQUAL(storage::spi::BucketInfo::NOT_ACTIVE, f.hset.handler2.lastBucketState); @@ -655,11 +655,11 @@ TEST_F("require that createBucket() is routed to handlers and merged", SimpleFix { storage::spi::LoadType loadType(0, "default"); Context context(loadType, storage::spi::Priority(0), storage::spi::Trace::TraceLevel(0)); - f.hset.handler1._createBucketResult = Result(Result::TRANSIENT_ERROR, "err1a"); - f.hset.handler2._createBucketResult = Result(Result::PERMANENT_ERROR, "err2a"); + f.hset.handler1._createBucketResult = Result(Result::ErrorType::TRANSIENT_ERROR, "err1a"); + f.hset.handler2._createBucketResult = Result(Result::ErrorType::PERMANENT_ERROR, "err2a"); Result result = f.engine.createBucket(bucket1, context); - EXPECT_EQUAL(Result::PERMANENT_ERROR, result.getErrorCode()); + EXPECT_EQUAL(Result::ErrorType::PERMANENT_ERROR, result.getErrorCode()); EXPECT_EQUAL("err1a, err2a", result.getErrorMessage()); } @@ -668,11 +668,11 @@ TEST_F("require that deleteBucket() is routed to handlers and merged", SimpleFix { storage::spi::LoadType loadType(0, "default"); Context context(loadType, storage::spi::Priority(0), storage::spi::Trace::TraceLevel(0)); - f.hset.handler1.deleteBucketResult = Result(Result::TRANSIENT_ERROR, "err1"); - f.hset.handler2.deleteBucketResult = Result(Result::PERMANENT_ERROR, "err2"); + f.hset.handler1.deleteBucketResult = Result(Result::ErrorType::TRANSIENT_ERROR, "err1"); + f.hset.handler2.deleteBucketResult = Result(Result::ErrorType::PERMANENT_ERROR, "err2"); Result result = f.engine.deleteBucket(bucket1, context); - EXPECT_EQUAL(Result::PERMANENT_ERROR, result.getErrorCode()); + EXPECT_EQUAL(Result::ErrorType::PERMANENT_ERROR, result.getErrorCode()); EXPECT_EQUAL("err1, err2", result.getErrorMessage()); } @@ -754,7 +754,7 @@ TEST_F("require that iterate requires valid iterator", SimpleFixture) { Context context(loadType, storage::spi::Priority(0), storage::spi::Trace::TraceLevel(0)); IterateResult it_result = f.engine.iterate(IteratorId(1), max_size, context); EXPECT_TRUE(it_result.hasError()); - EXPECT_EQUAL(Result::PERMANENT_ERROR, it_result.getErrorCode()); + EXPECT_EQUAL(Result::ErrorType::PERMANENT_ERROR, it_result.getErrorCode()); EXPECT_EQUAL("Unknown iterator with id 1", it_result.getErrorMessage()); CreateIteratorResult result = @@ -799,7 +799,7 @@ TEST_F("require that destroyIterator prevents iteration", SimpleFixture) { uint64_t max_size = 1024; IterateResult it_result = f.engine.iterate(create_result.getIteratorId(), max_size, context); EXPECT_TRUE(it_result.hasError()); - EXPECT_EQUAL(Result::PERMANENT_ERROR, it_result.getErrorCode()); + EXPECT_EQUAL(Result::ErrorType::PERMANENT_ERROR, it_result.getErrorCode()); string msg_prefix = "Unknown iterator with id"; EXPECT_EQUAL(msg_prefix, it_result.getErrorMessage().substr(0, msg_prefix.size())); } diff --git a/searchcore/src/vespa/searchcore/proton/persistenceengine/persistenceengine.cpp b/searchcore/src/vespa/searchcore/proton/persistenceengine/persistenceengine.cpp index 57e26f77cca..1f862b07048 100644 --- a/searchcore/src/vespa/searchcore/proton/persistenceengine/persistenceengine.cpp +++ b/searchcore/src/vespa/searchcore/proton/persistenceengine/persistenceengine.cpp @@ -325,7 +325,7 @@ PersistenceEngine::put(const Bucket& b, Timestamp t, const document::Document::S if (!_writeFilter.acceptWriteOperation()) { IResourceWriteFilter::State state = _writeFilter.getAcceptState(); if (!state.acceptWriteOperation()) { - return Result(Result::RESOURCE_EXHAUSTED, + return Result(Result::ErrorType::RESOURCE_EXHAUSTED, make_string("Put operation rejected for document '%s': '%s'", doc->getId().toString().c_str(), state.message().c_str())); } @@ -335,12 +335,12 @@ PersistenceEngine::put(const Bucket& b, Timestamp t, const document::Document::S LOG(spam, "put(%s, %" PRIu64 ", (\"%s\", \"%s\"))", b.toString().c_str(), static_cast<uint64_t>(t.getValue()), docType.toString().c_str(), doc->getId().toString().c_str()); if (!doc->getId().hasDocType()) { - return Result(Result::PERMANENT_ERROR, + return Result(Result::ErrorType::PERMANENT_ERROR, make_string("Old id scheme not supported in elastic mode (%s)", doc->getId().toString().c_str())); } IPersistenceHandler::SP handler = getHandler(b.getBucketSpace(), docType); if (!handler) { - return Result(Result::PERMANENT_ERROR, + return Result(Result::ErrorType::PERMANENT_ERROR, make_string("No handler for document type '%s'", docType.toString().c_str())); } TransportLatch latch(1); @@ -356,13 +356,13 @@ PersistenceEngine::remove(const Bucket& b, Timestamp t, const DocumentId& did, C LOG(spam, "remove(%s, %" PRIu64 ", \"%s\")", b.toString().c_str(), static_cast<uint64_t>(t.getValue()), did.toString().c_str()); if (!did.hasDocType()) { - return RemoveResult(Result::PERMANENT_ERROR, + return RemoveResult(Result::ErrorType::PERMANENT_ERROR, make_string("Old id scheme not supported in elastic mode (%s)", did.toString().c_str())); } DocTypeName docType(did.getDocType()); IPersistenceHandler::SP handler = getHandler(b.getBucketSpace(), docType); if (!handler) { - return RemoveResult(Result::PERMANENT_ERROR, + return RemoveResult(Result::ErrorType::PERMANENT_ERROR, make_string("No handler for document type '%s'", docType.toString().c_str())); } TransportLatch latch(1); @@ -378,7 +378,7 @@ PersistenceEngine::update(const Bucket& b, Timestamp t, const DocumentUpdate::SP if (!_writeFilter.acceptWriteOperation()) { IResourceWriteFilter::State state = _writeFilter.getAcceptState(); if (!state.acceptWriteOperation()) { - return UpdateResult(Result::RESOURCE_EXHAUSTED, + return UpdateResult(Result::ErrorType::RESOURCE_EXHAUSTED, make_string("Update operation rejected for document '%s': '%s'", upd->getId().toString().c_str(), state.message().c_str())); } @@ -386,16 +386,16 @@ PersistenceEngine::update(const Bucket& b, Timestamp t, const DocumentUpdate::SP try { upd->eagerDeserialize(); } catch (document::FieldNotFoundException & e) { - return UpdateResult(Result::TRANSIENT_ERROR, + return UpdateResult(Result::ErrorType::TRANSIENT_ERROR, make_string("Update operation rejected for document '%s' of type '%s': 'Field not found'", upd->getId().toString().c_str(), upd->getType().getName().c_str())); } catch (document::DocumentTypeNotFoundException & e) { - return UpdateResult(Result::TRANSIENT_ERROR, + return UpdateResult(Result::ErrorType::TRANSIENT_ERROR, make_string("Update operation rejected for document '%s' of type '%s'.", upd->getId().toString().c_str(), e.getDocumentTypeName().c_str())); } catch (document::WrongTensorTypeException &e) { - return UpdateResult(Result::TRANSIENT_ERROR, + return UpdateResult(Result::ErrorType::TRANSIENT_ERROR, make_string("Update operation rejected for document '%s' of type '%s': 'Wrong tensor type: %s'", upd->getId().toString().c_str(), upd->getType().getName().c_str(), @@ -407,11 +407,11 @@ PersistenceEngine::update(const Bucket& b, Timestamp t, const DocumentUpdate::SP b.toString().c_str(), static_cast<uint64_t>(t.getValue()), docType.toString().c_str(), upd->getId().toString().c_str(), (upd->getCreateIfNonExistent() ? "true" : "false")); if (!upd->getId().hasDocType()) { - return UpdateResult(Result::PERMANENT_ERROR, + return UpdateResult(Result::ErrorType::PERMANENT_ERROR, make_string("Old id scheme not supported in elastic mode (%s)", upd->getId().toString().c_str())); } if (upd->getId().getDocType() != docType.getName()) { - return UpdateResult(Result::PERMANENT_ERROR, + return UpdateResult(Result::ErrorType::PERMANENT_ERROR, make_string("Update operation rejected due to bad id (%s, %s)", upd->getId().toString().c_str(), docType.getName().c_str())); } IPersistenceHandler::SP handler = getHandler(b.getBucketSpace(), docType); @@ -423,7 +423,7 @@ PersistenceEngine::update(const Bucket& b, Timestamp t, const DocumentUpdate::SP latch.await(); return latch.getUpdateResult(); } else { - return UpdateResult(Result::PERMANENT_ERROR, make_string("No handler for document type '%s'", docType.toString().c_str())); + return UpdateResult(Result::ErrorType::PERMANENT_ERROR, make_string("No handler for document type '%s'", docType.toString().c_str())); } } @@ -493,11 +493,11 @@ PersistenceEngine::iterate(IteratorId id, uint64_t maxByteSize, Context&) const std::lock_guard<std::mutex> guard(_iterators_lock); auto it = _iterators.find(id); if (it == _iterators.end()) { - return IterateResult(Result::PERMANENT_ERROR, make_string("Unknown iterator with id %" PRIu64, id.getValue())); + return IterateResult(Result::ErrorType::PERMANENT_ERROR, make_string("Unknown iterator with id %" PRIu64, id.getValue())); } iteratorEntry = it->second; if (iteratorEntry->in_use) { - return IterateResult(Result::TRANSIENT_ERROR, make_string("Iterator with id %" PRIu64 " is already in use", id.getValue())); + return IterateResult(Result::ErrorType::TRANSIENT_ERROR, make_string("Iterator with id %" PRIu64 " is already in use", id.getValue())); } iteratorEntry->in_use = true; } @@ -509,7 +509,7 @@ PersistenceEngine::iterate(IteratorId id, uint64_t maxByteSize, Context&) const iteratorEntry->in_use = false; return result; } catch (const std::exception & e) { - IterateResult result(Result::PERMANENT_ERROR, make_string("Caught exception during visitor iterator.iterate() = '%s'", e.what())); + IterateResult result(Result::ErrorType::PERMANENT_ERROR, make_string("Caught exception during visitor iterator.iterate() = '%s'", e.what())); LOG(warning, "Caught exception during visitor iterator.iterate() = '%s'", e.what()); std::lock_guard<std::mutex> guard(_iterators_lock); iteratorEntry->in_use = false; @@ -528,7 +528,7 @@ PersistenceEngine::destroyIterator(IteratorId id, Context&) return Result(); } if (it->second->in_use) { - return Result(Result::TRANSIENT_ERROR, make_string("Iterator with id %" PRIu64 " is currently in use", id.getValue())); + return Result(Result::ErrorType::TRANSIENT_ERROR, make_string("Iterator with id %" PRIu64 " is currently in use", id.getValue())); } delete it->second; _iterators.erase(it); diff --git a/searchcore/src/vespa/searchcore/proton/server/buckethandler.cpp b/searchcore/src/vespa/searchcore/proton/server/buckethandler.cpp index af9038cba66..1d3b2165c80 100644 --- a/searchcore/src/vespa/searchcore/proton/server/buckethandler.cpp +++ b/searchcore/src/vespa/searchcore/proton/server/buckethandler.cpp @@ -26,7 +26,7 @@ BucketHandler::performSetCurrentState(BucketId bucketId, IGenericResultHandler *resultHandler) { if (!_nodeUp) { - Result result(Result::TRANSIENT_ERROR, + Result result(Result::ErrorType::TRANSIENT_ERROR, "Cannot set bucket active state when node is down"); resultHandler->handle(result); return; diff --git a/searchcore/src/vespa/searchcore/proton/server/feedhandler.cpp b/searchcore/src/vespa/searchcore/proton/server/feedhandler.cpp index fd38b74f584..338fc738040 100644 --- a/searchcore/src/vespa/searchcore/proton/server/feedhandler.cpp +++ b/searchcore/src/vespa/searchcore/proton/server/feedhandler.cpp @@ -476,7 +476,7 @@ void feedOperationRejected(FeedToken & token, const vespalib::string &opType, co if (token) { auto message = make_string("%s operation rejected for document '%s' of type '%s': '%s'", opType.c_str(), docId.c_str(), docTypeName.toString().c_str(), rejectMessage.c_str()); - token->setResult(make_unique<ResultType>(Result::RESOURCE_EXHAUSTED, message), false); + token->setResult(make_unique<ResultType>(Result::ErrorType::RESOURCE_EXHAUSTED, message), false); token->fail(); } } @@ -527,7 +527,7 @@ FeedHandler::considerUpdateOperationForRejection(FeedToken &token, UpdateOperati if (token) { auto message = make_string("Update operation rejected for document '%s' of type '%s': 'Field not found'", update.getId().toString().c_str(), _docTypeName.toString().c_str()); - token->setResult(make_unique<UpdateResult>(Result::TRANSIENT_ERROR, message), false); + token->setResult(make_unique<UpdateResult>(Result::ErrorType::TRANSIENT_ERROR, message), false); token->fail(); } return true; @@ -536,7 +536,7 @@ FeedHandler::considerUpdateOperationForRejection(FeedToken &token, UpdateOperati update.getId().toString().c_str(), e.getDocumentTypeName().c_str(), _docTypeName.toString().c_str()); - token->setResult(make_unique<UpdateResult>(Result::TRANSIENT_ERROR, message), false); + token->setResult(make_unique<UpdateResult>(Result::ErrorType::TRANSIENT_ERROR, message), false); token->fail(); return true; } catch (document::WrongTensorTypeException &e) { @@ -544,7 +544,7 @@ FeedHandler::considerUpdateOperationForRejection(FeedToken &token, UpdateOperati update.getId().toString().c_str(), _docTypeName.toString().c_str(), e.getMessage().c_str()); - token->setResult(make_unique<UpdateResult>(Result::TRANSIENT_ERROR, message), false); + token->setResult(make_unique<UpdateResult>(Result::ErrorType::TRANSIENT_ERROR, message), false); token->fail(); return true; } |