Expand accepted method names #1

Closed
wants to merge 2 commits into
from

Conversation

Projects
None yet
2 participants
@jasonjayr
Contributor

jasonjayr commented Dec 28, 2010

The JSON-RPC 2.0 spec says that any string is a valid method name, and I couldn't find any mention on their discussion list of an alphanumeric requirement on method names.

This patch will expand your dispatcher to accept registration on any method names, except empty string, non-string scalars, or any strings starting with 'rpc.' and on activation, accept any method names (in case you ever internally introduce "rpc." methods).

I've also included relevent test cases.

Thanks for this module, and thanks for your consideration. This is my first github/cpan pull request, I hope I'm not being improper :)

Adjust the register method to accept any string except those defiend …
…to be 'rpc-internal'

Adjusted the trigger on Procedure to accept any string on dispatch, so that if 'rpc.' methods
are ever implemented, they can be activated.

Added relavant test cases
@mlauer

This comment has been minimized.

Show comment Hide comment
@mlauer

mlauer Jan 26, 2011

I'd like to use method names including a separating dot. E.g.: "thing.act"
Therefore I would need this patch applied, too.

This module performs great in the infrastructure i'm going to deploy! Thumbs up!
I think, jasonjayr's work is also very convincing. Thank's for that!

mlauer commented Jan 26, 2011

I'd like to use method names including a separating dot. E.g.: "thing.act"
Therefore I would need this patch applied, too.

This module performs great in the infrastructure i'm going to deploy! Thumbs up!
I think, jasonjayr's work is also very convincing. Thank's for that!

@dmcbride dmcbride closed this in 26e0a31 Jan 22, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment