Many daemons reload config file on SIGHUP; laminar don't have config file, so
signal is ignored (with informative message on stdout). Previously, default
handler for SIGHUP was used that terminates process.
Closes: #166
as a further enhancement to efafda16f, schedule a render immediately if
500ms have passed without one, and cap the max delay to 500ms.
This removes delay for short logs, and prevents an issue where output that
is produced reasonably quickly will not be rendered for a long time.
frontend would furiously try to render as fast as it received data
chunks from the server. This causes a lot of extra load on the browser
renderer if the logs are large. Buffer and batch calls to rerender
to improve performance.
resolves#165
Originally reverted to prevent a crash when reading from an http
client raised ECONNRESET. Although this prevented a crash, laminar
stopped listening for http connections. That issue was resolved in
37bbf6ade4 (see #164), so make all exceptions fatal again.
This reverts commit 02810309fc.
In real deployments, sometimes http connections break with ECONNRESET.
This causes the kj::HttpServer listener promise to break, which means
no more connections are accepted. Catch this exception and restart
the listener.
resolves#164
do not escape links to downstream jobs generated with a private
ANSI CSI escape sequence, because the newer ansi_up escapes HTML.
Work around its dropping of unknown sequences, and have the link
use the Vue routing mechanism rather than a page reload.
resolves#161
kj::Directory::remove will throw if it fails to remove some files, e.g. in
case of insufficient permissions. Catch this and move right along.
resolves#156
Creating of LogWatcher makes it automatically receive new log
chunks as it is part of logWatchers. But we cannot be sure that
stream->write().then() will have already completed, so there is
a chance that a null fulfiller will be caused, causing a crash.
We cannot defer the creation of the LogWatcher until after
stream->write() because in the meantime we may lose new messages,
so call writeLogChunk to make sure we have a fulfiller before
entering stream->write().
Also, pending chunks of log output were std::move()'d to the first
interested client in the loop, they need to be copied if there
is more than one client.
Extend populateArtifacts() with a subdir parameter (default initialized to ".")
to allow for recursive calls. With subdirs encountered, call recursively.
only a small subset of vue-router is used, and integration is
complicated by each route having its own EventSource request.
Implementing the routing directly allows simplification of
the EventSource logic.
Another motivating factor is that the vue-router packages in
debian have been unreliable, making the dependence on vue-router
a hinderance for packaging laminar in debian.
to 2.6.12 and 3.4.8 respectively, as they are the versions available
in Debian. fix an exposed issue where the status handler attempted
to manipulate the DOM before vue had rendered it - such manipulations
need to be deferred with $nextTick().
using a glob expression, the same way jobs can specify
contexts. This allows more flexibility in situations where
there are many jobs sharing limited contexts because it
may obviate the need to create a conf file for each job.
resolves#124
too esoteric for the front page, converting it to an example
of querying laminar db directly and using gnuplot should provide
more value to those needing deeper insights into job behaviour.
This allows build chains to be traced in the common case where
an upstream job calls `laminarc queue' instead of `laminarc start'.
Incomplete job runs now have database entries, which requires
some adjustments in queries. Queued jobs can now be viewed in
the frontend and there is a corresponding status icon.
Similarly to 210787a3, and as discussed in #88 and #130, nginx
will buffer chunked transfer-encoding unless proxy_buffering
is turned off or the X-Accel-Buffering header is set to no.
resolves#130
some jobs may spawn child processes which change their process group
or session id, making the existing abort behavior of HUP-then-KILL to
the process group ineffective. Instead, if HUP to the process group
fails, recursively walk /proc and KILL anything with a ppid corresponding
to the leader process. This should keep working because the leader
process is a subreaper.
resolves#129