class TimestampParser
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.KinesisFirehose.TimestampParser |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awskinesisfirehose#TimestampParser |
Java | software.amazon.awscdk.services.kinesisfirehose.TimestampParser |
Python | aws_cdk.aws_kinesisfirehose.TimestampParser |
TypeScript (source) | aws-cdk-lib » aws_kinesisfirehose » TimestampParser |
Value class that wraps a Joda Time format string.
Use this with the Hive JSON input format for data record format conversion to parse custom timestamp formats.
Example
const inputFormat = new firehose.HiveJsonInputFormat({
timestampParsers: [
firehose.TimestampParser.fromFormatString('yyyy-MM-dd'),
firehose.TimestampParser.EPOCH_MILLIS,
]
})
Properties
| Name | Type | Description |
|---|---|---|
| format | string | The format string to use in Hive JSON input format configuration. |
| static EPOCH_MILLIS | Timestamp | Parses timestamps formatted in milliseconds since epoch. |
format
Type:
string
The format string to use in Hive JSON input format configuration.
static EPOCH_MILLIS
Type:
Timestamp
Parses timestamps formatted in milliseconds since epoch.
Methods
| Name | Description |
|---|---|
| static from | Creates a TimestampParser from the given format string. |
static fromFormatString(format)
public static fromFormatString(format: string): TimestampParser
Parameters
- format
string— the Joda Time format string.
Returns
Creates a TimestampParser from the given format string.
The format string should be a valid Joda Time pattern string. See Class DateTimeFormat for more details

.NET
Go
Java
Python
TypeScript (