You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by jc...@apache.org on 2009/03/06 19:20:10 UTC
svn commit: r751020 - in /couchdb/trunk: etc/couchdb/default.ini.tpl.in
src/couchdb/couch_os_process.erl
Author: jchris
Date: Fri Mar 6 18:20:09 2009
New Revision: 751020
URL: http://svn.apache.org/viewvc?rev=751020&view=rev
Log:
configure view and external server timeout in using ini variables.
closes COUCHDB-246
Modified:
couchdb/trunk/etc/couchdb/default.ini.tpl.in
couchdb/trunk/src/couchdb/couch_os_process.erl
Modified: couchdb/trunk/etc/couchdb/default.ini.tpl.in
URL: http://svn.apache.org/viewvc/couchdb/trunk/etc/couchdb/default.ini.tpl.in?rev=751020&r1=751019&r2=751020&view=diff
==============================================================================
--- couchdb/trunk/etc/couchdb/default.ini.tpl.in (original)
+++ couchdb/trunk/etc/couchdb/default.ini.tpl.in Fri Mar 6 18:20:09 2009
@@ -8,7 +8,7 @@
util_driver_dir = %couchprivlibdir%
max_document_size = 4294967296 ; 4 GB
max_attachment_chunk_size = 4294967296 ; 4GB
-view_timeout = 5000 ; 5 seconds
+os_process_timeout = 5000 ; 5 seconds. for view and external servers.
max_dbs_open = 100
[httpd]
Modified: couchdb/trunk/src/couchdb/couch_os_process.erl
URL: http://svn.apache.org/viewvc/couchdb/trunk/src/couchdb/couch_os_process.erl?rev=751020&r1=751019&r2=751020&view=diff
==============================================================================
--- couchdb/trunk/src/couchdb/couch_os_process.erl (original)
+++ couchdb/trunk/src/couchdb/couch_os_process.erl Fri Mar 6 18:20:09 2009
@@ -99,12 +99,14 @@
% gen_server API
init([Command, Options, PortOptions]) ->
+ BaseTimeOut = list_to_integer(couch_config:get(
+ "couchdb", "os_process_timeout", "5000")),
BaseProc = #os_proc{
command=Command,
port=open_port({spawn, Command}, PortOptions),
writer=fun writejson/2,
reader=fun readjson/1,
- timeout=5000
+ timeout=BaseTimeOut
},
OsProc =
lists:foldl(fun(Opt, Proc) ->