From f6fd760c17cb5d5d49211be4b4ff92e797e83157 Mon Sep 17 00:00:00 2001 From: John Christopher Anderson Date: Sat, 4 Jul 2009 15:47:47 +0000 Subject: Name view index files by their function hashes for no downtime deploys. Closes COUCHDB-218 Adds ability to switch view indexes on the fly by building the index from a "staging" design doc, and then COPYing the staging doc to the production doc's id. Since indexes are referenced by view definition, the new version of the production design doc will point immediately to the index files already built in staging. Please use and give feedback. git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@791140 13f79535-47bb-0310-9956-ffa450edef68 --- src/couchdb/couch_view_updater.erl | 20 -------------------- 1 file changed, 20 deletions(-) (limited to 'src/couchdb/couch_view_updater.erl') diff --git a/src/couchdb/couch_view_updater.erl b/src/couchdb/couch_view_updater.erl index 3c4c9108..11dfb544 100644 --- a/src/couchdb/couch_view_updater.erl +++ b/src/couchdb/couch_view_updater.erl @@ -106,26 +106,6 @@ process_doc(Db, DocInfo, {Docs, #group{sig=Sig,name=GroupId,design_options=Desig [conflicts, deleted_conflicts] end, case {IncludeDesign, DocId} of - {_, GroupId} -> - % uh oh. this is the design doc with our definitions. See if - % anything in the definition changed. - case couch_db:open_doc_int(Db, DocInfo, DocOpts) of - {ok, Doc} -> - case couch_view_group:design_doc_to_view_group(Doc) of - #group{sig=Sig} -> - % The same md5 signature, keep on computing - case IncludeDesign of - true -> - {[Doc | Docs], Group, ViewKVs, DocIdViewIdKeys}; - _ -> - {Docs, Group, ViewKVs, DocIdViewIdKeys} - end; - _ -> - exit(reset) - end; - {not_found, missing} -> - exit(reset) - end; {false, <>} -> % we skip design docs {Docs, Group, ViewKVs, DocIdViewIdKeys}; _ -> -- cgit v1.2.3