Module: HTTPX::Plugins::H2C
- Defined in:
- lib/httpx/plugins/h2c.rb
Overview
Defined Under Namespace
Modules: ConnectionMethods
Classes: H2CParser
Constant Summary
collapse
- VALID_H2C_VERBS =
%w[GET OPTIONS HEAD].freeze
Class Method Summary
collapse
Class Method Details
.call(connection, request, response) ⇒ Object
19
20
21
|
# File 'lib/httpx/plugins/h2c.rb', line 19
def call(connection, request, response)
connection.upgrade_to_h2c(request, response)
end
|
23
24
25
|
# File 'lib/httpx/plugins/h2c.rb', line 23
def (options)
options.merge(max_concurrent_requests: 1, upgrade_handlers: options.upgrade_handlers.merge("h2c" => self))
end
|
.load_dependencies(klass) ⇒ Object
15
16
17
|
# File 'lib/httpx/plugins/h2c.rb', line 15
def load_dependencies(klass)
klass.plugin(:upgrade)
end
|