-
Notifications
You must be signed in to change notification settings - Fork 183
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for Adding Map type in Input of HSet #649
Comments
if this issue is marks as |
Hi @atharva29, Thank you for the proposal. But In terms of performance, IMO, the By the way, I think we already made |
Currently for values its accepting '[]any' for
'rueidiscompat.Cmdable.HSet(ctx context.Context, key string, values ...any) '
It should accept input in form of
map[string]interface{}
, as most of the developers have their values in the form of structs.Developers can marshal and then unmarshal it to convert their structure into map, no need to convert it into []any.
eg.
``
type CustInfo struct {
CustomerID string
json:"customer_id"
Name string `json:"name"`
}
using json.marshal and json.unmarshal we can easily convert it into map and pass it in
rueidiscompat.Cmdable.HSetV1(ctx context.Context, key string, values map[string]interface{})
``
The text was updated successfully, but these errors were encountered: