当前位置: 首页>>代码示例>>Java>>正文


Java ClusterService.assertClusterStateThread方法代码示例

本文整理汇总了Java中org.elasticsearch.cluster.service.ClusterService.assertClusterStateThread方法的典型用法代码示例。如果您正苦于以下问题:Java ClusterService.assertClusterStateThread方法的具体用法?Java ClusterService.assertClusterStateThread怎么用?Java ClusterService.assertClusterStateThread使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.elasticsearch.cluster.service.ClusterService的用法示例。


在下文中一共展示了ClusterService.assertClusterStateThread方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: onFailure

import org.elasticsearch.cluster.service.ClusterService; //导入方法依赖的package包/类
private void onFailure(Throwable t) {
    ClusterService.assertClusterStateThread();
    ElectionCallback callback = getCallback(); // get under lock
    if (callback != null) {
        callback.onFailure(t);
    }
}
 
开发者ID:justor,项目名称:elasticsearch_my,代码行数:8,代码来源:NodeJoinController.java

示例2: markThreadAsDoneAndStartNew

import org.elasticsearch.cluster.service.ClusterService; //导入方法依赖的package包/类
/**
 * marks the given joinThread as completed and makes sure another thread is running (starting one if needed)
 * If the given thread is not the currently running join thread, the command is ignored.
 */
public void markThreadAsDoneAndStartNew(Thread joinThread) {
    ClusterService.assertClusterStateThread();
    if (!markThreadAsDone(joinThread)) {
        return;
    }
    startNewThreadIfNotRunning();
}
 
开发者ID:justor,项目名称:elasticsearch_my,代码行数:12,代码来源:ZenDiscovery.java

示例3: stopRunningThreadAndRejoin

import org.elasticsearch.cluster.service.ClusterService; //导入方法依赖的package包/类
/** cleans any running joining thread and calls {@link #rejoin} */
public ClusterStateTaskExecutor.ClusterTasksResult<LocalClusterUpdateTask> stopRunningThreadAndRejoin(ClusterState clusterState, String reason) {
    ClusterService.assertClusterStateThread();
    currentJoinThread.set(null);
    return rejoin(clusterState, reason);
}
 
开发者ID:justor,项目名称:elasticsearch_my,代码行数:7,代码来源:ZenDiscovery.java

示例4: markThreadAsDone

import org.elasticsearch.cluster.service.ClusterService; //导入方法依赖的package包/类
/** marks the given joinThread as completed. Returns false if the supplied thread is not the currently active join thread */
public boolean markThreadAsDone(Thread joinThread) {
    ClusterService.assertClusterStateThread();
    return currentJoinThread.compareAndSet(joinThread, null);
}
 
开发者ID:justor,项目名称:elasticsearch_my,代码行数:6,代码来源:ZenDiscovery.java

示例5: assertClusterStateThread

import org.elasticsearch.cluster.service.ClusterService; //导入方法依赖的package包/类
protected void assertClusterStateThread() {
    ClusterService.assertClusterStateThread();
}
 
开发者ID:justor,项目名称:elasticsearch_my,代码行数:4,代码来源:DelayedAllocationService.java


注:本文中的org.elasticsearch.cluster.service.ClusterService.assertClusterStateThread方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。