Skip to content

Possibility of custom process registration dispatching logic? #27

@Qqwy

Description

@Qqwy

Right now, it is possible to either return a PID, or to register using :global or :via. However, this needs to be given as option when ExActor.GenServer is included (used).

This unfortunately which means that it is impossible to build custom logic, to e.g. register at {:via, Registry, {MyRegistry, "user_#{user_id}"}}.

Maybe, a possibility would be to allow users to write a custom export function, which is used for the different functions to transform the first argument into a term like above that could be used to do the actual GenServer dispatching on.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions