Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

aws_s3 source should support codecs #16824

Closed
jszwedko opened this issue Mar 16, 2023 · 1 comment
Closed

aws_s3 source should support codecs #16824

jszwedko opened this issue Mar 16, 2023 · 1 comment
Labels
domain: codecs Anything related to Vector's codecs (encoding/decoding) source: aws_s3 Anything `aws_s3` source related type: feature A value-adding code addition that introduce new functionality.

Comments

@jszwedko
Copy link
Member

A note for the community

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Use Cases

Users want to use AWS S3 as a transport mechanism between Vector instances. The aws_s3 source currently only supports logs, so this doesn't work for metrics (or traces).

Attempted Solutions

No response

Proposal

Add codec options to the aws_s3 source to enable the use of native or native_json codecs to send data through AWS S3 as a transport.

References

I think usage of codecs could be introduced somewhere around here:

use Compression::*;
match compression {
Auto => unreachable!(), // is mapped above
None => Box::new(r),
Gzip => Box::new({
let mut decoder = bufread::GzipDecoder::new(r);
decoder.multiple_members(true);
decoder
}),
Zstd => Box::new({
let mut decoder = bufread::ZstdDecoder::new(r);
decoder.multiple_members(true);
decoder
}),
}
}

The config option should be added to

pub struct AwsS3Config {

Example configuration:

/// Decoder to use on the HTTP responses.
#[configurable(derived)]
#[serde(default = "default_decoding")]
pub decoding: DeserializerConfig,
/// Framing to use in the decoding.
#[configurable(derived)]
#[serde(default = "default_framing_message_based")]
pub framing: FramingConfig,

That source can be used as a good reference for applying those codec options too.

Version

vector 0.28.1

@jszwedko jszwedko added type: feature A value-adding code addition that introduce new functionality. domain: codecs Anything related to Vector's codecs (encoding/decoding) source: aws_s3 Anything `aws_s3` source related labels Mar 16, 2023
@jszwedko
Copy link
Member Author

Closed by #17098

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain: codecs Anything related to Vector's codecs (encoding/decoding) source: aws_s3 Anything `aws_s3` source related type: feature A value-adding code addition that introduce new functionality.
Projects
None yet
Development

No branches or pull requests

1 participant