user/dev discussion of public-inbox itself
 help / color / mirror / code / Atom feed
Search results ordered by [date|relevance]  view[summary|nested|Atom feed]
thread overview below | download mbox.gz: |
* Re: [PATCH 9/9] doc: lei-daemon: new manpage
  2021-10-02  8:08  7%     ` Eric Wong
@ 2021-10-04  3:16  7%       ` Kyle Meyer
  0 siblings, 0 replies; 5+ results
From: Kyle Meyer @ 2021-10-04  3:16 UTC (permalink / raw)
  To: Eric Wong; +Cc: meta

Eric Wong writes:

> Btw, did you have time to work on some of the other manpages?
> No worries if not, I might take a stab at them sometime in the
> next few days. [...]

Sorry, I haven't worked on manpages for the new commands.  (Actually I
still need to catch up on what the new commands are).  I suppose at this
point you might prefer to handle it yourself for a quicker turnaround,
but I think I could find time this week.

^ permalink raw reply	[relevance 7%]

* Re: [PATCH 9/9] doc: lei-daemon: new manpage
  2021-10-02  0:19  7%   ` Kyle Meyer
@ 2021-10-02  8:08  7%     ` Eric Wong
  2021-10-04  3:16  7%       ` Kyle Meyer
  0 siblings, 1 reply; 5+ results
From: Eric Wong @ 2021-10-02  8:08 UTC (permalink / raw)
  To: Kyle Meyer; +Cc: meta

Thanks, pushed with your Helped-by:.

Btw, did you have time to work on some of the other manpages?
No worries if not, I might take a stab at them sometime in the
next few days.  I often realize shortcomings while writing
documentation, and I still need to figure out why some messages
go missing or get duplicated...

^ permalink raw reply	[relevance 7%]

* Re: [PATCH 9/9] doc: lei-daemon: new manpage
  2021-10-01  9:54  4% ` [PATCH 9/9] doc: lei-daemon: new manpage Eric Wong
@ 2021-10-02  0:19  7%   ` Kyle Meyer
  2021-10-02  8:08  7%     ` Eric Wong
  0 siblings, 1 reply; 5+ results
From: Kyle Meyer @ 2021-10-02  0:19 UTC (permalink / raw)
  To: Eric Wong; +Cc: meta

Eric Wong writes:

> In case users see "lei-daemon" in ps(1) or syslog and wonder.

Thanks, this is very helpful/informative.

> diff --git a/Documentation/lei-daemon.pod b/Documentation/lei-daemon.pod
[...]
> +=head2 SOCK_SEQPACKET
> +
> +SOCK_SEQPACKET sockets are used for both communicating with
> +L<lei(1)> and to internal workers.  SOCK_SEQPACKET is guarantee
> +reliability (unlike SOCK_DGRAM), allows easy load distribution,

s/is guarantee/guarantees/ ?

> +and saves developers the trouble of maintaining stream parsers.
> +
> +=head2 File monitoring

Obviously unimportant, but this casing is inconsistent with some of the
titles above (e.g., "file descriptor passing").

> +Inotify or EVFILT_VNODE is used depending on the platform
> +to monitor Maildirs of changes and track keyword changes.

s/of changes/for changes/ ?

> +The listen socket at (default: C<$XDG_RUNTIME_DIR/lei/5.seq.sock>)

I stumbled parsing this because target of "at" is parenthesized.  At
least in my head, it'd read fine dropping the "at".

> +is also monitored, and the daemon will automatically shutdown
> +if it is unlinked.

^ permalink raw reply	[relevance 7%]

* [PATCH 9/9] doc: lei-daemon: new manpage
  2021-10-01  9:54  7% [PATCH 0/9] daemon-related things Eric Wong
@ 2021-10-01  9:54  4% ` Eric Wong
  2021-10-02  0:19  7%   ` Kyle Meyer
  0 siblings, 1 reply; 5+ results
From: Eric Wong @ 2021-10-01  9:54 UTC (permalink / raw)
  To: meta

In case users see "lei-daemon" in ps(1) or syslog and wonder.
---
 Documentation/lei-daemon.pod       | 61 ++++++++++++++++++++++++++++++
 Documentation/lei.pod              |  9 ++++-
 Documentation/lei_design_notes.txt |  2 +-
 MANIFEST                           |  1 +
 Makefile.PL                        |  2 +-
 5 files changed, 72 insertions(+), 3 deletions(-)
 create mode 100644 Documentation/lei-daemon.pod

diff --git a/Documentation/lei-daemon.pod b/Documentation/lei-daemon.pod
new file mode 100644
index 000000000000..1205e974706a
--- /dev/null
+++ b/Documentation/lei-daemon.pod
@@ -0,0 +1,61 @@
+=head1 NAME
+
+lei-daemon - technical information for local email interface daemon
+
+=head1 DESCRIPTION
+
+This documentation is a high-level overview for developers and
+administrators interested in how lei works.
+
+lei-daemon is a background daemon which powers the L<lei(1)>
+command-line tool.  It may support virtual users and read-write
+IMAP+JMAP APIs in the future.  It is designed to optimize shell
+completion by avoiding module loading costs, monitor Maildirs
+(and in the near future, IMAP folders) for changes.
+
+=head2 worker processes
+
+Most commands cause lei-daemon to L<fork(2)> new worker
+processes to isolate and parallelize work.  lei-daemon is
+significantly more aggressive than read-only
+L<public-inbox-daemon(8)> processes with regards to resource use
+since it's not designed to support C10K/C100K scenarios.
+
+=head2 file descriptor passing
+
+FD passing is used to reduce IPC costs for bulk I/O when
+importing large mboxes from stdin and dumping large mboxes
+to stdout.
+
+=head2 SOCK_SEQPACKET
+
+SOCK_SEQPACKET sockets are used for both communicating with
+L<lei(1)> and to internal workers.  SOCK_SEQPACKET is guarantee
+reliability (unlike SOCK_DGRAM), allows easy load distribution,
+and saves developers the trouble of maintaining stream parsers.
+
+=head2 File monitoring
+
+Inotify or EVFILT_VNODE is used depending on the platform
+to monitor Maildirs of changes and track keyword changes.
+
+The listen socket at (default: C<$XDG_RUNTIME_DIR/lei/5.seq.sock>)
+is also monitored, and the daemon will automatically shutdown
+if it is unlinked.
+
+=head1 CONTACT
+
+Feedback welcome via plain-text mail to L<mailto:meta@public-inbox.org>
+
+The mail archives are hosted at L<https://public-inbox.org/meta/> and
+L<http://4uok3hntl7oi7b4uf4rtfwefqeexfzil2w6kgk2jn5z2f764irre7byd.onion/meta/>
+
+=head1 COPYRIGHT
+
+Copyright all contributors L<mailto:meta@public-inbox.org>
+
+License: AGPL-3.0+ L<https://www.gnu.org/licenses/agpl-3.0.txt>
+
+=head1 SEE ALSO
+
+L<lei-overview(7)>, L<lei-daemon-kill(1)>, L<lei-daemon-pid(1)>
diff --git a/Documentation/lei.pod b/Documentation/lei.pod
index 3af9e2eeacf7..63d5ee6900a7 100644
--- a/Documentation/lei.pod
+++ b/Documentation/lei.pod
@@ -115,6 +115,13 @@ Other subcommands include
 By default storage is located at C<$XDG_DATA_HOME/lei/store>.  The
 configuration for lei resides at C<$XDG_CONFIG_HOME/lei/config>.
 
+=head1 ERRORS
+
+Errors and dianostics for interactive commands are reported to
+stderr.  Some errors for background tasks are emitted via
+L<syslog(3)> as L<lei-daemon(8)> for the top-level daemon,
+and C<lei/store> for the L<lei-store-format(5)> worker.
+
 =head1 CONTACT
 
 Feedback welcome via plain-text mail to L<mailto:meta@public-inbox.org>
@@ -130,4 +137,4 @@ License: AGPL-3.0+ L<https://www.gnu.org/licenses/agpl-3.0.txt>
 
 =head1 SEE ALSO
 
-L<lei-overview(7)>
+L<lei-overview(7)>, L<lei-daemon(8)>
diff --git a/Documentation/lei_design_notes.txt b/Documentation/lei_design_notes.txt
index f1d2ab6f2169..b5180374ad05 100644
--- a/Documentation/lei_design_notes.txt
+++ b/Documentation/lei_design_notes.txt
@@ -6,7 +6,7 @@ Daemon architecture
 
 The use of a persistent daemon works around slow startup time of
 Perl.  This is especially important for built-in support for
-shell completion.  It will eventually support inotify and EVFILT_VNODE
+shell completion.  It attempts to support inotify and EVFILT_VNODE
 background monitoring of Maildir keyword changes.
 
 If lei were reimplemented in a language with faster startup
diff --git a/MANIFEST b/MANIFEST
index 3e942855127f..929f5f869c5b 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -27,6 +27,7 @@ Documentation/lei-config.pod
 Documentation/lei-convert.pod
 Documentation/lei-daemon-kill.pod
 Documentation/lei-daemon-pid.pod
+Documentation/lei-daemon.pod
 Documentation/lei-edit-search.pod
 Documentation/lei-export-kw.pod
 Documentation/lei-forget-external.pod
diff --git a/Makefile.PL b/Makefile.PL
index 00a558d12472..c41c408a5704 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -60,7 +60,7 @@ $v->{-m5} = [ qw(public-inbox-config public-inbox-v1-format
 $v->{-m7} = [ qw(lei-overview lei-security
 		public-inbox-overview public-inbox-tuning
 		public-inbox-glossary) ];
-$v->{-m8} = [ qw(public-inbox-daemon) ];
+$v->{-m8} = [ qw(public-inbox-daemon lei-daemon) ];
 my @sections = (1, 5, 7, 8);
 $v->{check_80} = [];
 $v->{manuals} = [];

^ permalink raw reply related	[relevance 4%]

* [PATCH 0/9] daemon-related things
@ 2021-10-01  9:54  7% Eric Wong
  2021-10-01  9:54  4% ` [PATCH 9/9] doc: lei-daemon: new manpage Eric Wong
  0 siblings, 1 reply; 5+ results
From: Eric Wong @ 2021-10-01  9:54 UTC (permalink / raw)
  To: meta

5/9 has been a long-time coming, a few other small things, too.
The diff stat for lib/ alone shows a nice reduction

Eric Wong (9):
  doc: lei-security: some more updates
  listener: switch to level-triggered epoll
  daemon: make SO_ACCEPTFILTER a shared variable
  ipc: run Net::SSLeay::randomize
  ds: simplify signalfd use
  inbox: inline and eliminate git_cleanup
  inbox: keep DB handles if git processes are live
  ds: inline set_cloexec
  doc: lei-daemon: new manpage

 Documentation/lei-daemon.pod       |  61 ++++++++++++++++
 Documentation/lei-security.pod     |   5 +-
 Documentation/lei.pod              |   9 ++-
 Documentation/lei_design_notes.txt |   2 +-
 MANIFEST                           |   1 +
 Makefile.PL                        |   2 +-
 lib/PublicInbox/ConfigIter.pm      |   2 +-
 lib/PublicInbox/DS.pm              | 110 ++++++++++++++---------------
 lib/PublicInbox/DSKQXS.pm          |  10 +--
 lib/PublicInbox/Daemon.pm          |  20 ++----
 lib/PublicInbox/ExtMsg.pm          |   2 +-
 lib/PublicInbox/ExtSearchIdx.pm    |  12 +---
 lib/PublicInbox/Gcf2Client.pm      |   4 +-
 lib/PublicInbox/Git.pm             |   4 +-
 lib/PublicInbox/IPC.pm             |   5 +-
 lib/PublicInbox/Inbox.pm           |  41 +++++------
 lib/PublicInbox/LEI.pm             |  17 +----
 lib/PublicInbox/Listener.pm        |   5 +-
 lib/PublicInbox/Qspawn.pm          |   2 +-
 lib/PublicInbox/Sigfd.pm           |  10 +--
 lib/PublicInbox/Syscall.pm         |  12 ++--
 lib/PublicInbox/Watch.pm           |   3 +-
 script/public-inbox-watch          |   9 ---
 t/dir_idle.t                       |   6 +-
 t/ds-leak.t                        |   4 +-
 t/httpd-corner.t                   |   4 +-
 t/httpd-https.t                    |   6 +-
 t/httpd.t                          |   6 +-
 t/imapd-tls.t                      |   7 +-
 t/imapd.t                          |   6 +-
 t/nntpd-tls.t                      |   7 +-
 t/nntpd.t                          |   2 +-
 t/sigfd.t                          |   7 +-
 t/watch_maildir.t                  |   2 +-
 xt/mem-imapd-tls.t                 |   6 +-
 xt/net_writer-imap.t               |   2 +-
 36 files changed, 221 insertions(+), 192 deletions(-)
 create mode 100644 Documentation/lei-daemon.pod

^ permalink raw reply	[relevance 7%]

Results 1-5 of 5 | reverse | options above
-- pct% links below jump to the message on this page, permalinks otherwise --
2021-10-01  9:54  7% [PATCH 0/9] daemon-related things Eric Wong
2021-10-01  9:54  4% ` [PATCH 9/9] doc: lei-daemon: new manpage Eric Wong
2021-10-02  0:19  7%   ` Kyle Meyer
2021-10-02  8:08  7%     ` Eric Wong
2021-10-04  3:16  7%       ` Kyle Meyer

Code repositories for project(s) associated with this public inbox

	https://80x24.org/public-inbox.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).