[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[Pulp-list] Action Parameters



Hi All,

I've been playing around with making our API conform to the restful
practices in the 'rest-practices' branch. While hacking away, I've
noticed that we don't really have any particular convention for the
format of parameters (read: body) passed into action POST calls.

There are a number of conventions we can adopt:

1. no convention: let each controller figure out the parameters it
expects and the order it expects them in.

2. only one parameter: the body contains only a single parameter, which
can be a list or dictionary of multiple parameters.

3. key word arguments: the body always contains a dictionary, of
<parameter name>: <parameter value> pairs

4. others?

----

The reason I bring this up is: The restful practices has produced some
very nice looking patterns that allow for some abstraction in the web
services layer. However, not having a convention for the way parameters
are passed into the action uris limits our ability of abstraction and
places a burden on both client and server developers by having to know
how to format parameters on a action by action basis.

I don't have really strong feelings about this. But it seems like a nice
practice for consistency.

Thoughts?

-- 
Jason L Connor
Senior Software Engineer
Systems Management and Cloud Enablement
Red Hat, Inc.
+1.919.890.8331
Freenode: linear

Attachment: signature.asc
Description: This is a digitally signed message part


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]