Hi Ignacio, jclouds uses JAX-RS annotations to configure the request methods, but the @PATCH one is not part of that annotation set. I've had a quick look at the code, and adding support for it should be pretty straightforward.
You'll need to create the @PATCH annotation similar to the one suggested here [1], and then use it in the methods you want it. The annotation should be in the jclouds-core project. If you take a look at how jclouds converts the api calls to http requests (see [2] and [3]), you'll see that just adding the annotation should do the trick (you just have to take care of adding the HttpMethod annotation to it). If you want to give it a try, open a JIRA issue for this, have a look at our How to contribute guide [4], and let us know whatever you need. I will be happy to help! Ignasi [1] http://stackoverflow.com/questions/17897171/how-to-have-a-patch-annotation-in-jax-rs [2] https://github.com/jclouds/jclouds/blob/master/core/src/main/java/org/jclouds/rest/internal/RestAnnotationProcessor.java#L210-L211 [3] https://github.com/jclouds/jclouds/blob/master/core/src/main/java/org/jclouds/http/HttpUtils.java#L138-L154 [4] http://wiki.apache.org/jclouds/How%20to%20Contribute On 11 November 2013 13:35, Ignacio Mulas Viela <[email protected]> wrote: > Hi everyone! > I am currently working in updating the glance v1 to v2 and I came across > with an API method (update an image) that requires a PATCH HTTP request. I > could not find the annotation PATCH as the other common HTTP requests are > implemented on the API methods. > > I would like to ask here what is the best place to implement a new type of > HTTP request so I can use it in the glance afterwards? Any suggestion? > > Thanks in advance! > Ignacio
