I'm using the aws s3 component of Apache Camel. And I want to consume specific data only with an extension of .txt, how can this be achieved? According to camel documentation, it has a prefix options which is not suitable in my case since i want to filter based on extensions.
TIA
No there is no way to do this.
You cannot use a regular expression in the prefix option as it is just a string, see http://docs.aws.amazon.com/AWSJavaSDK/latest/javadoc/com/amazonaws/services/s3/model/ListObjectsRequest.html#setPrefix(java.lang.String)
The only way would be to retrieve a list of the files and filter them. Or name the files in such a way so that you can use a prefix
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With