org.elasticsearch.common.component.Lifecycle.moveToStarted()方法的使用及代码示例

x33g5p2x  于2022-01-24 转载在 其他  
字(5.5k)|赞(0)|评价(0)|浏览(92)

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

Lifecycle.moveToStarted介绍

暂无

代码示例

代码示例来源:origin: org.elasticsearch/elasticsearch

TransportKeepAlive(ThreadPool threadPool, AsyncBiFunction<TcpChannel, BytesReference, Void> pingSender) {
  this.threadPool = threadPool;
  this.pingSender = pingSender;
  try (BytesStreamOutput out = new BytesStreamOutput()) {
    out.writeByte((byte) 'E');
    out.writeByte((byte) 'S');
    out.writeInt(PING_DATA_SIZE);
    pingMessage = out.bytes();
  } catch (IOException e) {
    throw new AssertionError(e.getMessage(), e); // won't happen
  }
  this.lifecycle.moveToStarted();
}

代码示例来源:origin: org.elasticsearch/elasticsearch

@SuppressWarnings({"unchecked"})
@Override
public void start() {
  if (!lifecycle.canMoveToStarted()) {
    return;
  }
  for (LifecycleListener listener : listeners) {
    listener.beforeStart();
  }
  doStart();
  lifecycle.moveToStarted();
  for (LifecycleListener listener : listeners) {
    listener.afterStart();
  }
}

代码示例来源:origin: org.elasticsearch/elasticsearch

if (!lifecycle.moveToStarted()) {
  return this;

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.elasticsearch

public ConnectionManager(Settings settings, Transport transport, ThreadPool threadPool, ConnectionProfile defaultProfile) {
  this.transport = transport;
  this.threadPool = threadPool;
  this.pingSchedule = TcpTransport.PING_SCHEDULE.get(settings);
  this.defaultProfile = defaultProfile;
  this.lifecycle.moveToStarted();
  if (pingSchedule.millis() > 0) {
    threadPool.schedule(pingSchedule, ThreadPool.Names.GENERIC, new ScheduledPing());
  }
}

代码示例来源:origin: apache/servicemix-bundles

public ConnectionManager(Settings settings, Transport transport, ThreadPool threadPool, ConnectionProfile defaultProfile) {
  this.transport = transport;
  this.threadPool = threadPool;
  this.pingSchedule = TcpTransport.PING_SCHEDULE.get(settings);
  this.defaultProfile = defaultProfile;
  this.lifecycle.moveToStarted();
  if (pingSchedule.millis() > 0) {
    threadPool.schedule(pingSchedule, ThreadPool.Names.GENERIC, new ScheduledPing());
  }
}

代码示例来源:origin: harbby/presto-connectors

@SuppressWarnings({"unchecked"})
@Override
public T start() {
  if (!lifecycle.canMoveToStarted()) {
    return (T) this;
  }
  for (LifecycleListener listener : listeners) {
    listener.beforeStart();
  }
  doStart();
  lifecycle.moveToStarted();
  for (LifecycleListener listener : listeners) {
    listener.afterStart();
  }
  return (T) this;
}

代码示例来源:origin: com.strapdata.elasticsearch/elasticsearch

@SuppressWarnings({"unchecked"})
@Override
public void start() {
  if (!lifecycle.canMoveToStarted()) {
    return;
  }
  for (LifecycleListener listener : listeners) {
    listener.beforeStart();
  }
  doStart();
  lifecycle.moveToStarted();
  for (LifecycleListener listener : listeners) {
    listener.afterStart();
  }
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.elasticsearch

@SuppressWarnings({"unchecked"})
@Override
public void start() {
  if (!lifecycle.canMoveToStarted()) {
    return;
  }
  for (LifecycleListener listener : listeners) {
    listener.beforeStart();
  }
  doStart();
  lifecycle.moveToStarted();
  for (LifecycleListener listener : listeners) {
    listener.afterStart();
  }
}

代码示例来源:origin: apache/servicemix-bundles

@SuppressWarnings({"unchecked"})
@Override
public void start() {
  if (!lifecycle.canMoveToStarted()) {
    return;
  }
  for (LifecycleListener listener : listeners) {
    listener.beforeStart();
  }
  doStart();
  lifecycle.moveToStarted();
  for (LifecycleListener listener : listeners) {
    listener.afterStart();
  }
}

代码示例来源:origin: com.strapdata.elasticsearch/elasticsearch

if (!lifecycle.moveToStarted()) {
  return this;

代码示例来源:origin: apache/servicemix-bundles

if (!lifecycle.moveToStarted()) {
  return this;

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.elasticsearch

if (!lifecycle.moveToStarted()) {
  return this;

代码示例来源:origin: org.fusesource.insight/insight-elasticsearch

public Node start() {
  if (!lifecycle.moveToStarted()) {
    return this;
  }
  ESLogger logger = Loggers.getLogger(Node.class, settings.get("name"));
  logger.info("{{}}[{}]: starting ...", Version.CURRENT, JvmInfo.jvmInfo().pid());
  for (Class<? extends LifecycleComponent> plugin : pluginsService.services()) {
    injector.getInstance(plugin).start();
  }
  injector.getInstance(IndicesService.class).start();
  injector.getInstance(IndexingMemoryController.class).start();
  injector.getInstance(IndicesClusterStateService.class).start();
  injector.getInstance(IndicesTTLService.class).start();
  injector.getInstance(RiversManager.class).start();
  injector.getInstance(ClusterService.class).start();
  injector.getInstance(RoutingService.class).start();
  injector.getInstance(SearchService.class).start();
  injector.getInstance(MonitorService.class).start();
  injector.getInstance(RestController.class).start();
  injector.getInstance(TransportService.class).start();
  DiscoveryService discoService = injector.getInstance(DiscoveryService.class).start();
  // gateway should start after disco, so it can try and recovery from gateway on "start"
  injector.getInstance(GatewayService.class).start();
  if (settings.getAsBoolean("http.enabled", true)) {
    injector.getInstance(HttpServer.class).start();
  }
  injector.getInstance(JmxService.class).connectAndRegister(discoService.nodeDescription(), injector.getInstance(NetworkService.class));
  logger.info("{{}}[{}]: started", Version.CURRENT, JvmInfo.jvmInfo().pid());
  return this;
}

代码示例来源:origin: io.fabric8.insight/insight-elasticsearch

public Node start() {
  if (!lifecycle.moveToStarted()) {
    return this;

代码示例来源:origin: harbby/presto-connectors

if (!lifecycle.moveToStarted()) {
  return this;

相关文章