You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@storm.apache.org by "AK47Sonic (Jira)" <ji...@apache.org> on 2019/12/12 03:57:00 UTC
[jira] [Created] (STORM-3554) LocalCluster can't be shutdown and
JVM still run
AK47Sonic created STORM-3554:
--------------------------------
Summary: LocalCluster can't be shutdown and JVM still run
Key: STORM-3554
URL: https://issues.apache.org/jira/browse/STORM-3554
Project: Apache Storm
Issue Type: Bug
Components: storm-client, storm-server
Affects Versions: 2.1.0
Environment: Storm 2.1.0
IntelliJ IDEA
Reporter: AK47Sonic
Hi team,
[Storm version: 2.1.0] After I shutdown LocalCluster by calling shutdown or close method, JVM still run and can't exit on IDEA. I think it is a simple demo blow. Is it a bug?
import org.apache.storm.Config;
import org.apache.storm.LocalCluster;
import org.apache.storm.topology.TopologyBuilder;
public class WordCountTopology {
public static void main(String[] args) throws Exception {
TopologyBuilder builder = new TopologyBuilder();
// builder.setSpout("spout", new RandomSentenceSpout(), 5);
// builder.setBolt("split", new SplitSentenceBolt(), 8).shuffleGrouping("spout");
// builder.setBolt("count", new WordCountBolt(), 2).fieldsGrouping("split", new Fields("word"));
Config conf = new Config();
conf.setDebug(true);
String topologyName = "word-count";
conf.setNumWorkers(2);
LocalCluster cluster = null;
cluster = new LocalCluster();
cluster.submitTopology(topologyName, conf, builder.createTopology());
Thread.sleep(10000);
// cluster.close();
cluster.shutdown();
}
}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)