Skip to content
Snippets Groups Projects
Verified Commit 4f7c96c0 authored by Timm Fitschen's avatar Timm Fitschen
Browse files

Merge branch 'f-files' into f-consolidation

parents 7bc40ea8 ea446318
No related branches found
No related tags found
1 merge request!12F consolidation
/*
* This file is a part of the CaosDB Project.
* Copyright (C) 2021 Timm Fitschen <t.fitschen@indiscale.com>
* Copyright (C) 2021 IndiScale GmbH <info@indiscale.com>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
*********************************************************************************
*
* This is derived work which is heavily based on
* https://github.com/NeiRo21/grpcpp-bidi-streaming, Commit
* cd9cb78e5d6d72806c2ec4c703e5e856b223dc96, Aug 10, 2020
*
* The orginal work is licensed as
*
* > MIT License
* >
* > Copyright (c) 2019 NeiRo21
* >
* > Permission is hereby granted, free of charge, to any person obtaining a
* > copy of this software and associated documentation files (the "Software"),
* > to deal in the Software without restriction, including without limitation
* > the rights to use, copy, modify, merge, publish, distribute, sublicense,
* > and/or sell copies of the Software, and to permit persons to whom the
* > Software is furnished to do so, subject to the following conditions:
* >
* > The above copyright notice and this permission notice shall be included in
* > all copies or substantial portions of the Software.
* >
* > THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* > IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* > FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* > AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* > LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* > FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* > DEALINGS IN THE SOFTWARE.
*/
#include "caosdb/file_transmission/file_reader.h"
#include "caosdb/file_transmission/file_error.h" // for FileIOError
#include <boost/filesystem/path.hpp> // for path
#include <utility> // for move
namespace caosdb::transaction {
FileReader::FileReader(boost::filesystem::path filename)
: filename_(std::move(filename)), size_(0) {
this->openFile();
}
void FileReader::openFile() {
stream_.open(filename_, std::ios::binary | std::ios::ate);
if (!stream_) {
throw FileIOError("Can't open file for reading: " + filename_.string());
}
auto size = stream_.tellg();
stream_.seekg(0);
if (size > 0) {
size_ = static_cast<decltype(size_)>(size);
}
}
std::size_t FileReader::read(std::string &buffer) {
std::size_t bytesRead = 0;
if (!stream_.eof()) {
auto bufferSize = buffer.size();
if (bufferSize > 0) {
if (!stream_.read(&buffer[0], bufferSize)) {
throw FileIOError("Can't read file: " + filename_.string());
}
bytesRead = static_cast<std::size_t>(stream_.gcount());
}
}
return bytesRead;
}
} // namespace caosdb::transaction
/*
* This file is a part of the CaosDB Project.
* Copyright (C) 2021 Timm Fitschen <t.fitschen@indiscale.com>
* Copyright (C) 2021 IndiScale GmbH <info@indiscale.com>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
*********************************************************************************
*
* This is derived work which is heavily based on
* https://github.com/NeiRo21/grpcpp-bidi-streaming, Commit
* cd9cb78e5d6d72806c2ec4c703e5e856b223dc96, Aug 10, 2020
*
* The orginal work is licensed as
*
* > MIT License
* >
* > Copyright (c) 2019 NeiRo21
* >
* > Permission is hereby granted, free of charge, to any person obtaining a
* > copy of this software and associated documentation files (the "Software"),
* > to deal in the Software without restriction, including without limitation
* > the rights to use, copy, modify, merge, publish, distribute, sublicense,
* > and/or sell copies of the Software, and to permit persons to whom the
* > Software is furnished to do so, subject to the following conditions:
* >
* > The above copyright notice and this permission notice shall be included in
* > all copies or substantial portions of the Software.
* >
* > THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* > IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* > FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* > AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* > LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* > FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* > DEALINGS IN THE SOFTWARE.
*/
#include "caosdb/file_transmission/file_writer.h"
#include "caosdb/file_transmission/file_error.h" // for FileIOError
#include <boost/filesystem/path.hpp> // for path
#include <utility> // for move
namespace caosdb::transaction {
FileWriter::FileWriter(boost::filesystem::path filename)
: filename_(std::move(filename)) {
this->openFile();
}
void FileWriter::openFile() {
stream_.open(filename_, std::ios::binary | std::ios::trunc);
if (!stream_) {
throw FileIOError("Can't open file for writing: " + filename_.string());
}
}
void FileWriter::write(const std::string &buffer) {
auto bufferSize = buffer.size();
if (bufferSize > 0) {
if (!stream_.write(buffer.data(), bufferSize)) {
throw FileIOError("Can't write file: " + filename_.string());
}
}
}
} // namespace caosdb::transaction
/*
* This file is a part of the CaosDB Project.
* Copyright (C) 2021 Timm Fitschen <t.fitschen@indiscale.com>
* Copyright (C) 2021 IndiScale GmbH <info@indiscale.com>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
*********************************************************************************
*
* This is derived work which is heavily based on
* https://github.com/NeiRo21/grpcpp-bidi-streaming, Commit
* cd9cb78e5d6d72806c2ec4c703e5e856b223dc96, Aug 10, 2020
*
* The orginal work is licensed as
*
* > MIT License
* >
* > Copyright (c) 2019 NeiRo21
* >
* > Permission is hereby granted, free of charge, to any person obtaining a
* > copy of this software and associated documentation files (the "Software"),
* > to deal in the Software without restriction, including without limitation
* > the rights to use, copy, modify, merge, publish, distribute, sublicense,
* > and/or sell copies of the Software, and to permit persons to whom the
* > Software is furnished to do so, subject to the following conditions:
* >
* > The above copyright notice and this permission notice shall be included in
* > all copies or substantial portions of the Software.
* >
* > THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* > IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* > FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* > AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* > LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* > FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* > DEALINGS IN THE SOFTWARE.
*/
#include "caosdb/file_transmission/register_file_upload_handler.h"
#include "caosdb/logging.h" // for CAOSDB_LOG_TRACE
#include <boost/log/core/record.hpp> // for record
......@@ -33,6 +81,4 @@ void RegisterFileUploadHandler::handleNewCallState() {
<< "Leave RegisterFileUploadHandler::handleNewCallState";
}
void RegisterFileUploadHandler::handleReceivingFileState() {}
} // namespace caosdb::transaction
#include "caosdb/file_transmission/UploadRequestHandler.h"
#include "caosdb/exceptions.h" // for Exception
/*
* This file is a part of the CaosDB Project.
* Copyright (C) 2021 Timm Fitschen <t.fitschen@indiscale.com>
* Copyright (C) 2021 IndiScale GmbH <info@indiscale.com>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
*********************************************************************************
*
* This is derived work which is heavily based on
* https://github.com/NeiRo21/grpcpp-bidi-streaming, Commit
* cd9cb78e5d6d72806c2ec4c703e5e856b223dc96, Aug 10, 2020
*
* The orginal work is licensed as
*
* > MIT License
* >
* > Copyright (c) 2019 NeiRo21
* >
* > Permission is hereby granted, free of charge, to any person obtaining a
* > copy of this software and associated documentation files (the "Software"),
* > to deal in the Software without restriction, including without limitation
* > the rights to use, copy, modify, merge, publish, distribute, sublicense,
* > and/or sell copies of the Software, and to permit persons to whom the
* > Software is furnished to do so, subject to the following conditions:
* >
* > The above copyright notice and this permission notice shall be included in
* > all copies or substantial portions of the Software.
* >
* > THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* > IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* > FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* > AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* > LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* > FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* > DEALINGS IN THE SOFTWARE.
*/
#include "caosdb/file_transmission/upload_request_handler.h"
#include "caosdb/logging.h" // for CAOSDB_LOG_ERROR
#include "caosdb/protobuf_helper.h" // for get_arena
#include "caosdb/status_code.h" // for GENERIC_RPC_E...
#include "caosdb/transaction_status.h" // for TransactionStatus
#include <algorithm> // for min
#include <boost/filesystem/path.hpp> // for operator<<, path
#include <boost/log/core/record.hpp> // for record
......@@ -27,9 +75,6 @@
namespace caosdb::transaction {
using caosdb::StatusCode;
using caosdb::exceptions::AuthenticationError;
using caosdb::exceptions::ConnectionError;
using caosdb::exceptions::Exception;
using caosdb::utility::get_arena;
using google::protobuf::Arena;
......@@ -47,7 +92,7 @@ bool UploadRequestHandler::OnNext(bool ok) {
try {
if (state_ == CallState::CallComplete) {
this->handleCallCompleteState();
return false; // TODO(tf): comment
return false;
} else if (ok) {
if (state_ == CallState::NewCall) {
this->handleNewCallState();
......@@ -64,17 +109,20 @@ bool UploadRequestHandler::OnNext(bool ok) {
}
return true;
} catch (Exception &e) {
throw;
} catch (std::exception &e) {
CAOSDB_LOG_ERROR(logger_name) << "Upload processing error: " << e.what();
CAOSDB_LOG_ERROR(logger_name)
<< "UploadRequestHandler caught an exception: " << e.what();
transaction_status = TransactionStatus::GENERIC_ERROR(e.what());
state_ = CallState::CallComplete;
} catch (...) {
CAOSDB_LOG_ERROR(logger_name)
<< "Upload processing error: unknown exception caught";
<< "Transaction error: unknown exception caught";
transaction_status = TransactionStatus::GENERIC_ERROR(
"UploadRequestHandler caught an unknown exception");
state_ = CallState::CallComplete;
}
if (state_ == CallState::NewCall) {
// TODO(tf): comment
return false;
}
......@@ -91,6 +139,7 @@ void UploadRequestHandler::handleNewCallState() {
rpc_ = stub_->PrepareAsyncFileUpload(&ctx_, response_, cq_);
transaction_status = TransactionStatus::EXECUTING();
state_ = CallState::SendingHeader;
rpc_->StartCall(tag_);
}
......@@ -139,21 +188,31 @@ void UploadRequestHandler::handleExpectingResponseState() {
}
void UploadRequestHandler::handleCallCompleteState() {
CAOSDB_LOG_TRACE(logger_name)
<< "Enter UploadRequestHandler::handleCallCompleteState";
switch (status_.error_code()) {
case grpc::OK: {
auto bytesSent = fileReader_ ? fileReader_->fileSize() : 0;
auto bytesSent = fileReader_ != nullptr ? fileReader_->fileSize() : 0;
CAOSDB_LOG_INFO(logger_name)
<< "[" << file_descriptor_.local_path
<< "]: upload complete: " << bytesSent << " bytes sent" << std::endl;
<< "UploadRequestHandler finished successfully ("
<< file_descriptor_.local_path << "): upload complete, " << bytesSent
<< " bytes sent";
} break;
default: {
auto code(static_cast<StatusCode>(status_.error_code()));
std::string description(get_status_description(code) +
" Original message: " + status_.error_message());
transaction_status = TransactionStatus(code, description);
CAOSDB_LOG_ERROR(logger_name)
<< "UploadRequestHandler finished with an error ("
<< file_descriptor_.local_path << "): Upload aborted with code " << code
<< " - " << description;
} break;
case grpc::UNAUTHENTICATED:
throw AuthenticationError(status_.error_message());
case grpc::UNAVAILABLE:
throw ConnectionError(status_.error_message());
default:
throw Exception(StatusCode::GENERIC_RPC_ERROR, status_.error_message());
}
CAOSDB_LOG_TRACE(logger_name)
<< "Leave UploadRequestHandler::handleCallCompleteState";
}
} // namespace caosdb::transaction
......@@ -20,10 +20,11 @@
#include "caosdb/transaction.h"
#include "caosdb/entity/v1alpha1/main.grpc.pb.h" // for EntityTransac...
#include "caosdb/entity/v1alpha1/main.pb.h" // for TransactionRe...
#include "caosdb/file_transmission/Client.h" // for FileExchangeC...
#include "caosdb/file_transmission/download_request_handler.h" // Download...
#include "caosdb/file_transmission/file_reader.h" // for path
#include "caosdb/file_transmission/register_file_upload_handler.h"
#include "caosdb/file_transmission/upload_request_handler.h" // Upload...
#include "caosdb/logging.h" // for CAOSDB_LOG_FATAL
#include "caosdb/protobuf_helper.h" // for get_arena
#include "caosdb/status_code.h" // for StatusCode
#include "caosdb/transaction_handler.h"
#include <algorithm> // for max
......@@ -285,7 +286,6 @@ auto Transaction::ExecuteAsynchronously() noexcept -> StatusCode {
CAOSDB_LOG_INFO(logger_name)
<< "Number of files to be uploaded: " << upload_files.size();
// TODO(tf): Use Arena
auto *registration_request =
Arena::CreateMessage<RegisterFileUploadRequest>(GetArena());
auto *registration_response =
......@@ -302,15 +302,15 @@ auto Transaction::ExecuteAsynchronously() noexcept -> StatusCode {
return StatusCode::EXECUTING;
}
FileExchangeClient upload_client(file_service);
for (auto file_descriptor : upload_files) {
for (auto &file_descriptor : upload_files) {
file_descriptor.file_transmission_id->set_registration_id(
registration_response->registration_id());
CAOSDB_LOG_INFO(logger_name)
<< "Uploading " << file_descriptor.local_path;
auto file_upload_status = upload_client.upload(file_descriptor);
if (file_upload_status != StatusCode::SUCCESS) {
this->status = TransactionStatus::FILE_UPLOAD_ERROR();
handler_ = std::make_unique<UploadRequestHandler>(
&handler_, file_service.get(), &completion_queue, file_descriptor);
this->status = ProcessCalls();
if (this->status.GetCode() != StatusCode::EXECUTING) {
return StatusCode::EXECUTING;
}
}
......@@ -319,12 +319,13 @@ auto Transaction::ExecuteAsynchronously() noexcept -> StatusCode {
CAOSDB_LOG_DEBUG(logger_name) << "RPC Request: " << RequestToString();
handler_ = std::make_unique<EntityTransactionHandler>(
&handler_, entity_service.get(), &completion_queue, request, response);
this->status = ProcessCalls();
CAOSDB_LOG_DEBUG(logger_name) << "RPC Response: " << ResponseToString();
if (this->status.GetCode() != StatusCode::EXECUTING) {
return StatusCode::EXECUTING;
}
// file download afterwards
if (status.GetCode() == StatusCode::SUCCESS && !download_files.empty()) {
if (status.GetCode() == StatusCode::EXECUTING && !download_files.empty()) {
// run over all retrieved entities and get the download_id
for (auto sub_response : *(response->mutable_responses())) {
if (sub_response.transaction_response_case() ==
......@@ -342,15 +343,15 @@ auto Transaction::ExecuteAsynchronously() noexcept -> StatusCode {
}
}
FileExchangeClient download_client(file_service);
for (const auto &item : download_files) {
auto file_descriptor(item.second);
CAOSDB_DEBUG_MESSAGE_STRING(*file_descriptor.file_transmission_id, out)
CAOSDB_LOG_INFO(logger_name)
<< "Downloading " << file_descriptor.local_path << ", " << out;
auto file_download_status = download_client.download(file_descriptor);
if (file_download_status != StatusCode::SUCCESS) {
this->status = TransactionStatus::FILE_DOWNLOAD_ERROR();
<< "Downloading " << file_descriptor.local_path;
handler_ = std::make_unique<DownloadRequestHandler>(
&handler_, file_service.get(), &completion_queue, file_descriptor);
this->status = ProcessCalls();
if (this->status.GetCode() != StatusCode::EXECUTING) {
return StatusCode::EXECUTING;
}
}
......@@ -359,6 +360,10 @@ auto Transaction::ExecuteAsynchronously() noexcept -> StatusCode {
}
auto Transaction::WaitForIt() const noexcept -> TransactionStatus {
if (this->status.GetCode() != StatusCode::EXECUTING) {
return this->status;
}
this->status = TransactionStatus::SUCCESS();
bool set_error = false;
auto *responses = this->response->mutable_responses();
std::vector<std::unique_ptr<Entity>> entities;
......
......@@ -37,8 +37,4 @@ void EntityTransactionHandler::handleNewCallState() {
<< "Leave EntityTransactionHandler::handleNewCallState";
}
void EntityTransactionHandler::handleReceivingFileState() {
// TODO(tf) remove
}
} // namespace caosdb::transaction
/*
* This file is a part of the CaosDB Project.
* Copyright (C) 2021 Timm Fitschen <t.fitschen@indiscale.com>
* Copyright (C) 2021 IndiScale GmbH <info@indiscale.com>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
*********************************************************************************
*
* This is derived work which is heavily based on
* https://github.com/NeiRo21/grpcpp-bidi-streaming, Commit
* cd9cb78e5d6d72806c2ec4c703e5e856b223dc96, Aug 10, 2020
*
* The orginal work is licensed as
*
* > MIT License
* >
* > Copyright (c) 2019 NeiRo21
* >
* > Permission is hereby granted, free of charge, to any person obtaining a
* > copy of this software and associated documentation files (the "Software"),
* > to deal in the Software without restriction, including without limitation
* > the rights to use, copy, modify, merge, publish, distribute, sublicense,
* > and/or sell copies of the Software, and to permit persons to whom the
* > Software is furnished to do so, subject to the following conditions:
* >
* > The above copyright notice and this permission notice shall be included in
* > all copies or substantial portions of the Software.
* >
* > THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* > IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* > FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* > AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* > LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* > FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* > DEALINGS IN THE SOFTWARE.
*/
#include "caosdb/unary_rpc_handler.h"
#include "caosdb/logging.h" // for CAOSDB_LOG_TRACE
#include "caosdb/status_code.h" // for GENERIC_RPC_E...
......@@ -21,8 +69,6 @@ bool UnaryRpcHandler::OnNext(bool ok) {
if (ok) {
if (state_ == CallState::NewCall) {
this->handleNewCallState();
} else if (state_ == CallState::ReceivingFile) {
this->handleReceivingFileState();
} else if (state_ == CallState::CallComplete) {
this->handleCallCompleteState();
return false;
......@@ -69,7 +115,6 @@ void UnaryRpcHandler::handleCallCompleteState() {
switch (status_.error_code()) {
case grpc::OK:
transaction_status = TransactionStatus::SUCCESS();
CAOSDB_LOG_INFO(logger_name) << "UnaryRpcHandler finished successfully.";
break;
default:
......
#include "caosdb/file_transmission/FileWriter.h"
#include "caosdb/file_transmission/FileReader.h"
/*
* This file is a part of the CaosDB Project.
*
* Copyright (C) 2021 Timm Fitschen <t.fitschen@indiscale.com>
* Copyright (C) 2021 IndiScale GmbH <info@indiscale.com>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
#include "caosdb/file_transmission/file_writer.h"
#include "caosdb/file_transmission/file_reader.h"
#include <boost/filesystem/operations.hpp> // for exists, file_size, remove
#include <boost/filesystem/path.hpp> // for path
#include <boost/filesystem/path_traits.hpp> // for filesystem
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment