From 9744b9a3e6e98ba44f0ae20a81d64f44c58764f8 Mon Sep 17 00:00:00 2001 From: nidhidhamnani Date: Thu, 27 Mar 2025 13:39:38 -0700 Subject: [PATCH 1/4] feat: set_if api --- .idea/.gitignore | 8 +++++++ .idea/modules.xml | 8 +++++++ .idea/rpc-perf.iml | 12 ++++++++++ .idea/vcs.xml | 6 +++++ src/clients/cache/momento/commands/mod.rs | 2 ++ .../cache/momento/commands/set_if_absent.rs | 22 +++++++++++++++++++ src/clients/cache/momento/mod.rs | 4 +++- src/config/workload.rs | 3 +++ src/metrics/mod.rs | 4 +++- src/workload/client.rs | 7 ++++++ src/workload/mod.rs | 4 ++++ 11 files changed, 78 insertions(+), 2 deletions(-) create mode 100644 .idea/.gitignore create mode 100644 .idea/modules.xml create mode 100644 .idea/rpc-perf.iml create mode 100644 .idea/vcs.xml create mode 100644 src/clients/cache/momento/commands/set_if_absent.rs diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 00000000..13566b81 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,8 @@ +# Default ignored files +/shelf/ +/workspace.xml +# Editor-based HTTP Client requests +/httpRequests/ +# Datasource local storage ignored files +/dataSources/ +/dataSources.local.xml diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 00000000..1300b833 --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/rpc-perf.iml b/.idea/rpc-perf.iml new file mode 100644 index 00000000..9b4cf845 --- /dev/null +++ b/.idea/rpc-perf.iml @@ -0,0 +1,12 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 00000000..35eb1ddf --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/src/clients/cache/momento/commands/mod.rs b/src/clients/cache/momento/commands/mod.rs index b6897224..75f84dbd 100644 --- a/src/clients/cache/momento/commands/mod.rs +++ b/src/clients/cache/momento/commands/mod.rs @@ -18,6 +18,7 @@ mod list_push_front; mod list_remove; mod set; mod set_add; +mod set_if_absent; mod set_members; mod set_remove; mod sorted_set_add; @@ -43,6 +44,7 @@ pub use list_push_front::*; pub use list_remove::*; pub use set::*; pub use set_add::*; +pub use set_if_absent::*; pub use set_members::*; pub use set_remove::*; pub use sorted_set_add::*; diff --git a/src/clients/cache/momento/commands/set_if_absent.rs b/src/clients/cache/momento/commands/set_if_absent.rs new file mode 100644 index 00000000..cf57e5f6 --- /dev/null +++ b/src/clients/cache/momento/commands/set_if_absent.rs @@ -0,0 +1,22 @@ +use super::*; + +pub async fn set_if_absent( + client: &mut CacheClient, + config: &Config, + cache_name: &str, + request: workload::client::SetIfAbsent, +) -> std::result::Result<(), ResponseError> { + SET_IF_ABSENT.increment(); + + let result = timeout( + config.client().unwrap().request_timeout(), + client.set_if_absent( + cache_name, + (*request.key).to_owned(), + (*request.value).to_owned(), + ), + ) + .await; + + record_result!(result, SET_IF_ABSENT) +} diff --git a/src/clients/cache/momento/mod.rs b/src/clients/cache/momento/mod.rs index 82e8e563..6a05c8a2 100644 --- a/src/clients/cache/momento/mod.rs +++ b/src/clients/cache/momento/mod.rs @@ -86,7 +86,9 @@ async fn task( ClientRequest::Get(r) => get(&mut client, &config, cache_name, r).await, ClientRequest::Set(r) => set(&mut client, &config, cache_name, r).await, ClientRequest::Delete(r) => delete(&mut client, &config, cache_name, r).await, - + ClientRequest::SetIfAbsent(r) => { + set_if_absent(&mut client, &config, cache_name, r).await + } /* * HASHES (DICTIONARIES) */ diff --git a/src/config/workload.rs b/src/config/workload.rs index f6174eba..7d54f7bf 100644 --- a/src/config/workload.rs +++ b/src/config/workload.rs @@ -427,6 +427,9 @@ pub enum Verb { /// * Momento: unsupported /// * RESP: `SET` with `XX` option Replace, + /// Set the value for a key only if it already exists. + /// * RESP: `STORED` or `NOT_STORED` + SetIfAbsent, /* * HASHES (DICTIONARIES) diff --git a/src/metrics/mod.rs b/src/metrics/mod.rs index be242deb..a9b7fae9 100644 --- a/src/metrics/mod.rs +++ b/src/metrics/mod.rs @@ -308,7 +308,7 @@ macro_rules! request { paste! { #[allow(dead_code)] pub static [<$ident _EX_COUNTER>]: &'static str = concat!($name, "/exception"); - } + } } paste! { @@ -524,6 +524,8 @@ counter!( "delete requests that resulted in timeout" ); +request!(SET_IF_ABSENT, "set_if_absent"); + request!(HASH_GET, "hash_get"); counter!(HASH_GET_FIELD_HIT, "hash_get/field_hit"); counter!(HASH_GET_FIELD_MISS, "hash_get/field_miss"); diff --git a/src/workload/client.rs b/src/workload/client.rs index a4440023..54ea8e54 100644 --- a/src/workload/client.rs +++ b/src/workload/client.rs @@ -42,6 +42,12 @@ pub struct Set { pub ttl: Option, } +#[derive(Debug, PartialEq)] +pub struct SetIfAbsent { + pub key: Arc<[u8]>, + pub value: Bytes, +} + // Hash #[derive(Debug, PartialEq)] @@ -212,6 +218,7 @@ pub enum ClientRequest { MultiGet(MultiGet), Replace(Replace), Set(Set), + SetIfAbsent(SetIfAbsent), // Hash Commands HashExists(HashExists), diff --git a/src/workload/mod.rs b/src/workload/mod.rs index 2c26066e..bc99fff6 100644 --- a/src/workload/mod.rs +++ b/src/workload/mod.rs @@ -370,6 +370,10 @@ impl Generator { Verb::Delete => ClientRequest::Delete(client::Delete { key: keyspace.sample(rng), }), + Verb::SetIfAbsent => ClientRequest::SetIfAbsent(client::SetIfAbsent { + key: keyspace.sample(rng), + value: keyspace.gen_value(sequence as _, rng), + }), Verb::Replace => ClientRequest::Replace(client::Replace { key: keyspace.sample(rng), value: keyspace.gen_value(sequence as _, rng), From 745e913fcdc26a84e44f943f91c97d6395b702f4 Mon Sep 17 00:00:00 2001 From: nidhidhamnani Date: Thu, 27 Mar 2025 13:46:34 -0700 Subject: [PATCH 2/4] chore: remove .idea files --- .idea/.gitignore | 8 -------- .idea/modules.xml | 8 -------- .idea/rpc-perf.iml | 12 ------------ .idea/vcs.xml | 6 ------ 4 files changed, 34 deletions(-) delete mode 100644 .idea/.gitignore delete mode 100644 .idea/modules.xml delete mode 100644 .idea/rpc-perf.iml delete mode 100644 .idea/vcs.xml diff --git a/.idea/.gitignore b/.idea/.gitignore deleted file mode 100644 index 13566b81..00000000 --- a/.idea/.gitignore +++ /dev/null @@ -1,8 +0,0 @@ -# Default ignored files -/shelf/ -/workspace.xml -# Editor-based HTTP Client requests -/httpRequests/ -# Datasource local storage ignored files -/dataSources/ -/dataSources.local.xml diff --git a/.idea/modules.xml b/.idea/modules.xml deleted file mode 100644 index 1300b833..00000000 --- a/.idea/modules.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - - \ No newline at end of file diff --git a/.idea/rpc-perf.iml b/.idea/rpc-perf.iml deleted file mode 100644 index 9b4cf845..00000000 --- a/.idea/rpc-perf.iml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - - - - - - \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml deleted file mode 100644 index 35eb1ddf..00000000 --- a/.idea/vcs.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file From daf8ea2c458472584b39777fb1c85a0c56e768cd Mon Sep 17 00:00:00 2001 From: nidhidhamnani Date: Fri, 28 Mar 2025 14:02:22 -0700 Subject: [PATCH 3/4] feat: set_if_present_and_not_equal api and item_get_type api --- .../cache/momento/commands/item_get_type.rs | 18 +++++++++++++++ src/clients/cache/momento/commands/mod.rs | 4 ++++ .../commands/set_if_present_and_not_equal.rs | 23 +++++++++++++++++++ src/clients/cache/momento/mod.rs | 7 ++++++ src/config/workload.rs | 13 +++++++++-- src/metrics/mod.rs | 4 ++++ src/workload/client.rs | 13 +++++++++++ src/workload/mod.rs | 9 ++++++++ 8 files changed, 89 insertions(+), 2 deletions(-) create mode 100644 src/clients/cache/momento/commands/item_get_type.rs create mode 100644 src/clients/cache/momento/commands/set_if_present_and_not_equal.rs diff --git a/src/clients/cache/momento/commands/item_get_type.rs b/src/clients/cache/momento/commands/item_get_type.rs new file mode 100644 index 00000000..5b2e0640 --- /dev/null +++ b/src/clients/cache/momento/commands/item_get_type.rs @@ -0,0 +1,18 @@ +use super::*; + +pub async fn item_get_type( + client: &mut CacheClient, + config: &Config, + cache_name: &str, + request: workload::client::ItemGetType, +) -> std::result::Result<(), ResponseError> { + ITEM_GET_TYPE.increment(); + + let result = timeout( + config.client().unwrap().request_timeout(), + client.item_get_type(cache_name, (*request.key).to_owned()), + ) + .await; + + record_result!(result, ITEM_GET_TYPE) +} diff --git a/src/clients/cache/momento/commands/mod.rs b/src/clients/cache/momento/commands/mod.rs index 75f84dbd..b7be257d 100644 --- a/src/clients/cache/momento/commands/mod.rs +++ b/src/clients/cache/momento/commands/mod.rs @@ -9,6 +9,7 @@ mod hash_get; mod hash_get_all; mod hash_increment; mod hash_set; +mod item_get_type; mod list_fetch; mod list_length; mod list_pop_back; @@ -19,6 +20,7 @@ mod list_remove; mod set; mod set_add; mod set_if_absent; +mod set_if_present_and_not_equal; mod set_members; mod set_remove; mod sorted_set_add; @@ -35,6 +37,7 @@ pub use hash_get::*; pub use hash_get_all::*; pub use hash_increment::*; pub use hash_set::*; +pub use item_get_type::*; pub use list_fetch::*; pub use list_length::*; pub use list_pop_back::*; @@ -45,6 +48,7 @@ pub use list_remove::*; pub use set::*; pub use set_add::*; pub use set_if_absent::*; +pub use set_if_present_and_not_equal::*; pub use set_members::*; pub use set_remove::*; pub use sorted_set_add::*; diff --git a/src/clients/cache/momento/commands/set_if_present_and_not_equal.rs b/src/clients/cache/momento/commands/set_if_present_and_not_equal.rs new file mode 100644 index 00000000..7d10ae57 --- /dev/null +++ b/src/clients/cache/momento/commands/set_if_present_and_not_equal.rs @@ -0,0 +1,23 @@ +use super::*; + +pub async fn set_if_present_and_not_equal( + client: &mut CacheClient, + config: &Config, + cache_name: &str, + request: workload::client::SetIfPresentAndNotEqual, +) -> std::result::Result<(), ResponseError> { + SET_IF_PRESENT_AND_NOT_EQUAL.increment(); + + let result = timeout( + config.client().unwrap().request_timeout(), + client.set_if_present_and_not_equal( + cache_name, + (*request.key).to_owned(), + (*request.value).to_owned(), // new value + (*request.value).to_owned(), // old value + ), + ) + .await; + + record_result!(result, SET_IF_PRESENT_AND_NOT_EQUAL) +} diff --git a/src/clients/cache/momento/mod.rs b/src/clients/cache/momento/mod.rs index 6a05c8a2..1786f136 100644 --- a/src/clients/cache/momento/mod.rs +++ b/src/clients/cache/momento/mod.rs @@ -89,6 +89,13 @@ async fn task( ClientRequest::SetIfAbsent(r) => { set_if_absent(&mut client, &config, cache_name, r).await } + ClientRequest::SetIfPresentAndNotEqual(r) => { + set_if_present_and_not_equal(&mut client, &config, cache_name, r).await + } + ClientRequest::ItemGetType(r) => { + item_get_type(&mut client, &config, cache_name, r).await + } + /* * HASHES (DICTIONARIES) */ diff --git a/src/config/workload.rs b/src/config/workload.rs index 7d54f7bf..635a095f 100644 --- a/src/config/workload.rs +++ b/src/config/workload.rs @@ -427,9 +427,18 @@ pub enum Verb { /// * Momento: unsupported /// * RESP: `SET` with `XX` option Replace, - /// Set the value for a key only if it already exists. - /// * RESP: `STORED` or `NOT_STORED` + /// Set the value for a key only if it does not exists. + /// * Momento: `set_if_absent` + /// * RESP: `SET` with `XX` option SetIfAbsent, + /// Set the value for a key only if it already exists. + /// * Momento: `set_if_present_and_not_equal` + /// * RESP: Raw `SET` with cached value comparison + SetIfPresentAndNotEqual, + /// Set the value for a key only if it already exists. + /// * Momento: `item_get_type` + /// * RESP: `TYPE` + ItemGetType, /* * HASHES (DICTIONARIES) diff --git a/src/metrics/mod.rs b/src/metrics/mod.rs index a9b7fae9..553df878 100644 --- a/src/metrics/mod.rs +++ b/src/metrics/mod.rs @@ -526,6 +526,10 @@ counter!( request!(SET_IF_ABSENT, "set_if_absent"); +request!(SET_IF_PRESENT_AND_NOT_EQUAL, "set_if_present_and_not_equal"); + +request!(ITEM_GET_TYPE, "item_get_type"); + request!(HASH_GET, "hash_get"); counter!(HASH_GET_FIELD_HIT, "hash_get/field_hit"); counter!(HASH_GET_FIELD_MISS, "hash_get/field_miss"); diff --git a/src/workload/client.rs b/src/workload/client.rs index 54ea8e54..a78b0ec6 100644 --- a/src/workload/client.rs +++ b/src/workload/client.rs @@ -48,6 +48,17 @@ pub struct SetIfAbsent { pub value: Bytes, } +#[derive(Debug, PartialEq)] +pub struct SetIfPresentAndNotEqual { + pub key: Arc<[u8]>, + pub value: Bytes, +} + +#[derive(Debug, PartialEq)] +pub struct ItemGetType { + pub key: Arc<[u8]>, +} + // Hash #[derive(Debug, PartialEq)] @@ -219,6 +230,8 @@ pub enum ClientRequest { Replace(Replace), Set(Set), SetIfAbsent(SetIfAbsent), + SetIfPresentAndNotEqual(SetIfPresentAndNotEqual), + ItemGetType(ItemGetType), // Hash Commands HashExists(HashExists), diff --git a/src/workload/mod.rs b/src/workload/mod.rs index bc99fff6..51736365 100644 --- a/src/workload/mod.rs +++ b/src/workload/mod.rs @@ -374,6 +374,15 @@ impl Generator { key: keyspace.sample(rng), value: keyspace.gen_value(sequence as _, rng), }), + Verb::SetIfPresentAndNotEqual => { + ClientRequest::SetIfPresentAndNotEqual(client::SetIfPresentAndNotEqual { + key: keyspace.sample(rng), + value: keyspace.gen_value(sequence as _, rng), + }) + } + Verb::ItemGetType => ClientRequest::ItemGetType(client::ItemGetType { + key: keyspace.sample(rng), + }), Verb::Replace => ClientRequest::Replace(client::Replace { key: keyspace.sample(rng), value: keyspace.gen_value(sequence as _, rng), From 4803565ab244a1428317f0412c35b969143a3ba2 Mon Sep 17 00:00:00 2001 From: nidhidhamnani Date: Fri, 28 Mar 2025 15:36:59 -0700 Subject: [PATCH 4/4] fix: PR feedbacks --- .../cache/momento/commands/item_get_type.rs | 27 +++++++++++++--- .../cache/momento/commands/set_if_absent.rs | 27 +++++++++++++--- .../commands/set_if_present_and_not_equal.rs | 31 +++++++++++++++---- src/config/workload.rs | 6 ++-- src/metrics/mod.rs | 12 +++++++ src/workload/client.rs | 3 +- src/workload/mod.rs | 3 +- 7 files changed, 91 insertions(+), 18 deletions(-) diff --git a/src/clients/cache/momento/commands/item_get_type.rs b/src/clients/cache/momento/commands/item_get_type.rs index 5b2e0640..f5e07c8e 100644 --- a/src/clients/cache/momento/commands/item_get_type.rs +++ b/src/clients/cache/momento/commands/item_get_type.rs @@ -1,4 +1,5 @@ use super::*; +use ::momento::cache::ItemGetTypeResponse; pub async fn item_get_type( client: &mut CacheClient, @@ -8,11 +9,29 @@ pub async fn item_get_type( ) -> std::result::Result<(), ResponseError> { ITEM_GET_TYPE.increment(); - let result = timeout( + match timeout( config.client().unwrap().request_timeout(), client.item_get_type(cache_name, (*request.key).to_owned()), ) - .await; - - record_result!(result, ITEM_GET_TYPE) + .await + { + Ok(Ok(r)) => match r { + ItemGetTypeResponse::Hit { .. } => { + ITEM_GET_TYPE_HIT.increment(); + Ok(()) + } + ItemGetTypeResponse::Miss => { + ITEM_GET_TYPE_MISS.increment(); + Ok(()) + } + }, + Ok(Err(e)) => { + ITEM_GET_TYPE_EX.increment(); + Err(e.into()) + } + Err(_) => { + ITEM_GET_TYPE_TIMEOUT.increment(); + Err(ResponseError::Timeout) + } + } } diff --git a/src/clients/cache/momento/commands/set_if_absent.rs b/src/clients/cache/momento/commands/set_if_absent.rs index cf57e5f6..4e63b506 100644 --- a/src/clients/cache/momento/commands/set_if_absent.rs +++ b/src/clients/cache/momento/commands/set_if_absent.rs @@ -1,4 +1,5 @@ use super::*; +use ::momento::cache::SetIfAbsentResponse; pub async fn set_if_absent( client: &mut CacheClient, @@ -8,7 +9,7 @@ pub async fn set_if_absent( ) -> std::result::Result<(), ResponseError> { SET_IF_ABSENT.increment(); - let result = timeout( + match timeout( config.client().unwrap().request_timeout(), client.set_if_absent( cache_name, @@ -16,7 +17,25 @@ pub async fn set_if_absent( (*request.value).to_owned(), ), ) - .await; - - record_result!(result, SET_IF_ABSENT) + .await + { + Ok(Ok(r)) => match r { + SetIfAbsentResponse::Stored { .. } => { + SET_IF_ABSENT_STORED.increment(); + Ok(()) + } + SetIfAbsentResponse::NotStored => { + SET_IF_ABSENT_NOT_STORED.increment(); + Ok(()) + } + }, + Ok(Err(e)) => { + SET_IF_ABSENT_EX.increment(); + Err(e.into()) + } + Err(_) => { + SET_IF_ABSENT_TIMEOUT.increment(); + Err(ResponseError::Timeout) + } + } } diff --git a/src/clients/cache/momento/commands/set_if_present_and_not_equal.rs b/src/clients/cache/momento/commands/set_if_present_and_not_equal.rs index 7d10ae57..c9cd7db5 100644 --- a/src/clients/cache/momento/commands/set_if_present_and_not_equal.rs +++ b/src/clients/cache/momento/commands/set_if_present_and_not_equal.rs @@ -1,4 +1,5 @@ use super::*; +use ::momento::cache::SetIfPresentAndNotEqualResponse; pub async fn set_if_present_and_not_equal( client: &mut CacheClient, @@ -8,16 +9,34 @@ pub async fn set_if_present_and_not_equal( ) -> std::result::Result<(), ResponseError> { SET_IF_PRESENT_AND_NOT_EQUAL.increment(); - let result = timeout( + match timeout( config.client().unwrap().request_timeout(), client.set_if_present_and_not_equal( cache_name, (*request.key).to_owned(), - (*request.value).to_owned(), // new value - (*request.value).to_owned(), // old value + (*request.new_value).to_owned(), + (*request.old_value).to_owned(), ), ) - .await; - - record_result!(result, SET_IF_PRESENT_AND_NOT_EQUAL) + .await + { + Ok(Ok(r)) => match r { + SetIfPresentAndNotEqualResponse::Stored { .. } => { + SET_IF_PRESENT_AND_NOT_EQUAL_STORED.increment(); + Ok(()) + } + SetIfPresentAndNotEqualResponse::NotStored => { + SET_IF_PRESENT_AND_NOT_EQUAL_NOT_STORED.increment(); + Ok(()) + } + }, + Ok(Err(e)) => { + SET_IF_PRESENT_AND_NOT_EQUAL_EX.increment(); + Err(e.into()) + } + Err(_) => { + SET_IF_PRESENT_AND_NOT_EQUAL_TIMEOUT.increment(); + Err(ResponseError::Timeout) + } + } } diff --git a/src/config/workload.rs b/src/config/workload.rs index 635a095f..cf6ba195 100644 --- a/src/config/workload.rs +++ b/src/config/workload.rs @@ -431,11 +431,13 @@ pub enum Verb { /// * Momento: `set_if_absent` /// * RESP: `SET` with `XX` option SetIfAbsent, - /// Set the value for a key only if it already exists. + /// Set the value for a key only if it already exists and the + /// current value does not match the value to compare against + /// from the request /// * Momento: `set_if_present_and_not_equal` /// * RESP: Raw `SET` with cached value comparison SetIfPresentAndNotEqual, - /// Set the value for a key only if it already exists. + /// Get the type of the value stored under the key. /// * Momento: `item_get_type` /// * RESP: `TYPE` ItemGetType, diff --git a/src/metrics/mod.rs b/src/metrics/mod.rs index 553df878..70b9e080 100644 --- a/src/metrics/mod.rs +++ b/src/metrics/mod.rs @@ -525,10 +525,22 @@ counter!( ); request!(SET_IF_ABSENT, "set_if_absent"); +counter!(SET_IF_ABSENT_STORED, "set_if_absent/stored"); +counter!(SET_IF_ABSENT_NOT_STORED, "set_if_absent/not_stored"); request!(SET_IF_PRESENT_AND_NOT_EQUAL, "set_if_present_and_not_equal"); +counter!( + SET_IF_PRESENT_AND_NOT_EQUAL_STORED, + "set_if_present_and_not_equal/stored" +); +counter!( + SET_IF_PRESENT_AND_NOT_EQUAL_NOT_STORED, + "set_if_present_and_not_equal/not_stored" +); request!(ITEM_GET_TYPE, "item_get_type"); +counter!(ITEM_GET_TYPE_HIT, "item_get_type/hit"); +counter!(ITEM_GET_TYPE_MISS, "item_get_type/miss"); request!(HASH_GET, "hash_get"); counter!(HASH_GET_FIELD_HIT, "hash_get/field_hit"); diff --git a/src/workload/client.rs b/src/workload/client.rs index a78b0ec6..feb6d3d5 100644 --- a/src/workload/client.rs +++ b/src/workload/client.rs @@ -51,7 +51,8 @@ pub struct SetIfAbsent { #[derive(Debug, PartialEq)] pub struct SetIfPresentAndNotEqual { pub key: Arc<[u8]>, - pub value: Bytes, + pub new_value: Bytes, + pub old_value: Bytes, } #[derive(Debug, PartialEq)] diff --git a/src/workload/mod.rs b/src/workload/mod.rs index 51736365..cff77122 100644 --- a/src/workload/mod.rs +++ b/src/workload/mod.rs @@ -377,7 +377,8 @@ impl Generator { Verb::SetIfPresentAndNotEqual => { ClientRequest::SetIfPresentAndNotEqual(client::SetIfPresentAndNotEqual { key: keyspace.sample(rng), - value: keyspace.gen_value(sequence as _, rng), + new_value: keyspace.gen_value(sequence as _, rng), + old_value: keyspace.gen_value(sequence as _, rng), }) } Verb::ItemGetType => ClientRequest::ItemGetType(client::ItemGetType {