backtype.storm.Config.setFallBackOnJavaSerialization()方法的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(3.3k)|赞(0)|评价(0)|浏览(121)

本文整理了Java中backtype.storm.Config.setFallBackOnJavaSerialization()方法的一些代码示例,展示了Config.setFallBackOnJavaSerialization()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Config.setFallBackOnJavaSerialization()方法的具体详情如下:
包路径:backtype.storm.Config
类名称:Config
方法名:setFallBackOnJavaSerialization

Config.setFallBackOnJavaSerialization介绍

暂无

代码示例

代码示例来源:origin: alibaba/jstorm

public void setFallBackOnJavaSerialization(boolean fallback) {
  setFallBackOnJavaSerialization(this, fallback);
}

代码示例来源:origin: alibaba/jstorm

boolean useJavaSer = JStormUtils.parseBoolean(conf.get("fall.back.on.java.serialization"), true);
Config.setFallBackOnJavaSerialization(conf, useJavaSer);

代码示例来源:origin: alibaba/jstorm

boolean useJavaSer = JStormUtils.parseBoolean(conf.get("fall.back.on.java.serialization"), true);
Config.setFallBackOnJavaSerialization(conf, useJavaSer);

代码示例来源:origin: com.alibaba.jstorm/jstorm-core

public void setFallBackOnJavaSerialization(boolean fallback) {
  setFallBackOnJavaSerialization(this, fallback);
}

代码示例来源:origin: com.twitter.heron/heron-storm

public void setFallBackOnJavaSerialization(boolean fallback) {
  setFallBackOnJavaSerialization(this, fallback);
 }
}

代码示例来源:origin: com.n3twork.storm/storm-core

public void setFallBackOnJavaSerialization(boolean fallback) {
  setFallBackOnJavaSerialization(this, fallback);
}

代码示例来源:origin: openimaj/openimaj

@Override
public Config prepareConfig() {
  if (preparedConfig == null) {
    preparedConfig = new Config();
    preparedConfig.setMaxSpoutPending(500);
    preparedConfig.setNumWorkers(numberOfWorkers);
    preparedConfig.setFallBackOnJavaSerialization(false);
    preparedConfig.setSkipMissingKryoRegistrations(false);
    JenaStormUtils.registerSerializers(preparedConfig);
  }
  return preparedConfig;
}

代码示例来源:origin: openimaj/openimaj

public static void main(String[] args) {
    final Config conf = new Config();
    conf.setDebug(false);
    conf.setNumWorkers(2);
    conf.setMaxSpoutPending(1);
    conf.setFallBackOnJavaSerialization(false);
    conf.setSkipMissingKryoRegistrations(false);
    final LocalCluster cluster = new LocalCluster();
    final TopologyBuilder builder = new TopologyBuilder();
    builder.setSpout("randomSpout1", new RandomFieldSpout(2, 0, 0, 1)); // (nfields,seed,min,max)
    builder.setSpout("randomSpout2", new RandomFieldSpout(2, 10, 0, 1)); // (nfields,seed,min,max)
    JoinBolt.connectNewBolt(builder);
    final StormTopology topology = builder.createTopology();
    cluster.submitTopology("playTopology", conf, topology);
    Utils.sleep(10000);
    cluster.killTopology("playTopology");
    cluster.shutdown();

  }
}

代码示例来源:origin: org.openimaj.storm/core-storm

public static void main(String[] args) {
    final Config conf = new Config();
    conf.setDebug(false);
    conf.setNumWorkers(2);
    conf.setMaxSpoutPending(1);
    conf.setFallBackOnJavaSerialization(false);
    conf.setSkipMissingKryoRegistrations(false);
    final LocalCluster cluster = new LocalCluster();
    final TopologyBuilder builder = new TopologyBuilder();
    builder.setSpout("randomSpout1", new RandomFieldSpout(2, 0, 0, 1)); // (nfields,seed,min,max)
    builder.setSpout("randomSpout2", new RandomFieldSpout(2, 10, 0, 1)); // (nfields,seed,min,max)
    JoinBolt.connectNewBolt(builder);
    final StormTopology topology = builder.createTopology();
    cluster.submitTopology("playTopology", conf, topology);
    Utils.sleep(10000);
    cluster.killTopology("playTopology");
    cluster.shutdown();

  }
}

相关文章