Skip to content

Instantly share code, notes, and snippets.

@jhs
Created January 25, 2013 11:09
Show Gist options
  • Save jhs/4633548 to your computer and use it in GitHub Desktop.
Save jhs/4633548 to your computer and use it in GitHub Desktop.

Hi, all.

Encouraged by my successful experiment with a Node.js view server, I am now working on a branch, nodejs_couchdb, with the following properties:

  • Remove couchjs from the project
  • Remove dependency on SpiderMonkey, libjs, 1.8.whatever...all that is gone
  • Remove dependency on libcurl
  • (Thus, simplified autoconf version dependency Hell)

Phase 1: Dependency on a "couchjs" executable which you install via npm install couchjs

Phase 2: Dependency only on a node binary

As before, with the exception of E4X, I expect to retain 100% compatibility.

This is an experiment just to see how things feel. I want to see how it feels to stop saying "CouchDB requires libjs185/xulrunner/spidermonkey/whatever" and start saying "CouchDB requires Node.js."

Status

I just got it compiling and ./utils/run runs but I have not tested more yet. But check out my diff!

https://github.com/jhs/couchdb/compare/nodejs_couchdb

$ git diff --stat asf/master..HEAD
 bin/Makefile.am                   |    8 +-
 configure.ac                      |  141 --------
 etc/couchdb/Makefile.am           |    5 -
 etc/couchdb/default.ini.tpl.in    |    4 +-
 license.skip                      |    2 -
 src/couchdb/priv/Makefile.am      |   31 --
 src/couchdb/priv/couch_js/help.h  |   82 -----
 src/couchdb/priv/couch_js/http.c  |  698 -------------------------------------
 src/couchdb/priv/couch_js/http.h  |   27 --
 src/couchdb/priv/couch_js/main.c  |   21 --
 src/couchdb/priv/couch_js/sm170.c |  398 ---------------------
 src/couchdb/priv/couch_js/sm180.c |  407 ---------------------
 src/couchdb/priv/couch_js/sm185.c |  427 -----------------------
 src/couchdb/priv/couch_js/utf8.c  |  291 ----------------
 src/couchdb/priv/couch_js/utf8.h  |   19 -
 src/couchdb/priv/couch_js/util.c  |  294 ----------------
 src/couchdb/priv/couch_js/util.h  |   35 --
 test/javascript/run.tpl           |    2 +-
 18 files changed, 4 insertions(+), 2888 deletions(-)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment