On 06/07/2011 06:54 PM, Martyn Taylor wrote:
Hi Geert,
So sort of moving from formal definitions to API types here :) and probably beyond my
knowledge :)
Yes I agree with how we should think about a RESTful API as not RPC based. I meant to
use SOAP just as an example.
I think a pre-runtime definition is what I want really, when I am implementing a client
for an API. I personally think this makes understanding the use of a client much easier,
and would also allow a lot of the code to be auto-generated for us. Which if there was
such a thing a formal RESTful definition would offer.
That's a good point. A pre-runtime description is something that is
completely lacking today for the RHEV-M API. We (at least, I) sort of
accepted that. My thinking is that in the time of fast-moving APIs, you
really want to connect to a server to see what it has on offer, rather
than using a (cached) description locally of what you think the server has.
But i would still be very interested in such a pre-runtime definition
language, as it can also be used at runtime to efficiently transfer the
entire API in one go. We tried to create one for the RHEV-M API (dubbed
"RSDL," the m/l archives have some information on it) but it didn't
really work out. If you can create something simple and RESTful then i
think our project would be very interested. In my view it would
preferably not use XMLSchema as its type definition language but instead
something simpler and more specific to types in a RESTful context.
Regards,
Geert