Add support for S3 bucket upload - #38
Open
dnovitski wants to merge 4 commits into
Open
Conversation
commit 7026739 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Fri May 5 17:27:22 2023 +0200 Improve startup conditions commit 199bd16 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Fri May 5 15:13:07 2023 +0200 Add support for S3 bucket upload commit 6d551ba Merge: 5d83b4b 1cda000 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Thu May 4 14:45:35 2023 +0200 Merge commit '1cda000fb70d83a51030929f46bbe885364b9659' commit 5d83b4b Merge: 3ca32e6 ecd9785 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Thu May 4 14:43:38 2023 +0200 Merge commit 'ecd97852aaa02686de86a6106f14962d2749b9d7' commit 3ca32e6 Merge: 964eafb 035c722 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Thu May 4 14:42:54 2023 +0200 Merge commit '035c722d8fdae686f8b81264ba63b07e29227c0b' commit 964eafb Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Thu May 20 11:25:23 2021 +0200 Release 1.5.1 commit 1ac95b2 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Thu May 20 11:24:14 2021 +0200 Upgrade to AWS SDK v2 -- fix concurrent modification issue commit 70ba5d0 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Wed May 19 18:19:38 2021 +0200 Use groupId io.github.dnovitski commit f6a70ec Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Wed May 19 17:48:03 2021 +0200 Upgrade to AWS SDK v2
commit 26fd779 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Wed Sep 13 19:05:38 2023 +0200 Add support for multiple S3 output file formats, including compression; Release as 1.7.2 commit 1999c0b Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Tue May 9 16:59:08 2023 +0200 Correct typo Invalid endpoint endpoint URL commit 7026739 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Fri May 5 17:27:22 2023 +0200 Improve startup conditions commit 199bd16 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Fri May 5 15:13:07 2023 +0200 Add support for S3 bucket upload commit 6d551ba Merge: 5d83b4b 1cda000 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Thu May 4 14:45:35 2023 +0200 Merge commit '1cda000fb70d83a51030929f46bbe885364b9659' commit 5d83b4b Merge: 3ca32e6 ecd9785 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Thu May 4 14:43:38 2023 +0200 Merge commit 'ecd97852aaa02686de86a6106f14962d2749b9d7' commit 3ca32e6 Merge: 964eafb 035c722 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Thu May 4 14:42:54 2023 +0200 Merge commit '035c722d8fdae686f8b81264ba63b07e29227c0b' commit 964eafb Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Thu May 20 11:25:23 2021 +0200 Release 1.5.1 commit 1ac95b2 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Thu May 20 11:24:14 2021 +0200 Upgrade to AWS SDK v2 -- fix concurrent modification issue commit 70ba5d0 Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Wed May 19 18:19:38 2021 +0200 Use groupId io.github.dnovitski commit f6a70ec Author: dnovitski <54758025+dnovitski@users.noreply.github.com> Date: Wed May 19 17:48:03 2021 +0200 Upgrade to AWS SDK v2
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi @pierredavidbelanger,
We noticed that using CloudWatch logs is rather expensive and sought a way to reduce the cost.
One way we found is to use AWS S3 instead.
So the idea is apps will upload their logs to an AWS S3 bucket (after each flush time), and this S3 bucket will have event notification enabled to send ObjectCreated events to an AWS SQS queue when new log files are uploaded.
A separate Filebeat service will watch the SQS queue and pick up these log files for shipping to ElasticSearch.
We expect to reduce our logging costs 10x by using this strategy, and still retaining all the same functionality we had before.
This PR adds support in the AWSLogs appender for uploading to S3 bucket.
All the concepts from CloudWatch (log groups, log streams, etc) are ported over to the S3 way so users can easily switch between the two if needed.
As example, we use the following logback and Filebeat configuration:
Logback.xml
Filebeat: