From fec06cfe915a53e5e53cd2b8e114c99814fbe436 Mon Sep 17 00:00:00 2001 From: Kristina Date: Mon, 19 Sep 2011 13:29:37 -0400 Subject: upgrade indexes on resync SERVER-3900 --- db/cloner.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/db/cloner.cpp b/db/cloner.cpp index 8956133daa3..f13ea528c05 100644 --- a/db/cloner.cpp +++ b/db/cloner.cpp @@ -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(), '.'); -- cgit v1.2.1