Class: SafeImage::Zygote::Worker
- Inherits:
-
Struct
- Object
- Struct
- SafeImage::Zygote::Worker
- Defined in:
- lib/safe_image/zygote.rb
Overview
generation: the pool generation a worker was born into; shutdown!/fork bump the generation so a worker checked out under the old config is retired (never re-pooled) when it returns. owner_pid: the process that spawned it, so a worker inherited across fork is never killed by the child (it belongs to the parent). tmproot: a parent-created directory the worker puts its per-operation tmpdirs under. The worker removes it on graceful exit (at_exit); the parent removes it when it kills the worker, so a SIGKILL mid-operation (where the worker cannot clean up) does not leak the op’s tmpdir.
Instance Attribute Summary collapse
-
#generation ⇒ Object
Returns the value of attribute generation.
-
#last_used ⇒ Object
Returns the value of attribute last_used.
-
#owner_pid ⇒ Object
Returns the value of attribute owner_pid.
-
#pid ⇒ Object
Returns the value of attribute pid.
-
#stdin ⇒ Object
Returns the value of attribute stdin.
-
#stdout ⇒ Object
Returns the value of attribute stdout.
-
#tmproot ⇒ Object
Returns the value of attribute tmproot.
Instance Attribute Details
#generation ⇒ Object
Returns the value of attribute generation
78 79 80 |
# File 'lib/safe_image/zygote.rb', line 78 def generation @generation end |
#last_used ⇒ Object
Returns the value of attribute last_used
78 79 80 |
# File 'lib/safe_image/zygote.rb', line 78 def last_used @last_used end |
#owner_pid ⇒ Object
Returns the value of attribute owner_pid
78 79 80 |
# File 'lib/safe_image/zygote.rb', line 78 def owner_pid @owner_pid end |
#pid ⇒ Object
Returns the value of attribute pid
78 79 80 |
# File 'lib/safe_image/zygote.rb', line 78 def pid @pid end |
#stdin ⇒ Object
Returns the value of attribute stdin
78 79 80 |
# File 'lib/safe_image/zygote.rb', line 78 def stdin @stdin end |
#stdout ⇒ Object
Returns the value of attribute stdout
78 79 80 |
# File 'lib/safe_image/zygote.rb', line 78 def stdout @stdout end |
#tmproot ⇒ Object
Returns the value of attribute tmproot
78 79 80 |
# File 'lib/safe_image/zygote.rb', line 78 def tmproot @tmproot end |