if (localNimbus != null) { LOG.info("Submitting topology " + name + " in local mode"); localNimbus.submitTopology(name, null, serConf, topology); } else { NimbusClient client = NimbusClient.getConfiguredClient(conf);
client.init(nimbusConf); String topologyId = client.getClient().getTopologyId(topologyName); TopologyInfo topologyInfo = client.getClient().getTopologyInfo(topologyId);
public static void killTopology(Map conf, String topologyName) throws Exception { NimbusClientWrapper client = new NimbusClientWrapper(); try { Map clusterConf = Utils.readStormConfig(); clusterConf.putAll(conf); client.init(clusterConf); KillOptions killOption = new KillOptions(); killOption.set_wait_secs(1); client.getClient().killTopologyWithOpts(topologyName, killOption); } finally { client.cleanup(); } }
if (localNimbus != null) { LOG.info("Submitting topology " + name + " in local mode"); localNimbus.submitTopology(name, null, serConf, topology); } else { NimbusClient client = NimbusClient.getConfiguredClient(conf);
if(localNimbus!=null) { LOG.info("Submitting topology " + name + " in local mode"); localNimbus.submitTopology(name, null, serConf, topology); } else { NimbusClient client = NimbusClient.getConfiguredClient(conf);
if (localNimbus != null) { LOG.info("Submitting topology " + name + " in local mode"); localNimbus.submitTopology(name, null, serConf, topology); } else { NimbusClient client = NimbusClient.getConfiguredClient(conf);
protected killTopologyWithOpts_result getResult(I iface, killTopologyWithOpts_args args) throws org.apache.thrift.TException { killTopologyWithOpts_result result = new killTopologyWithOpts_result(); try { iface.killTopologyWithOpts(args.name, args.options); } catch (NotAliveException e) { result.e = e; } return result; } }
protected getTopologyInfo_result getResult(I iface, getTopologyInfo_args args) throws org.apache.thrift.TException { getTopologyInfo_result result = new getTopologyInfo_result(); try { result.success = iface.getTopologyInfo(args.id); } catch (NotAliveException e) { result.e = e; } return result; } }
protected beginFileDownload_result getResult(I iface, beginFileDownload_args args) throws org.apache.thrift.TException { beginFileDownload_result result = new beginFileDownload_result(); result.success = iface.beginFileDownload(args.file); return result; } }
protected finishFileUpload_result getResult(I iface, finishFileUpload_args args) throws org.apache.thrift.TException { finishFileUpload_result result = new finishFileUpload_result(); iface.finishFileUpload(args.location); return result; } }
protected submitTopology_result getResult(I iface, submitTopology_args args) throws org.apache.thrift.TException { submitTopology_result result = new submitTopology_result(); try { iface.submitTopology(args.name, args.uploadedJarLocation, args.jsonConf, args.topology); } catch (AlreadyAliveException e) { result.e = e; } catch (InvalidTopologyException ite) { result.ite = ite; } return result; } }
protected beginFileUpload_result getResult(I iface, beginFileUpload_args args) throws org.apache.thrift.TException { beginFileUpload_result result = new beginFileUpload_result(); result.success = iface.beginFileUpload(); return result; } }
protected deactivate_result getResult(I iface, deactivate_args args) throws org.apache.thrift.TException { deactivate_result result = new deactivate_result(); try { iface.deactivate(args.name); } catch (NotAliveException e) { result.e = e; } return result; } }
protected activate_result getResult(I iface, activate_args args) throws org.apache.thrift.TException { activate_result result = new activate_result(); try { iface.activate(args.name); } catch (NotAliveException e) { result.e = e; } return result; } }
protected getClusterInfo_result getResult(I iface, getClusterInfo_args args) throws org.apache.thrift.TException { getClusterInfo_result result = new getClusterInfo_result(); result.success = iface.getClusterInfo(); return result; } }
protected downloadChunk_result getResult(I iface, downloadChunk_args args) throws org.apache.thrift.TException { downloadChunk_result result = new downloadChunk_result(); result.success = iface.downloadChunk(args.id); return result; } }
if(localNimbus!=null) { LOG.info("Submitting topology " + name + " in local mode"); localNimbus.submitTopology(name, null, serConf, topology); } else { submitJar(conf);
protected killTopologyWithOpts_result getResult(I iface, killTopologyWithOpts_args args) throws org.apache.thrift7.TException { killTopologyWithOpts_result result = new killTopologyWithOpts_result(); try { iface.killTopologyWithOpts(args.name, args.options); } catch (NotAliveException e) { result.e = e; } return result; } }
protected downloadChunk_result getResult(I iface, downloadChunk_args args) throws org.apache.thrift7.TException { downloadChunk_result result = new downloadChunk_result(); result.success = iface.downloadChunk(args.id); return result; } }
protected deactivate_result getResult(I iface, deactivate_args args) throws org.apache.thrift7.TException { deactivate_result result = new deactivate_result(); try { iface.deactivate(args.name); } catch (NotAliveException e) { result.e = e; } return result; } }