valkey-io / valkeymodule-rs

Rust valkey SDK for modules
BSD 3-Clause "New" or "Revised" License
20 stars 5 forks source link

Help: How to set key value pair? #39

Open krishnaTORQUE opened 4 weeks ago

krishnaTORQUE commented 4 weeks ago

Help: How to set key value pair? Is there any simple API where I can store or get key value?

E.g.

valkey_module.set("Key", "Value")

valkey_module.get("Key")

Thanks

mkmkme commented 2 weeks ago

From what I'm seeing from this request you'd like to have a client library for valkey in Rust. This is a library that helps you write a module, i.e. expanding valkey functionality.

Or am I getting it wrong and you want to get/set the key-value pair from the module?

krishnaTORQUE commented 2 weeks ago

From what I'm seeing from this request you'd like to have a client library for valkey in Rust. This is a library that helps you write a module, i.e. expanding valkey functionality.

Or am I getting it wrong and you want to get/set the key-value pair from the module?

@mkmkme Thanks Yes you are right. I am looking for official valkey library for rust that can get, set etc.

mkmkme commented 2 weeks ago

AFAIK there's no Rust client for Valkey at the moment.

However, you could try to use redis-rs with valkey. IIRC currently there are no features exclusive to valkey so it might just work.

krishnaTORQUE commented 2 weeks ago

AFAIK there's no Rust client for Valkey at the moment.

However, you could try to use redis-rs with valkey. IIRC currently there are no features exclusive to valkey so it might just work.

Thanks

mkmkme commented 2 weeks ago

@krishnaTORQUE glad to help! Please let me know if it doesn't work for you

krishnaTORQUE commented 2 weeks ago

@krishnaTORQUE glad to help! Please let me know if it doesn't work for you

Sure, I will test & let you know.