Docs Menu
Docs Home
/
MongoDB Kafka Connector
/ /

Kafka Time Series 속성

이 페이지의 내용

  • 개요
  • 설정

다음 구성 설정을 사용하여 MongoDB Kafka connector가 데이터를 MongoDB time-series collection에 싱크하는 방법을 지정합니다.

카테고리별로 정리된 싱크 connector 구성 설정 목록은 싱크 Connector 구성 속성가이드 를 참조하세요.

이름
설명
timeseries.timefield
Type: string

Description:
The name of the top-level field in the source data that contains time information that you want to associate with the new document in the time series collection.

Default: ""
Accepted Values: An empty string or the name of a field that contains a BSON DateTime value
timeseries.timefield.auto.convert.date.format
Type: string

Description:
The date format pattern the connector should use to convert the source data contained in the field specified by the timeseries.timefield setting.

The connector passes the date format pattern to the Java DateTimeFormatter.ofPattern(pattern, locale) method to perform date and time conversions on the time field.

If the date value from the source data only contains date information, the connector sets the time information to the start of the specified day. If the date value does not contain the timezone offset, the connector sets the offset to UTC.

Default:
yyyy-MM-dd[['T'][ ]][HH:mm:ss[[.][SSSSSS][SSS]][ ]VV[ ]'['VV']'][HH:mm:ss[[.][SSSSSS][SSS]][ ]X][HH:mm:ss[[.][SSSSSS][SSS]]]
Accepted Values: A valid DateTimeFormatter format
timeseries.timefield.auto.convert
Type: boolean

Description:
Whether to convert the data in the field into the BSON Date format.

When set to true, the connector uses the milliseconds after epoch and discards fractional parts if the value is a number. If the value is a string, the connector uses the setting in the following configuration to parse the date:
timeseries.timefield.auto.convert.date.format
If the connector fails to convert the value, it sends the original value to the time series collection.

Default: false
Accepted Values: true or false
timeseries.timefield.auto.convert.locale.language.tag
Type: string

Description:
Which DateTimeFormatter locale language tag to use with the date format pattern (e.g. "en-US").

To learn more about locales, see the Java SE documentation of Locale.

Default: ROOT
Accepted Values: A valid Locale language tag format
timeseries.metafield
Type: string

Description:
Which top-level field to read from the source data to describe a group of related time series documents.

IMPORTANT: This field must not be the _id field nor the field you specified in the timeseries.timefield setting.

Default: ""
Accepted Values: An empty string or the name of a field that contains any BSON type except BsonArray.
timeseries.expire.after.seconds
Type: int

Description:
The number of seconds MongoDB should wait before automatically removing the time series collection data. The connector disables timed expiry when the setting value is less than 1.

To learn more, see Set up Automatic Removal for Time Series Collections in the MongoDB manual.

Default: 0
Accepted Values: An integer
timeseries.granularity
Type: string

Description:
The expected interval between subsequent measurements of your source data.

To learn more, see Set Granularity for Time Series Data in the MongoDB manual.

Optional
Default: ""
Accepted Values: "", "seconds", "minutes", "hours"

기존 컬렉션을 Time Series 컬렉션으로 변환하는 방법에 대한 예 는 기존 컬렉션을 Time Series 컬렉션으로 마이그레이션하는 방법에 대한 튜토리얼을 참조하세요.

돌아가기

데이터 캡처 속성 변경

이 페이지의 내용