[systemd-devel] [PATCH 11/17] journal: add sd_journal_open_files
Lennart Poettering
lennart at poettering.net
Mon Jun 10 02:40:23 PDT 2013
On Sat, 08.06.13 00:22, Zbigniew Jędrzejewski-Szmek (zbyszek at in.waw.pl) wrote:
> This allows the caller to explicitly specify which journal files
> should be opened. The same functionality could be achieved before
> by creating a directory and playing around with symlinks. It
> is useful to debug stuff and explore the journal, and has been
> requested before.
>
> Waiting is supported, the journal will notice modifications on
> the files supplied when opening the journal, but will not add
> any new files.
I am not too thrilled by this addition. I can see why people want this,
but I am pretty sure this will result in people writing bad code...
Maybe we should at least extend the man page to clarify the
deficiciencies of this call, and that this never should be used for
anything but the most simple debug tools? The major problem is that
files are rotated, so opening just a file (rather than a dir) will
quickly lead to out-of-date results...
Lennart
--
Lennart Poettering - Red Hat, Inc.
More information about the systemd-devel
mailing list