diff --git a/pipeline/outputs/kinesis.md b/pipeline/outputs/kinesis.md index 2ca80d8c2..807ef98b2 100644 --- a/pipeline/outputs/kinesis.md +++ b/pipeline/outputs/kinesis.md @@ -4,45 +4,45 @@ description: Send logs to Amazon Kinesis Streams # Amazon Kinesis Data Streams -The Amazon Kinesis Data Streams output plugin allows to ingest your records into the [Kinesis](https://aws.amazon.com/kinesis/data-streams/) service. +The Amazon Kinesis Data Streams output plugin lets you ingest your records into the [Kinesis](https://aws.amazon.com/kinesis/data-streams/) service. -This is the documentation for the core Fluent Bit Kinesis plugin written in C. It has all the core features of the [aws/amazon-kinesis-streams-for-fluent-bit](https://github.com/aws/amazon-kinesis-streams-for-fluent-bit) Golang Fluent Bit plugin released in 2019. The Golang plugin was named `kinesis`; this new high performance and highly efficient kinesis plugin is called `kinesis_streams` to prevent conflicts/confusion. +This is the documentation for the core Fluent Bit Kinesis plugin written in C. It has all the core features of the [aws/amazon-kinesis-streams-for-fluent-bit](https://github.com/aws/amazon-kinesis-streams-for-fluent-bit) Golang Fluent Bit plugin released in 2019. The original Golang plugin is named `kinesis`, and this new high performance and highly efficient Kinesis plugin is called `kinesis_streams` to prevent conflicts or confusion. -Currently, this `kinesis_streams` plugin will always use a random partition key when uploading records to kinesis via the [PutRecords API](https://docs.aws.amazon.com/kinesis/latest/APIReference/API_PutRecords.html). +This `kinesis_streams` plugin always uses a random partition key when uploading records to Kinesis through the [PutRecords API](https://docs.aws.amazon.com/kinesis/latest/APIReference/API_PutRecords.html). -See [here](https://github.com/fluent/fluent-bit-docs/tree/43c4fe134611da471e706b0edb2f9acd7cdfdbc3/administration/aws-credentials.md) for details on how AWS credentials are fetched. +For information about how AWS credentials are fetched, see [AWS credentials](../administration/aws-credentials). -## Configuration Parameters +## Configuration parameters -| Key | Description | -| :--- | :--- | -| region | The AWS region. | -| stream | The name of the Kinesis Streams Delivery stream that you want log records sent to. | -| time\_key | Add the timestamp to the record under this key. By default the timestamp from Fluent Bit will not be added to records sent to Kinesis. | -| time\_key\_format | strftime compliant format string for the timestamp; for example, the default is '%Y-%m-%dT%H:%M:%S'. Supports millisecond precision with '%3N' and supports nanosecond precision with '%9N' and '%L'; for example, adding '%3N' to support millisecond '%Y-%m-%dT%H:%M:%S.%3N'. This option is used with time\_key. | -| log\_key | By default, the whole log record will be sent to Kinesis. If you specify a key name with this option, then only the value of that key will be sent to Kinesis. For example, if you are using the Fluentd Docker log driver, you can specify `log_key log` and only the log message will be sent to Kinesis. | -| role\_arn | ARN of an IAM role to assume \(for cross account access\). | -| endpoint | Specify a custom endpoint for the Kinesis API. | -| port | TCP port of the Kinesis Streams service. Defaults to port `443`. | -| sts\_endpoint | Custom endpoint for the STS API. | -| auto\_retry\_requests | Immediately retry failed requests to AWS services once. This option does not affect the normal Fluent Bit retry mechanism with backoff. Instead, it enables an immediate retry with no delay for networking errors, which may help improve throughput when there are transient/random networking issues. This option defaults to `true`. | -| external\_id | Specify an external ID for the STS API, can be used with the role_arn parameter if your role requires an external ID. | -| profile | AWS profile name to use. Defaults to `default`. | -| workers | The number of [workers](../../administration/multithreading.md#outputs) to perform flush operations for this output. Default: `1`. | +| Key | Description | Default | +| --- | ----------- | ------- | +| `region` | The AWS region. | _none_ | +| `stream` | The name of the Kinesis Streams Delivery stream that you want log records sent to. | _none_ | +| `time_key` | Add the timestamp to the record under this key. | `false` | +| `time_key_format` | The strftime compliant format string for the timestamp. Supports millisecond precision with `%3N` and supports nanosecond precision with `%9N` and `%L`. For example, adding `%3N` to support millisecond `%Y-%m-%dT%H:%M:%S.%3N`. This option is used with `time_key`. | `%Y-%m-%dT%H:%M:%S` | +| `log_key` | By default, the whole log record will be sent to Kinesis. If you specify a key name with this option, then only the value of that key will be sent to Kinesis. For example, if you are using the Fluentd Docker log driver, you can specify `log_key log` and only the log message will be sent to Kinesis. | _none_ | +| `role_arn` | ARN of an IAM role to assume (for cross account access). | _none_ | +| `endpoint` | Specify a custom endpoint for the Kinesis API. | _none_ | +| `port` | TCP port of the Kinesis Streams service. | `443` | +| `sts_endpoint` | Custom endpoint for the STS API. | _none_ | +| `auto_retry_requests` | Immediately retry failed requests to AWS services once. This option doesn't affect the normal Fluent Bit retry mechanism with backoff. Instead, it enables an immediate retry with no delay for networking errors, which might help improve throughput when there are transient/random networking issues. | `true` | +| `external_id` | Specify an external ID for the STS API, can be used with the `role_arn` parameter if your role requires an external ID. | _none_ | +| `profile` | AWS profile name to use. | `default` | +| `workers` | The number of [workers](../../administration/multithreading.md#outputs) to perform flush operations for this output. | `1` | -## Getting Started +## Get started -In order to send records into Amazon Kinesis Data Streams, you can run the plugin from the command line or through the configuration file: +To send records into Amazon Kinesis Data Streams, you can run the plugin from the command line or through the configuration file. -### Command Line +### Command line -The **kinesis\_streams** plugin, can read the parameters from the command line through the **-p** argument \(property\), e.g: +The `kinesis_streams` plugin can read the parameters from the command line through the `-p` (property) argument. For example: ```shell fluent-bit -i cpu -o kinesis_streams -p stream=my-stream -p region=us-west-2 -m '*' -f 1 ``` -### Configuration File +### Configuration file In your main configuration file append the following: @@ -51,7 +51,7 @@ In your main configuration file append the following: ```yaml pipeline: - + outputs: - name: kinesis_steams match: '*' @@ -78,9 +78,9 @@ pipeline: The following AWS IAM permissions are required to use this plugin: ```json -{ - "Version": "2012-10-17", - "Statement": [{ +{ + "Version": "2012-10-17", + "Statement": [{ "Effect": "Allow", "Action": [ "kinesis:PutRecords" @@ -90,48 +90,42 @@ The following AWS IAM permissions are required to use this plugin: } ``` -### AWS for Fluent Bit +## Container images Amazon distributes a container image with Fluent Bit and these plugins. -#### GitHub - -[github.com/aws/aws-for-fluent-bit](https://github.com/aws/aws-for-fluent-bit) +### GitHub -#### Amazon ECR Public Gallery +The [aws-for-fluent-bit](https://github.com/aws/aws-for-fluent-bit) container image is available on GitHub. -[aws-for-fluent-bit](https://gallery.ecr.aws/aws-observability/aws-for-fluent-bit) +### Amazon ECR Public Gallery -Our images are available in Amazon ECR Public Gallery. You can download images with different tags by following command: +The [aws-for-fluent-bit](https://gallery.ecr.aws/aws-observability/aws-for-fluent-bit) container image is available on the Amazon ECR Public Gallery. Use the following command to download images with different tags: ```shell -docker pull public.ecr.aws/aws-observability/aws-for-fluent-bit: +docker pull public.ecr.aws/aws-observability/aws-for-fluent-bit:TAG ``` -For example, you can pull the image with latest version by: - -```shell -docker pull public.ecr.aws/aws-observability/aws-for-fluent-bit:latest -``` +Replace `TAG` with the tag of the image you want to download. You can also use the value `latest` to download the latest image. -If you see errors for image pull limits, try log into public ECR with your AWS credentials: +If you see errors for image pull limits, try to log into the gallery with your AWS credentials: ```shell aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws ``` -You can check the [Amazon ECR Public official doc](https://docs.aws.amazon.com/AmazonECR/latest/public/get-set-up-for-amazon-ecr.html) for more details. +You can use the Fluent Bit SSM Public Parameters to find the Amazon ECR image URI in your region: -#### Docker Hub +```shell +aws ssm get-parameters-by-path --path /aws/service/aws-for-fluent-bit/ +``` -[amazon/aws-for-fluent-bit](https://hub.docker.com/r/amazon/aws-for-fluent-bit/tags) +For more details, see the [Amazon ECR Public official doc](https://docs.aws.amazon.com/AmazonECR/latest/public/get-set-up-for-amazon-ecr.html). -#### Amazon ECR +### Docker Hub -You can use our SSM Public Parameters to find the Amazon ECR image URI in your region: +The [aws-for-fluent-bit](https://hub.docker.com/r/amazon/aws-for-fluent-bit/tags) container image is available on Docker Hub. -```shell -aws ssm get-parameters-by-path --path /aws/service/aws-for-fluent-bit/ -``` +### More information -For more see [the AWS for Fluent Bit github repo](https://github.com/aws/aws-for-fluent-bit#public-images). \ No newline at end of file +For more information, see the [aws-for-fluent-bit README](https://github.com/aws/aws-for-fluent-bit#public-images) on GitHub. diff --git a/vale-styles/FluentBit/Acronyms.yml b/vale-styles/FluentBit/Acronyms.yml index ab5a03c1a..08bbe0f60 100644 --- a/vale-styles/FluentBit/Acronyms.yml +++ b/vale-styles/FluentBit/Acronyms.yml @@ -93,6 +93,7 @@ exceptions: - SQL - SSH - SSL + - SSM - SSO - STS - SVG diff --git a/vale-styles/FluentBit/Headings.yml b/vale-styles/FluentBit/Headings.yml index 4cde49e16..36dfd8652 100644 --- a/vale-styles/FluentBit/Headings.yml +++ b/vale-styles/FluentBit/Headings.yml @@ -11,6 +11,7 @@ exceptions: - Amazon CloudWatch - Amazon ECR Public Gallery - Amazon Kinesis Data Firehose + - Amazon Kinesis Data Streams - Amazon Kinesis Firehose - Amazon Kinesis Streams - Amazon OpenSearch Service