Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for AddressPolicy (0.33 sec)

  1. okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/connection/AddressPolicy.kt

     * limitations under the License.
     */
    package okhttp3.internal.connection
    
    /**
     * A policy for how the pool should treat a specific address.
     */
    class AddressPolicy(
      /**
       * How many concurrent calls should be possible to make at any time.
       * The pool will routinely try to pre-emptively open connections to satisfy this minimum.
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Tue Jun 03 17:10:08 UTC 2025
    - 1.3K bytes
    - Viewed (0)
  2. okhttp/src/jvmTest/kotlin/okhttp3/internal/connection/ConnectionPoolTest.kt

        val address = routePlanner.address
        val pool = routePlanner.pool
    
        // Connections are created as soon as a policy is set
        setPolicy(pool, address, AddressPolicy(2))
        assertThat(pool.connectionCount()).isEqualTo(2)
    
        // Connections are replaced if they idle out or are evicted from the pool
        evictAllConnections(pool)
        assertThat(pool.connectionCount()).isEqualTo(2)
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Thu Jul 31 04:18:40 UTC 2025
    - 12.9K bytes
    - Viewed (0)
  3. okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/connection/RealConnectionPool.kt

    class RealConnectionPool internal constructor(
      private val taskRunner: TaskRunner,
      /**
       * The maximum number of idle connections across all addresses.
       * Connections needed to satisfy a [ConnectionPool.AddressPolicy] are not considered idle.
       */
      private val maxIdleConnections: Int,
      keepAliveDuration: Long,
      timeUnit: TimeUnit,
      internal val connectionListener: ConnectionListener,
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Tue Jun 03 17:10:08 UTC 2025
    - 16.1K bytes
    - Viewed (0)
  4. CHANGELOG.md

        that this function is sensitive to when it is called: the response body must be supplied before
        it can be compressed.
    
     *  Breaking: Remove `AddressPolicy`, `AsyncDns`, and `ConnectionListener` from the public API. We
        intend to ship a public API for these features, but we don't want to hold OkHttp 5.0.0 until
        those APIs are stable.
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Mon Jul 07 19:32:33 UTC 2025
    - 31.6K bytes
    - Viewed (1)
Back to top