aboutsummaryrefslogtreecommitdiffstats
path: root/storage/src/vespa/storage/persistence/mergehandler.h
diff options
context:
space:
mode:
Diffstat (limited to 'storage/src/vespa/storage/persistence/mergehandler.h')
-rw-r--r--storage/src/vespa/storage/persistence/mergehandler.h44
1 files changed, 13 insertions, 31 deletions
diff --git a/storage/src/vespa/storage/persistence/mergehandler.h b/storage/src/vespa/storage/persistence/mergehandler.h
index 0f9f01b4cb1..f3bef802229 100644
--- a/storage/src/vespa/storage/persistence/mergehandler.h
+++ b/storage/src/vespa/storage/persistence/mergehandler.h
@@ -51,26 +51,17 @@ public:
MergeHandler(PersistenceUtil& env, spi::PersistenceProvider& spi,
const ClusterContext& cluster_context, const framework::Clock & clock,
vespalib::ISequencedTaskExecutor& executor,
- uint32_t maxChunkSize = 4190208,
- uint32_t commonMergeChainOptimalizationMinimumSize = 64);
+ uint32_t maxChunkSize = 4190208);
~MergeHandler() override;
- bool buildBucketInfoList(
- const spi::Bucket& bucket,
- Timestamp maxTimestamp,
- uint8_t myNodeIndex,
- std::vector<api::GetBucketDiffCommand::Entry>& output,
- spi::Context& context) const;
- void fetchLocalData(const spi::Bucket& bucket,
- std::vector<api::ApplyBucketDiffCommand::Entry>& diff,
- uint8_t nodeIndex,
- spi::Context& context) const;
- void applyDiffLocally(const spi::Bucket& bucket,
- std::vector<api::ApplyBucketDiffCommand::Entry>& diff,
- uint8_t nodeIndex,
- spi::Context& context,
- std::shared_ptr<ApplyBucketDiffState> async_results) const;
+ bool buildBucketInfoList(const spi::Bucket& bucket, Timestamp maxTimestamp, uint8_t myNodeIndex,
+ std::vector<api::GetBucketDiffCommand::Entry>& output, spi::Context& context) const;
+ void fetchLocalData(const spi::Bucket& bucket, std::vector<api::ApplyBucketDiffCommand::Entry>& diff,
+ uint8_t nodeIndex, spi::Context& context) const;
+ void applyDiffLocally(const spi::Bucket& bucket, std::vector<api::ApplyBucketDiffCommand::Entry>& diff,
+ uint8_t nodeIndex, spi::Context& context,
+ const std::shared_ptr<ApplyBucketDiffState> & async_results) const;
void sync_bucket_info(const spi::Bucket& bucket) const override;
void schedule_delayed_delete(std::unique_ptr<ApplyBucketDiffState>) const override;
@@ -89,35 +80,26 @@ private:
spi::PersistenceProvider &_spi;
std::unique_ptr<vespalib::MonitoredRefCount> _monitored_ref_count;
const uint32_t _maxChunkSize;
- const uint32_t _commonMergeChainOptimalizationMinimumSize;
vespalib::ISequencedTaskExecutor& _executor;
MessageTrackerUP handleGetBucketDiffStage2(api::GetBucketDiffCommand&, MessageTrackerUP) const;
/** Returns a reply if merge is complete */
- api::StorageReply::SP processBucketMerge(const spi::Bucket& bucket,
- MergeStatus& status,
- MessageSender& sender,
- spi::Context& context,
- std::shared_ptr<ApplyBucketDiffState>& async_results) const;
+ api::StorageReply::SP processBucketMerge(const spi::Bucket& bucket, MergeStatus& status, MessageSender& sender,
+ spi::Context& context, std::shared_ptr<ApplyBucketDiffState>& async_results) const;
/**
* Invoke either put, remove or unrevertable remove on the SPI
* depending on the flags in the diff entry.
*/
- void applyDiffEntry(std::shared_ptr<ApplyBucketDiffState> async_results,
- const spi::Bucket&,
- const api::ApplyBucketDiffCommand::Entry&,
- const document::DocumentTypeRepo& repo) const;
+ void applyDiffEntry(std::shared_ptr<ApplyBucketDiffState> async_results, const spi::Bucket&,
+ const api::ApplyBucketDiffCommand::Entry&, const document::DocumentTypeRepo& repo) const;
/**
* Fill entries-vector with metadata for bucket up to maxTimestamp,
* sorted ascendingly on entry timestamp.
* Throws std::runtime_error upon iteration failure.
*/
- void populateMetaData(const spi::Bucket&,
- Timestamp maxTimestamp,
- DocEntryList & entries,
- spi::Context& context) const;
+ void populateMetaData(const spi::Bucket&, Timestamp maxTimestamp, DocEntryList & entries, spi::Context& context) const;
std::unique_ptr<document::Document>
deserializeDiffDocument(const api::ApplyBucketDiffCommand::Entry& e, const document::DocumentTypeRepo& repo) const;