Class: Nonnative::Runner
- Inherits:
-
Object
- Object
- Nonnative::Runner
- Defined in:
- lib/nonnative/runner.rb
Overview
Base runtime wrapper for a configured runnable unit.
A runner wraps a configuration object (a subclass of ConfigurationRunner) and exposes lifecycle behavior via specialized subclasses:
-
Process for OS-level child processes
-
Server for in-process Ruby servers (threads)
-
Service for proxy-only external dependencies
Each runner has an associated proxy instance created via ProxyFactory.
Instance Attribute Summary collapse
-
#proxy ⇒ Nonnative::Proxy
readonly
Returns the proxy instance for this runner.
Instance Method Summary collapse
-
#initialize(service) ⇒ Runner
constructor
A new instance of Runner.
-
#name ⇒ String?
Returns the configured runner name.
Constructor Details
#initialize(service) ⇒ Runner
Returns a new instance of Runner.
25 26 27 28 |
# File 'lib/nonnative/runner.rb', line 25 def initialize(service) @service = service @proxy = Nonnative::ProxyFactory.create(service) end |
Instance Attribute Details
#proxy ⇒ Nonnative::Proxy (readonly)
Returns the proxy instance for this runner.
22 23 24 |
# File 'lib/nonnative/runner.rb', line 22 def proxy @proxy end |
Instance Method Details
#name ⇒ String?
Returns the configured runner name.
33 34 35 |
# File 'lib/nonnative/runner.rb', line 33 def name service.name end |