couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j..@apache.org
Subject [1/2] git commit: COUCHDB-1667: Revert index_dir to view_index_dir config option.
Date Wed, 06 Feb 2013 20:46:45 GMT
COUCHDB-1667: Revert index_dir to view_index_dir config option.

Patch by Alexander Shorin.


Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/b267a290
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/b267a290
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/b267a290

Branch: refs/heads/master
Commit: b267a29011c02712860dd69bd0b680e93739935b
Parents: 3fab6bb
Author: Jan Lehnardt <jan@apache.org>
Authored: Wed Feb 6 21:45:48 2013 +0100
Committer: Jan Lehnardt <jan@apache.org>
Committed: Wed Feb 6 21:45:48 2013 +0100

----------------------------------------------------------------------
 etc/couchdb/default.ini.tpl.in             |    2 +-
 src/couch_index/src/couch_index_server.erl |    7 -------
 src/couch_index/src/couch_index_util.erl   |    5 +----
 test/etap/072-cleanup.t                    |    2 +-
 4 files changed, 3 insertions(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb/blob/b267a290/etc/couchdb/default.ini.tpl.in
----------------------------------------------------------------------
diff --git a/etc/couchdb/default.ini.tpl.in b/etc/couchdb/default.ini.tpl.in
index be92fcf..94bf2fe 100644
--- a/etc/couchdb/default.ini.tpl.in
+++ b/etc/couchdb/default.ini.tpl.in
@@ -7,7 +7,7 @@ version = %version%
 
 [couchdb]
 database_dir = %localstatelibdir%
-index_dir = %localstatelibdir%
+view_index_dir = %localstatelibdir%
 util_driver_dir = %couchprivlibdir%
 max_document_size = 4294967296 ; 4 GB
 os_process_timeout = 5000 ; 5 seconds. for view and external servers.

http://git-wip-us.apache.org/repos/asf/couchdb/blob/b267a290/src/couch_index/src/couch_index_server.erl
----------------------------------------------------------------------
diff --git a/src/couch_index/src/couch_index_server.erl b/src/couch_index/src/couch_index_server.erl
index bc1fce7..8e2baf6 100644
--- a/src/couch_index/src/couch_index_server.erl
+++ b/src/couch_index/src/couch_index_server.erl
@@ -75,13 +75,6 @@ init([]) ->
     ets:new(?BY_DB, [protected, bag, named_table]),
     couch_db_update_notifier:start_link(fun ?MODULE:update_notify/1),
     RootDir = couch_index_util:root_dir(),
-    % Deprecation warning if it wasn't index_dir
-    case couch_config:get("couchdb", "index_dir") of
-        undefined ->
-            Msg = "Deprecation warning: 'view_index_dir' is now 'index_dir'",
-            ?LOG_ERROR(Msg, []);
-        _ -> ok
-    end,
     couch_file:init_delete_dir(RootDir),
     {ok, #st{root_dir=RootDir}}.
 

http://git-wip-us.apache.org/repos/asf/couchdb/blob/b267a290/src/couch_index/src/couch_index_util.erl
----------------------------------------------------------------------
diff --git a/src/couch_index/src/couch_index_util.erl b/src/couch_index/src/couch_index_util.erl
index 28ec8d2..0b833d3 100644
--- a/src/couch_index/src/couch_index_util.erl
+++ b/src/couch_index/src/couch_index_util.erl
@@ -19,10 +19,7 @@
 
 
 root_dir() ->
-    case couch_config:get("couchdb", "index_dir") of
-        undefined -> couch_config:get("couchdb", "view_index_dir");
-        Value -> Value
-    end.
+  couch_config:get("couchdb", "view_index_dir").
 
 
 index_dir(Module, DbName) when is_binary(DbName) ->

http://git-wip-us.apache.org/repos/asf/couchdb/blob/b267a290/test/etap/072-cleanup.t
----------------------------------------------------------------------
diff --git a/test/etap/072-cleanup.t b/test/etap/072-cleanup.t
index 6721090..9cbcdfa 100755
--- a/test/etap/072-cleanup.t
+++ b/test/etap/072-cleanup.t
@@ -121,6 +121,6 @@ view_cleanup() ->
 
 count_index_files() ->
     % call server to fetch the index files
-    RootDir = couch_config:get("couchdb", "index_dir"),
+    RootDir = couch_config:get("couchdb", "view_index_dir"),
     length(filelib:wildcard(RootDir ++ "/." ++
         binary_to_list(?TEST_DB) ++ "_design"++"/mrview/*")).


Mime
View raw message