aboutsummaryrefslogtreecommitdiff
path: root/src/zenstore/cache/cacherpc.cpp
diff options
context:
space:
mode:
authorzousar <[email protected]>2025-09-23 09:26:11 -0600
committerzousar <[email protected]>2025-09-23 09:26:11 -0600
commitc7eebb0c8fc5d046d630b462bbfdab1f46bb2d42 (patch)
treee833c531de232503db4e006afeadb6563d71dcc9 /src/zenstore/cache/cacherpc.cpp
parentMerge branch 'main' into zs/put-overwrite-policy-response (diff)
downloadzen-c7eebb0c8fc5d046d630b462bbfdab1f46bb2d42.tar.xz
zen-c7eebb0c8fc5d046d630b462bbfdab1f46bb2d42.zip
Adjust the responses from PUT commands
- Ensure that text responses are in a field named "Message" - Change the record response to be named "Record" instead of "Object"
Diffstat (limited to 'src/zenstore/cache/cacherpc.cpp')
-rw-r--r--src/zenstore/cache/cacherpc.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/zenstore/cache/cacherpc.cpp b/src/zenstore/cache/cacherpc.cpp
index 5cecc8b6b..77ca26409 100644
--- a/src/zenstore/cache/cacherpc.cpp
+++ b/src/zenstore/cache/cacherpc.cpp
@@ -438,7 +438,7 @@ CacheRpcHandler::PutCacheRecord(PutRequestData& Request, const CbPackage* Packag
if (Count.Invalid > 0)
{
CbObjectWriter DetailWriter;
- DetailWriter.AddString(fmt::format("Found {}/{} invalid attachments", Count.Invalid, Count.Total));
+ DetailWriter.AddString("Message", fmt::format("Found {}/{} invalid attachments", Count.Invalid, Count.Total));
return ZenCacheStore::PutResult{PutStatus::Invalid, DetailWriter.Save()};
}
@@ -1068,7 +1068,7 @@ CacheRpcHandler::HandleRpcPutCacheValues(const CacheRequestContext& Context, con
else
{
CbObjectWriter DetailWriter;
- DetailWriter.AddString(fmt::format("Missing attachment with raw hash {}", RawHash));
+ DetailWriter.AddString("Message", fmt::format("Missing attachment with raw hash {}", RawHash));
Results.push_back({zen::PutStatus::Fail, DetailWriter.Save()});
}
}