Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 26 for tank (0.13 sec)

  1. docs/changelogs/changelog_4x.md

     *  New: Share threads more aggressively between OkHttp's HTTP/2 connections, connection pool,
        web sockets, and cache. OkHttp has a new internal task runner abstraction for managed task
        scheduling. In your debugger you will see new thread names and more use of daemon threads.
    
     *  Fix: Don't drop callbacks on unexpected exceptions. When an interceptor throws an unchecked
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 17 13:25:31 GMT 2024
    - 25.2K bytes
    - Viewed (0)
  2. okhttp/src/main/kotlin/okhttp3/internal/concurrent/Task.kt

     *
     * Recurrence
     * ----------
     *
     * Tasks control their recurrence schedule. The [runOnce] function returns -1L to signify that the
     * task should not be executed again. Otherwise it returns a delay until the next execution.
     *
     * A task has at most one next execution. If the same task instance is scheduled multiple times, the
     * earliest one wins. This applies to both executions scheduled with [TaskRunner.Queue.schedule] and
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 2.4K bytes
    - Viewed (0)
  3. okhttp/src/main/kotlin/okhttp3/internal/concurrent/TaskQueue.kt

       * is running when that time is reached, that task is allowed to complete before this task is
       * started. Similarly the task will be delayed if the host lacks compute resources.
       *
       * @throws RejectedExecutionException if the queue is shut down and the task is not cancelable.
       */
      fun schedule(
        task: Task,
        delayNanos: Long = 0L,
      ) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 7.5K bytes
    - Viewed (0)
  4. okhttp/src/main/kotlin/okhttp3/internal/connection/FastFallbackExchangeFinder.kt

    import java.io.IOException
    import java.util.concurrent.CopyOnWriteArrayList
    import java.util.concurrent.LinkedBlockingDeque
    import java.util.concurrent.TimeUnit
    import okhttp3.internal.concurrent.Task
    import okhttp3.internal.concurrent.TaskRunner
    import okhttp3.internal.connection.RoutePlanner.ConnectResult
    import okhttp3.internal.connection.RoutePlanner.Plan
    import okhttp3.internal.okHttpName
    
    /**
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 5.8K bytes
    - Viewed (0)
  5. docs/contribute/concurrency.md

    #### Framed protocols
    
    Framed protocols like http/2 don't lend themselves to blocking APIs. Each application-layer thread wants to do blocking I/O for a specific stream, but the streams are multiplexed on the socket. You can't just talk to the socket, you need to cooperate with the other application-layer threads that you're sharing it with.
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Feb 06 16:35:36 GMT 2022
    - 7K bytes
    - Viewed (0)
  6. okhttp/src/test/java/okhttp3/CallTest.kt

          MockResponse(
            code = 503,
            headers = headersOf("Retry-After", "0"),
            body = "please retry",
          ),
        )
        server.enqueue(
          MockResponse(body = "thank you for retrying"),
        )
        val request =
          Request(
            url = server.url("/"),
            body =
              object : RequestBody() {
                var attempt = 0
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 10 19:46:48 GMT 2024
    - 142.5K bytes
    - Viewed (0)
  7. okhttp/src/main/kotlin/okhttp3/internal/concurrent/TaskRunner.kt

          startAnotherThread()
        }
      }
    
      private fun beforeRun(task: Task) {
        lock.assertHeld()
    
        task.nextExecuteNanoTime = -1L
        val queue = task.queue!!
        queue.futureTasks.remove(task)
        readyQueues.remove(queue)
        queue.activeTask = task
        busyQueues.add(queue)
      }
    
      private fun runTask(task: Task) {
        val currentThread = Thread.currentThread()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 29 00:33:04 GMT 2024
    - 10.6K bytes
    - Viewed (0)
  8. okhttp-testing-support/src/main/kotlin/okhttp3/internal/concurrent/TaskFaker.kt

      var nanoTime = 0L
        private set
    
      /** Backlog of tasks to run. Only one task runs at a time. Guarded by [TaskRunner.lock]. */
      private val serialTaskQueue = ArrayDeque<SerialTask>()
    
      /** The task that's currently executing. Guarded by [TaskRunner.lock]. */
      private var currentTask: SerialTask = TestThreadSerialTask
    
      /** The coordinator task if it's waiting, and how it will resume. Guarded by [TaskRunner.lock]. */
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 29 00:33:04 GMT 2024
    - 12.6K bytes
    - Viewed (0)
  9. okhttp/src/test/java/okhttp3/internal/concurrent/TaskRunnerRealBackendTest.kt

      }
    
      @Test fun taskFailsWithUncheckedException() {
        queue.schedule("task", TimeUnit.MILLISECONDS.toNanos(100)) {
          log.put("failing task running")
          throw RuntimeException("boom!")
        }
    
        queue.schedule("task", TimeUnit.MILLISECONDS.toNanos(200)) {
          log.put("normal task running")
          return@schedule -1L
        }
    
        queue.idleLatch().await(500, TimeUnit.MILLISECONDS)
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 3.5K bytes
    - Viewed (0)
  10. docs/contribute/debug_logging.md

    [2020-01-01 00:00:00] << 0x00000003     0 DATA          END_STREAM
    [2020-01-01 00:00:00] << 0x00000000     8 GOAWAY
    [2020-01-01 00:00:05] << 0x00000000     8 GOAWAY
    ```
    
    ### Task Runner Logging 
    
    This logs task enqueues, starts, and finishes.
    
    ```
    [2020-01-01 00:00:00] Q10000 scheduled after   0 µs: OkHttp ConnectionPool
    [2020-01-01 00:00:00] Q10000 starting              : OkHttp ConnectionPool
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Feb 06 16:35:36 GMT 2022
    - 2.7K bytes
    - Viewed (0)
Back to top