Looking for good example/guide to develop new Compute Provider for Private Cloud API

17 views
Skip to first unread message

Egor Guz

unread,
Feb 28, 2012, 1:48:24 AM2/28/12
to jclouds-dev
Hi,

I would like to implement Jclouds Compute Provider for our Private
Cloud API (mostly for simple operations create/remove compute).
Can anyone recommend good tutorial or any existing provider which I
can use as example (EC2 looks too complicated ;))

The main reason for this implementation is try to run/use Apache Whirr
on our environment.

---
Egor

Andrei Savu

unread,
Feb 28, 2012, 4:38:02 PM2/28/12
to jclou...@googlegroups.com
Hi Egor,

Here is a commit that can be helpful for you:

It shows how to create the skeleton needed for a new provider. 

Are there any special requirements? Can you tell us more about the Private Cloud API?

-- Andrei Savu / andreisavu.ro


--
You received this message because you are subscribed to the Google Groups "jclouds-dev" group.
To post to this group, send email to jclou...@googlegroups.com.
To unsubscribe from this group, send email to jclouds-dev...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/jclouds-dev?hl=en.


Koper, Dies

unread,
Feb 28, 2012, 8:43:15 PM2/28/12
to jclou...@googlegroups.com
Hi Egor,

I also used EC2 first as reference and found out the hard way that that
was a big mistake :)
The skeleton Andrei pointed you to is the best starting point.

Two other things that helped me:

* Looking at providers/apis that don't have too much functionality
implemented (yet). I referred to the Glesys and DeltaCloud
implementations a lot after abandoning my EC2 based draft.
* The step-by-step guide under 'Fixing up' on the following page:
http://www.jclouds.org/documentation/devguides/contributing-to-jclouds

Regards,
Dies

> --
> You received this message because you are subscribed to the Google
> Groups "jclouds-dev" group.
> To post to this group, send email to jclou...@googlegroups.com.
> To unsubscribe from this group, send email to jclouds-

> dev+uns...@googlegroups.com.

Egor Guz

unread,
Feb 29, 2012, 7:14:21 PM2/29/12
to jclouds-dev
Hi,

Thanks for skeleton it looks like exactly what I need (I am going to
look deeply during later this week).

There is nothing special about our API, it's Rest API with get/post
and Json payload (the typical flow: authenticate user with user name
and password (return token), submit create compute job and go through
loop (usually we check status every two minutes) until job is done).
Do you think current jclouds API can be integrated for this case?

Also we have to pass some paramaters in http header for some calls.
Are their any good examples for that?

---
Egor

On Feb 28, 1:38 pm, Andrei Savu <savu.and...@gmail.com> wrote:
> Hi Egor,
>
> Here is a commit that can be helpful for you:https://github.com/jclouds/jclouds/commit/39c79f6ffa5138987048693b029...

Koper, Dies

unread,
Feb 29, 2012, 7:39:24 PM2/29/12
to jclou...@googlegroups.com
Hi Egor,

> Also we have to pass some paramaters in http header for some calls.
> Are their any good examples for that?

There are several examples, just grep for @Headers.
If you want to take the header value from the method parameter, check out S3AsyncClient.java:

@PUT
@Path("/{destinationObject}")
@Headers(keys = "x-amz-copy-source", values = "/{sourceBucket}/{sourceObject}")
@XMLResponseParser(CopyObjectHandler.class)
ListenableFuture<ObjectMetadata> copyObject(
@PathParam("sourceBucket") String sourceBucket,
@PathParam("sourceObject") String sourceObject,
@Bucket @BinderParam(BindAsHostPrefixIfConfigured.class) @ParamValidators({ BucketNameValidator.class }) String destinationBucket,
@PathParam("destinationObject") String destinationObject, CopyObjectOptions... options);

Regards,
Dies


> -----Original Message-----
> From: jclou...@googlegroups.com [mailto:jclouds-
> d...@googlegroups.com] On Behalf Of Egor Guz
> Sent: Thursday, 1 March 2012 11:14 AM
> To: jclouds-dev
> Subject: Re: Looking for good example/guide to develop new Compute
> Provider for Private Cloud API
>

> dev+uns...@googlegroups.com.

Andrew Phillips

unread,
Mar 1, 2012, 4:15:58 PM3/1/12
to jclou...@googlegroups.com
Thanks for sharing your experiences, Dies! Any suggestions as to how the
getting started docs could be improved much appreciated, obviously!

ap

--
Andrew Phillips
qrmedia

Unless expressly stated otherwise, this message is confidential.
Access to this e-mail by anyone else is unauthorised. If you are
not an addressee, any disclosure or copying of the contents of
this e-mail or any action taken (or not taken) in reliance on it
is unauthorised and may be unlawful. If you are not an addressee,
please inform the sender immediately.

This message is confidential and may not be redistributed or
broadcast in whole or part in any form, including but not limited
to any form of internet transmission including email, usenet,
newsgroups, www, irc, icq, etc.
All liability for errors and viruses is disclaimed.

Adrian Cole

unread,
Mar 1, 2012, 6:43:56 PM3/1/12
to jclou...@googlegroups.com
good job workin this out, guys!
-A
Reply all
Reply to author
Forward
0 new messages