This repository has been archived by the owner. It is now read-only.
Free and Hassle-free Pastebin for Markdown Pages.
Switch branches/tags
Nothing to show
Clone or download
Pull request Compare This branch is 78 commits behind chmllr:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.



NoteHub is a free and hassle-free pastebin for one-off markdown publishing and was implemented as a one-app-one-language experiment.


NoteHub's implementation aims for ultimate simplicity and performance.


  1. At a request, the server first checks, if a note is already rendered and is present in the LRU cache.
    (a) If yes, it return the rendered HTML code and increases the views counter.
    (b) Otherwise, the note is retrieved from the DB, rendered and put into the LRU cache; the views counter will be increased.
  2. The rendering of note pages: there are HTML file tempates with placeholders, which will be trivially filled with replacements.
  3. The LRU cache holds the rendered HTML for the most popular notes, which makes their access a static O(1) operation without any DB I/O.
  4. The server keeps corresponding models for all notes in the cache for statistics updates. These models are persisted every 5 minutes to the DB.

Installation & Deployment

To run NoteHub as a standalone version, execute:

  1. git clone
  2. npm install
  3. npm start

This starts a NoteHub instance on port 3000.