Constructor TimeSeriesOptions

| MongoDB CSharp Driver API Reference (original) (raw)

Namespace

MongoDB.Driver

Assembly

MongoDB.Driver.dll

TimeSeriesOptions(string, Optional, Optional<TimeSeriesGranularity?>, Optional<int?>, Optional<int?>)

public TimeSeriesOptions(string timeField, Optional<string> metaField = default, Optional<TimeSeriesGranularity?> granularity = default, Optional<int?> bucketMaxSpanSeconds = default, Optional<int?> bucketRoundingSeconds = default)

Parameters

timeField string

The name of the top-level field to be used for time.

metaField Optional<string>

The name of the top-level field describing the series upon which related data will be grouped.

granularity Optional<TimeSeriesGranularity?>

The TimeSeriesGranularity for the time series. Do not set if using bucketMaxSpanSeconds

bucketMaxSpanSeconds Optional<int?>

The maximum time between timestamps in the same bucket.

bucketRoundingSeconds Optional<int?>

The interval used to round down the first timestamp when opening a new bucket.