- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 260 for Executor (0.05 sec)
-
src/test/java/jcifs/smb/SmbSessionImplSecurityTest.java
int iterations = 1000; ExecutorService executor = Executors.newFixedThreadPool(2); CountDownLatch endLatch = new CountDownLatch(2); AtomicInteger successCount = new AtomicInteger(0); List<Exception> exceptions = Collections.synchronizedList(new ArrayList<>()); // Thread 1: Continuously adds trees executor.submit(() -> { try {Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Sun Aug 31 08:00:57 UTC 2025 - 11K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/util/concurrent/MoreExecutorsTest.java
barrier.await(1, SECONDS); assertFalse(executor.isShutdown()); assertFalse(executor.isTerminated()); executor.shutdown(); assertTrue(executor.isShutdown()); assertThrows(RejectedExecutionException.class, () -> executor.submit(() -> {})); assertFalse(executor.isTerminated()); // WAIT #2 barrier.await(1, SECONDS); assertFalse(executor.awaitTermination(20, MILLISECONDS));
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Fri Dec 12 00:25:21 UTC 2025 - 26.5K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/JdkFutureAdapters.java
*/ public static <V extends @Nullable Object> ListenableFuture<V> listenInPoolThread( Future<V> future, Executor executor) { checkNotNull(executor); if (future instanceof ListenableFuture) { return (ListenableFuture<V>) future; } return new ListenableFutureAdapter<>(future, executor); } /** * An adapter to turn a {@link Future} into a {@link ListenableFuture}. This will wait on the
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Thu Jul 17 15:26:41 UTC 2025 - 7.5K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/AbstractFutureTest.java
public String get(long time, TimeUnit unit) { throw new CancellationException(); // BAD!! } @Override public void addListener(Runnable runnable, Executor executor) { executor.execute(runnable); } }; future.setFuture(badFuture); ExecutionException expected = getExpectingExecutionException(future);
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Thu Dec 11 20:45:32 UTC 2025 - 46.8K bytes - Viewed (0) -
fess-crawler/src/test/java/org/codelibs/fess/crawler/interval/impl/HostIntervalControllerTest.java
// Execution failed } finally { executor.shutdown(); try { if (!executor.awaitTermination(10, java.util.concurrent.TimeUnit.SECONDS)) { executor.shutdownNow(); } } catch (final InterruptedException e) { executor.shutdownNow(); } }Registered: Sat Dec 20 11:21:39 UTC 2025 - Last Modified: Mon Nov 24 03:59:47 UTC 2025 - 11.4K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/util/concurrent/SequentialExecutorTest.java
SettableFuture<?> future = SettableFuture.create(); Executor delegate = new Executor() { @Override public void execute(Runnable task) { if (future.set(null)) { awaitUninterruptibly(latch); } throw new RejectedExecutionException(); } }; SequentialExecutor executor = new SequentialExecutor(delegate);
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Fri Jul 11 18:52:30 UTC 2025 - 11.4K bytes - Viewed (0) -
fess-crawler-opensearch/src/test/java/org/codelibs/fess/crawler/client/FesenClientTest.java
final int numThreads = 10; final ExecutorService executor = Executors.newFixedThreadPool(numThreads); final CountDownLatch latch = new CountDownLatch(numThreads); final AtomicInteger callbackCount = new AtomicInteger(0); // Add listeners concurrently from multiple threads for (int i = 0; i < numThreads; i++) { executor.submit(() -> { try {Registered: Sat Dec 20 11:21:39 UTC 2025 - Last Modified: Thu Nov 20 08:44:44 UTC 2025 - 17K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/util/concurrent/ExecutionSequencerTest.java
@NullUnmarked public class ExecutionSequencerTest extends TestCase { ExecutorService executor; private ExecutionSequencer serializer; private SettableFuture<@Nullable Void> firstFuture; private TestCallable firstCallable; @Override public void setUp() throws Exception { executor = newCachedThreadPool(); serializer = ExecutionSequencer.create(); firstFuture = SettableFuture.create();Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Tue Sep 23 01:35:55 UTC 2025 - 16.2K bytes - Viewed (0) -
guava/src/com/google/common/util/concurrent/AbstractScheduledService.java
public Cancellable schedule( AbstractService service, ScheduledExecutorService executor, Runnable task) { return new FutureAsCancellable( executor.scheduleAtFixedRate(task, initialDelay, period, unit)); } }; } /** Schedules the task to run on the provided executor on behalf of the service. */ abstract Cancellable schedule(
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Sat Aug 09 01:14:59 UTC 2025 - 27.8K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/cache/CacheLoaderTest.java
assertThat(loadCount.get()).isEqualTo(1); assertThat(reloadCount.get()).isEqualTo(1); assertThat(loadAllCount.get()).isEqualTo(1); QueuingExecutor executor = new QueuingExecutor(); CacheLoader<Object, Object> asyncReloader = CacheLoader.asyncReloading(baseLoader, executor); Object unused3 = asyncReloader.load(new Object()); @SuppressWarnings("unused") // https://errorprone.info/bugpattern/FutureReturnValueIgnored
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Tue Sep 30 22:03:28 UTC 2025 - 3.8K bytes - Viewed (0)