Skip to content

Commit

Permalink
upgrade indexes on resync SERVER-3900
Browse files Browse the repository at this point in the history
  • Loading branch information
kchodorow authored and erh committed Sep 30, 2011
1 parent 47360db commit fec06cf
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions db/cloner.cpp
Expand Up @@ -83,6 +83,12 @@ namespace mongo {
BSONElement e = i.next();
if ( e.eoo() )
break;

// for now, skip the "v" field so that v:0 indexes will be upgraded to v:1
if ( string("v") == e.fieldName() ) {
continue;
}

if ( string("ns") == e.fieldName() ) {
uassert( 10024 , "bad ns field for index during dbcopy", e.type() == String);
const char *p = strchr(e.valuestr(), '.');
Expand Down

0 comments on commit fec06cf

Please sign in to comment.