Thanks Subin. We can continue the discussions on the jira. thanks mahadev
On Tue, Apr 2, 2013 at 8:40 AM, Modeel, Subin <[email protected]> wrote: > Hi **** > > I have added the JIRA **** > > https://issues.apache.org/jira/browse/AMBARI-1769**** > > ** ** > > Thanks**** > > Subin**** > > ** ** > > *From:* Mahadev Konar [mailto:[email protected]] > *Sent:* Tuesday, April 02, 2013 9:08 PM > *To:* Modeel, Subin > *Subject:* Re: Ambari python REST client**** > > ** ** > > This is reaaly nice Subin. Can you open a jira and attach the scripts? I > can review the code with you and help committing it to trunk.**** > > ** ** > > thanks**** > > mahadev**** > > ** ** > > On Tue, Apr 2, 2013 at 4:09 AM, Modeel, Subin <[email protected]> wrote: > **** > > Hi **** > > **** > > I have attached a skeleton code for the Ambari python REST client. I wish > to get your feedback on this.**** > > I have actually extended the features of the python client and I am also > able to create a cluster from the client.**** > > How exactly do I get the permission to commit?**** > > **** > > **** > > **** > > install python client on linux box**** > > =============================='**** > > 1)unzip the attachment**** > > 2)execute 'python setup.py install --record installation.txt'**** > > **** > > **** > > **** > > **** > > example:**** > > ==========**** > > from ambari_api.ambari_client import AmbariClient **** > > client = AmbariClient("localhost", 8080, "admin","admin",version=1)**** > > all_clusters = client.get_all_clusters()**** > > **** > > **** > > cluster = client.get_cluster('test1')**** > > **** > > serviceList = cluster.get_all_services()**** > > **** > > **** > > for service in serviceList:**** > > print str(service.service_name)+" = "+str(service.state)**** > > **** > > **** > > to start/stop service**** > > =================================**** > > ganglia = cluster.get_service("GANGLIA") **** > > ganglia.stop()**** > > ganglia.start()**** > > **** > > **** > > Thanks**** > > Subin**** > > ** ** >
