[ 
https://issues.apache.org/jira/browse/ACE-151?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13089371#comment-13089371
 ] 

Bram de Kruijff commented on ACE-151:
-------------------------------------

Two important pitfalls related to REST client API usage and configuration are:

1) One is required to set the processorId to "org.osgi.deployment.rp.autoconf" 
on configuration artifact or thing will fall apart.
2) Resource processor are "hidden" and must be deployed manually (or at least 
be in the OBR?). Not 100% clear toe me yet.

These issues might warrant improvement/change requests but at least documenting 
it for now will help a lot.

see: http://www.mail-archive.com/ace-dev@incubator.apache.org/msg01333.html

> Create a REST client API
> ------------------------
>
>                 Key: ACE-151
>                 URL: https://issues.apache.org/jira/browse/ACE-151
>             Project: Ace
>          Issue Type: New Feature
>            Reporter: Marcel Offermans
>            Assignee: Marcel Offermans
>
> After some discussion on the mailing list, we agreed that it makes sense to 
> add a REST based client API to ACE to make it easier to integrate ACE in 
> different environments.
> The main requirement for this API is that it should expose the whole client 
> API (currently available as OSGi services) using REST. Because each client 
> interacts with the server using a local checkout, this probably means some 
> means to work on sessions (which might seem like something that's not done in 
> REST but in this case a session is like a working area that you create for 
> manipulating its contents and finally commit back to the server and clean up. 
> Authentication can be added via normal basic authentication, so there's no 
> need to explicitly design that into the API.
> So an interaction with the server could start somewhat like this:
> POST /ace/client -> sessionid
> This will trigger a basic authentication, which, if it succeeds, will return 
> a session id. It makes sense to also implicitly do a checkout.
> GET /ace/client/mysessionid/feature -> list of feature id's
> Will return a list of features in the repository.
> PUT /ace/client/mysessionid/feature/MyCustomFeature
> Will create a new feature with a unique id called "MyCustomFeature". Maybe 
> the put will also contain some (JSON/XML) data to describe the feature.
> In general, we can map all our entities (artifacts, features, distributions 
> and targets) as well as all our associations (artifact2feature, 
> feature2distribution, distribution2target) to REST endpoints that are very 
> similar, so:
> /ace/client/<sessionid>
>    /artifact
>    /feature
>    ...
> And for each of those repository objects (as they're called in the code) we 
> can do things like:
> GET /ace/client/<sessionid>/<repositoryobjecttype>/<objectid>/tag
> To get a list of all tags associated with object "objectid".
> PUT /ace/client/<sessionid>/<repositoryobjecttype>/<objectid>/tag/description 
> "This is a description."
> To set/replace the description tag.
> Finally, for the 'checkout', 'revert' and 'commit' commands, we could do 
> something like this:
> GET /ace/client/<sessionid>/{commit,revert,update}
> Which will return success or failure.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to