Documentation ¶
Index ¶
- func ConvertEventsRecords(records []events.KinesisEventRecord) []*kinesis.Record
- func New(cfg iaws.Config) *kinesis.Kinesis
- type API
- func (a *API) ActiveShards(ctx aws.Context, stream string) (int64, error)
- func (a *API) GetTags(ctx aws.Context, stream string) ([]*kinesis.Tag, error)
- func (a *API) IsEnabled() bool
- func (a *API) PutRecord(ctx aws.Context, stream, partitionKey string, data []byte) (*kinesis.PutRecordOutput, error)
- func (a *API) PutRecords(ctx aws.Context, stream, partitionKey string, data [][]byte) (*kinesis.PutRecordsOutput, error)
- func (a *API) Setup(cfg iaws.Config)
- func (a *API) UpdateShards(ctx aws.Context, stream string, shards int64) error
- type Aggregate
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConvertEventsRecords ¶
func ConvertEventsRecords(records []events.KinesisEventRecord) []*kinesis.Record
ConvertEventsRecords converts Kinesis records between the Lambda and Go SDK packages. This is required for deaggregating Kinesis records processed by AWS Lambda.
Types ¶
type API ¶
type API struct {
Client kinesisiface.KinesisAPI
}
API wraps the Kinesis API interface.
func (*API) ActiveShards ¶
ActiveShards returns the number of in-use shards for a Kinesis stream.
func (*API) PutRecord ¶
func (a *API) PutRecord(ctx aws.Context, stream, partitionKey string, data []byte) (*kinesis.PutRecordOutput, error)
PutRecord is a convenience wrapper for putting a record into a Kinesis stream.
func (*API) PutRecords ¶ added in v1.0.0
func (a *API) PutRecords(ctx aws.Context, stream, partitionKey string, data [][]byte) (*kinesis.PutRecordsOutput, error)
PutRecords is a convenience wrapper for putting multiple records into a Kinesis stream.
type Aggregate ¶
type Aggregate struct { Record *rec.AggregatedRecord Count int MaxCount int MaxSize int PartitionKey string }
Aggregate produces a KPL-compliant Kinesis record
func (*Aggregate) Add ¶
Add inserts a Kinesis record into an aggregated Kinesis record https://github.com/awslabs/kinesis-aggregation/blob/398fbd4b430d4bf590431b301d03cbbc94279cef/python/aws_kinesis_agg/aggregator.py#L382
func (*Aggregate) Get ¶
Get returns a KPL-compliant compressed Kinesis record https://github.com/awslabs/kinesis-aggregation/blob/398fbd4b430d4bf590431b301d03cbbc94279cef/python/aws_kinesis_agg/aggregator.py#L293
func (*Aggregate) New ¶
func (a *Aggregate) New()
New creates a new Kinesis record with default values https://github.com/awslabs/kinesis-aggregation/blob/398fbd4b430d4bf590431b301d03cbbc94279cef/python/aws_kinesis_agg/aggregator.py#L167