Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 29 for threadpool (0.2 sec)

  1. src/main/java/org/codelibs/curl/CurlRequest.java

            } catch (final UnsupportedEncodingException e) {
                throw new CurlException("Invalid encoding: " + encoding, e);
            }
        }
    
        public CurlRequest threadPool(final ForkJoinPool threadPool) {
            this.threadPool = threadPool;
            return this;
        }
    
        public static class RequestProcessor implements Consumer<HttpURLConnection> {
            protected CurlResponse response = new CurlResponse();
    
    Java
    - Registered: Thu Apr 25 15:34:08 GMT 2024
    - Last Modified: Sun Feb 12 12:21:25 GMT 2023
    - 12.3K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/collect/QueuesTest.java

       * be a SynchronousQueue.
       */
      private ExecutorService threadPool;
    
      @Override
      public void setUp() {
        threadPool = newCachedThreadPool();
      }
    
      @Override
      public void tearDown() throws InterruptedException {
        threadPool.shutdown();
        assertTrue("Some worker didn't finish in time", threadPool.awaitTermination(10, SECONDS));
      }
    
      private static <T> int drain(
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 12K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/util/concurrent/AtomicLongMapBasherTest.java

        final String key = "key";
    
        final AtomicLongMap<String> map = AtomicLongMap.create();
    
        ExecutorService threadPool = Executors.newFixedThreadPool(nThreads);
        ArrayList<Future<Long>> futures = new ArrayList<>();
        for (int i = 0; i < nTasks; i++) {
          futures.add(
              threadPool.submit(
                  new Callable<Long>() {
                    @Override
                    public Long call() {
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Tue Feb 13 14:28:25 GMT 2024
    - 4.2K bytes
    - Viewed (0)
  4. fastapi/concurrency.py

    from starlette.concurrency import iterate_in_threadpool as iterate_in_threadpool  # noqa
    from starlette.concurrency import run_in_threadpool as run_in_threadpool  # noqa
    from starlette.concurrency import (  # noqa
        run_until_first_complete as run_until_first_complete,
    )
    
    _T = TypeVar("_T")
    
    
    @asynccontextmanager
    async def contextmanager_in_threadpool(
        cm: ContextManager[_T],
    ) -> AsyncGenerator[_T, None]:
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Mon Dec 25 17:57:35 GMT 2023
    - 1.4K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/cache/CacheBuilderTest.java

        ExecutorService threadPool = Executors.newFixedThreadPool(nThreads);
        final CountDownLatch tasksFinished = new CountDownLatch(nTasks);
        for (int i = 0; i < nTasks; i++) {
          final String s = "a" + i;
          @SuppressWarnings("unused") // https://errorprone.info/bugpattern/FutureReturnValueIgnored
          Future<?> possiblyIgnoredError =
              threadPool.submit(
                  new Runnable() {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Oct 03 20:10:02 GMT 2023
    - 23.2K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/collect/QueuesTest.java

       * be a SynchronousQueue.
       */
      private ExecutorService threadPool;
    
      @Override
      public void setUp() {
        threadPool = newCachedThreadPool();
      }
    
      @Override
      public void tearDown() throws InterruptedException {
        threadPool.shutdown();
        assertTrue("Some worker didn't finish in time", threadPool.awaitTermination(10, SECONDS));
      }
    
      private static <T> int drain(
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 12K bytes
    - Viewed (0)
  7. android/guava-tests/test/com/google/common/util/concurrent/AtomicLongMapBasherTest.java

        final String key = "key";
    
        final AtomicLongMap<String> map = AtomicLongMap.create();
    
        ExecutorService threadPool = Executors.newFixedThreadPool(nThreads);
        ArrayList<Future<Long>> futures = new ArrayList<>();
        for (int i = 0; i < nTasks; i++) {
          futures.add(
              threadPool.submit(
                  new Callable<Long>() {
                    @Override
                    public Long call() {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Feb 13 14:28:25 GMT 2024
    - 4.2K bytes
    - Viewed (0)
  8. fastapi/datastructures.py

            To be awaitable, compatible with async, this is run in threadpool.
            """
            return await super().seek(offset)
    
        async def close(self) -> None:
            """
            Close the file.
    
            To be awaitable, compatible with async, this is run in threadpool.
            """
            return await super().close()
    
        @classmethod
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Apr 02 02:48:51 GMT 2024
    - 5.6K bytes
    - Viewed (0)
  9. guava-tests/test/com/google/common/cache/CacheBuilderTest.java

        ExecutorService threadPool = Executors.newFixedThreadPool(nThreads);
        final CountDownLatch tasksFinished = new CountDownLatch(nTasks);
        for (int i = 0; i < nTasks; i++) {
          final String s = "a" + i;
          @SuppressWarnings("unused") // https://errorprone.info/bugpattern/FutureReturnValueIgnored
          Future<?> possiblyIgnoredError =
              threadPool.submit(
                  new Runnable() {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Tue Oct 03 20:10:02 GMT 2023
    - 25.5K bytes
    - Viewed (0)
  10. fastapi/dependencies/utils.py

        sequence_types,
        serialize_sequence_value,
        value_is_sequence,
    )
    from fastapi.background import BackgroundTasks
    from fastapi.concurrency import (
        asynccontextmanager,
        contextmanager_in_threadpool,
    )
    from fastapi.dependencies.models import Dependant, SecurityRequirement
    from fastapi.logger import logger
    from fastapi.security.base import SecurityBase
    from fastapi.security.oauth2 import OAuth2, SecurityScopes
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Tue Apr 02 02:52:56 GMT 2024
    - 29.5K bytes
    - Viewed (0)
Back to top