Skip to content
Snippets Groups Projects
Commit ef504e45 authored by Ramon Nou's avatar Ramon Nou
Browse files

added adhoc uuid to query

parent fe41a711
No related branches found
No related tags found
1 merge request!126Resolve "Root issues and stage-out with SPANK"
Pipeline #4448 failed
......@@ -85,8 +85,9 @@ main(int argc, char* argv[]) {
fmt::print(stdout,
"Job metadata:\n"
" adhoc_controller: {}\n"
" adhoc_uuid: {}\n"
" io_procs: {}\n",
info.adhoc_controller_address(), info.io_procs());
info.adhoc_controller_address(), info.uuid(), info.io_procs());
} catch(const std::exception& ex) {
fmt::print(stderr, "Error: {}\n", ex.what());
......
......@@ -493,9 +493,9 @@ class job_info {
public:
job_info() = default;
explicit job_info(std::string adhoc_controller_address,
explicit job_info(std::string adhoc_controller_address,std::string uuid,
std::uint32_t procs_for_io)
: m_adhoc_address(std::move(adhoc_controller_address)),
: m_adhoc_address(std::move(adhoc_controller_address)), m_uuid(std::move(uuid)),
m_procs_for_io(procs_for_io) {}
constexpr std::string const&
......@@ -512,16 +512,23 @@ public:
return m_procs_for_io;
}
constexpr std::string const&
uuid() const {
return m_uuid;
}
private:
friend class cereal::access;
template <class Archive>
void
serialize(Archive& ar) {
ar & m_adhoc_address;
ar & m_uuid;
ar & m_procs_for_io;
}
std::string m_adhoc_address;
std::string m_uuid;
std::uint32_t m_procs_for_io;
};
......
......@@ -164,9 +164,13 @@ rpc_server::query(const network::request& req, slurm_job_id job_id) {
return tl::make_unexpected(
error_code::no_resources);
}
return job_info{
job_metadata_ptr->adhoc_storage_metadata()
->controller_address(),
job_metadata_ptr->adhoc_storage_metadata()->uuid(),
job_metadata_ptr->io_procs()};
});
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment