brexhq / substation

Substation is a toolkit for routing, normalizing, and enriching security event and audit logs.
https://substation.readme.io
MIT License
322 stars 16 forks source link

perf(aws): Reduce Aggregated Kinesis Record Size #147

Closed jshlbrd closed 6 months ago

jshlbrd commented 6 months ago

Description

Motivation and Context

Kinesis Data Streams charge based on PUT payload units, which have a minimum size of 25 KB. Historically the project aggregated up to the Kinesis limit of 1 MB because there was no support for the PutRecords API, but as of v1.0 there is. There's little (or no) value in sending aggregated records larger than 25 KB and by sending them via PutRecords the throughput performance increases by ~33% to ~50% (see screenshot).

25kb_put_records

How Has This Been Tested?

This was tested on a high-volume, production data pipeline.

Types of changes

Checklist: