Method: Async::HTTP::Protocol::HTTP2::Connection#initialize

Defined in:
lib/async/http/protocol/http2/connection.rb

#initializeObject



44
45
46
47
48
49
50
51
52
# File 'lib/async/http/protocol/http2/connection.rb', line 44

def initialize(*)
  super
  
  @count = 0
  @reader = nil
  
  # Writing multiple frames at the same time can cause odd problems if frames are only partially written. So we use a semaphore to ensure frames are written in their entirety.
  @write_frame_guard = Async::Semaphore.new(1)
end