Reply
Highlighted
Explorer
Posts: 8
Registered: ‎01-25-2017
Accepted Solution

Cluster Scaling via Director API

I understand that scaling the cluster is done by redefining the cluster itself.  What I don't know (and have been unable to find) is how much information do I need to include in PUT to change the cluster.  There's a lot of information that is generated automatically (IP addresses for example) that I don't have/want to include, I'd rather just say I want X nodes of Y template.  Anyone have a resource I can look at?  I've spent sometime working in the API console and the documentation just seems lacking here...

Cloudera Employee
Posts: 48
Registered: ‎10-14-2014

Re: Cluster Scaling via Director API

It's good to hear that you're looking into this. I don't think we have a lot of API users at the moment, so your feedback will be very useful to us.

So you'll really need PUT for the cluster template in order to make an update rather than the cluster object. The cluster object is a bit more ephemeral in nature and reflects the current active state of the cluster.

Are you using one of the SDKs (https://github.com/cloudera/director-sdk, only available in Java/Python)? It sounds like you're doing something a little more manual, but I'd encourage you to use those if possible. Otherwise, the API console is probably your best bet for documentation at the moment. Assuming Director is running on your local machine, you'd navigate to:

http://localhost:7189/api-console

Let me know if that points you in the right direction.
Explorer
Posts: 8
Registered: ‎01-25-2017

Re: Cluster Scaling via Director API

My original thought was to talk JSON to the API directly. The API console is where I've been spending my time trying to understand what's needed to resize the cluster. I'd glanced at the sdk, but looking at it further, it might work for what I'm trying to do (faux EMR).

Explorer
Posts: 8
Registered: ‎01-25-2017

Re: Cluster Scaling via Director API

FYI - Further investigation in to the python version of the SDK looks like it will do what I need. Thanks for pointing me back to it.
Announcements