diff options
author | Tor Egge <Tor.Egge@broadpark.no> | 2020-10-20 16:56:16 +0200 |
---|---|---|
committer | Tor Egge <Tor.Egge@broadpark.no> | 2020-10-20 16:56:16 +0200 |
commit | 289c9ac6e517a2eef2c6510147683a65313e62df (patch) | |
tree | 40908d77a5a3ed1656186a3086c1d4f7e794be7d /storage | |
parent | 0708959b560d9a9aea18e665bc920961e5c6d52f (diff) |
Remove storage::spi::PartitionId type.
Diffstat (limited to 'storage')
-rw-r--r-- | storage/src/vespa/storage/common/bucketmessages.cpp | 10 | ||||
-rw-r--r-- | storage/src/vespa/storage/common/bucketmessages.h | 6 | ||||
-rw-r--r-- | storage/src/vespa/storage/persistence/simplemessagehandler.cpp | 1 |
3 files changed, 5 insertions, 12 deletions
diff --git a/storage/src/vespa/storage/common/bucketmessages.cpp b/storage/src/vespa/storage/common/bucketmessages.cpp index d7f75f12013..51c6af8ea5f 100644 --- a/storage/src/vespa/storage/common/bucketmessages.cpp +++ b/storage/src/vespa/storage/common/bucketmessages.cpp @@ -8,10 +8,9 @@ using document::BucketSpace; namespace storage { -ReadBucketList::ReadBucketList(BucketSpace bucketSpace, spi::PartitionId partition) +ReadBucketList::ReadBucketList(BucketSpace bucketSpace) : api::InternalCommand(ID), - _bucketSpace(bucketSpace), - _partition(partition) + _bucketSpace(bucketSpace) { } ReadBucketList::~ReadBucketList() = default; @@ -24,7 +23,7 @@ ReadBucketList::getBucket() const void ReadBucketList::print(std::ostream& out, bool verbose, const std::string& indent) const { - out << "ReadBucketList(" << _partition << ")"; + out << "ReadBucketList()"; if (verbose) { out << " : "; @@ -34,8 +33,7 @@ ReadBucketList::print(std::ostream& out, bool verbose, const std::string& indent ReadBucketListReply::ReadBucketListReply(const ReadBucketList& cmd) : api::InternalReply(ID, cmd), - _bucketSpace(cmd.getBucketSpace()), - _partition(cmd.getPartition()) + _bucketSpace(cmd.getBucketSpace()) { } ReadBucketListReply::~ReadBucketListReply() = default; diff --git a/storage/src/vespa/storage/common/bucketmessages.h b/storage/src/vespa/storage/common/bucketmessages.h index b0dfa35fbd1..428b5268293 100644 --- a/storage/src/vespa/storage/common/bucketmessages.h +++ b/storage/src/vespa/storage/common/bucketmessages.h @@ -15,16 +15,14 @@ namespace storage { */ class ReadBucketList : public api::InternalCommand { document::BucketSpace _bucketSpace; - spi::PartitionId _partition; public: typedef std::unique_ptr<ReadBucketList> UP; static const uint32_t ID = 2003; - ReadBucketList(document::BucketSpace bucketSpace, spi::PartitionId partition); + ReadBucketList(document::BucketSpace bucketSpace); ~ReadBucketList(); document::BucketSpace getBucketSpace() const { return _bucketSpace; } - spi::PartitionId getPartition() const { return _partition; } document::Bucket getBucket() const override; std::unique_ptr<api::StorageReply> makeReply() override; @@ -39,7 +37,6 @@ public: */ class ReadBucketListReply : public api::InternalReply { document::BucketSpace _bucketSpace; - spi::PartitionId _partition; spi::BucketIdListResult::List _buckets; public: @@ -51,7 +48,6 @@ public: ~ReadBucketListReply(); document::BucketSpace getBucketSpace() const { return _bucketSpace; } - spi::PartitionId getPartition() const { return _partition; } document::Bucket getBucket() const override; spi::BucketIdListResult::List& getBuckets() { return _buckets; } diff --git a/storage/src/vespa/storage/persistence/simplemessagehandler.cpp b/storage/src/vespa/storage/persistence/simplemessagehandler.cpp index e2e98dbd84d..d3acf3b2c81 100644 --- a/storage/src/vespa/storage/persistence/simplemessagehandler.cpp +++ b/storage/src/vespa/storage/persistence/simplemessagehandler.cpp @@ -202,7 +202,6 @@ SimpleMessageHandler::handleReadBucketList(ReadBucketList& cmd, MessageTracker:: { tracker->setMetric(_env._metrics.readBucketList); - assert(cmd.getPartition() == 0u); spi::BucketIdListResult result(_spi.listBuckets(cmd.getBucketSpace())); if (tracker->checkForError(result)) { auto reply = std::make_shared<ReadBucketListReply>(cmd); |