diff options
Diffstat (limited to 'storage/src/vespa/storage/storageserver/communicationmanager.cpp')
-rw-r--r-- | storage/src/vespa/storage/storageserver/communicationmanager.cpp | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/storage/src/vespa/storage/storageserver/communicationmanager.cpp b/storage/src/vespa/storage/storageserver/communicationmanager.cpp index 5a1c2aed113..7fb85ef0ecc 100644 --- a/storage/src/vespa/storage/storageserver/communicationmanager.cpp +++ b/storage/src/vespa/storage/storageserver/communicationmanager.cpp @@ -259,16 +259,8 @@ void CommunicationManager::fail_with_unresolvable_bucket_space( LOG(debug, "Could not map DocumentAPI message to internal bucket: %s", error_message.c_str()); MBUS_TRACE(msg->getTrace(), 6, "Communication manager: Failing message as its document type has no known bucket space mapping"); std::unique_ptr<mbus::Reply> reply; - if (msg->getType() == documentapi::DocumentProtocol::MESSAGE_GETDOCUMENT) { - // HACK: to avoid breaking legacy routing of GetDocumentMessages to _all_ clusters - // regardless of them having a document type or not, we remap missing bucket spaces - // to explicit Not Found replies (empty document GetDocumentReply). - // TODO remove this workaround for Vespa 7 - reply = std::make_unique<documentapi::GetDocumentReply>(std::shared_ptr<document::Document>()); - } else { - reply = std::make_unique<mbus::EmptyReply>(); - reply->addError(mbus::Error(documentapi::DocumentProtocol::ERROR_REJECTED, error_message)); - } + reply = std::make_unique<mbus::EmptyReply>(); + reply->addError(mbus::Error(documentapi::DocumentProtocol::ERROR_REJECTED, error_message)); msg->swapState(*reply); _metrics.bucketSpaceMappingFailures.inc(); _messageBusSession->reply(std::move(reply)); |