summaryrefslogtreecommitdiffstats
path: root/storageapi/src/vespa/storageapi/mbusprot/protocolserialization7.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'storageapi/src/vespa/storageapi/mbusprot/protocolserialization7.cpp')
-rw-r--r--storageapi/src/vespa/storageapi/mbusprot/protocolserialization7.cpp15
1 files changed, 5 insertions, 10 deletions
diff --git a/storageapi/src/vespa/storageapi/mbusprot/protocolserialization7.cpp b/storageapi/src/vespa/storageapi/mbusprot/protocolserialization7.cpp
index b356ce59999..98f76b4afb7 100644
--- a/storageapi/src/vespa/storageapi/mbusprot/protocolserialization7.cpp
+++ b/storageapi/src/vespa/storageapi/mbusprot/protocolserialization7.cpp
@@ -14,11 +14,9 @@
namespace storage::mbusprot {
-ProtocolSerialization7::ProtocolSerialization7(std::shared_ptr<const document::DocumentTypeRepo> repo,
- const documentapi::LoadTypeSet& load_types)
+ProtocolSerialization7::ProtocolSerialization7(std::shared_ptr<const document::DocumentTypeRepo> repo)
: ProtocolSerialization(),
- _repo(std::move(repo)),
- _load_types(load_types)
+ _repo(std::move(repo))
{
}
@@ -113,7 +111,6 @@ void write_request_header(vespalib::GrowableByteBuffer& buf, const api::StorageC
hdr.set_message_id(cmd.getMsgId());
hdr.set_priority(cmd.getPriority());
hdr.set_source_index(cmd.getSourceIndex());
- hdr.set_loadtype_id(cmd.getLoadType().getId());
uint8_t dest[128]; // Only primitive fields, should be plenty large enough.
auto encoded_size = static_cast<uint32_t>(hdr.ByteSizeLong());
@@ -232,12 +229,10 @@ class RequestDecoder {
protobuf::RequestHeader _hdr;
::google::protobuf::Arena _arena;
ProtobufType* _proto_obj;
- const documentapi::LoadTypeSet& _load_types;
public:
- RequestDecoder(document::ByteBuffer& in_buf, const documentapi::LoadTypeSet& load_types)
+ RequestDecoder(document::ByteBuffer& in_buf)
: _arena(),
- _proto_obj(::google::protobuf::Arena::Create<ProtobufType>(&_arena)),
- _load_types(load_types)
+ _proto_obj(::google::protobuf::Arena::Create<ProtobufType>(&_arena))
{
decode_request_header(in_buf, _hdr);
assert(in_buf.getRemaining() <= INT_MAX);
@@ -308,7 +303,7 @@ void encode_response(vespalib::GrowableByteBuffer& out_buf, const api::StorageRe
template <typename ProtobufType, typename Func>
std::unique_ptr<api::StorageCommand>
ProtocolSerialization7::decode_request(document::ByteBuffer& in_buf, Func&& f) const {
- RequestDecoder<ProtobufType> dec(in_buf, _load_types);
+ RequestDecoder<ProtobufType> dec(in_buf);
const auto& req = dec.request();
auto cmd = f(req);
dec.transfer_meta_information_to(*cmd);