Constructors MethodsOptional
afterUpSuccess afterUpSuccess () : unknown Returns unknown createCollection createCollection ( collectionName : string ) : void Returns void createCollections createCollections ( collectionNames : string [] ) : void Parameters collectionNames : string [] Returns void createIndex createIndex ( collectionName : string , index : IndexSpecification , options ?: Omit < CreateIndexesOptions , "session" > , ) : void Parameters collectionName : string index : IndexSpecification Optional
options : Omit < CreateIndexesOptions , "session" > Returns void defer defer ( callback : ( db : Db , client : ClientSession ) => Promise < void > ) : void Parameters callback : ( db : Db , client : ClientSession ) => Promise < void > Returns void dropCollection dropCollection ( collectionName : string ) : void Returns void dropIndex dropIndex ( collectionName : string , indexName : string , options ?: Omit < CommandOperationOptions , "session" > , ) : void Parameters collectionName : string indexName : string Optional
options : Omit < CommandOperationOptions , "session" > Returns void execUp execUp ( session : ClientSession ) : Promise < void > Returns Promise < void >
M M N E P V F C I C P M F P C P T T A A A T R
Drop a collection. This operation will be done last in the migration. It cannot be run in a transaction, so we recommend doing it in a separate migration file.