about summary refs log tree commit homepage
path: root/lib/PublicInbox/Feed.pm
DateCommit message (Collapse)
2015-08-17feed: remove unnecesary time paramenter in index state
We no longer do "smart" time displays as of commit ea0e8649f90d1fd0850a41c0ca16642faadf4f14 ("view: simplify timestamp generation"). In retrospect, that commit also made us more cache-friendly, too.
2015-08-15thread: common sorting code
We'll be sharing the same threading, so it makes sense to sort replies using the same code and message headers without repeating ourselves. This also standardizes on sorting on X-PI-TS (Unix epoch in seconds) instead over using X-PI-Date differently in two different places
2015-07-20feed: extract subroutines for threading
We'll be using this in the future for displaying per-thread views.
2015-07-06feed: compile regexps only once
This avoids some runtime penalties associated with recompiling a regexp based on a constant local variable.
2015-07-06feed: close body tag correctly in index
Oops, noticed by manual inspection. One day we'll run tidy in tests to validate.
2014-09-15index: add prev/next index navigation
This helps readers jump around more quickly when there are large messages.
2014-09-15index group state parameters together for generation
This allows us to more-easily group and pass parameters.
2014-09-15index: show short-ish permalinks to messages in threads
This should allow us to reference discussions more easily.
2014-09-13line-wrap generated HTML source around attrs for readability
It's important to keep HTML source readable to folks who prefer to read raw HTML. This should improve readability of the HTML source by keeping line length in check without wasting bytes.
2014-09-07feed: (cleanup) avoid redundant ->message call
Avoid redundant subroutine calls as their costs tend to add up.
2014-09-07feed: sort child messages (forward) chronologically
Only root messages should be sorted in reverse chronological order, child messages should be chronological. This gives precedence to _topics_, but also for initial replies. This improves readability when several messages appear at the same nesting level, and helps git patch series' appear correctly as: [PATCH 0/3] ... [PATCH 1/3] ... [PATCH 2/3] ... [PATCH 3/3] ... Instead of (what it was previously): [PATCH 0/3] ... [PATCH 3/3] ... [PATCH 2/3] ... [PATCH 1/3] ...
2014-08-28feed: deal with removed files
Sometimes we get spam and need to delete messages, we must prevent errors on missing messages from propagating.
2014-08-28feed: show permalink to home page
This will make it easier to bookmark an index page with threading context.
2014-08-28redo main HTML index to show nested messages
This reduces the need for page reloads in common cases and should improve reading speed so users do not need to open many browser tabs. This will hopefully increase an encourage readership. The downside of this are increased server processing overhead and easier address scraping by spam bots.
2014-08-26show date in top-level threaded index
This is probably useful information for folks browsing via web interface. It'll probably make more sense if we show the entire body in the threaded display, though.
2014-05-07consistently whitespace wrap on <pre> sections
Horizontal scrolling is a usability problem for GUI browsers, so help them avoid it. I love GUI users, really! :)
2014-05-05feed: add atom feed link to the bottom
This should improve navigation as browsers may not make it obvious there is an Atom feed.
2014-05-05www: add footers to HTML index and message views
Some advertising is necessary.
2014-05-04add various TODO items
Screen space is precious, and we do not need it in the abbreviated view.
2014-05-02view: API cleanup, remove "as_" prefix
These views are not OO, so the "as_" prefix makes little sense and "as_html" conflicts with Hval, which is OO.
2014-05-02reduce copies by passing string refs to Email::MIME
This should reduce data copies and memory usage, according to Email::Simple documentation.
2014-05-01workaround Mail::Thread memory leak
Thanks to Ask for the patch in https://rt.cpan.org/Public/Bug/Display.html?id=22817
2014-05-01purge Email::Address cache
This prevents memory bloat in case we're serving many requests with a large, diverse set of email addresses (potentially from malicious spammers).
2014-04-30feed: unset GIT_DIR and use "git --git-dir=.. log"
This should elimate all of our %ENV dependencies in the WWW portion of our code.
2014-04-29implement our own cat-file --batch wrapper
We use --git-dir=... instead of $ENV{GIT_DIR} because ENV changes do not propagate easily with mod_perl.
2014-04-28feed: call URI->as_string explicitly
Implicit string conversion is more confusing.
2014-04-28use relative URLs in HTML index
Browsers know how to follow relative URLs, so we may generate smaller HTML pages.
2014-04-28feed: swap order of "next" and "head" links
This is one less key stroke for somebody paging through the list history.
2014-04-28feed: avoid redirect on permalink
This saves one round-trip request response so reduces latency over slow links. The redirect only exists for convenience and isn't 100% reliable in case the Message-ID terminates with a .(html|txt) suffix.
2014-04-28feed: dead code elimination around dropped endpoints
public-inbox is for discussion, so top-level posts do not get special treatment.
2014-04-28feed: disable navigation to previous page
This is unfortunately needed for scalability to long histories. The design of git requires it to traverse full history to walk forward in time, since commits can only record past history. Instead, replace "prev" with a "head" link to zip us back to the most recent page. Users who wish to go backwards can use browser history, which should always work on our old-fashioned HTML pages.
2014-04-28feed: pedantically quote HTML attributes
This is more correct, although it costs us 4 bytes.
2014-04-28allow running as a Plack app without CGI emulation
This might be slightly cleaner, though generating the base URL now has an ugly condition in it.
2014-04-27feeds use XHTML to avoid tag soup
This should work in most browsers, lets find out!
2014-04-27Feed: <id> element must be a URI, oops :x
For each feed element, we'll just use the link since there's currently no suitable URN.
2014-04-26feed: comment about the %deleted hash
It's strictly not necessary anymore since commit fa6168c56bdd1cece178b6b852a9b2cba6ce6ffb ("feed: message must exist in current HEAD to show up") However it can still save us some unnecessary syscalls and round-trips to the "git cat-file --batch" process, so it's probably worth th cost of stuffing it in a hash.
2014-04-26feed: message must exist in current HEAD to show up
We do not want recently-deleted spam showing up when looking in old histories.
2014-04-26huge refactor of encoding handling
Hopefully this simplifies and corrects our usage of Perl encoding APIs.
2014-04-24html: refactor header value handling to be OO
This helps us keep track of escaping which needs to be done for various levels.
2014-04-22fix quoted URL generation in feeds
While we're at it, make sure strange characters are escaped properly in Message-IDs. We'll need tests for all this behavior.
2014-04-21feed: fix address when multiple addresses exist
This needs to be cleaned up
2014-04-21config: use description file for gitweb
Do not repeat ourselves, just use the same description file gitweb uses to avoid surprising users.
2014-04-21html/index: fix broken prev/next pagination on short histories
We do not have much history in public-inbox meta, so do not mislead users with strange navigation elements which lead nowhere.
2014-04-21feed: there is only one atom feed, with all messages
This is not a blog. All posts, whether replies or not, carry equal weight.
2014-04-21html/index: do not waste space with non-existent thread roots
Screen real-estate is valuable, and missing roots tend to be false-positive matches (using Subject, not In-Reply-To or References).
2014-04-20feed: close string ref before returning
Just in case there is an error, this should be more explicit.
2014-04-20cgi: delay some requires
This shaves off nearly 100ms when my Core2Duo is clocked to 800Mhz when rendering a full HTML index.
2014-04-20feed: speed up blob checks if Git.pm is usable
Git::cat_blob is a handy interface to read multiple emails without incurring fork + exec overhead. Git.pm is GPLv2+, not GPLv2-only, so we may link to it.
2014-04-19cgi: index pages allow iterating some pagination
This allows WWW readers to slowly page through the entire history of the mailing list.
2014-04-17cgi: sort HTML index by most recent date
This is hopefully the most user-friendly method.