diff --git a/cmdline/CtaAdminCmd.cpp b/cmdline/CtaAdminCmd.cpp index 63bb07a036d896f4a5480152ef6fa7a393aedfec..cdf8a8f792c0aabd253bf8afad47d32a810bb2aa 100644 --- a/cmdline/CtaAdminCmd.cpp +++ b/cmdline/CtaAdminCmd.cpp @@ -473,11 +473,11 @@ void CtaAdminCmd::printLprHeader() void CtaAdminCmd::printLprItem(const cta::admin::ArchiveFileItem &af_item) { - std::cout << std::setfill(' ') << std::setw(13) << std::right << af_item.vid() << ' ' + std::cout << std::setfill(' ') << std::setw(13) << std::right << af_item.tf().vid() << ' ' << std::setfill(' ') << std::setw(7) << std::right << af_item.af().archive_id() << ' ' << std::setfill(' ') << std::setw(7) << std::right << af_item.copy_nb() << ' ' - << std::setfill(' ') << std::setw(7) << std::right << "fseq" << ' ' - << std::setfill(' ') << std::setw(9) << std::right << "block id" << ' ' + << std::setfill(' ') << std::setw(7) << std::right << af_item.tf().f_seq() << ' ' + << std::setfill(' ') << std::setw(9) << std::right << af_item.tf().block_id() << ' ' << std::setfill(' ') << std::setw(12) << std::right << af_item.af().size() << ' ' << std::setfill(' ') << std::setw(8) << std::right << af_item.af().df().owner() << ' ' << std::setfill(' ') << std::setw(8) << std::right << af_item.af().df().group() << ' ' diff --git a/xroot_plugins/XrdCtaListPendingQueue.hpp b/xroot_plugins/XrdCtaListPendingQueue.hpp index 1f8a37f87ec08f0e7dff4b91e51c648b8003f38c..9a7335e8f0dc41047538597ebb0a97b92ac741b4 100644 --- a/xroot_plugins/XrdCtaListPendingQueue.hpp +++ b/xroot_plugins/XrdCtaListPendingQueue.hpp @@ -218,7 +218,6 @@ template<> bool ListPendingQueue<OStoreDB::RetrieveQueueItor_t>::pushRecord(XrdSsiPb::OStreamBuffer<Data> *streambuf, const std::string &vid, const common::dataStructures::RetrieveJob &job) { - #if 0 if(vid) { std::list<cta::common::dataStructures::RetrieveJob> list = m_scheduler.getPendingRetrieveJobs(vid.value(), m_lc); @@ -226,17 +225,6 @@ bool ListPendingQueue<OStoreDB::RetrieveQueueItor_t>::pushRecord(XrdSsiPb::OStre } else { result = m_scheduler.getPendingRetrieveJobs(m_lc); } - - for(auto it = result.cbegin(); it != result.cend(); it++) - { - for(auto jt = it->second.cbegin(); jt != it->second.cend(); jt++) - { - currentRow.push_back(jt->request.requester.name); - currentRow.push_back(jt->request.requester.group); - currentRow.push_back(jt->request.diskFileInfo.path); - responseTable.push_back(currentRow); - } - } #endif bool is_buffer_full = false; @@ -253,33 +241,27 @@ bool ListPendingQueue<OStoreDB::RetrieveQueueItor_t>::pushRecord(XrdSsiPb::OStre // Response type record.mutable_af_item()->set_type(cta::admin::ArchiveFileItem::LISTPENDINGRETRIEVES); - // VID - record.mutable_af_item()->set_vid(tape_it->first); - // Copy number record.mutable_af_item()->set_copy_nb(tape_it->second.first); - // Retrieve file + // Archive file auto af = record.mutable_af_item()->mutable_af(); af->set_archive_id(job.request.archiveFileID); af->set_size(tape_it->second.second.compressedSize); #if 0 cta::common::dataStructures::ArchiveFile file = m_catalogue.getArchiveFileById(jt->request.archiveFileID); - currentRow.push_back(std::to_string(static_cast<unsigned long long>((jt->tapeCopies.at(it->first).first)))); - currentRow.push_back(std::to_string(static_cast<unsigned long long>((jt->tapeCopies.at(it->first).second.fSeq)))); - currentRow.push_back(std::to_string(static_cast<unsigned long long>((jt->tapeCopies.at(it->first).second.blockId)))); currentRow.push_back(std::to_string(static_cast<unsigned long long>(file.fileSize))); - af->set_disk_instance(job.instanceName); - af->set_disk_id(job.request.diskFileID); - af->set_size(job.request.fileSize); - af->mutable_cs()->set_type(job.request.checksumType); - af->mutable_cs()->set_value(job.request.checksumValue); - af->set_storage_class(job.request.storageClass); #endif af->mutable_df()->set_owner(job.request.requester.name); af->mutable_df()->set_group(job.request.requester.group); af->mutable_df()->set_path(job.request.diskFileInfo.path); + // Tape file + auto tf = record.mutable_af_item()->mutable_tf(); + tf->set_vid(tape_it->first); + tf->set_f_seq(tape_it->second.second.fSeq); + tf->set_block_id(tape_it->second.second.blockId); + is_buffer_full = streambuf->Push(record); } diff --git a/xrootd-ssi-protobuf-interface b/xrootd-ssi-protobuf-interface index 3ce8079aec20aa77b3a4773e6caa02b36bb0a749..36cf1ea86e6f6cd0843a9a90521b36c3948d2937 160000 --- a/xrootd-ssi-protobuf-interface +++ b/xrootd-ssi-protobuf-interface @@ -1 +1 @@ -Subproject commit 3ce8079aec20aa77b3a4773e6caa02b36bb0a749 +Subproject commit 36cf1ea86e6f6cd0843a9a90521b36c3948d2937