Table of Contents

Constructor MongoDatabaseCreationOptions

Namespace
MongoDB.EntityFrameworkCore.Metadata
Assembly
MongoDB.EntityFrameworkCore.dll

MongoDatabaseCreationOptions(bool, bool, bool, bool, TimeSpan?, CreateCollectionOptions?, bool, bool)

public MongoDatabaseCreationOptions(bool CreateMissingCollections = true, bool CreateMissingIndexes = true, bool CreateMissingVectorIndexes = true, bool WaitForVectorIndexes = true, TimeSpan? IndexCreationTimeout = null, CreateCollectionOptions? CreateCollectionOptions = null, bool CreateMissingSearchIndexes = true, bool WaitForSearchIndexes = true)

Parameters

CreateMissingCollections bool

Creates any MongoDB database collections that do not already exist. The default is true.

CreateMissingIndexes bool

Creates any non-search and non-vector search MongoDB indexes that do not already exist. The default is true.

CreateMissingVectorIndexes bool

Creates any MongoDB vector indexes that do not already exist. The default is true.

WaitForVectorIndexes bool

Waits for all MongoDB vector indexes to be 'READY' before continuing. The default is true.

IndexCreationTimeout TimeSpan?

The minimum amount of time to wait for all indexes to be 'READY' before aborting. The default is 60 seconds. Zero seconds means no timeout.

CreateCollectionOptions CreateCollectionOptions

The options to use when creating the MongoDB database collections. The default is null.

CreateMissingSearchIndexes bool

Creates any MongoDB search indexes that do not already exist. The default is true.

WaitForSearchIndexes bool

Waits for all MongoDB search indexes to be 'READY' before continuing. The default is true.

MongoDatabaseCreationOptions()

Creates a MongoDatabaseCreationOptions with default values for all options.

public MongoDatabaseCreationOptions()