Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 68 for QThread (0.18 sec)

  1. okhttp/src/main/kotlin/okhttp3/internal/cache2/Relay.kt

      /** The maximum size of [buffer]. */
      val bufferMaxSize: Long,
    ) {
      /** The thread that currently has access to upstream. Possibly null. Guarded by this. */
      var upstreamReader: Thread? = null
    
      /**
       * A buffer for [upstreamReader] to use when pulling bytes from upstream. Only the
       * [upstreamReader] thread may access this buffer.
       */
      val upstreamBuffer = Buffer()
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 11.8K bytes
    - Viewed (0)
  2. okhttp-testing-support/src/main/kotlin/okhttp3/RecordingConnectionListener.kt

          takeEvent()
        }
      }
    
      private fun logEvent(e: ConnectionEvent) {
        if (e.connection != null) {
          assertThat(Thread.holdsLock(e.connection), "Called with lock $${e.connection}")
            .isFalse()
        }
        for (lock in forbiddenLocks) {
          assertThat(Thread.holdsLock(lock), "Called with lock $lock")
            .isFalse()
        }
    
        if (enforceOrder) {
          checkForStartEvent(e)
        }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 5.6K bytes
    - Viewed (0)
  3. okhttp/src/main/kotlin/okhttp3/Interceptor.kt

     *
     *  * For asynchronous calls made with [Call.enqueue], an [IOException] is propagated to the caller
     *    indicating that the call was canceled. The interceptor's exception is delivered to the current
     *    thread's [uncaught exception handler][Thread.UncaughtExceptionHandler]. By default this
     *    crashes the application on Android and prints a stacktrace on the JVM. (Crash reporting
     *    libraries may customize this behavior.)
     *
    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)
  4. okhttp/src/main/kotlin/okhttp3/internal/connection/RealCall.kt

            ******@****.***()
          }
        }.apply {
          timeout(client.callTimeoutMillis.toLong(), MILLISECONDS)
        }
    
      private val executed = AtomicBoolean()
    
      // These properties are only accessed by the thread executing the call.
    
      /** Initialized in [callStart]. */
      private var callStackTrace: Any? = null
    
      /** Finds an exchange to send the next request and receive the next response. */
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 17.9K bytes
    - Viewed (2)
  5. mockwebserver/src/main/kotlin/mockwebserver3/internal/SleepNanos.kt

     *
     */
    package mockwebserver3.internal
    
    internal fun sleepNanos(nanos: Long) {
      val ms = nanos / 1_000_000L
      val ns = nanos - (ms * 1_000_000L)
      if (ms > 0L || nanos > 0) {
        Thread.sleep(ms, ns.toInt())
      }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Jan 07 16:05:34 GMT 2024
    - 811 bytes
    - Viewed (0)
  6. okhttp/src/main/kotlin/okhttp3/Callback.kt

       * proceed to read the response body with [Response.body]. The response is still live until its
       * response body is [closed][ResponseBody]. The recipient of the callback may consume the response
       * body on another thread.
       *
       * Note that transport-layer success (receiving a HTTP response code, headers and body) does not
       * necessarily indicate application-layer success: `response` may still indicate an unhappy HTTP
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.6K bytes
    - Viewed (0)
  7. docs/changelogs/changelog_4x.md

     *  Fix: Don't crash when the URL hostname contains an underscore on Android.
     *  Fix: Change HTTP/2 to use a daemon thread for its socket reader. If you've ever seen a command
        line application hang after all of the work is done, it may be due to a non-daemon thread like
        this one.
     *  New: Include suppressed exceptions when all routes to a target service fail.
    
    
    ## Version 4.4.1
    
    _2020-03-08_
    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)
  8. okhttp/src/test/java/okhttp3/ServerTruncatesRequestTest.kt

        override fun contentType(): MediaType? = null
    
        override fun writeTo(sink: BufferedSink) {
          for (i in 0 until 50) {
            sink.writeUtf8("abc")
            sink.flush()
            Thread.sleep(100)
          }
          fail("")
        }
      }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 9.5K bytes
    - Viewed (0)
  9. okhttp/src/test/java/okhttp3/URLConnectionTest.kt

        assertThat(server.takeRequest().sequenceNumber).isEqualTo(0)
    
        // Give the server time to enact the socket policy if it's one that could happen after the
        // client has received the response.
        Thread.sleep(500)
        val response2 = getResponse(newRequest("/b"))
        response1.body.source().timeout().timeout(100, TimeUnit.MILLISECONDS)
        assertContent("This comes after a busted connection", response2)
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 131.7K bytes
    - Viewed (0)
  10. samples/guide/src/main/java/okhttp3/recipes/PostStreamingWithPipe.java

      }
    
      private void streamPrimesToSinkAsynchronously(final BufferedSink sink) {
        Thread thread = new Thread("writer") {
          @Override public void run() {
            try {
              sink.writeUtf8("Numbers\n");
              sink.writeUtf8("-------\n");
              for (int i = 2; i <= 997; i++) {
                System.out.println(i);
                Thread.sleep(10);
                sink.writeUtf8(String.format(" * %s = %s\n", i, factor(i)));
              }
    Java
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Fri Jul 06 03:18:15 GMT 2018
    - 3.1K bytes
    - Viewed (0)
Back to top