Hi,
I think it would be great to have versioning capability for ESB API
resources..
For example following could be the draft schemas of API's that can be
deployed as resources of the same version...

    <api name="AccountManagementAPI" *version*=*"1.0.0"* *version-type="url
| header | query-param | .." *context="/am">
        <resource uri-template="/account/{accountId}" methods="GET"
inSequence="..." outSequence="..."/>
        <resource uri-template="/account/{accountId}" methods="PUT"
inSequence="...." outSequence="..." />
        ...................
        ..............
        .....
    </api>

     <api name="AccountManagementAPI" *version*=*"1.0.1"* *version-type**="url
| header | query-param | .."* context="/am">
        <resource uri-template="/account/{accountId}" methods="GET"
inSequence="..." outSequence="..."/>
        <resource uri-template="/account/{accountId}" methods="PUT"
inSequence="...." outSequence="..." />
        ...................
        ..............
        .....
    </api>

This way Requests will only be dispatched to the relevant versioned
Resource depending on the version..
For example a sample request can be -->

http://{host}:{port}/am/{version}/account/A1  --> dispatch to
"AccountManagementAPI" on {version}

Additionally versions can be resolved based on url , transport header value
, query parameters ,etc.. This attributes to "*version-type*"..
I would like to go ahead with this implementation and IMO would be fairly
straight forward to implement in Synapse..Appreciate any feedback,
suggestions you have..

Regards,
udayanga







-- 
*Udayanga Wickramasinghe*
Software Engineer; WSO2 Inc.; http://wso2.com,
*email: **[email protected]* <[email protected]>* cell: +94 (77) 983-4365
blog: **http://udayangawiki.blogspot.com*<http://udayangawiki.blogspot.com/>
*
twitter: **http://twitter.com/udayanga_wick*<http://twitter.com/udayanga_wick>
*
*

Reply via email to