Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for Http2Writer (0.46 sec)

  1. okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/http2/Http2Writer.kt

    import okhttp3.internal.http2.Http2.frameLogWindowUpdate
    import okhttp3.internal.writeMedium
    import okio.Buffer
    import okio.BufferedSink
    
    /** Writes HTTP/2 transport frames. */
    @Suppress("NAME_SHADOWING")
    class Http2Writer(
      private val sink: BufferedSink,
      private val client: Boolean,
    ) : Closeable,
      Lockable {
      private val hpackBuffer: Buffer = Buffer()
      private var maxFrameSize: Int = INITIAL_MAX_FRAME_SIZE
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed May 28 23:28:25 UTC 2025
    - 11K bytes
    - Viewed (0)
  2. okhttp/src/jvmTest/kotlin/okhttp3/internal/http2/Http2Test.kt

        val newMaxFrameSize = 16777215
        val writer = Http2Writer(Buffer(), true)
        writer.applyAndAckSettings(Settings().set(Settings.MAX_FRAME_SIZE, newMaxFrameSize))
        assertThat(writer.maxDataLength()).isEqualTo(newMaxFrameSize)
        writer.frameHeader(0, newMaxFrameSize, Http2.TYPE_DATA, FLAG_NONE)
      }
    
      @Test fun streamIdHasReservedBit() {
        val writer = Http2Writer(Buffer(), true)
        assertFailsWith<IllegalArgumentException> {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 28.1K bytes
    - Viewed (0)
  3. docs/contribute/concurrency.md

    #### Http2Writer
    
    Socket writes are guarded by the Http2Writer. Only one stream can write at a time so that messages are not interleaved. Writes are either made by application-layer threads or the do-stuff-later pool.
    
    ### Holding multiple locks
    
    You're allowed to take the Http2Connection lock while holding the Http2Writer lock. But not vice-versa. Because taking the Http2Writer lock can block.
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Sun Feb 06 16:35:36 UTC 2022
    - 7K bytes
    - Viewed (0)
  4. okhttp/src/jvmTest/kotlin/okhttp3/internal/http2/MockHttp2Peer.kt

        this.client = client
        writer = Http2Writer(bytesOut, client)
      }
    
      fun acceptFrame() {
        frameCount++
      }
    
      /** Maximum length of an outbound data frame.  */
      fun maxOutboundDataLength(): Int = writer.maxDataLength()
    
      /** Count of frames sent or received.  */
      fun frameCount(): Int = frameCount
    
      fun sendFrame(): Http2Writer {
        outFrames.add(OutFrame(frameCount++, bytesOut.size, false))
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 8.7K bytes
    - Viewed (0)
  5. okhttp/src/androidMain/baseline-prof.txt

    HSPLokhttp3/internal/http2/Http2Writer;-><clinit>()V
    HSPLokhttp3/internal/http2/Http2Writer;-><init>(Lokio/BufferedSink;Z)V
    HSPLokhttp3/internal/http2/Http2Writer;->applyAndAckSettings(Lokhttp3/internal/http2/Settings;)V
    HSPLokhttp3/internal/http2/Http2Writer;->close()V
    HSPLokhttp3/internal/http2/Http2Writer;->data(ZILokio/Buffer;I)V
    HSPLokhttp3/internal/http2/Http2Writer;->flush()V
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Mon Dec 30 23:28:56 UTC 2024
    - 127.9K bytes
    - Viewed (0)
  6. okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/http2/Http2Connection.kt

      var writeBytesMaximum: Long = peerSettings.initialWindowSize.toLong()
        private set
    
      internal val socket: BufferedSocket = builder.socket
      val writer = Http2Writer(socket.sink, client)
    
      // Visible for testing
      val readerRunnable = ReaderRunnable(Http2Reader(socket.source, client))
    
      // Guarded by this.
      private val currentPushRequests = mutableSetOf<Int>()
    
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Thu Jul 31 04:18:40 UTC 2025
    - 31.8K bytes
    - Viewed (0)
Back to top