Skip to content

Instantly share code, notes, and snippets.

@ahamid
Created October 24, 2014 03:18

Revisions

  1. ahamid created this gist Oct 24, 2014.
    16 changes: 16 additions & 0 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,16 @@
    var express = require("express");
    var app = express();

    var TOO_MANY = 8000;

    function handler(req, res) {
    res.send("handler");
    }

    // test higher routes, eventually you will get
    // RangeError: Maximum call stack size exceeded
    for (var i = 0; i < TOO_MANY; i++) {
    app.get('/' + i, handler);
    }

    app.listen(8181);