Skip to content
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

Module experimental cluster api #5371

Open
MeirShpilraien opened this issue Sep 20, 2018 · 2 comments
Open

Module experimental cluster api #5371

MeirShpilraien opened this issue Sep 20, 2018 · 2 comments

Comments

@MeirShpilraien
Copy link
Collaborator

Hey,

As I see the experimental api expose the following function to retrieve information on the cluster:

int REDISMODULE_API_FUNC(RedisModule_GetClusterNodeInfo)(RedisModuleCtx *ctx, const char *id, char *ip, char *master_id, int *port, int *flags);
char **REDISMODULE_API_FUNC(RedisModule_GetClusterNodesList)(RedisModuleCtx *ctx, size_t *numnodes);

I did not see any possibility to get the slot range for a given node, is it possible to add it to RedisModule_GetClusterNodeInfo ?

@MeirShpilraien
Copy link
Collaborator Author

In addition I saw that its not possible to use RedisModule_SendClusterMessage on the current node, its kind of forcing the module writer to distinguish between the scenario on which I am sending to myself and the scenario on which I am sending the another server. In case I am sending to myself I will need to call directly to receive function and in such case it will be called on the same stack. I think the better approach here is to allow calling yourself using RedisModule_SendClusterMessage, what do you think?

@gkorland
Copy link
Contributor

@antirez it seems like a very important functionally to allow users develop distributed cluster aware modules

@yossigo yossigo mentioned this issue Dec 8, 2020
52 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants