Class: Tenable::Connection
- Inherits:
-
Object
- Object
- Tenable::Connection
- Defined in:
- lib/tenable/connection.rb
Overview
Manages the Faraday HTTP connection with configured middleware.
Automatically configures authentication, retry, and logging middleware based on the provided Configuration.
Instance Attribute Summary collapse
-
#faraday ⇒ Faraday::Connection
readonly
The underlying Faraday connection.
Instance Method Summary collapse
-
#initialize(config) ⇒ Connection
constructor
Creates a new connection from the given configuration.
Constructor Details
#initialize(config) ⇒ Connection
Creates a new connection from the given configuration.
16 17 18 19 |
# File 'lib/tenable/connection.rb', line 16 def initialize(config) @config = config @faraday = build_connection end |
Instance Attribute Details
#faraday ⇒ Faraday::Connection (readonly)
Returns the underlying Faraday connection.
10 11 12 |
# File 'lib/tenable/connection.rb', line 10 def faraday @faraday end |