diff --git a/dbms/src/IO/ReadBufferFromS3.cpp b/dbms/src/IO/ReadBufferFromS3.cpp index e26f683cdd4..852e601b9ab 100644 --- a/dbms/src/IO/ReadBufferFromS3.cpp +++ b/dbms/src/IO/ReadBufferFromS3.cpp @@ -32,7 +32,7 @@ ReadBufferFromS3::ReadBufferFromS3(Poco::URI uri_, if (!credentials.getUsername().empty()) credentials.authenticate(*request); - LOG_TRACE((&Logger::get("ReadWriteBufferFromS3")), "Sending request to " << uri.toString()); + LOG_TRACE((&Logger::get("ReadBufferFromS3")), "Sending request to " << uri.toString()); session->sendRequest(*request); diff --git a/dbms/src/IO/WriteBufferFromS3.cpp b/dbms/src/IO/WriteBufferFromS3.cpp index 4e574a11c0b..181fba7f63f 100644 --- a/dbms/src/IO/WriteBufferFromS3.cpp +++ b/dbms/src/IO/WriteBufferFromS3.cpp @@ -49,9 +49,6 @@ void WriteBufferFromS3::nextImpl() if (!offset()) return; - - LOG_TRACE((&Logger::get("WriteBufferFromS3")), "nextImpl(), offset() == " << offset()); - temporary_buffer->write(working_buffer.begin(), offset()); last_part_size += offset(); @@ -68,11 +65,9 @@ void WriteBufferFromS3::nextImpl() void WriteBufferFromS3::finalize() { - LOG_TRACE((&Logger::get("WriteBufferFromS3")), "finalize()"); temporary_buffer->finish(); if (!buffer_string.empty()) { - LOG_TRACE((&Logger::get("WriteBufferFromS3")), "finalize(), writing last part"); writePart(buffer_string); } @@ -101,7 +96,8 @@ void WriteBufferFromS3::initiate() HTTPSessionPtr session; std::istream * istr = nullptr; /// owned by session Poco::URI initiate_uri = uri; - initiate_uri.setRawQuery("uploads"); // FIXME find how to leave user params as is + initiate_uri.setRawQuery("uploads"); + initiate_uri.setQueryParameters(uri.getQueryParameters()); for (int i = 0; i < DEFAULT_S3_MAX_FOLLOW_PUT_REDIRECT; ++i) { @@ -225,7 +221,7 @@ void WriteBufferFromS3::complete() String data; WriteBufferFromString buffer(data); - writeString("", buffer); // FIXME move to Poco::XML maybe?? + writeString("", buffer); for (size_t i = 0; i < part_tags.size(); ++i) { writeString("", buffer);