From 499adf847db401d368d6611b2ec46014568b87dd Mon Sep 17 00:00:00 2001 From: Lenar Fatikhov Date: Fri, 15 Nov 2024 09:54:12 -0800 Subject: [PATCH] for SETs via DL, compare write timestamp with existing item creation time Summary: as title Reviewed By: stuclar Differential Revision: D65797021 fbshipit-source-id: 4e48c7d03837e345176dd794c52abbdf9948c5a1 --- mcrouter/lib/carbon/RequestCommon.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/mcrouter/lib/carbon/RequestCommon.h b/mcrouter/lib/carbon/RequestCommon.h index 609db44e1..498b73df5 100644 --- a/mcrouter/lib/carbon/RequestCommon.h +++ b/mcrouter/lib/carbon/RequestCommon.h @@ -102,10 +102,14 @@ class RequestCommon : public MessageCommon { sourceIpAddr_ = sourceIpAddr; } - void setWriteTimestamp(uint64_t writeTimestamp) noexcept { + void setWriteTimestampNs(uint64_t writeTimestamp) noexcept { writeTimestamp_ = writeTimestamp; } + std::optional getWriteTimestampNs() const noexcept { + return writeTimestamp_; + } + protected: void markBufferAsDirty() { serializedBuffer_ = nullptr;