- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 20 for writeTimeout (0.1 sec)
-
okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Stream.kt
require(trailers.size != 0) { "trailers.size() == 0" } this.sink.trailers = trailers } } fun readTimeout(): Timeout = readTimeout fun writeTimeout(): Timeout = writeTimeout /** Returns a source that reads data from the peer. */ fun getSource(): Source = source /** * Returns a sink that can be used to write data to the peer. *
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Apr 20 17:03:43 UTC 2024 - 23.2K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/ConfigureTimeouts.java
public final class ConfigureTimeouts { private final OkHttpClient client; public ConfigureTimeouts() throws Exception { client = new OkHttpClient.Builder() .connectTimeout(5, TimeUnit.SECONDS) .writeTimeout(5, TimeUnit.SECONDS) .readTimeout(5, TimeUnit.SECONDS) .callTimeout(10, TimeUnit.SECONDS) .build(); } public void run() throws Exception { Request request = new Request.Builder()
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Sep 28 18:00:26 UTC 2019 - 1.5K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/kt/ConfigureTimeouts.kt
import okhttp3.OkHttpClient import okhttp3.Request class ConfigureTimeouts { private val client: OkHttpClient = OkHttpClient.Builder() .connectTimeout(5, TimeUnit.SECONDS) .writeTimeout(5, TimeUnit.SECONDS) .readTimeout(5, TimeUnit.SECONDS) .callTimeout(10, TimeUnit.SECONDS) .build() fun run() { val request = Request.Builder()
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 1.3K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/OkHttpClient.kt
* The write timeout is applied for individual write IO operations. The default value is 10 * seconds. * * @see Sink.timeout */ fun writeTimeout( timeout: Long, unit: TimeUnit, ) = apply { writeTimeout = checkDuration("timeout", timeout, unit) } /** * Sets the default write timeout for new connections. A value of 0 means no timeout, otherwise
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Apr 06 04:21:33 UTC 2024 - 52K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http2/Http2ExchangeCodec.kt
if (canceled) { stream!!.closeLater(ErrorCode.CANCEL) throw IOException("Canceled") } stream!!.readTimeout().timeout(chain.readTimeoutMillis.toLong(), TimeUnit.MILLISECONDS) stream!!.writeTimeout().timeout(chain.writeTimeoutMillis.toLong(), TimeUnit.MILLISECONDS) } override fun flushRequest() { http2Connection.flush() } override fun finishRequest() { stream!!.getSink().close() }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 6.9K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/OkHttpClientTest.kt
} catch (ignored: IllegalArgumentException) { } try { builder.connectTimeout(Duration.ofNanos(1)) } catch (ignored: IllegalArgumentException) { } try { builder.writeTimeout(Duration.ofNanos(1)) } catch (ignored: IllegalArgumentException) { } try { builder.readTimeout(Duration.ofNanos(1)) } catch (ignored: IllegalArgumentException) { } try {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Mar 31 17:16:15 UTC 2024 - 13.2K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http/RealInterceptorChain.kt
timeout: Int, unit: TimeUnit, ): Interceptor.Chain { check(exchange == null) { "Timeouts can't be adjusted in a network interceptor" } return copy(writeTimeoutMillis = checkDuration("writeTimeout", timeout.toLong(), unit)) } override fun call(): Call = call override fun request(): Request = request @Throws(IOException::class) override fun proceed(request: Request): Response {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 4.2K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/SocketChannelTest.kt
} val client = clientTestRule.newClientBuilder() .dns { listOf(InetAddress.getByName("localhost")) } .callTimeout(4, SECONDS) .writeTimeout(2, SECONDS) .readTimeout(2, SECONDS) .apply { if (socketMode is TlsInstance) { if (socketMode.socketMode == Channel) { socketFactory(ChannelSocketFactory())
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 8K bytes - Viewed (0) -
internal/event/target/kafka.go
config.Producer.Compression = cc config.Producer.CompressionLevel = args.Producer.CompressionLevel } config.Net.ReadTimeout = (5 * time.Second) config.Net.DialTimeout = (5 * time.Second) config.Net.WriteTimeout = (5 * time.Second) config.Metadata.Retry.Max = 1 config.Metadata.Retry.Backoff = (1 * time.Second) config.Metadata.RefreshFrequency = (15 * time.Minute) target.config = config brokers := []string{}
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri Sep 06 23:06:30 UTC 2024 - 13.6K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/ws/WebSocketHttpTest.kt
private val clientListener = WebSocketRecorder("client") private val serverListener = WebSocketRecorder("server") private val random = Random(0) private var client = clientTestRule.newClientBuilder() .writeTimeout(Duration.ofMillis(500)) .readTimeout(Duration.ofMillis(500)) .addInterceptor( Interceptor { chain: Interceptor.Chain -> val response = chain.proceed(chain.request())
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Mar 31 17:16:15 UTC 2024 - 35.2K bytes - Viewed (0)