[ 
https://issues.apache.org/jira/browse/COUCHDB-1654?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13563783#comment-13563783
 ] 

Benoit Chesneau commented on COUCHDB-1654:
------------------------------------------

Just read the code and it seems that the index file signature is now based on 
the indexer module name:

snippet from couch_index_util (l28):

    index_dir(Module, DbName) when is_binary(DbName) ->
        DbDir = "." ++ binary_to_list(DbName) ++ "_design",
        filename:join([root_dir(), DbDir, Module]);
    index_dir(Module, #db{}=Db) ->
        index_dir(Module, couch_db:name(Db)).


    index_file(Module, DbName, FileName) ->
        filename:join(index_dir(Module, DbName), FileName).

Also the path is now based on the module name. So we have two things:

1. signature chane
2. old index file can't be found since the path changed.

Not sure what is the best way to solve that.... For example how do we manage 
other  index if we don't change the path accordingly?


                
> couchdb view sig changed
> ------------------------
>
>                 Key: COUCHDB-1654
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-1654
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Database Core
>            Reporter: Robert Newson
>            Priority: Blocker
>             Fix For: 1.3
>
>
> view sigs and location changed between 1.2.x and 1.3.x, which would cause 
> full rebuilds.
> to be clear: upgrading to 1.3 should not cause a view to rebuild from scratch.
> ➜  couchdb git:(1.3.x) find tmp
> tmp
> tmp/lib
> tmp/lib/.db1_design
> tmp/lib/.db1_design/0761939631be54bf36d3ed9172bcf689.view
> tmp/lib/.delete
> tmp/lib/_replicator.couch
> tmp/lib/_users.couch
> tmp/lib/db1.couch
> tmp/log
> tmp/log/couch.log
> tmp/run
> tmp/run/couch.uri
> tmp/run/couchdb
> ➜  couchdb git:(1.3.x) find tmp
> tmp
> tmp/lib
> tmp/lib/.db1_design
> tmp/lib/.db1_design/0761939631be54bf36d3ed9172bcf689.view
> tmp/lib/.db1_design/mrview
> tmp/lib/.db1_design/mrview/641ce136c0f1dbe93aa94d3a419a0efe.view
> tmp/lib/.delete
> tmp/lib/_replicator.couch
> tmp/lib/_users.couch
> tmp/lib/db1.couch
> tmp/log
> tmp/log/couch.log
> tmp/run
> tmp/run/couch.uri
> tmp/run/couchdb

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to