diff options
Diffstat (limited to 'zenserver/upstream')
| -rw-r--r-- | zenserver/upstream/upstreamcache.cpp | 18 | ||||
| -rw-r--r-- | zenserver/upstream/upstreamcache.h | 20 | ||||
| -rw-r--r-- | zenserver/upstream/zen.cpp | 2 | ||||
| -rw-r--r-- | zenserver/upstream/zen.h | 2 |
4 files changed, 21 insertions, 21 deletions
diff --git a/zenserver/upstream/upstreamcache.cpp b/zenserver/upstream/upstreamcache.cpp index 8288b910d..6976e5bed 100644 --- a/zenserver/upstream/upstreamcache.cpp +++ b/zenserver/upstream/upstreamcache.cpp @@ -346,9 +346,9 @@ namespace detail { return Result; } - virtual GetUpstreamCacheResult GetCacheValue(std::string_view Namespace, const CacheKey&, const IoHash& ValueContentId) override + virtual GetUpstreamCacheResult GetCacheChunk(std::string_view Namespace, const CacheKey&, const IoHash& ValueContentId) override { - ZEN_TRACE_CPU("Upstream::Horde::GetSingleCacheValue"); + ZEN_TRACE_CPU("Upstream::Horde::GetSingleCacheChunk"); try { @@ -913,16 +913,16 @@ namespace detail { return {.Error{.ErrorCode = Result.ErrorCode, .Reason = std::move(Result.Reason)}}; } - virtual GetUpstreamCacheResult GetCacheValue(std::string_view Namespace, + virtual GetUpstreamCacheResult GetCacheChunk(std::string_view Namespace, const CacheKey& CacheKey, const IoHash& ValueContentId) override { - ZEN_TRACE_CPU("Upstream::Zen::GetCacheValue"); + ZEN_TRACE_CPU("Upstream::Zen::GetCacheChunk"); try { ZenStructuredCacheSession Session(GetClientRef()); - const ZenCacheResult Result = Session.GetCacheValue(Namespace, CacheKey.Bucket, CacheKey.Hash, ValueContentId); + const ZenCacheResult Result = Session.GetCacheChunk(Namespace, CacheKey.Bucket, CacheKey.Hash, ValueContentId); m_Status.SetFromErrorCode(Result.ErrorCode, Result.Reason); @@ -1642,11 +1642,11 @@ public: } } - virtual GetUpstreamCacheResult GetCacheValue(std::string_view Namespace, + virtual GetUpstreamCacheResult GetCacheChunk(std::string_view Namespace, const CacheKey& CacheKey, const IoHash& ValueContentId) override { - ZEN_TRACE_CPU("Upstream::GetCacheValue"); + ZEN_TRACE_CPU("Upstream::GetCacheChunk"); if (m_Options.ReadUpstream) { @@ -1662,7 +1662,7 @@ public: { metrics::OperationTiming::Scope Scope(Stats.CacheGetRequestTiming); - Result = Endpoint->GetCacheValue(Namespace, CacheKey, ValueContentId); + Result = Endpoint->GetCacheChunk(Namespace, CacheKey, ValueContentId); } Stats.CacheGetCount.Increment(1); @@ -1679,7 +1679,7 @@ public: { Stats.CacheErrorCount.Increment(1); - ZEN_WARN("get cache value FAILED, endpoint '{}', reason '{}', error code '{}'", + ZEN_WARN("get cache chunk FAILED, endpoint '{}', reason '{}', error code '{}'", Endpoint->GetEndpointInfo().Url, Result.Error.Reason, Result.Error.ErrorCode); diff --git a/zenserver/upstream/upstreamcache.h b/zenserver/upstream/upstreamcache.h index 5b154a1b5..4a4bede0f 100644 --- a/zenserver/upstream/upstreamcache.h +++ b/zenserver/upstream/upstreamcache.h @@ -179,14 +179,14 @@ public: std::span<CacheKeyRequest*> Requests, OnCacheRecordGetComplete&& OnComplete) = 0; - virtual GetUpstreamCacheResult GetCacheValue(std::string_view Namespace, const CacheKey& CacheKey, const IoHash& PayloadId) = 0; virtual GetUpstreamCacheResult GetCacheValues(std::string_view Namespace, std::span<CacheValueRequest*> CacheValueRequests, - OnCacheValueGetComplete&& OnComplete) = 0; + OnCacheValueGetComplete&& OnComplete) = 0; + virtual GetUpstreamCacheResult GetCacheChunk(std::string_view Namespace, const CacheKey& CacheKey, const IoHash& PayloadId) = 0; virtual GetUpstreamCacheResult GetCacheChunks(std::string_view Namespace, std::span<CacheChunkRequest*> CacheChunkRequests, - OnCacheChunksGetComplete&& OnComplete) = 0; + OnCacheChunksGetComplete&& OnComplete) = 0; virtual PutUpstreamCacheResult PutCacheRecord(const UpstreamCacheRecord& CacheRecord, IoBuffer RecordValue, @@ -219,14 +219,14 @@ public: std::span<CacheKeyRequest*> Requests, OnCacheRecordGetComplete&& OnComplete) = 0; - virtual GetUpstreamCacheResult GetCacheValue(std::string_view Namespace, const CacheKey& CacheKey, const IoHash& ValueContentId) = 0; - virtual void GetCacheValues(std::string_view Namespace, - std::span<CacheValueRequest*> CacheValueRequests, - OnCacheValueGetComplete&& OnComplete) = 0; + virtual void GetCacheValues(std::string_view Namespace, + std::span<CacheValueRequest*> CacheValueRequests, + OnCacheValueGetComplete&& OnComplete) = 0; - virtual void GetCacheChunks(std::string_view Namespace, - std::span<CacheChunkRequest*> CacheChunkRequests, - OnCacheChunksGetComplete&& OnComplete) = 0; + virtual GetUpstreamCacheResult GetCacheChunk(std::string_view Namespace, const CacheKey& CacheKey, const IoHash& ValueContentId) = 0; + virtual void GetCacheChunks(std::string_view Namespace, + std::span<CacheChunkRequest*> CacheChunkRequests, + OnCacheChunksGetComplete&& OnComplete) = 0; virtual void EnqueueUpstream(UpstreamCacheRecord CacheRecord) = 0; diff --git a/zenserver/upstream/zen.cpp b/zenserver/upstream/zen.cpp index b837f767c..980958740 100644 --- a/zenserver/upstream/zen.cpp +++ b/zenserver/upstream/zen.cpp @@ -437,7 +437,7 @@ ZenStructuredCacheSession::GetCacheRecord(std::string_view Namespace, std::strin } ZenCacheResult -ZenStructuredCacheSession::GetCacheValue(std::string_view Namespace, +ZenStructuredCacheSession::GetCacheChunk(std::string_view Namespace, std::string_view BucketId, const IoHash& Key, const IoHash& ValueContentId) diff --git a/zenserver/upstream/zen.h b/zenserver/upstream/zen.h index 955cfa107..9a082ebc9 100644 --- a/zenserver/upstream/zen.h +++ b/zenserver/upstream/zen.h @@ -129,7 +129,7 @@ public: ZenCacheResult CheckHealth(); ZenCacheResult GetCacheRecord(std::string_view Namespace, std::string_view BucketId, const IoHash& Key, ZenContentType Type); - ZenCacheResult GetCacheValue(std::string_view Namespace, std::string_view BucketId, const IoHash& Key, const IoHash& ValueContentId); + ZenCacheResult GetCacheChunk(std::string_view Namespace, std::string_view BucketId, const IoHash& Key, const IoHash& ValueContentId); ZenCacheResult PutCacheRecord(std::string_view Namespace, std::string_view BucketId, const IoHash& Key, |