| Class | DaemonKit::EM |
| In: |
lib/daemon_kit/em.rb
|
| Parent: | Object |
EventMachine forms a critical part of the daemon-kit toolset, and especially of daemon process developers.
This class abstracts away the difficulties of managing multiple libraries that all utilize the event reactor.
Start a reactor, just like classical EM.run. If the block is provided, the method will block and call the provided block argument inside the running reactor. If the block argument is not provided the reactor will be started in a separate thread and the program will continue to run after the method. All the signal traps are configured to shutdown the reactor when the daemon exists.