Why are both args && kwargs sent in uri calls

#1

My colleagues and I were trying to determine the reasoning behind passing both args and kwargs in uri calls why not just allow arg to be anything, string, array, object, int etc…

e.g.
session.call(‘com.example.test’,[Why,array], {and:object});

0 Likes

#2

Hi Greg,

because there are languages that have keyword parameters, not only positional parameters, and WAMP strives to natively support this.

In fact, WAMP also supports positional (multi-value) and keyword return values. E.g. database procedural languages have that (e.g. PostgreSQL PL/pgSQL).

You can have a look the full discussion that lead to this design here https://github.com/tavendo/WAMP/issues/21

Cheers,
/Tobias

···

Am Donnerstag, 9. Juli 2015 03:02:50 UTC+2 schrieb Greg Keys:

My colleagues and I were trying to determine the reasoning behind passing both args and kwargs in uri calls why not just allow arg to be anything, string, array, object, int etc…

e.g.
session.call(‘com.example.test’,[Why,array], {and:object});

0 Likes

#3

Hi Greg,

there was considerable discussion about this during the design of WAMP v2 (see https://github.com/tavendo/WAMP/issues/21). In the end, a superset approach was adopted, i.e. WAMP attempts to cover various argument styles.

Regards,

Alex

···

Am Donnerstag, 9. Juli 2015 03:02:50 UTC+2 schrieb Greg Keys:

My colleagues and I were trying to determine the reasoning behind passing both args and kwargs in uri calls why not just allow arg to be anything, string, array, object, int etc…

e.g.
session.call(‘com.example.test’,[Why,array], {and:object});

0 Likes