Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: cloudant/bigcouch
...
head fork: cloudant/bigcouch
Checking mergeability… Don't worry, you can still create the pull request.
Commits on Jun 23, 2011
@fdmanana fdmanana Merged revision 1138796 from trunk
    Simpler and safer db open/closing in view group servers

    This makes the opening and closing of databases in the view
    group server to be more friendly with the db reference counting
    system, avoiding more potential db file leaking after compaction,
    as we currently open a database in one process and use it on
    another process (view compactor, view updater).

    This significantly reduces the chances of failure when compacting
    very large views as discussed in COUCHDB-994.

    This relates to COUCHDB-926 and COUCHDB-994.



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1138798 13f79535-47bb-0310-9956-ffa450edef68
91e2121
@fdmanana fdmanana Merged revision 1104168 from trunk
   Add infinity timeout to couch_ref_counter calls

   After compacting a very large database, the updater calls the couch_db gen_server with
   a db record that contains a new ref counter. The couch_db gen_server calls drop on the
   old ref counter and calls add on the new ref counter. However since the system is busy
   deleting the old db file or garbage collecting, one of the ref counter calls times out,
   causing couch_db's terminate to invoked and terminate calls shutdown on the updater.
   However the updater is waiting for the call it made to couch_db to complete, which can't
   complete since it's waiting for the updater.



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1138799 13f79535-47bb-0310-9956-ffa450edef68
71eb204
Commits on Jun 26, 2011
@fdmanana fdmanana Merged revision 1139894 from trunk
    Don't steal data from subsequent requests in the pipeline


git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1139897 13f79535-47bb-0310-9956-ffa450edef68
7e906e6
Commits on Jun 28, 2011
@fdmanana fdmanana Backport revision 1140886 from trunk
    Improved error message in the replicator


git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1140887 13f79535-47bb-0310-9956-ffa450edef68
d698504
Commits on Jun 30, 2011
@rnewson rnewson COUCHDB-1206 - include current_seq in view ETag for include_docs=true
git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1141522 13f79535-47bb-0310-9956-ffa450edef68
b727a76
@rnewson rnewson COUCHDB-1206 - document in CHANGES/NEWS.
git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1141524 13f79535-47bb-0310-9956-ffa450edef68
364d54f
Commits on Jul 02, 2011
@fdmanana fdmanana Restart replications on error
If a replication transitions to the "error" state, attempt
to restart it up to "max_replication_retry_count" times
(.ini configuration parameter). This number of retry attempts
can now be set to "infinity" as well.

This was already current behaviour in trunk (upcoming 1.2).

Closes COUCHDB-1194.



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1142258 13f79535-47bb-0310-9956-ffa450edef68
276406d
@fdmanana fdmanana Merge revision 1142259 from trunk
    Replication manager, ignore db monitor messages

    Ignore local database monitor messages. These messages
    are received in some circunstances because replication
    processes spawn local database monitors but never
    do the corresponding erlang:demonitor/1,2 calls.


git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1142260 13f79535-47bb-0310-9956-ffa450edef68
7369394
@fdmanana fdmanana Merged revision 1142262 from trunk
    On server startup, restart replications in error

    If we setup a continuous replication which goes into
    an error state and restart Couch just before the
    replication is retried (before it transitions to the
    triggered state), the user has to manually restart
    the replication (recreating the document or deleting      
    its _replication_state field).



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1142263 13f79535-47bb-0310-9956-ffa450edef68
5caca0f
Commits on Jul 03, 2011
@fdmanana fdmanana Remove warning about unused variable
git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1142410 13f79535-47bb-0310-9956-ffa450edef68
6ef446a
Commits on Jul 04, 2011
@janl janl Backport r1142685 from trunk: Allow "/" as vhost target.
Includes a one-line whitespace fix.

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1142689 13f79535-47bb-0310-9956-ffa450edef68
5fa79a8
Commits on Jul 06, 2011
@fdmanana fdmanana Merge revision 1143375 from trunk
    Redefine logging macros

    With these macro definitions we don't evaluate the arguments
    if the corresponding log level is not enabled.
    This behaviour was accidently removed by the patch from
    COUCHDB-1054.



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1143376 13f79535-47bb-0310-9956-ffa450edef68
8d53b7d
Commits on Jul 25, 2011
@rnewson rnewson assert that calls to file functions actually succeed.
1) couch_file:sync could leave open fd's if close failed. Now we'll get a trace.
2) couch_file:append_term failing would be bad, so let's test that too.

backported from trunk r1150915

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1150918 13f79535-47bb-0310-9956-ffa450edef68
9e4abec
Commits on Jul 28, 2011
@rnewson rnewson revert redundant pattern match.
git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1151976 13f79535-47bb-0310-9956-ffa450edef68
6f43183
Commits on Jul 30, 2011
@tilgovi tilgovi Backport of r1152397 from trunk
Call traversal handlers in btree folds

Previously the fold function was only invoked for leafs.
With this change it's possible to define a fold function which is called
for inner nodes and can return a tuple {skip, Acc} in order to skip
exploration of the branch.

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1152405 13f79535-47bb-0310-9956-ffa450edef68
daa640b
@tilgovi tilgovi Backport of r1152398 from trunk
Fix COUCHDB-1076 - views skip empty btree branches

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1152406 13f79535-47bb-0310-9956-ffa450edef68
2a92b4b
@tilgovi tilgovi Backport of r1152399 from trunk
add an etap test for btree traversal callbacks

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1152407 13f79535-47bb-0310-9956-ffa450edef68
916f33c
Commits on Aug 10, 2011
@rnewson rnewson COUCHDB-1244 - close file descriptor in couch_log:read/2
git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1156351 13f79535-47bb-0310-9956-ffa450edef68
5385dee
@fdmanana fdmanana Merged revision 1156360 from trunk
    Prevent data loss on db creation request

    1) Create and populate a database
    2) Restart the server
    3) Send a PUT request to create the database - the server
       will override the existing file, making all previous
       documents no longer accessible nor recoverable



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1156361 13f79535-47bb-0310-9956-ffa450edef68
b2db4f1
@rnewson rnewson COUCHDB-1245 - enforce maximum chunk size for _log call to better man…
…age memory.

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1156369 13f79535-47bb-0310-9956-ffa450edef68
0ac7f70
@fdmanana fdmanana Revert couch_server changes added in revision 1156361
Leaving the tests however since it doesn't hurt.



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1156385 13f79535-47bb-0310-9956-ffa450edef68
f269c49
Commits on Aug 13, 2011
@fdmanana fdmanana Merge revision 1157428 from trunk
    Doc validation functions from deleted ddocs must be ignored

    If a design document is deleted by updating it with a "_deleted"
    field set to the boolean value true, its validate_doc_update function
    should be ignored for subsequent document insertions/updates.

    This closes COUCHDB-1227.



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1157429 13f79535-47bb-0310-9956-ffa450edef68
2eb6233
Commits on Aug 15, 2011
@davisp davisp Fix empty range check for raw collation.
The check for empty ranges was not taking into account the
view option for raw collation. This fixes that by passing
the couch_btree:less/2 function into the check.

Patch by: Jason Smith
Back port of: 1156506, 1156507, 1156509, 1156509, 1156610




git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1157706 13f79535-47bb-0310-9956-ffa450edef68
0dc0f8b
Commits on Aug 18, 2011
@fdmanana fdmanana Merge revision 1159045 from trunk
    Fix dead lock case in the os process pool

    Part of this patch was done by Paul Davis.
    The patch also introduces a test case to validate that
    the os process pool (couch_query_servers) operates as it
    should.
    Closes COUCHDB-1246.



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1159049 13f79535-47bb-0310-9956-ffa450edef68
82a10d7
@fdmanana fdmanana Added executable bit to test/etap/210-os-proc-pool.t
git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1159050 13f79535-47bb-0310-9956-ffa450edef68
33c0215
@fdmanana fdmanana Add missing assertions to test/etap/210-os-proc-pool.t
git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1159059 13f79535-47bb-0310-9956-ffa450edef68
542f273
Commits on Aug 19, 2011
@fdmanana fdmanana Updated changes feed connect timeout to 30 seconds
This is the timeout used everywhere else. Some users are
constantly unable to replicate since under some scenarios
(namely via SSL) a timeout of 10 seconds is too short.

This is related to a thread in the users mailing list:
http://mail-archives.apache.org/mod_mbox/couchdb-user/201106.mbox/%3CBANLkTik3y-nN1uWMyNgzA_0ZSjxXdcMqQw@mail.gmail.com%3E



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1159501 13f79535-47bb-0310-9956-ffa450edef68
045fa89
Commits on Aug 23, 2011
@tilgovi tilgovi bring windows in line with r1001283 (COUCHDB-1197)
Thanks to Dave Cottlehuber for the patch.
This is a backport of r1160857 from trunk

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1160859 13f79535-47bb-0310-9956-ffa450edef68
476b01c
Commits on Aug 25, 2011
@kocolosk kocolosk Do not suppress old revisions from _changes
Requests to '_changes?style=all_docs' with a 'since' parameter would
suppress revisions of a document generated before the start of the
feed.  The assumption may have been that those revisions were seen by
the client in a previous request to _changes, but this is not
necessarily true if the client is resuming the feed after a partial
download.

The safe thing to do is to include all leaf revisions for each document
in the feed.

Thanks Bob Dionne for the test code.

Closes COUCHDB-1256

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1161702 13f79535-47bb-0310-9956-ffa450edef68
9472aff
@kocolosk kocolosk Remove Style where we have no need for it
git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1161703 13f79535-47bb-0310-9956-ffa450edef68
595ceeb
Commits on Aug 27, 2011
@fdmanana fdmanana Fix replication crash on database compaction
There were race conditions that made replications crash
when a local endpoint database is compacted.
Patch tested by Joan Touzet.



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1162306 13f79535-47bb-0310-9956-ffa450edef68
745dc43
@fdmanana fdmanana Remove unnecessary call after revision 1162306
git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1162307 13f79535-47bb-0310-9956-ffa450edef68
d87bcb8
Commits on Aug 31, 2011
@fdmanana fdmanana Fix order of parameters in log message
git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1163747 13f79535-47bb-0310-9956-ffa450edef68
25f208d
Commits on Sep 02, 2011
@davisp davisp Fixes COUCHDB-1265
Backport of 1164350 from trunk. Slightly modified for an export 
declaration conflict and removing a clause that only applies to
trunk.



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1164351 13f79535-47bb-0310-9956-ffa450edef68
840cb72
Commits on Sep 07, 2011
@tilgovi tilgovi additional libtool lubrication for windows build
This is related to COUCHDB-1197
Thanks Dave Cottlehuber for the patch

Backport of r1166438

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1166439 13f79535-47bb-0310-9956-ffa450edef68
61ca44e
Commits on Sep 08, 2011
@davisp davisp Fix CouchJS compatibility with older SpiderMonkey.
This is a backport of the work to make CouchJS build against all of the
major versions of SpiderMonkey. Thanks to Randall Leeds and Chris
Coulson for the original patches.

Backport based on r1137464 and r1164346
Fixes COUCHDB-1078
Fixes COUCHDB-1260



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1166525 13f79535-47bb-0310-9956-ffa450edef68
7108131
@davisp davisp And the rest of the commit/
SVN != Git. Forgot to check svn status before committing.



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1166526 13f79535-47bb-0310-9956-ffa450edef68
6cf2f03
@janl janl Fix list-style send() API in show functions when using provides()
Also fix ignoring the return value when the send() API isnused.

Patch by Alexander Shorin.

Closes COUCHDB-1272

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1166625 13f79535-47bb-0310-9956-ffa450edef68
860be76
@rnewson rnewson COUCHDB-1274 - Use text/javascript content-type for jsonp responses.
Backported from trunk @1166618

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1166627 13f79535-47bb-0310-9956-ffa450edef68
9d0a0a5
Commits on Sep 12, 2011
@tilgovi tilgovi Insane libtool hackery for windows (COUCHDB-1197)
Patch by Dave Cottlehuber

Backport of r1169920

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1169921 13f79535-47bb-0310-9956-ffa450edef68
fb94d04
Commits on Sep 13, 2011
@janl janl Allow slashes in doc ids in URLs to _update handlers.
This mirrors the behaviour of the _show API.

Patch by Christopher Bonhage.

Closes COUCHDB-1229

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1170299 13f79535-47bb-0310-9956-ffa450edef68
9d93a3e
Commits on Sep 15, 2011
@janl janl remove trailing comma
git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1171170 13f79535-47bb-0310-9956-ffa450edef68
22e1994
@fdmanana fdmanana Make sure view compaction terminates
If a view group is compacting and the corresponding database
is shutdown by the LRU system, then the view compaction is
aborted because its couch view group process shutdowns.
This could lead to situations where the number of active
databases is much higher than max_dbs_open and making it
impossible to compact view groups.

Issue reported and patch tested by Mike Leddy. Thanks.

COUCHDB-1283

This is a backport of revision 1171328 from branch 1.2.x



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1171329 13f79535-47bb-0310-9956-ffa450edef68
dc5c352
Commits on Sep 22, 2011
@rnewson rnewson fix port conversion in vhost
fix port conversion, don't forget to use substr function. spotted by
@rnewson on irc, again. thanks. patch by benoitc.

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1174358 13f79535-47bb-0310-9956-ffa450edef68
8a76961
Commits on Sep 23, 2011
@kocolosk kocolosk Write header before handing over compacted group
Writing the header first ensures that the index will not be reset if
the server crashes in between the handoff and the next delayed_commit.

See COUCHDB-994

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1174979 13f79535-47bb-0310-9956-ffa450edef68
befbdfb
Commits on Sep 26, 2011
@benoitc benoitc add https support. e9cc7d0
Commits on Sep 27, 2011
Robert Newson set cluster_ssl correctly, and tidy chttps section. d73a628
Robert Newson Merge commit '34ba230324bb329ce5ed54d703dcb4d84a65ab86' c8d7b6d
@rnewson rnewson Fixes COUCHDB-1152 - Update ICU on Windows.
Thanks to Dave Cottlehuber for the patch.

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1176651 13f79535-47bb-0310-9956-ffa450edef68
b707a67
@davisp davisp Fix function evaluation by newer SpiderMonkey's.
Found this error using the Debian package for SM 1.8.5 and have since
had reports of users seeing it as well. The basic error is that some
versions of SpiderMonkey appear to dislike this call to eval:

    eval("function(){}");

The fix is simply to wrap the function source in parenthesis so that
SM is convinced that it knows how to evaluate a function.

Backport of r1176666 from trunk.



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1176667 13f79535-47bb-0310-9956-ffa450edef68
61f10e7
Commits on Sep 28, 2011
@davisp davisp Allow CommonJS modules to be an empty string.
We were making a typical JavaScript mistake testing a module for
truthiness instead of checking that it was undefined.

Fixes COUCHDB-1223
Backport of r1176677 from trunk



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1176679 13f79535-47bb-0310-9956-ffa450edef68
86f113f
@davisp davisp Rest of the fix for COUCHDB-1265
As a follow up to COUCHDB-1265 I was missing the fact that after the
insertion of a new update_seq into an internal node it is quite possible
that a compaction runs before the doc is updated again. This is
important because compaction removes information of the largest update
seq from the tree itself.

The fix is simple to include the update_seq from the #full_doc_info{}
record when calculating #doc_info.high_seq. The way to think of this
is that it's the maximum value from all known values for the update
sequence which can be defined as all values known in the tree or in the
full_doc_info record.

Backport of r1176701 from trunk



git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1176704 13f79535-47bb-0310-9956-ffa450edef68
89a5c28
Robert Newson Merge 1.1.x changes
Conflicts:
	apps/couch/include/couch_db.hrl
	apps/couch/src/couch_db.erl
	apps/couch/src/couch_os_process.erl
	apps/couch/src/couch_query_servers.erl
	apps/couch/src/couch_rep.erl
	apps/couch/src/couch_replication_manager.erl
	apps/couch/src/couch_view_compactor.erl
	apps/couch/src/couch_view_group.erl
	apps/couch/src/couch_view_updater.erl
	configure.ac
	couchjs/c_src/http.c
	couchjs/c_src/main.c
	couchjs/c_src/utf8.c
	etc/windows/couchdb.iss.tpl
	src/couchdb/priv/Makefile.am
	src/couchdb/priv/couch_js/main.c
	test/etap/160-vhosts.t
	test/etap/200-view-group-no-db-leaks.t
	test/etap/Makefile.am

BugzID: 12645
954ddf0
Robert Newson remove bad new tests. evil tests, I keel you. 24e1156
Robert Newson Merge 1.1.x because Paul Davis kept his important bug fix super secre…
…t while I was slaving away on this merge for two days.
fc0d250
Robert Newson handle bigcouch sequences in futon.browse.js 9bc5ef0
Robert Newson permit . within database names to allow shard browsing on :5986 b57aadd
Commits on Sep 29, 2011
Robert Newson restore update_group for better update_after implementation. 33b60ba
@fdmanana fdmanana Remove usage of http module from etap tests
This module is deprecated in OTP R15, which is going to
be released by the end of this year.
The etap tests now use ibrowse instead.

This is a backport of revision 1177459 from trunk.


git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1177463 13f79535-47bb-0310-9956-ffa450edef68
1285cd9
Commits on Sep 30, 2011
@fdmanana fdmanana Replicator: skip documents with empty ID
Due to a bug, older releases allowed the creation of
documents with an empty ID, which are impossible to
GET therefore making the replicator crash.
This change simply skips such documents and logs
an error message to inform users.

This is a backport of revision 1177548 from trunk.


git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1177550 13f79535-47bb-0310-9956-ffa450edef68
e14981f
Commits on Oct 01, 2011
@tilgovi tilgovi fix COUCHDB-648 - _update handler ignores "code"
Test by Christian Carter
This is a backport of r1177890

git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1177892 13f79535-47bb-0310-9956-ffa450edef68
e779492
Commits on Oct 02, 2011
@tilgovi tilgovi improve argument parsing in couchjs
This change makes argument parsing in couchjs more robust:
  * Removes the need for couchjs script
  * Adds long options
  * Makes all the options to couchjs available (fix COUCHDB-893)

Conflicts:

	bin/Makefile.am
	bin/couchjs.tpl.in
	configure.ac
a378a6a
@tilgovi tilgovi distclean couchjs.1 help2man file 76d9095
@tilgovi tilgovi fix couchjs help language and use short options f2211f2
Commits on Oct 04, 2011
@kocolosk kocolosk Merge remote branch 'apache/1.1.x' 4e19639
@kocolosk kocolosk Merge pull request #67 from cloudant/12645-merge_latest_1.1.x da7284e
Commits on Oct 05, 2011
@rnewson rnewson update CHANGES and NEWS to include a one line summary for every ticke…
…t resolved in 1.1.1
6ee2a48
@fdmanana fdmanana Update CHANGES and NEWS for the 1.1.1 release e6c0fc9
Commits on Oct 06, 2011
@rnewson rnewson Remove SpiderMonkey 1.8.5 compatibility
This commit reverts 1.8.5 compatibility including the corresponding couchjs
paren hack as this leads to significant breakage in existing functions.
5b558c8
@rnewson rnewson fix shadowing warning. 4818fdd
@rnewson rnewson Revert "Remove SpiderMonkey 1.8.5 compatibility"
This reverts commit 5b558c8.
a628a43
@rnewson rnewson Revert "Fix function evaluation by newer SpiderMonkey's."
This reverts commit 61f10e7.
da22c19
Commits on Oct 07, 2011
@kocolosk kocolosk Include twig explicitly in the release config
This fixes "Unable to generate spec" errors when trying to build a
release on Erlang/OTP R13.
6e6523d
Commits on Oct 10, 2011
Robert Newson Merge remote-tracking branch 'apache/1.1.x' cf630a2
@rnewson rnewson Backport erlang-oauth from master for R15 compat 1a11127
@rnewson rnewson Fix R15 warning for etap_web.erl 605f274
Commits on Oct 11, 2011
@davisp davisp Remove call to subprocess.check_output
This function is new in Python 2.7 and we already have a function that
returns command ouput. Just reuse runcmd to get the version.
6947cab
Commits on Oct 12, 2011
@davisp davisp Document custom HTTP/socket options in default.ini
Part of the backport of COUCHDB-1008 to chttpd. This just updates
the default.ini with some commented out options describing their
availability to users.
8a3e76c
@davisp davisp Add a remsh command to BigCouch
The remsh pattern is quite useful for connecting to running nodes for
debugging production issues. This adds a small script that lets users
connect quickly to a running node.
44ba062
@fdmanana fdmanana Remove duplicated word "the" 79fa8d7
@rnewson rnewson Update CHANGES/NEWS/acinclude.m4.in for 1.1.1 d010475
@kocolosk kocolosk Remove obsolete options, document N,Q ece26f9
@kocolosk kocolosk Merge pull request #71 from cloudant/12726-custom-http-options 82de8a4
@kocolosk kocolosk Freeze dependencies, this is 0.4.0pre1 282ed2c
Commits on Oct 13, 2011
@davisp davisp Fix badarg error in couch_server:try_close_lru/1
The race condition in couch_server's ets table usage rears its ugly head
by leaving an entry in couch_lru. This patch just addresses the issue by
allowing the client pid to use the db and ignores the fact that for the
duration its over the max_dbs_open setting.
7c04f93
@rnewson rnewson restore couch_util:verify call in oauth. 1e1d07a
@kocolosk kocolosk Merge pull request #74 from cloudant/7c04f93
Fix badarg error in couch_server:try_close_lru/1

BugzID: 12363
41e7cb7
@davisp davisp Improve remsh script
Cookies now default to using ~/.erlang.cookie which is automatically
generated if it does not exist when erlang starts with a name.

There is also no longer a need to specify a name to remsh as it'll
generate a name based on the process id and set the short or long
version appropriately.
d367c4b
@davisp davisp Merge pull request #72 from cloudant/12730-add-remsh-script
Add a remsh script for each node

BugzId: 12730
2063aca
Commits on Oct 17, 2011
Robert Newson remove scons cache in 'make clean' 1605ef5
Robert Newson remove scons cache in 'make clean' e671953
Robert Newson Build couchjs with C, not C++. Fixes libm error on CentOS. 6b26f47
Robert Newson Build couchjs with C, not C++. Fixes libm error on CentOS. e311d45
Bob Dionne Fix seq problem in full_uri by encoding
BugzID:12741
9c1d679
Robert Newson Revert "Build couchjs with C, not C++. Fixes libm error on CentOS."
This reverts commit e311d45.

Turns out the 'libm' error is a very obscure way of reporting a lack
of a c++ compiler.
04ca967
Commits on Oct 18, 2011
@kocolosk kocolosk Merge pull request #76 from cloudant/12741-replication-seq-format df394dd
@kocolosk kocolosk Merge pull request #77 from cloudant/12741-replication-seq-format c8a5018
@davisp davisp Prevent linking against too new of a SpiderMonkey
Versions of SpiderMonkey newer than js185-1.0.0 have removed the
JSOPTION_ANONFUNFIX which basically invalidates all CouchDB JavaScript
functions ever written.

This configure patch prevents the accidental linking to a library that
has this new behavior while allowing people to forcefully override the
check.
7ce9e10
@davisp davisp Minor fixes to link agianst SpiderMonkey trunk
This patch allows couchjs to link against the SpiderMonkey as it existed
in the mercurial hash 59c1e6bdb11 from [1]. This does *not* ensure
compatibility with CouchDB as there are other things that will also need
to be fixed. Specifically, the anonymous function issue for builtin JS
functions.

[1] http://hg.mozilla.org/mozilla-central/
7c6e5f0
Commits on Oct 19, 2011
@kocolosk kocolosk Revert "Build couchjs with C, not C++. Fixes libm error on CentOS."
This reverts commit 6b26f47.

Turns out the 'libm' error is a very obscure way of reporting a lack
of a C++ compiler.
5f59de1
@rnewson rnewson mention 1.8.5 support in NEWS/CHANGES e37148e
Commits on Oct 20, 2011
@rnewson rnewson Fix object sealing on sm 1.7.0 ac1f52b
@davisp davisp Fix JavaScript CLI test runner.
Accidentally inverted the logic of a test when patching for newer
versions of SpiderMonkey.
0d0ed41
@fdmanana fdmanana Update CHANGES and NEWS to reflect COUCHDB-1129 89f7faa
Robert Newson Fix object sealing with spidermonkey 1.7.0 a5d2cea
Robert Newson Fix object sealing with spidermonkey 1.7.0 75ae049
Commits on Oct 23, 2011
@davisp davisp Hardcode couchjs binary name
Windows doesn't have the libgen.h header or an easily identified
basename function. Instead of playing games we just configure the name
with autoconf and run with that.
af7a6ae
Commits on Oct 24, 2011
@davisp davisp Fix SpiderMonkey source evaluation
Looks like we had a couple commits get crossed over during the merges.
This removes the original version of the patch that wrapped JS functions
with parens.
f351ee6
Commits on Oct 25, 2011
@davisp davisp Fix SpiderMonkey source evaluation
Looks like we had a couple commits get crossed over during the merges.
This removes the original version of the patch that wrapped JS functions
with parens.
9f734e0
Commits on Oct 31, 2011
@kocolosk kocolosk Fix retrieval of headers larger than 4k
Our headers start with a <<1>> and then four bytes indicating the length
of the header and its checksum. When the header is larger than 4090
bytes it will be split across multiple blocks in the file and will need
to be reassembled on read. The reassembly consists of stripping out
<<0>> from the beginning of each subsequent block in the
remove_block_prefixes/2 function. The bug here is that we tell
remove_block_prefixes that we're starting 1 byte into the current block
instead of 5, so it ends up removing one good byte from the header and
injecting one or more random <<0>>s.

Headers larger than 4k are very rare and generally require a view group
with a huge number of indexes or indexes with fairly large reductions,
which explains why this bug has gone undetected until now.

Closes COUCHDB-1319.
a635249
@kocolosk kocolosk Fix retrieval of headers larger than 4k
Our headers start with a <<1>> and then four bytes indicating the length
of the header and its checksum. When the header is larger than 4090
bytes it will be split across multiple blocks in the file and will need
to be reassembled on read. The reassembly consists of stripping out
<<0>> from the beginning of each subsequent block in the
remove_block_prefixes/2 function. The bug here is that we tell
remove_block_prefixes that we're starting 1 byte into the current block
instead of 5, so it ends up removing one good byte from the header and
injecting one or more random <<0>>s.

Headers larger than 4k are very rare and generally require a view group
with a huge number of indexes or indexes with fairly large reductions,
which explains why this bug has gone undetected until now.

Closes COUCHDB-1319.
7c94ebb
Robert Newson Merge commit '1.1.1' into 0.4.x
Conflicts:
	acinclude.m4.in
	configure.ac
	couchjs/c_src/http.c
	src/erlang-oauth/Makefile.am
	src/erlang-oauth/oauth.app.in
	src/erlang-oauth/oauth_hmac_sha1.erl
	src/erlang-oauth/oauth_http.erl
	src/erlang-oauth/oauth_plaintext.erl
	src/etap/etap_web.erl
8bbd833
Commits on Nov 04, 2011
Robert Newson Add a script to create a source tarball 2e1054a
Commits on Nov 08, 2011
@kocolosk kocolosk Simplify README 0bda8d8
@kocolosk kocolosk Update troubleshooting link 4216ca2
@kocolosk kocolosk Simplify README e0dd9f3
Commits on Nov 09, 2011
Robert Newson Conditionally apply JSON encoding to update_seq values
BigCouch 0.3 cannot parse requests of the form /db/_changes?since="123-foo" so
the recent ?JSON_ENCODE addition to Since in two places causes 0.3 <-> 0.4
replication to fail with json_encode/badterm errors.

This patch applies JSON encoding only when the Since value is not already a
binary (i.e, when it's a [integer(), binary()]) and interop is restored.

BugzID: 12833
6ad4258
@kocolosk kocolosk Merge pull request #80 from cloudant/12833-conditional_json_encode 0b2c8fb
Robert Newson Conditionally apply JSON encoding to update_seq values
BigCouch 0.3 cannot parse requests of the form /db/_changes?since="123-foo" so
the recent ?JSON_ENCODE addition to Since in two places causes 0.3 <-> 0.4
replication to fail with json_encode/badterm errors.

This patch applies JSON encoding only when the Since value is not already a
binary (i.e, when it's a [integer(), binary()]) and interop is restored.

BugzID: 12833
223646a
@kocolosk kocolosk Bump fabric version and drop the pre1 from release version 89850ce
@davisp davisp Add check for JS script object type 3462a56
Commits on Nov 11, 2011
@davisp davisp Add check for JS script object type f2e2e77
Commits on Nov 22, 2011
Bob Dionne Remove unused imports 768324c
Commits on Dec 01, 2011
@davisp davisp Set the stack size for sub contexts
I was forgetting to pass the args through to evalcx so that it could use
the stack size specified on the command line.
5eefb4a
Commits on Dec 02, 2011
Bob Dionne whitespace 7578809
Commits on Dec 06, 2011
@davisp davisp Allow CPPPATH to be overriden in the environment 055b630
Commits on Dec 12, 2011
@davisp davisp Set the stack size for sub contexts
I was forgetting to pass the args through to evalcx so that it could use
the stack size specified on the command line.
83a451f
@davisp davisp Allow CPPPATH to be overriden in the environment 0bdc62b
Commits on Dec 23, 2011
@davisp davisp Make cURL a soft dependency
This makes sure that we only optionally require the same version of cURL
that CouchDB does.
6cec3db
@davisp davisp Make cURL a soft dependency
This makes sure that we only optionally require the same version of cURL
that CouchDB does.
11b4484
Commits on Jan 10, 2012
@kocolosk kocolosk Bump fabric and chttpd versions
The fabric bump fixes some corner cases for read repair.  The chttpd
bump improves error handling for delayed responses.
631ab54
@kocolosk kocolosk Remove unused URLs 91c25cf
@kocolosk kocolosk Remove superfluous formatting 121c71c
Commits on Jan 16, 2012
Robert Newson Use spawn_monitor to await process completion
BugzID: 13133
effae95
Robert Newson Only set the process dictionary if exit was ok 5a7a1a5
Commits on Jan 17, 2012
@rnewson rnewson Merge pull request #91 from cloudant/13133-attachment-replication
Fix attachment replication

BugzID: 13133
42334fa
Robert Newson Bump to chttpd 1.4.2 b5c6252
Commits on Jan 18, 2012
Robert Newson Revert use of spawn_monitor
As Filipe correctly points out, we want the parent to die if the child dies.
855bb7d
Commits on Jan 21, 2012
Robert Newson Bump dependencies for pre7 release 050b8c9
Commits on Jan 24, 2012
@davisp davisp Minor bug getting the reduce_limit setting 6696d6f
@davisp davisp Minor bug getting the reduce_limit setting b8cbeed
Commits on Jan 27, 2012
Bob Dionne Whitespace f5913f7
Commits on Jan 31, 2012
@davisp davisp Fix bug in replicator request piplining
A replication with both an HTTP source and target on the same host and
port could end up in a dead lock due to ibrowse replication pipelining
when attachments are present on the source. The ibrowse http worker
would end up forming a multipart/mime body using anonymous reader
functions for attachment stubs. When the attachment stub functions are
executed it is possible that they end up assigned to the same ibrowse
worker.

This is a bit of a long path but then end result is equivalent to
calling gen_server:call(self(), Args, infinity) from a gen_server
callback.

A quick work around for users is to set up a DNA alias (possibly in
/etc/hosts) or to use a combination of hostname and ip address so that
ibrowse assigns the requests to different pools.
f199c33
Robert Newson Fix previous commit db23528
Commits on Feb 22, 2012
Robert Newson Merge 0.4.x 986c86b
Commits on Mar 16, 2012
Robert Newson Enable Travis builds b8e61ed
Commits on Mar 20, 2012
@kocolosk kocolosk Invoke couch_view_updater with the proper arguments
This fixes stale=update_after.
91ce15d
Commits on Apr 24, 2012
Bob Dionne Whitespace 9492fa3
Commits on Apr 25, 2012
@Xylakant Xylakant Fix Build for Gentoo
Modify SConscript so that it recognizes the standard name for the
mozjs/spidermonkey lib on gentoo.
0516fad
@kocolosk kocolosk Merge pull request #105 from Asquera/fixes/gentoo-build
Allow building on Gentoo
561a93b
Commits on Jun 17, 2012
@kocolosk kocolosk Bump rebar to version 2.0.0 09f0be1
@kocolosk kocolosk Update lots of dependencies 0436a17
@kocolosk kocolosk Fix deprecation warnings for port_compiler 32233a7
@kocolosk kocolosk Fix URL for twig a15c8ef
Commits on Jun 18, 2012
Robert Newson Revert "allow replication callback module to be chosen at runtime."
This reverts commit faf9071.
0ad1f99
@kocolosk kocolosk Add a dummy replicate/3 for now
Conflicts:
	apps/couch/src/couch_rep.erl
0250151
Robert Newson Fix _replicator db 95732bf
Commits on Jun 19, 2012
Robert Newson Don't perform callbacks to couch_replicator 3d53b19
Robert Newson Bump couch_replicator to 0.1.2 4e4e606
Commits on Aug 02, 2012
Robert Newson Add _replication_stats e70411d
Commits on Aug 08, 2012
Robert Newson Bump dependencies 90dcfeb
Commits on Aug 09, 2012
Robert Newson Don't always require exactly N replies for an mp attachment PUT
It's not safe to assume we require, or will receive, exactly N replies
(where N is read from the "n" key of the "cluster" section of the
configuaration). This needs proper fabric-ification.

This commit will at least allow replication tests with clusters of
less than N nodes where the documents have attachments (which triggers
the multipart code).

BugzID: 14258
1cea79d
Commits on Sep 18, 2012
Robert Newson Bump dependencies ce2fc13
Commits on Oct 03, 2012
wohali Support multiarch library paths on Linux. 3d1812d
Commits on Oct 23, 2012
@tilgovi tilgovi don't delete view groups that fail to open
...but log a message instead. Fixes COUCHDB-1445.
b5e2063
Commits on Nov 14, 2012
Robert Newson Bump dependencies dfddfeb
Robert Newson Support jsonp in externals.
Allow ?callback= for any external that returns json (i.e,
uses "json":{} instead of "data":"data".

BugzID: 12748
d9ad14b
@kocolosk kocolosk Fix spurious declarations of new merge conflicts
This patch also adds extra tests of the key tree merging logic as well
as edoc-formatted documentation for the module and a few of the merge
functions.  Closes COUCHDB-902.

Thanks Paul Davis, Bob Dionne, Klaus Trainer.

git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@1065471 13f79535-47bb-0310-9956-ffa450edef68
574be32
@kocolosk kocolosk Skip ddoc pull, use middleman for validation reset
We were pulling a list of design documents and then ignoring the result
when the #db was a partition of a clustered database.  Also, the call to
fabric:reset_validation_funs/1 can occasionally cause a stray rexi_EXIT
message to arrive in the db_updater mailbox (and subsequently kill the
server) if a worker fails.  I don't think that's desired behavior,
though it's a debatable point.  This patch spawns a middleman process to
act as a sink for those stray messages.

BugzID: 13087
dc15027
Bob Dionne Expose latest=true option in calls to retrieve revisions
When a call is made to retrieve a specific revision, latest=true will
retrieve any descendent leaves instead. This enables the replicator to
better keep up with edits that occur whilst it's retrieving revisions

BugzID: 14241
7967c2f
@kocolosk kocolosk Add an index keyed on LRU for faster candidate ID
Our current implementation for closing an LRU DB involves a full scan
of a public ets table.  This scan blocks all other activity in
couch_server and can become a serious bottleneck when the LRU cache hit
rate drops too low.  In the worst-case all_dbs_active scenario we end up
with O(N**2) algorithmic complexity.

This patch adds a new index keyed on LRU for faster access to the least
recently used databases.  It also moves the ets table to a dict on the
couch_server heap.  The downside is an increased message rate inbound on
the couch_server, as clients are no longer allowed to update the LRU
data structures without sending a message.

BugzID: 12879

Conflicts:
	apps/couch/src/couch_server.erl
7bd0718
@kocolosk kocolosk Fork new OS processes outside proc_manager loop 90c656f
@davisp davisp Allow processes to idle before exiting
When system load exceeds the ability of os_process_soft_limit to keep
up with demand we enter a fork-use-kill (FUK) cycle. The constant
spawning and destruction os these processes thrashes system resources
and causes general instability.

This patch changes the behavior from killing each process as its
returned to letting it idle for a configurable amount of time (default
five minutes) which allows it to be reused by other clients. This way we
can avoid adding unnecessary load when demand for couchjs processes
exceeds os_process_soft_limit.

As a happy benefit this should also allow os_process_soft_limit to be
set much lower since the number of processes will now more closely
follow actual demand (instead of provisioning for the worst case
scenario).

Conflicts:

	apps/couch/src/couch_os_process.erl
	apps/couch/src/couch_proc_manager.erl

Conflicts:
	apps/couch/src/couch_os_process.erl
b9f0271
@kocolosk kocolosk Trigger a GC when OS process is returned e9440ae
@kocolosk kocolosk Mark proc as unused in ret_proc
Otherwise we'll never reuse it
017ba1c
@davisp davisp Avoid scanning the entire table of procs
For large numbers of os processes its possible that we have a slowdown
when requesting a new process. The old code matches all possible
processes out of the table to find an appropriate candidate.

We avoid the issue by using ets:select_reverse to also prefer keeping
newer processes and releasing longer lived processes. Length of life is
based on the implicit sorting of pids having newer pids sorting larger.
c15440c
@davisp davisp Use a match_spec() instead of a match_pattern()
I misread the docs on what was expected for ets:select_receive/3.
a15205d
@davisp davisp Two last bugs in couch_proc_manager
* Design doc languages are converted to lists
* Make sure to monitor every client correctly
a15c94a
@davisp davisp Remove the client ref when it dies
We have observed periods of couchjs processes spiking into the hundreds
and thousands for short periods of time since the new couch_proc_manager
was released. Today I happened to catch one in the act and poked at
couch_proc_manager's ets table. There seemed to be a few more couchjs
processes with clients than I would have expected so I skimmed the code
looking for a place where we didn't clear the client value (which would
prevent it from being reused so that it would eventually just timeout).

I found a case where if the Pid that checked out the process dies
without the OS process dying, we were forgetting to clear the client in
the ets table. This patch refactors the two places we return processes
into a single function call which clears the OS process client.
fa43486
@davisp davisp Only close idle processes that have no client
Previously we didn't check if an os_process was in use by a process
before closing it. This ended up generating noproc errors in the
couch_view_updaters which would then spider out to the couch_view_group
processes causing client errors and resetting compaction.

BugzId: 13798
5eb7447
@kocolosk kocolosk Allow 202 as a valid status code
BugzID: 13940
f7adbbe
@kocolosk kocolosk Don't touch the old couch_lru ets table
It doesn't exist.

BugzID: 13299
bf4d46b
Commits on Nov 15, 2012
Robert Newson Backport new /_active_tasks API
Improved _active_tasks API

Tasks are now free to set any properties they wish (as an
Erlang proplist). Different tasks can have different properties
and the status string doesn't exist anymore - instead client
applications can build it using more granular properties from
_active_tasks. Some of these properties are:

1) "progress" (an integer percentage, for all tasks)
2) "database" (for compactions and indexer tasks)
3) "design_document" (for indexer and view compaction tasks)
4) "source" and "target" (for replications)
5) "docs_read", "docs_written", "doc_write_failures",
   "missing_revs_found", "missing_revs_checked", "source_seq",
   "checkpointed_source_seq" and "continuous" for replications

BugzID: 14269

Conflicts:
	apps/couch/src/couch_db_updater.erl
	apps/couch/src/couch_rep.erl
	apps/couch/src/couch_task_status.erl
	apps/couch/src/couch_view_compactor.erl
	apps/couch/src/couch_view_updater.erl
19017b3
Robert Newson Fix design_document inconsistency
Always report it as "design_document":"_design/foo"

BugzID: 14562

Conflicts:
	apps/couch/src/couch_view_compactor.erl
cde32e6
Robert Newson Add total_changes to view compaction status
Conflicts:
	apps/couch/src/couch_view_compactor.erl
478e957
@kocolosk kocolosk Use twig for logging
Conflicts:
	apps/couch/include/couch_db.hrl
	apps/couch/src/couch_server_sup.erl
	rebar.config
	rel/reltool.config
b878b52
@kocolosk kocolosk Suppress duplicate access logs b2bf557
Robert Newson Fix travis build? 0c4e0ec
Robert Newson disable cover bbf0032
Bob Dionne Add twig to path for etap tests
Required to run 030-doc-from-json.t

BugzID: 14419

Conflicts:
	Makefile
be218b3
Robert Newson use chttpd/master during development 7af6efe
wohali Update couchjs for static build option, eliminate eval() 3c4555f
wohali remove dreyfus 2303dde
Commits on Dec 07, 2012
Robert Newson quick fix for badmatch f629dca
Commits on Jan 23, 2013
Robert Newson Pin chttpd to 1.4.5 badefe2
Commits on Jan 31, 2013
Robert Newson Bump chttpd to 1.4.6 793b4c8
Robert Newson Bump mem3 to 3.2.2 73f530a