lordgamez commented on a change in pull request #970:
URL: https://github.com/apache/nifi-minifi-cpp/pull/970#discussion_r552049971
##########
File path: extensions/aws/s3/S3WrapperBase.cpp
##########
@@ -32,6 +33,17 @@ namespace minifi {
namespace aws {
namespace s3 {
+void GetObjectResult::setFilePaths(const std::string& key) {
+ const auto last_slash = key.find_last_of('/');
+ absolute_path = key;
+ if (last_slash != std::string::npos) {
+ path = key.substr(0, last_slash);
+ filename = key.substr(last_slash + 1);
+ } else {
+ filename = key;
Review comment:
You are right there is a getFileNameAndPath in pathutils, but that uses
OS specific separators, but in AWS the object key always uses '/' character as
a separator.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]