Commit 92be4a20 authored by Michael Davis's avatar Michael Davis
Browse files

[frontend] Sends ObjectStore Id along with failed requests

parent afda862c
......@@ -45,6 +45,7 @@ struct ArchiveJob {
std::string instanceName;
uint32_t copyNumber;
uint64_t archiveFileID;
std::string objectId; //!< Objectstore address, provided when reporting a failed job
std::list<std::string> failurelogs;
}; // struct ArchiveJob
......
......@@ -44,6 +44,7 @@ struct RetrieveJob {
RetrieveRequest request;
uint64_t fileSize;
std::map<std::string,std::pair<uint32_t,TapeFile>> tapeCopies;
std::string objectId; //!< Objectstore address, provided when reporting a failed job
std::list<std::string> failurelogs;
}; // struct RetrieveJob
......
......@@ -118,6 +118,7 @@ getQueueJobs(const jobQueue_t &jobQueueChunk)
job.request.srcURL = osar.first.getSrcURL();
job.request.archiveReportURL = osar.first.getArchiveReportURL();
job.request.storageClass = osar.first.getArchiveFile().storageClass;
job.objectId = osar.first.getAddressIfSet();
job.failurelogs = osar.first.getFailures();
m_jobCache.push_back(job);
......@@ -209,6 +210,7 @@ getQueueJobs(const jobQueue_t &jobQueueChunk)
job.request = osrr.first.getSchedulerRequest();
job.fileSize = osrr.first.getArchiveFile().fileSize;
job.tapeCopies[tf.vid] = std::make_pair(tf.copyNb, tf);
job.objectId = osrr.first.getAddressIfSet();
job.failurelogs = osrr.first.getFailures();
m_jobCache.push_back(job);
......
......@@ -137,7 +137,7 @@ pushRecord(XrdSsiPb::OStreamBuffer<Data> *streambuf, const common::dataStructure
auto &tapepool = m_archiveQueueItorPtr->qid();
Data record;
record.mutable_frls_item()->set_object_id("PLACEHOLDER");
record.mutable_frls_item()->set_object_id(item.objectId);
record.mutable_frls_item()->set_request_type(admin::RequestType::ARCHIVE_REQUEST);
record.mutable_frls_item()->set_tapepool(tapepool);
record.mutable_frls_item()->set_copy_nb(item.copyNumber);
......@@ -166,7 +166,7 @@ pushRecord(XrdSsiPb::OStreamBuffer<Data> *streambuf, const common::dataStructure
Data record;
record.mutable_frls_item()->set_object_id("PLACEHOLDER");
record.mutable_frls_item()->set_object_id(item.objectId);
record.mutable_frls_item()->set_request_type(admin::RequestType::RETRIEVE_REQUEST);
record.mutable_frls_item()->set_copy_nb(item.tapeCopies.at(vid).first);
record.mutable_frls_item()->mutable_requester()->set_username(item.request.requester.name);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment