Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 42 for 100 (0.16 sec)

  1. okhttp/src/main/kotlin/okhttp3/ConnectionPool.kt

        @JvmField val backoffDelayMillis: Long = 60 * 1000,
        /** How much jitter to introduce in connection retry backoff delays */
        @JvmField val backoffJitterMillis: Int = 100,
      )
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 03 20:39:41 GMT 2024
    - 5.6K bytes
    - Viewed (0)
  2. 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)
  3. okhttp/src/test/java/okhttp3/URLConnectionTest.kt

      }
    
      @Test
      fun streamDiscardingIsTimely() {
        // This response takes at least a full second to serve: 10,000 bytes served 100 bytes at a time.
        server.enqueue(
          MockResponse.Builder()
            .body(Buffer().write(ByteArray(10000)))
            .throttleBody(100, 10, TimeUnit.MILLISECONDS)
            .build(),
        )
        server.enqueue(
          MockResponse(body = "A"),
        )
    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)
  4. okhttp-brotli/src/test/java/okhttp3/brotli/BrotliBombTest.kt

        }.isInstanceOf<IOException>()
          .message()
          .isNotNull()
          .matches(
            Regex(
              "decompression bomb\\? outputByteCount=\\d+, inputByteCount=\\d+ exceeds max ratio of 100",
            ),
          )
      }
    
      /** Returns a ByteString that expands to 10 GiB when Brotli-decompressed. */
      private fun readBrotli10G(): ByteString {
        val gzippedBrotliBomb =
          (
    Plain Text
    - Registered: Fri Mar 29 11:42:11 GMT 2024
    - Last Modified: Mon Jan 29 22:50:20 GMT 2024
    - 2.9K bytes
    - Viewed (0)
  5. samples/guide/src/main/java/okhttp3/recipes/Progress.java

                }
              }
    
              System.out.println(bytesRead);
    
              if (contentLength != -1) {
                System.out.format("%d%% done\n", (100 * bytesRead) / contentLength);
              }
            }
          }
        };
    
        OkHttpClient client = new OkHttpClient.Builder()
            .addNetworkInterceptor(chain -> {
    Java
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 12 03:31:36 GMT 2019
    - 3.9K bytes
    - Viewed (0)
  6. okhttp/src/test/java/okhttp3/internal/http/ThreadInterruptTest.kt

                  override fun writeTo(sink: BufferedSink) {
                    for (i in 0..9) {
                      sink.writeByte(0)
                      sink.flush()
                      sleep(100)
                    }
                    fail("Expected connection to be closed")
                  }
                },
              )
              .build(),
          )
        interruptLater(500)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 4.6K bytes
    - Viewed (0)
  7. okhttp-testing-support/src/main/kotlin/okhttp3/TestUtilJvm.kt

       * java/lang/ref/FinalizationTester.java
       */
      @Throws(Exception::class)
      @JvmStatic
      fun awaitGarbageCollection() {
        Runtime.getRuntime().gc()
        Thread.sleep(100)
        System.runFinalization()
      }
    
      @JvmStatic
      fun assumeNetwork() {
        try {
          InetAddress.getByName("www.google.com")
        } catch (uhe: UnknownHostException) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Thu Apr 11 22:09:35 GMT 2024
    - 4.3K bytes
    - Viewed (0)
  8. okhttp/src/test/java/okhttp3/DuplexTest.kt

            .add100Continue()
            .streamHandler(body)
            .build(),
        )
        val call =
          client.newCall(
            Request.Builder()
              .url(server.url("/"))
              .header("Expect", "100-continue")
              .post(AsyncRequestBody())
              .build(),
          )
        call.execute().use { response ->
          val requestBody = (call.request().body as AsyncRequestBody?)!!.takeSink()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 23.9K bytes
    - Viewed (0)
  9. mockwebserver/src/main/kotlin/mockwebserver3/MockWebServer.kt

              httpHeaders.add(name, value)
            } else {
              throw IllegalStateException()
            }
            if (name == "expect" && value.equals("100-continue", ignoreCase = true)) {
              // Don't read the body unless we've invited the client to send it.
              readBody = false
            }
          }
          val headers = httpHeaders.build()
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Mar 31 17:16:15 GMT 2024
    - 37.4K bytes
    - Viewed (0)
  10. okhttp/src/test/java/okhttp3/CacheTest.kt

        // Test each documented HTTP/1.1 code, plus the first unused value in each range.
        // http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html
    
        // We can't test 100 because it's not really a response.
        // assertCached(false, 100);
        assertCached(false, 101)
        assertCached(true, 200)
        assertCached(false, 201)
        assertCached(false, 202)
        assertCached(true, 203)
        assertCached(true, 204)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 10 19:46:48 GMT 2024
    - 108.6K bytes
    - Viewed (0)
Back to top