diff options
author | Aaron <aaron@10gen.com> | 2009-04-20 13:51:54 -0400 |
---|---|---|
committer | Aaron <aaron@10gen.com> | 2009-04-20 13:51:54 -0400 |
commit | 80847b561c5851fa763866af06bb021af893f31a (patch) | |
tree | 4b6c080eae2f6ab024ab1d4cbe61d19245746f57 /dbtests/perf | |
parent | c34ef0f68d7f0dd493bdd2e50798f2c0211a71a7 (diff) | |
download | mongo-80847b561c5851fa763866af06bb021af893f31a.tar.gz |
add unique option when creating index in c++, js drivers; basic unique key unit tests
Diffstat (limited to 'dbtests/perf')
-rw-r--r-- | dbtests/perf/perftest.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/dbtests/perf/perftest.cpp b/dbtests/perf/perftest.cpp index e995a9347e8..3d383796277 100644 --- a/dbtests/perf/perftest.cpp +++ b/dbtests/perf/perftest.cpp @@ -111,7 +111,7 @@ namespace Insert { const char *names = "aaaaaaaaaa"; for( int i = 0; i < 10; ++i ) { client_->resetIndexCache(); - client_->ensureIndex( ns_.c_str(), BSON( "_id" << 1 ), names + i ); + client_->ensureIndex( ns_.c_str(), BSON( "_id" << 1 ), false, names + i ); } } void run() { @@ -612,7 +612,7 @@ namespace Plan { const char *names = "aaaaaaaaaa"; for( int i = 0; i < 10; ++i ) { client_->resetIndexCache(); - client_->ensureIndex( ns_.c_str(), BSON( ( names + i ) << 1 ), names + i ); + client_->ensureIndex( ns_.c_str(), BSON( ( names + i ) << 1 ), false, names + i ); } lk_.reset( new dblock ); setClient( ns_.c_str() ); @@ -635,7 +635,7 @@ namespace Plan { const char *names = "aaaaaaaaaa"; for( int i = 0; i < 10; ++i ) { client_->resetIndexCache(); - client_->ensureIndex( ns_.c_str(), BSON( ( names + i ) << 1 ), names + i ); + client_->ensureIndex( ns_.c_str(), BSON( ( names + i ) << 1 ), false, names + i ); } lk_.reset( new dblock ); setClient( ns_.c_str() ); @@ -654,7 +654,7 @@ namespace Plan { const char *names = "aaaaaaaaaa"; for( int i = 0; i < 10; ++i ) { client_->resetIndexCache(); - client_->ensureIndex( ns_.c_str(), BSON( ( names + i ) << 1 ), names + i ); + client_->ensureIndex( ns_.c_str(), BSON( ( names + i ) << 1 ), false, names + i ); } lk_.reset( new dblock ); setClient( ns_.c_str() ); |