cabol / nebulex_redis_adapter

Nebulex adapter for Redis

Home Page:https://hexdocs.pm/nebulex_redis_adapter/NebulexRedisAdapter.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Allow passing Redis client options to `command` and `pipeline` functions

cabol opened this issue · comments

Allow passing Redis client option to the extended cache functions like command and pipeline.

Currently, these functions look like this:

command(key \\ nil, name \\ __MODULE__, command)

command!(key \\ nil, name \\ __MODULE__, command)

pipeline(key \\ nil, name \\ __MODULE__, commands)

pipeline!(key \\ nil, name \\ __MODULE__, commands)

They don't admit extra options. Therefore, the idea is to make them like so:

command(command, opts \\ [])

command!(command, opts \\ [])

pipeline(commands, opts \\ [])

pipeline!(commands, opts \\ [])

Add add :key and :name to the supported options.