]> Sergey Matveev's repositories - public-inbox.git/log
public-inbox.git
6 years agomid: be strict with References, but loose on Message-Id
Eric Wong (Contractor, The Linux Foundation) [Sat, 3 Mar 2018 05:14:33 +0000 (05:14 +0000)]
mid: be strict with References, but loose on Message-Id

Traditionally we've been more lax on parsing Message-Id
and allow it without the angle brackets.  We've always been
strict on References and can't have it be pointlessly
large when some MUA decides to use HTML-escaped angle
brackets ("<", ">").

6 years agosearchidx: support indexing multiple MIDs
Eric Wong (Contractor, The Linux Foundation) [Sat, 3 Mar 2018 04:00:09 +0000 (04:00 +0000)]
searchidx: support indexing multiple MIDs

It's possible to have a message handle multiple terms;
so use this feature to ensure messages with multiple MIDs
can be found by either one.

6 years agosearch: revert to using 'Q' as a uniQue id per-Xapian conventions
Eric Wong (Contractor, The Linux Foundation) [Fri, 2 Mar 2018 20:46:55 +0000 (20:46 +0000)]
search: revert to using 'Q' as a uniQue id per-Xapian conventions

'Q' is merely a convention in the Xapian world, and is close
enough to unique for practical purposes, so stop using XMID
and gain a little more term length as a result.

6 years agov2writable: inject new Message-IDs on true duplicates
Eric Wong (Contractor, The Linux Foundation) [Fri, 2 Mar 2018 19:32:19 +0000 (19:32 +0000)]
v2writable: inject new Message-IDs on true duplicates

Since we'll need to support multiple Message-IDs anyways,
inject a new one if we hit a duplicate (or don't get one at
all).

Try to use a deterministic Message-Id for consistency, but give
up determinism and use a random Message-Id if an "attacker"
wants to prevent their message from being archived.

6 years agocontent_id: no need to be human-friendly
Eric Wong (Contractor, The Linux Foundation) [Fri, 2 Mar 2018 18:27:54 +0000 (18:27 +0000)]
content_id: no need to be human-friendly

We merely use this for internal comparisons and do not store
this in Xapian.  So using a shorter, non-human readable digest
is enough.  Furthermore, introduce "content_digest" which
returns the Digest::SHA object for extra changes.

6 years agosearchidx: use new `references' method for parsing References
Eric Wong (Contractor, The Linux Foundation) [Fri, 2 Mar 2018 09:53:11 +0000 (09:53 +0000)]
searchidx: use new `references' method for parsing References

It's shorter and more convenient, here.

6 years agocontent_id: use `mids' and `references' for MID extraction
Eric Wong (Contractor, The Linux Foundation) [Fri, 2 Mar 2018 09:39:31 +0000 (09:39 +0000)]
content_id: use `mids' and `references' for MID extraction

These already take care of deduping internally, so we'll save
ourselves at least some of the trouble while using a more
consistent API.  While we're at it, hash the header name as
well, since we need to distinguish which header a certain value
came from.

6 years agomid: add `mids' and `references' methods for extraction
Eric Wong (Contractor, The Linux Foundation) [Fri, 2 Mar 2018 09:38:35 +0000 (09:38 +0000)]
mid: add `mids' and `references' methods for extraction

We'll be using a more consistent API for extracting Message-IDs
from various headers.

6 years agoevcleanup: do not create event loop if nothing was registered
Eric Wong (Contractor, The Linux Foundation) [Fri, 2 Mar 2018 03:43:30 +0000 (03:43 +0000)]
evcleanup: do not create event loop if nothing was registered

This was creating an unnecessary epoll descriptor via
Danga::Socket when using V2Writable to import a mbox.  That
said, there should probably be better way of detecting whether
or not we're inside a Danga::Socket event loop.

Fixes: 427245acacaf04a8
       ("evcleanup: ensure deferred close from timers are handled ASAP")

6 years agov2writable: deduplicate detection on add
Eric Wong (Contractor, The Linux Foundation) [Fri, 2 Mar 2018 03:39:09 +0000 (03:39 +0000)]
v2writable: deduplicate detection on add

This is a bit expensive in a multi-process situation because
we need to make our indices and packs visible to the read-only
pieces.

6 years agoevcleanup: disable outside of daemon
Eric Wong (Contractor, The Linux Foundation) [Fri, 2 Mar 2018 03:12:23 +0000 (03:12 +0000)]
evcleanup: disable outside of daemon

We'll be using these in a more OO manner for V2Writable
(which doesn't use Danga::Socket), so lets not unnecessarily
register cleanup handlers intended for network daemons.

6 years agocontent_id: special treatment for Message-Id headers
Eric Wong (Contractor, The Linux Foundation) [Fri, 2 Mar 2018 03:08:33 +0000 (03:08 +0000)]
content_id: special treatment for Message-Id headers

Some emails in LKML archives are identical with the only
difference being s/References:/In-Reply-To:/ in the headers.
Since this difference doesn't affect how we handle message
threading, we will treat them the same way for the purposes
of deduplication.

There may be more changes to how we do content_id along these
lines (e.g. using msg_iter to walk the message).

6 years agosearchidx: add PID to error message when die-ing
Eric Wong (Contractor, The Linux Foundation) [Fri, 2 Mar 2018 00:50:56 +0000 (00:50 +0000)]
searchidx: add PID to error message when die-ing

6 years agosearch: remove informational "warning" message
Eric Wong (Contractor, The Linux Foundation) [Fri, 2 Mar 2018 00:49:51 +0000 (00:49 +0000)]
search: remove informational "warning" message

It was making imports too noisy.

6 years agov2writable: delete ::Import obj when ->done
Eric Wong (Contractor, The Linux Foundation) [Thu, 1 Mar 2018 08:24:00 +0000 (08:24 +0000)]
v2writable: delete ::Import obj when ->done

As with the ::Import class this wraps, we want this to be
usable as a checkpoint and be able to call ->add afterwards.
We'll be relying on ->done to flush changes through all
partition and skeleton DBs for deduplication checks.

6 years agov2/ui: get nntpd and init tests running on v2
Eric Wong (Contractor, The Linux Foundation) [Wed, 28 Feb 2018 22:29:38 +0000 (22:29 +0000)]
v2/ui: get nntpd and init tests running on v2

A work-in-progress, but it appears the v2 UI pieces do
will not require a lot of work to do.

6 years agosearch: query_xover uses skeleton DB iff available
Eric Wong (Contractor, The Linux Foundation) [Tue, 27 Feb 2018 08:29:09 +0000 (08:29 +0000)]
search: query_xover uses skeleton DB iff available

The skeleton DB is where we store all the information needed
for NNTP overviews via XOVER.  This seems to be the only change
necessary (besides eventually handling duplicates) necessary
to support our nntpd interface for v2 repositories.

6 years agosearchidx: do not modify Xapian DB while iterating
Eric Wong (Contractor, The Linux Foundation) [Tue, 27 Feb 2018 20:25:23 +0000 (20:25 +0000)]
searchidx: do not modify Xapian DB while iterating

Iterating through a list of documents while modifying them does
not seem to be supported in Xapian and it can trigger
DatabaseCorruptError exceptions.  This only worked with past
datasets out of dumb luck.  With the work-in-progress "v2"
public-inbox layout, this problem might become more visible
as the "thread skeleton" is partitioned out to a separate,
smaller Xapian database.

I've reproduced the problem on both Debian 8.x and 9.x with
Xapian 1.2.19 (chert backend) and 1.4.3 (glass backend)
respectively.

6 years agosearchidxskeleton: extra error checking
Eric Wong (Contractor, The Linux Foundation) [Wed, 28 Feb 2018 17:37:00 +0000 (17:37 +0000)]
searchidxskeleton: extra error checking

I added these while chasing down the DatabaseCorruptError
exceptions which turned out to be caused by Xapian DB
modifications during iteration.

6 years agov2writable: commit to skeleton via remote partitions
Eric Wong (Contractor, The Linux Foundation) [Tue, 27 Feb 2018 20:29:55 +0000 (20:29 +0000)]
v2writable: commit to skeleton via remote partitions

We need to ensure Xapian transaction commits are made to remote
partitions before associated commits hit the skeleton DB.

This causes unnecessary commits to be made to the skeleton DB;
but they're mostly harmless.  Further work will be necessary
to ensure proper ordering and avoidance of unnecessary commits.

6 years agorename SearchIdxThread to SearchIdxSkeleton
Eric Wong (Contractor, The Linux Foundation) [Tue, 27 Feb 2018 00:41:21 +0000 (00:41 +0000)]
rename SearchIdxThread to SearchIdxSkeleton

Interchangably using "all", "skel", "threader", etc. were
confusing.  Standardize on the "skeleton" term to describe
this class since it's also used for retrieval of basic headers.

6 years agosearch: use different Enquire object for skeleton queries
Eric Wong (Contractor, The Linux Foundation) [Mon, 26 Feb 2018 23:42:14 +0000 (23:42 +0000)]
search: use different Enquire object for skeleton queries

A different Xapian DB requires the use of a different Enquire
object.  This is necessary for get_thread and thread skeleton
to work in the PSGI UI.

6 years agosearchidx: index values in the threader
Eric Wong (Contractor, The Linux Foundation) [Mon, 26 Feb 2018 23:41:11 +0000 (23:41 +0000)]
searchidx: index values in the threader

We will need timestamp, YYYYMMDD, article number, and line count
for querying thread information (including XOVER for NNTP).

6 years agosearch: reopen skeleton DB as well
Eric Wong (Contractor, The Linux Foundation) [Mon, 26 Feb 2018 23:25:52 +0000 (23:25 +0000)]
search: reopen skeleton DB as well

Any Xapian DB is subject to the same errors and retries.
Perhaps in the future this can made more granular to avoid
unnecessary reopens.

6 years agosearchidxpart: force integers into add_message
Eric Wong (Contractor, The Linux Foundation) [Mon, 26 Feb 2018 23:02:13 +0000 (23:02 +0000)]
searchidxpart: force integers into add_message

Make data passed via Storable to the skeleton worker
a little neater.

6 years agosearchidxthread: load doc data for references
Eric Wong (Contractor, The Linux Foundation) [Sat, 24 Feb 2018 06:58:55 +0000 (06:58 +0000)]
searchidxthread: load doc data for references

Otherwise, references and thread linking doesn't happen
across subject mismatches.  Oops, this is important.

6 years agoview: remove X-PI-TS reference
Eric Wong (Contractor, The Linux Foundation) [Sat, 24 Feb 2018 03:33:59 +0000 (03:33 +0000)]
view: remove X-PI-TS reference

We haven't needed this since we integrated threading
and dropped Email::Abstract and Mail::Thread usage.

6 years agosearchidx: get rid of pointless index_blob wrapper
Eric Wong (Contractor, The Linux Foundation) [Sat, 24 Feb 2018 00:40:09 +0000 (00:40 +0000)]
searchidx: get rid of pointless index_blob wrapper

This used to lookup the message in git, but no longer, so
remove a needless indirection layer and call add_message
directly.

6 years agosearchidx*: name child subprocesses
Eric Wong (Contractor, The Linux Foundation) [Sat, 24 Feb 2018 00:29:51 +0000 (00:29 +0000)]
searchidx*: name child subprocesses

This makes viewing "ps" output nicer.

6 years agosearchidxpart: chomp line before splitting
Eric Wong (Contractor, The Linux Foundation) [Sat, 24 Feb 2018 00:19:51 +0000 (00:19 +0000)]
searchidxpart: chomp line before splitting

This was adding a needless newline into doc_data

6 years agouse PublicInbox::MIME consistently
Eric Wong (Contractor, The Linux Foundation) [Fri, 23 Feb 2018 18:33:34 +0000 (18:33 +0000)]
use PublicInbox::MIME consistently

It works around some bugs in older Email::MIME which we'll
find useful.

6 years agosearchidxpart: binmode
Eric Wong (Contractor, The Linux Foundation) [Fri, 23 Feb 2018 02:28:53 +0000 (02:28 +0000)]
searchidxpart: binmode

Probably unnecessary, but set binmode for consistency across
platforms.

6 years agov2writable: cleanup unused pipes in partitions
Eric Wong (Contractor, The Linux Foundation) [Fri, 23 Feb 2018 02:26:45 +0000 (02:26 +0000)]
v2writable: cleanup unused pipes in partitions

Leaking these pipes to child processes wasn't harmful, but
made determining relationships and dataflow between processes
more confusing.

6 years agov2/ui: retry DB reopens in a few more places
Eric Wong (Contractor, The Linux Foundation) [Thu, 22 Feb 2018 21:17:53 +0000 (21:17 +0000)]
v2/ui: retry DB reopens in a few more places

Relying more on Xapian requires retrying reopens in more
places to ensure it does not fall down and show errors to
the user.

6 years agov2/ui: some hacky things to get the PSGI UI to show up
Eric Wong (Contractor, The Linux Foundation) [Thu, 22 Feb 2018 07:15:54 +0000 (07:15 +0000)]
v2/ui: some hacky things to get the PSGI UI to show up

Fortunately, Xapian multiple database support makes things
easier but we still need to handle the skeleton DB separately.

6 years agov2writable: warn on duplicate Message-IDs
Eric Wong (Contractor, The Linux Foundation) [Thu, 22 Feb 2018 19:10:31 +0000 (19:10 +0000)]
v2writable: warn on duplicate Message-IDs

This should give us an idea of how much a problem deduplication
will be.

6 years agosearchidxpart: increase pipe size for partitions
Eric Wong (Contractor, The Linux Foundation) [Thu, 22 Feb 2018 17:55:37 +0000 (17:55 +0000)]
searchidxpart: increase pipe size for partitions

We want to reduce the time in the main V2Writable process
spends writing to the pipe, as the main process itself is
the primary source of contention.

While we're at it, always flush after writing to ensure
the child sees it at once.  (Grr... Perl doesn't use writev)

6 years agov2writable: round-robin to partitions based on article number
Eric Wong (Contractor, The Linux Foundation) [Thu, 22 Feb 2018 17:55:35 +0000 (17:55 +0000)]
v2writable: round-robin to partitions based on article number

Instead of relying on the git object_id hash to partition,
round-robin to these partitions based on the NNTP article
number.  This reduces the partition pipes as a source of
contention when two (or more) sequential messages end up
going to the same partition.

6 years agov2: parallelize Xapian indexing
Eric Wong (Contractor, The Linux Foundation) [Thu, 22 Feb 2018 01:49:08 +0000 (01:49 +0000)]
v2: parallelize Xapian indexing

The parallelization requires splitting Msgmap, text+term
indexing, and thread-linking out into separate processes.

git-fast-import is fast, so we don't bother parallelizing it.

Msgmap (SQLite) and thread-linking (Xapian) must be serialized
because they rely on monotonically increasing numbers (NNTP
article number and internal thread_id, respectively).

We handle msgmap in the main process which drives fast-import.
When the article number is retrieved/generated, we write the
entire message to per-partition subprocesses via pipes for
expensive text+term indexing.

When these per-partition subprocesses are done with the
expensive text+term indexing, they write SearchMsg (small data)
to a shared pipe (inherited from the main V2Writable process)
back to the threader, which runs its own subprocess.

The number of text+term Xapian partitions is chosen at import
and can be made equal to the number of cores in a machine.

V2Writable --> Import -> git-fast-import
           \-> SearchIdxThread -> Msgmap (synchronous)
           \-> SearchIdxPart[n] -> SearchIdx[*]
   \-> SearchIdxThread -> SearchIdx ("threader", a subprocess)

[* ] each subprocess writes to threader

6 years agoimport_vger_from_mbox: use PublicInbox::MIME and avoid clobbering
Eric Wong (Contractor, The Linux Foundation) [Thu, 22 Feb 2018 17:55:36 +0000 (17:55 +0000)]
import_vger_from_mbox: use PublicInbox::MIME and avoid clobbering

It is less confusing without the clobber assignment; and
PublicInbox::MIME exists to workaround bugs in older
Email::MIME (which is in Debian 9 (stretch))

6 years agoimport_vger_from_inbox: allow "-V" option
Eric Wong (Contractor, The Linux Foundation) [Thu, 22 Feb 2018 05:17:40 +0000 (05:17 +0000)]
import_vger_from_inbox: allow "-V" option

This will let us quickly test between v2 and v1 inboxes.

6 years agov2: support Xapian + SQLite indexing
Eric Wong (Contractor, The Linux Foundation) [Tue, 20 Feb 2018 21:00:21 +0000 (21:00 +0000)]
v2: support Xapian + SQLite indexing

This is too slow, currently.  Working with only 2017 LKML
archives:

         git-only: ~1 minute
     git + SQLite: ~12 minutes
git+Xapian+SQlite: ~45 minutes

So yes, it looks like we'll need to parallelize Xapian indexing,
at least.

6 years agogit: reload alternates file on missing blob
Eric Wong (Contractor, The Linux Foundation) [Mon, 19 Feb 2018 20:07:11 +0000 (20:07 +0000)]
git: reload alternates file on missing blob

Since we'll be adding new repositories to the `alternates' file
in git, we must restart the `git cat-file --batch' process as
git currently does not detect changes to the alternates file
in long-running cat-file processes.

Don't bother with the `--batch-check' process since we won't be
using it with v2.

6 years agov2writable: initial cut for repo-rotation
Eric Wong (Contractor, The Linux Foundation) [Sat, 17 Feb 2018 10:19:47 +0000 (10:19 +0000)]
v2writable: initial cut for repo-rotation

Wrap the old Import package to enable creating new repos based
on size thresholds.  This is better than relying on time-based
rotation as LKML traffic seems to be increasing.

6 years agowww: stop assuming mainrepo == git_dir
Eric Wong (Contractor, The Linux Foundation) [Fri, 16 Feb 2018 03:54:37 +0000 (03:54 +0000)]
www: stop assuming mainrepo == git_dir

It won't be in v2

6 years agosearch: stop assuming Message-ID is unique
Eric Wong (Contractor, The Linux Foundation) [Fri, 16 Feb 2018 02:59:11 +0000 (02:59 +0000)]
search: stop assuming Message-ID is unique

In general, they are, but there's no way for or general purpose
mail server to enforce that.  This is a step in allowing us
to handle more corner cases which existing lists throw at us.

6 years agoextmsg: fix broken Xapian MID lookup
Eric Wong (Contractor, The Linux Foundation) [Fri, 16 Feb 2018 00:17:16 +0000 (00:17 +0000)]
extmsg: fix broken Xapian MID lookup

This likely has no real world implications, though, as we
fall back to Msgmap lookups anyways.

Broken since commit 7eeadcb62729b0efbcb53cd9b7b181897c92cf9a
("search: remove unnecessary abstractions and functionality")

6 years agoimport: allow the epoch (0s) as a valid time
Eric Wong (Contractor, The Linux Foundation) [Thu, 15 Feb 2018 23:20:20 +0000 (23:20 +0000)]
import: allow the epoch (0s) as a valid time

Despite email not existing until 1971; "Jan 1, 1970 00:00:00"
seems like a common default timestamp for some test emails
to use as a Date: header.

6 years agoimport: quiet down warnings from bogus From: lines
Eric Wong (Contractor, The Linux Foundation) [Thu, 15 Feb 2018 09:27:55 +0000 (09:27 +0000)]
import: quiet down warnings from bogus From: lines

There's a lot of crap in archives and git-fast-import
accepts empty names and email addresses for authors
just fine.

6 years agoscripts/import_vger_from_mbox: use v2 layout for import
Eric Wong (Contractor, The Linux Foundation) [Thu, 15 Feb 2018 01:12:18 +0000 (01:12 +0000)]
scripts/import_vger_from_mbox: use v2 layout for import

Big lists are orders of magnitude more efficient with v2.

6 years agoimport: pass "raw" dates to git-fast-import(1)
Eric Wong (Contractor, The Linux Foundation) [Thu, 15 Feb 2018 01:10:06 +0000 (01:10 +0000)]
import: pass "raw" dates to git-fast-import(1)

For LKML, it appears we need an even more liberal parser than
RFC2822 date parser in git.  I have not validated Date::Parse
parses dates correctly, but this at least prevents
git-fast-import(1) from choking.

6 years agoaddress: extract more characters from email addresses
Eric Wong (Contractor, The Linux Foundation) [Thu, 15 Feb 2018 00:25:53 +0000 (00:25 +0000)]
address: extract more characters from email addresses

There's a lot of weird characters which show up in LKML archives
which we did not support before.  Furthermore, allow spaces
before the '>' in the From: line as at least some non-spam
poster used it.

6 years agosearchidx: fix comment around next_thread_id
Eric Wong (Contractor, The Linux Foundation) [Wed, 14 Feb 2018 08:20:38 +0000 (08:20 +0000)]
searchidx: fix comment around next_thread_id

I decided not to copy the notmuch implementation regarding
serialization of integers to Xapian metadata.

6 years agosearch: free up 'Q' prefix for a real unique identifier
Eric Wong (Contractor, The Linux Foundation) [Tue, 13 Feb 2018 03:02:56 +0000 (03:02 +0000)]
search: free up 'Q' prefix for a real unique identifier

This will allow easier-compatibility with v2 code which will
introduce content_id as the unique identifier.
The old "XMID" becomes "XM" as a free text searchable term.
"Q" becomes "XMID" as a boolean prefix.

There's no user-visible changes in this, but there needs to
be a schema version bump later on...
(more changes planned which can affect v1)

6 years agoimport: APIs to support v2 use
Eric Wong (Contractor, The Linux Foundation) [Wed, 14 Feb 2018 00:30:33 +0000 (00:30 +0000)]
import: APIs to support v2 use

Wrap "get-mark" and "checkpoint" commands for git-fast-import
while documenting/cementing parts of the API.

6 years agoscripts/import_vger_from_mbox: support --dry-run option
Eric Wong (Contractor, The Linux Foundation) [Tue, 13 Feb 2018 18:39:40 +0000 (18:39 +0000)]
scripts/import_vger_from_mbox: support --dry-run option

This can be useful for getting baseline of performance
of just Email::MIME and Date: header parsing.  We'll need
to do some Date: header parsing for LKML since there are
some wonky date formats which causes the git RFC822 parser
to choke.

6 years agosearchmsg: add mid_mime import for _extract_mid
Eric Wong (Contractor, The Linux Foundation) [Tue, 13 Feb 2018 02:58:56 +0000 (02:58 +0000)]
searchmsg: add mid_mime import for _extract_mid

Oops, I guess this code was never called and may not be
needed.  But for now, import it so it can run properly.

6 years agocontent_id: add test case
Eric Wong (Contractor, The Linux Foundation) [Mon, 12 Feb 2018 23:09:07 +0000 (23:09 +0000)]
content_id: add test case

6 years agot/import: test for last_object_id insertion
Eric Wong (Contractor, The Linux Foundation) [Mon, 12 Feb 2018 17:55:52 +0000 (17:55 +0000)]
t/import: test for last_object_id insertion

Check for this before doing the Xapian-based v2 importer.

6 years agoimport: initial handling for v2
Eric Wong (Contractor, The Linux Foundation) [Sat, 10 Feb 2018 05:13:19 +0000 (05:13 +0000)]
import: initial handling for v2

Call order will need to change a bit since this is going to be
tied to Xapian

6 years agoimport: begin supporting this without ssoma.lock
Eric Wong (Contractor, The Linux Foundation) [Fri, 9 Feb 2018 23:38:03 +0000 (23:38 +0000)]
import: begin supporting this without ssoma.lock

We'll reuse this class in v2, but won't be utilizing
per-git-repository ssoma.lock files.

Meanwhile, stop treating ::Inbox objects as an afterthought
and allow importing name and email into them.

6 years agoimport: stop writing legacy ssoma.index by default
Eric Wong (Contractor, The Linux Foundation) [Thu, 8 Feb 2018 17:21:36 +0000 (17:21 +0000)]
import: stop writing legacy ssoma.index by default

For machines which have never seen ssoma, they don't need the
index so stop creating it.

6 years agoscripts/import_vger_from_mbox: relax From_ line match slightly
Eric Wong (Contractor, The Linux Foundation) [Thu, 8 Feb 2018 03:49:51 +0000 (03:49 +0000)]
scripts/import_vger_from_mbox: relax From_ line match slightly

The mboxes I got from cregit have two spaces after the email
address, while the "git format-patch" output I'm used to dealing
with only has one space.

It's still a "strict" match in that it checks for something
resembling a timestamp, but it relaxes the number of spaces
between the email address and date.

6 years agowatch_maildir: allow '-' in mail filename
Eric Wong (Contractor, The Linux Foundation) [Thu, 8 Feb 2018 03:32:05 +0000 (03:32 +0000)]
watch_maildir: allow '-' in mail filename

Hostnames can contain '-' and this allows public-inbox-watch(1)
to work on machines which generate Maildir files with '-' in
them.

6 years agoAUTHORS: add The Linux Foundation
Eric Wong (Contractor, The Linux Foundation) [Thu, 8 Feb 2018 02:39:41 +0000 (02:39 +0000)]
AUTHORS: add The Linux Foundation

I'll be working as a contractor for The Linux Foundation on v2
in an effort to support LKML and associated lists.

6 years agopublic-inbox 1.0.0 v1.0.0
Eric Wong [Thu, 8 Feb 2018 02:25:19 +0000 (02:25 +0000)]
public-inbox 1.0.0

Might as well, this release is mostly to serve as a checkpoint
for the start of new development on v2 stuff mentioned in the
TODO.

6 years agoMANIFEST: add AUTHORS file
Eric Wong [Thu, 8 Feb 2018 02:24:45 +0000 (02:24 +0000)]
MANIFEST: add AUTHORS file

6 years agoadd AUTHORS file
Eric Wong [Wed, 7 Feb 2018 21:14:03 +0000 (21:14 +0000)]
add AUTHORS file

This can be useful for tarball distributions which lack full git
history.

6 years agoupdate copyrights for 2018
Eric Wong [Wed, 7 Feb 2018 19:56:45 +0000 (19:56 +0000)]
update copyrights for 2018

Using update-copyrights from gnulib

While we're at it, use the SPDX identifier for AGPL-3.0+ to
ease mechanical processing.

6 years agoview: allow expanding directly to "nested" view
Eric Wong [Sat, 3 Feb 2018 02:50:46 +0000 (02:50 +0000)]
view: allow expanding directly to "nested" view

Sometimes, it can be desirable to jump directly to the "nested"
view when viewing a thread skeleton.  This makes it possible.
While we're at it, shorten some of the text to ensure it still
fits in 80 columns.

6 years agoview: close <pre> in reply instructions
Eric Wong [Tue, 30 Jan 2018 18:17:47 +0000 (18:17 +0000)]
view: close <pre> in reply instructions

We leave the mailto: link out when obfuscating address, so
do not stuff the "</pre>" closing tag into it.  Instead,
keep the closing tag in the same context as the opening one,
making it easier to keep track of.

6 years agoreply: follow obfuscation rules for HTML in sh args
Eric Wong [Mon, 29 Jan 2018 13:04:09 +0000 (13:04 +0000)]
reply: follow obfuscation rules for HTML in sh args

Namely, we do not want to obfuscate the mail address of the
site itself.

6 years agoview: adjust wording for reply-to-list configs
Eric Wong [Mon, 29 Jan 2018 11:49:56 +0000 (11:49 +0000)]
view: adjust wording for reply-to-list configs

This makes the wording less confusing when showing archives
for lists where the convention is reply-to-list.
I still hate reply-to-list, but it's still better than no
archives or list at all.

6 years agoatom: show metadata before message body
Eric Wong [Fri, 26 Jan 2018 21:54:00 +0000 (21:54 +0000)]
atom: show metadata before message body

This can allow streaming parsers (SAX) to work a little more
efficiently as they can handle/discard all the metadata before
the big content.

6 years agodoc/design_www: adjust some wording and URLs around CSS
Eric Wong [Thu, 25 Jan 2018 06:30:03 +0000 (06:30 +0000)]
doc/design_www: adjust some wording and URLs around CSS

I still hate that CSS is over-used, but colors are useful
and perhaps using them for highlighting won't be too bad;
but user-supplied colors will ALWAYS be supported.

6 years agoTODO: notes about v2 format for giant archives
Eric Wong [Tue, 16 Jan 2018 22:18:16 +0000 (22:18 +0000)]
TODO: notes about v2 format for giant archives

Inspired by interest in LKML archival:

https://public-inbox.org/meta/d5546b24-5840-4ae9-d25b-5e3e737ed73b@linuxfoundation.org

6 years agohval: only allow domain obfuscation in address
Eric Wong [Tue, 16 Jan 2018 05:08:22 +0000 (05:08 +0000)]
hval: only allow domain obfuscation in address

Obfuscating username portions of the email address leads
to having subsequent parts of the address not being obfuscated;
which could mean we show someone else's email entirely.

In other words, obfuscating "john.doe@example.com" becomes
might mean "doe@example.com" is picked up by scanners.

In other news, email address obfuscation is still a horrible
usability issue and only exists to appease misguided people.

6 years agoview: avoid deduping a single word in subject skeletons
Eric Wong [Thu, 21 Dec 2017 00:58:01 +0000 (00:58 +0000)]
view: avoid deduping a single word in subject skeletons

It is usually pointless to replace a single word with a '"' character.

6 years agosearch: force large mbox result downloads to POST
Eric Wong [Fri, 8 Dec 2017 20:54:09 +0000 (20:54 +0000)]
search: force large mbox result downloads to POST

This should prevent crawlers (including most robots.txt ignoring
ones) from burning our CPU time without severely compromising
usability for humans.

6 years agosearchview: nofollow on mbox downloads
Eric Wong [Thu, 7 Dec 2017 20:30:07 +0000 (20:30 +0000)]
searchview: nofollow on mbox downloads

Some search results are gigantic, and search engines are
unlikely to be able to handle gzipped mboxes anyways.

6 years agosearch: allow downloading search results as mbox
Eric Wong [Wed, 29 Nov 2017 09:33:17 +0000 (09:33 +0000)]
search: allow downloading search results as mbox

Allowing downloading of all search results as an gzipped mboxrd
file can be convenient for some users.

6 years agoview: avoid warning from negative repeat counts
Eric Wong [Wed, 29 Nov 2017 09:29:24 +0000 (09:29 +0000)]
view: avoid warning from negative repeat counts

Perl 5.22 started warning about this.

6 years agosearchview: s/threaded/nested/
Eric Wong [Wed, 29 Nov 2017 09:23:38 +0000 (09:23 +0000)]
searchview: s/threaded/nested/

We want to be consistent with the view change in
commit b223e6f49debb99b9132bc85d97a065ebcee00b9

6 years agowatch: use "spam" in commit message for removals
Eric Wong [Thu, 16 Nov 2017 19:23:49 +0000 (19:23 +0000)]
watch: use "spam" in commit message for removals

This makes it easy to identify the reason for message removals.

6 years agolearn: use "spam" as subject for removal commits (part #2)
Eric Wong [Thu, 16 Nov 2017 19:21:06 +0000 (19:21 +0000)]
learn: use "spam" as subject for removal commits (part #2)

We need to use the correct subject when doing global scanning,
too.  In fact, the per-recipient spam training path is entirely
redundant at this point.

6 years agolearn: use "spam" as subject for removal commits
Eric Wong [Thu, 16 Nov 2017 18:48:39 +0000 (18:48 +0000)]
learn: use "spam" as subject for removal commits

Sometimes an email is an innocent removal "rm" for a
misdirected, off-topic post, while most removed messages are
"spam".  Allow anybody to look at history and easily distinguish
the reason for removing the message.

6 years agoview: s/threaded/nested/ in view
Eric Wong [Wed, 18 Oct 2017 21:28:52 +0000 (21:28 +0000)]
view: s/threaded/nested/ in view

We always do threading, so perhaps it's not a good name.
"Nested" is probably more appropriate and closer to what
people are used to seeing.

6 years agombox: support inline filename via Content-Disposition header
Eric Wong [Wed, 4 Oct 2017 22:54:23 +0000 (22:54 +0000)]
mbox: support inline filename via Content-Disposition header

This is hopefully more sensical than "raw" files from
resulting downloads.

6 years agosearch: try to fill in ghosts when generating thread skeleton
Eric Wong [Tue, 3 Oct 2017 19:43:30 +0000 (19:43 +0000)]
search: try to fill in ghosts when generating thread skeleton

Since we attempt to fill in threads by Subject, our thread
skeletons can cross actual thread IDs, leading to the
possibility of false ghosts showing up in the skeleton.
Try to fill in the ghosts as well as possible by performing
a message lookup.

6 years agothreading: deal with improperly-terminated References headers
Eric Wong [Mon, 2 Oct 2017 22:19:16 +0000 (22:19 +0000)]
threading: deal with improperly-terminated References headers

We should not blindly join References and In-Reply-To headers
as a single string, because some messages can have an open
angle brace '<' in References: without a corresponding '>'.

6 years agowww: Atom stream respects timezone
Eric Wong [Thu, 13 Jul 2017 22:47:29 +0000 (22:47 +0000)]
www: Atom stream respects timezone

Oops, we must not discard the timezone when parsing dates
for the Atom stream.

6 years agoMANIFEST: add hosted list
Eric Wong [Thu, 13 Jul 2017 22:46:29 +0000 (22:46 +0000)]
MANIFEST: add hosted list

6 years agodoc: add ruby-dev mirror to the list of hosted mirrors
Eric Wong [Sun, 2 Jul 2017 21:43:51 +0000 (21:43 +0000)]
doc: add ruby-dev mirror to the list of hosted mirrors

It seems Xapian is not prepared for Japanese, unfortunately.

https://public-inbox.org/meta/20170702213657.GA5312@dcvr/

6 years agodoc: add a list of hosted archives for external projects
Eric Wong [Fri, 30 Jun 2017 18:47:33 +0000 (18:47 +0000)]
doc: add a list of hosted archives for external projects

This will hopefully increase visibility of some archives.

6 years agoview: cull redundant phrases in subjects
Eric Wong [Thu, 29 Jun 2017 21:48:30 +0000 (21:48 +0000)]
view: cull redundant phrases in subjects

There is no need to show the same phrases over and over again
in thread skeletons, it adds to visual noise and makes things
more difficult to read.

6 years agoscripts/import_maildir: rewrite to use Import
Eric Wong [Thu, 29 Jun 2017 07:14:28 +0000 (07:14 +0000)]
scripts/import_maildir: rewrite to use Import

This will be much faster and invoking -mda for every message.

6 years agohval: only perform one substitution when obfuscating
Eric Wong [Thu, 29 Jun 2017 00:10:38 +0000 (00:10 +0000)]
hval: only perform one substitution when obfuscating

Only one substitution character is necessary when obfuscating
email addresses.

6 years agomsgmap: reduce constant usage
Eric Wong [Mon, 26 Jun 2017 18:13:57 +0000 (18:13 +0000)]
msgmap: reduce constant usage

It is needless bloat and doesn't seem to help with readability,
in retrospect, either.

6 years agowatch: avoid potential race condition while quitting
Eric Wong [Mon, 26 Jun 2017 17:44:41 +0000 (17:44 +0000)]
watch: avoid potential race condition while quitting

We must not trigger future activity when initializing
a -watch shutdown.

6 years agotests: deal with the removal of '.' from @INC in newer Perl
Eric Wong [Mon, 26 Jun 2017 04:34:13 +0000 (04:34 +0000)]
tests: deal with the removal of '.' from @INC in newer Perl

Oops, this is needed for Perl 5.22 (tested 5.24.1) since '.'
was removed due to security problems.  Fwiw, I consider this
change to Perl an overreaction and do not agree with it.