Name |
|
---|---|
Description |
This module allows you to turn a regular Ceylon program into a daemonized version.
On each connection, the daemon will accept command line arguments, a working directory, and standard input.
It will then set up the environment for the program, and launch it.
Afterwards, the program’s output and result are sent over the connection again.
A simple client that just communicates with the daemon can then be used in place of the original program,
eliminating VM startup time and taking advantage of VM optimizations for long-running programs.
One example client may be found in the import com.example.program { program=run } import de.lucaswerkmeister.ceylond.daemonizeProgram { daemonizeProgram } shared void run() => daemonizeProgram { program; fd = 3; }; The following mechanisms are trapped/replaced and may be used by the program:
The working directory of the daemon process remains unchanged,
but a small handler may be [[registered|makeDaemonizeProgramInstance.argumentsMap]] to adapt paths in The following mechanisms are not trapped/replaced and should not be used by the program:
LoggingThis module provides a custom version of the core module’s [[de.lucaswerkmeister.ceylond.core::writeSystemdLog]]
that does not interfere with trapped standard error: see |
Last Published | Jan 19, 2017 |
Stats |
Downloads (JVM): 238 Downloads (JS): 62 Source downloads: 300 |
Module links |
Imported By Browse |
1.0.0 | JVM JavaScript JVM: 1.2.x, 1.3.x (latest) JavaScript: 1.2.1, 1.2.2, 1.3.x (latest) | Published Jan 19, 2017 |
Browse |
View docs |