]> Sergey Matveev's repositories - public-inbox.git/blob - Documentation/design_notes.txt
doc: language-neutral client-side endpoints
[public-inbox.git] / Documentation / design_notes.txt
1 public-inbox design notes
2 -------------------------
3
4 Challenges to running normal mailing lists
5 ------------------------------------------
6
7 1) spam
8 2) bounce processing of invalid/bad email addresses
9 3) processing subscribe/unsubscribe requests
10
11 Issues 2) and 3) are side-stepped entirely by moving reader
12 subscriptions to git repository synchronization and Atom feeds.  There's
13 no chance of faked subscription requests and no need to deal with
14 confused users who cannot unsubscribe.
15
16 Use existing infrastructure
17 ---------------------------
18
19 * public-inbox can coexist with existing mailing lists, any subscriber
20   to the existing mailing list can begin delivering messages to
21   public-inbox-mda(1)
22
23 * public-inbox uses SMTP for posting.  Posting a message to a public-inbox
24   instance is no different than sending a message to any _open_ mailing
25   list.
26
27 * Existing spam filtering on an SMTP server is also effective on
28   public-inbox.
29
30 * readers may continue using use their choice of mail clients and
31   mailbox formats, only learning a few commands of the ssoma(1) tool
32   is required.
33
34 * Atom is a reasonable feed format for casual readers and is supported
35   by a variety of feed readers.
36
37 Why email?
38 ----------
39
40 * Freedom from proprietary services, tools and APIs.  Communicating with
41   developers and users of Free Software should not rely on proprietary
42   tools or services.
43
44 * Existing infrastructure, tools, and user familiarity.
45   There is already a large variety of tools, clients, and email providers
46   available.  There are also many resources for users to run their own
47   SMTP server on a domain they control.
48
49 * All public discussion mediums are affected by spam and advertising.
50   There exist several good Free Software anti-spam tools for email.
51
52 * Privacy is not an issue for public discussion.  Public mailing list
53   archives are common and accepted by Free Software communities.
54   There is no need to ask the NSA for backups of your mail archives :)
55
56 * git, one of the most widely-used version control systems, includes many
57   tools for for email, including: git-format-patch(1), git-send-email(1),
58   git-am(1), git-imap-send(1).  Furthermore, the development of git itself
59   is based on the git mailing list.
60
61 * Email is already the de-facto form of communication in many Free Software
62   communities..
63
64 * Fallback/transition to private email and other lists, in case the
65   public-inbox host becomes unavailable, users may still directly email
66   each other (or Cc: lists for related/dependent projects).
67
68 Why git?
69 --------
70
71 * git is distributed and robust while being both fast and
72   space-efficient with text data.  NNTP was considered, but does not
73   support delta-compression and places no guarantees on data/transport
74   integrity.  However, a read-only NNTP gateway is implemented.
75
76 * As of 2016, git is widely used and known to nearly all Free Software
77   developers.  For non-developers it is packaged for all major GNU/Linux
78   and *BSD distributions.  NNTP is not as widely-used nowadays.
79
80 Why perl 5?
81 -----------
82
83 * Perl 5 is widely available on modern *nix systems with good a history
84   of backwards and forward compatibility.
85
86 * git and SpamAssassin both use it, so it should be one less thing for
87   admins to install and waste disk space with.
88
89 Laziness
90 --------
91
92 * Stick to dependencies available in Debian main, this should make it
93   easier for potential users to install, and easier for distro
94   maintainers to pick up.
95
96 * A list server being turned into an SMTP spam relay and being
97   blacklisted while an admin is asleep is scary.
98   Sidestep that entirely by having clients pull.
99
100 * Eric has a great Maildir+inotify-based Bayes training setup
101   going back many years.  Document, integrate and publicize it for
102   public-inbox usage, encouraging other admins to use it (it works
103   as long as admins read their public-inbox).
104
105 * Custom, difficult-for-Bayes requires custom anti-spam rules.
106   We may steal rules from the Debian listmasters:
107   svn://anonscm.debian.org/pkg-listmaster
108
109 * Full archives are easily distributable with git, so somebody else
110   can take over the list if we give up.  Anybody may also run an SMTP
111   notifier/delivery service based on the archives.
112
113 * Avoids bikeshedding about web UI decisions, GUI-lovers can write their
114   own GUI-friendly interfaces (HTML or native) based on public archives.
115   Maybe one day integrated MUAs will feature built-in git protocol support!
116
117 Web notes
118 ---------
119
120 * Getting users to install/run ssoma (or any new tool) is difficult.
121   The web views must be easily read/cache/mirror-able.
122
123 * There may also be a significant number of webmail users without
124   an MUA or feed reader; so a web view is necessary.
125
126 * Expose Message-ID in web views to encourage replies from drive-by
127   contributors.
128
129 * Raw text endpoint allows users to write client-side endpoints
130   without hosting the data themselves (or on a different server).
131
132 What sucks about public-inbox
133 -----------------------------
134
135 * Lack of push notification.  On the other hand, feeds seem popular.
136
137 * some (mostly GUI) mail clients cannot set In-Reply-To headers
138   properly without the original message.
139
140 Scalability notes
141 -----------------
142
143 Even with shallow clone, storing the history of large/busy mailing lists
144 may place much burden on subscribers and servers.  However, having a
145 single (or few) refs representing the entire history of a list is good
146 for small lists since it's easier to look up a message by Message-ID, so
147 we want to avoid splitting refs with independent histories.
148
149 ssoma will likely grow its own built-in ref rotation system based on
150 message count (not rotating at fixed time intervals).  This would
151 split the histories and require O(n) lookup time based on Message-ID,
152 where `n' is the number of history splits.
153
154 Copyright
155 ---------
156
157 Copyright 2013-2015 all contributors <meta@public-inbox.org>
158 License: AGPLv3 or later <http://www.gnu.org/licenses/agpl-3.0.txt>