public static Thread createThread(ThreadGroup threadGroup, Runnable runnable, String name) { return createThread(threadGroup, runnable, name, false); }
public static Thread createThread(Runnable runnable, String name) { return createThread(null, runnable, name); }
public static Thread createThread(Runnable runnable, String name) { return createThread(null, runnable, name); }
public static Thread createThread(Runnable runnable, String name, boolean daemon) { return createThread(null, runnable, name, daemon); }
public static Thread createThread(Runnable runnable, String name, boolean daemon) { return createThread(null, runnable, name, daemon); }
public static Thread createThread(Runnable runnable, String name) { return createThread(null, runnable, name); }
@VisibleForTesting public static Thread createThread(Runnable runnable) { return createThread(null, runnable, "anonymous-" + threadCounter.incrementAndGet()); }
@VisibleForTesting public static Thread createThread(Runnable runnable) { return createThread(null, runnable, "anonymous-" + threadCounter.incrementAndGet()); }
@VisibleForTesting public static Thread createThread(Runnable runnable) { return createThread(null, runnable, "anonymous-" + threadCounter.incrementAndGet()); }
@VisibleForTesting public static Thread createThread(Runnable runnable) { return createThread(null, runnable, "anonymous-" + threadCounter.incrementAndGet()); }
public Thread newThread(Runnable runnable) { String name = id + ':' + n.getAndIncrement(); Thread thread = createThread(threadGroup, runnable, name, true); thread.setPriority(priority); if (contextClassLoader != null) thread.setContextClassLoader(contextClassLoader); return thread; }
public Thread newThread(Runnable runnable) { String name = id + ':' + n.getAndIncrement(); Thread thread = createThread(threadGroup, runnable, name, true); thread.setPriority(priority); if (contextClassLoader != null) thread.setContextClassLoader(contextClassLoader); return thread; }
public Thread newThread(Runnable runnable) { String name = id + ':' + n.getAndIncrement(); Thread thread = createThread(threadGroup, runnable, name, true); thread.setPriority(priority); if (contextClassLoader != null) thread.setContextClassLoader(contextClassLoader); return thread; }
public Thread newThread(Runnable runnable) { String name = id + ':' + n.getAndIncrement(); Thread thread = createThread(threadGroup, runnable, name, true); thread.setPriority(priority); if (contextClassLoader != null) thread.setContextClassLoader(contextClassLoader); return thread; }
void start() { if (syncIntervalNanos < 1) throw new IllegalArgumentException(String.format("Commit log flush interval must be positive: %fms", syncIntervalNanos * 1e-6)); shutdown = false; Runnable runnable = new SyncRunnable(new Clock()); thread = NamedThreadFactory.createThread(runnable, name); thread.start(); }
void start() { if (syncIntervalNanos < 1) throw new IllegalArgumentException(String.format("Commit log flush interval must be positive: %fms", syncIntervalNanos * 1e-6)); shutdown = false; Runnable runnable = new SyncRunnable(new Clock()); thread = NamedThreadFactory.createThread(runnable, name); thread.start(); }
void start() { if (syncIntervalNanos < 1) throw new IllegalArgumentException(String.format("Commit log flush interval must be positive: %fms", syncIntervalNanos * 1e-6)); shutdown = false; Runnable runnable = new SyncRunnable(new Clock()); thread = NamedThreadFactory.createThread(runnable, name); thread.start(); }
public int forceRepairAsync(String keyspace, RepairOption options, boolean legacy) { if (options.getRanges().isEmpty() || Keyspace.open(keyspace).getReplicationStrategy().getReplicationFactor() < 2) return 0; int cmd = nextRepairCommand.incrementAndGet(); NamedThreadFactory.createThread(createRepairTask(cmd, keyspace, options, legacy), "Repair-Task-" + threadCounter.incrementAndGet()).start(); return cmd; }
public int forceRepairAsync(String keyspace, RepairOption options, boolean legacy) { if (options.getRanges().isEmpty() || Keyspace.open(keyspace).getReplicationStrategy().getReplicationFactor() < 2) return 0; int cmd = nextRepairCommand.incrementAndGet(); NamedThreadFactory.createThread(createRepairTask(cmd, keyspace, options, legacy), "Repair-Task-" + threadCounter.incrementAndGet()).start(); return cmd; }
public int forceRepairAsync(String keyspace, RepairOption options, boolean legacy) { if (options.getRanges().isEmpty() || Keyspace.open(keyspace).getReplicationStrategy().getReplicationFactor() < 2) return 0; int cmd = nextRepairCommand.incrementAndGet(); NamedThreadFactory.createThread(createRepairTask(cmd, keyspace, options, legacy), "Repair-Task-" + threadCounter.incrementAndGet()).start(); return cmd; }