Loading src/common/api/types.cpp +0 −5 Original line number Diff line number Diff line Loading @@ -26,13 +26,8 @@ #include <net/proto/rpc_types.h> #include <net/serialization.hpp> #include <utility> #include <utils/ctype_ptr.hpp> #include <cstdarg> #include <api/convert.hpp> #include <variant> #include <optional> #include <cereal/types/memory.hpp> #include <thallium/serialization/proc_input_archive.hpp> #include "admire_types.hpp" #include "internal_types.hpp" Loading src/lib/detail/impl.cpp +0 −129 Original line number Diff line number Diff line Loading @@ -27,140 +27,11 @@ #include <net/endpoint.hpp> #include <net/request.hpp> #include <net/serialization.hpp> #include <net/proto/rpc_types.h> #include <api/convert.hpp> #include <admire_types.hpp> #include "impl.hpp" using namespace std::literals; #if 0 void rpc_registration_cb(scord::network::rpc_client* client) { REGISTER_RPC(client, "ADM_ping", void, ADM_ping_out_t, NULL, true); REGISTER_RPC(client, "ADM_register_job", ADM_register_job_in_t, ADM_register_job_out_t, NULL, true); REGISTER_RPC(client, "ADM_update_job", ADM_update_job_in_t, ADM_update_job_out_t, NULL, true); REGISTER_RPC(client, "ADM_remove_job", ADM_remove_job_in_t, ADM_remove_job_out_t, NULL, true); REGISTER_RPC(client, "ADM_register_adhoc_storage", ADM_register_adhoc_storage_in_t, ADM_register_adhoc_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_update_adhoc_storage", ADM_update_adhoc_storage_in_t, ADM_update_adhoc_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_remove_adhoc_storage", ADM_remove_adhoc_storage_in_t, ADM_remove_adhoc_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_deploy_adhoc_storage", ADM_deploy_adhoc_storage_in_t, ADM_deploy_adhoc_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_register_pfs_storage", ADM_register_pfs_storage_in_t, ADM_register_pfs_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_update_pfs_storage", ADM_update_pfs_storage_in_t, ADM_update_pfs_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_remove_pfs_storage", ADM_remove_pfs_storage_in_t, ADM_remove_pfs_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_input", ADM_input_in_t, ADM_input_out_t, NULL, true); REGISTER_RPC(client, "ADM_output", ADM_output_in_t, ADM_output_out_t, NULL, true); REGISTER_RPC(client, "ADM_inout", ADM_inout_in_t, ADM_inout_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_context", ADM_adhoc_context_in_t, ADM_adhoc_context_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_context_id", ADM_adhoc_context_id_in_t, ADM_adhoc_context_id_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_nodes", ADM_adhoc_nodes_in_t, ADM_adhoc_nodes_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_walltime", ADM_adhoc_walltime_in_t, ADM_adhoc_walltime_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_access", ADM_adhoc_access_in_t, ADM_adhoc_access_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_distribution", ADM_adhoc_distribution_in_t, ADM_adhoc_distribution_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_background_flush", ADM_adhoc_background_flush_in_t, ADM_adhoc_background_flush_out_t, NULL, true); REGISTER_RPC(client, "ADM_in_situ_ops", ADM_in_situ_ops_in_t, ADM_in_situ_ops_out_t, NULL, true); REGISTER_RPC(client, "ADM_in_transit_ops", ADM_in_transit_ops_in_t, ADM_in_transit_ops_out_t, NULL, true); REGISTER_RPC(client, "ADM_transfer_datasets", ADM_transfer_datasets_in_t, ADM_transfer_datasets_out_t, NULL, true); REGISTER_RPC(client, "ADM_set_dataset_information", ADM_set_dataset_information_in_t, ADM_set_dataset_information_out_t, NULL, true); REGISTER_RPC(client, "ADM_set_io_resources", ADM_set_io_resources_in_t, ADM_set_io_resources_out_t, NULL, true); REGISTER_RPC(client, "ADM_get_transfer_priority", ADM_get_transfer_priority_in_t, ADM_get_transfer_priority_out_t, NULL, true); REGISTER_RPC(client, "ADM_set_transfer_priority", ADM_set_transfer_priority_in_t, ADM_set_transfer_priority_out_t, NULL, true); REGISTER_RPC(client, "ADM_cancel_transfer", ADM_cancel_transfer_in_t, ADM_cancel_transfer_out_t, NULL, true); REGISTER_RPC(client, "ADM_get_pending_transfers", ADM_get_pending_transfers_in_t, ADM_get_pending_transfers_out_t, NULL, true); REGISTER_RPC(client, "ADM_set_qos_constraints", ADM_set_qos_constraints_in_t, ADM_set_qos_constraints_out_t, NULL, true); REGISTER_RPC(client, "ADM_get_qos_constraints", ADM_get_qos_constraints_in_t, ADM_get_qos_constraints_out_t, NULL, true); REGISTER_RPC(client, "ADM_define_data_operation", ADM_define_data_operation_in_t, ADM_define_data_operation_out_t, NULL, true); REGISTER_RPC(client, "ADM_connect_data_operation", ADM_connect_data_operation_in_t, ADM_connect_data_operation_out_t, NULL, true); REGISTER_RPC(client, "ADM_finalize_data_operation", ADM_finalize_data_operation_in_t, ADM_finalize_data_operation_out_t, NULL, true); REGISTER_RPC(client, "ADM_link_transfer_to_data_operation", ADM_link_transfer_to_data_operation_in_t, ADM_link_transfer_to_data_operation_out_t, NULL, true); REGISTER_RPC(client, "ADM_get_statistics", ADM_get_statistics_in_t, ADM_get_statistics_out_t, NULL, true); } #endif namespace api { struct remote_procedure { Loading src/scord/rpc_handlers.cpp +0 −1282 File changed.Preview size limit exceeded, changes collapsed. Show changes src/scord/rpc_handlers.hpp +1 −94 Original line number Diff line number Diff line Loading @@ -25,6 +25,7 @@ #ifndef SCORD_RPC_HANDLERS_HPP #define SCORD_RPC_HANDLERS_HPP #include <net/request.hpp> #include <net/serialization.hpp> #include <admire_types.hpp> Loading Loading @@ -81,98 +82,4 @@ transfer_datasets(const request& req, admire::job_id job_id, } // namespace scord::network::handlers #include <margo.h> #ifdef __cplusplus extern "C" { #endif // FIXME: cannot be in a namespace due to Margo limitations // namespace scord::network::rpc { /// ADM_input DECLARE_MARGO_RPC_HANDLER(ADM_input); /// ADM_output DECLARE_MARGO_RPC_HANDLER(ADM_output); /// ADM_inout DECLARE_MARGO_RPC_HANDLER(ADM_inout); /// ADM_adhoc_context DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_context); /// ADM_adhoc_context_id DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_context_id); /// ADM_adhoc_nodes DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_nodes) /// ADM_adhoc_walltime DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_walltime); /// ADM_adhoc_access DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_access); /// ADM_adhoc_distribution DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_distribution); /// ADM_adhoc_background_flush DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_background_flush); /// ADM_in_situ_ops DECLARE_MARGO_RPC_HANDLER(ADM_in_situ_ops); /// ADM_in_transit_ops DECLARE_MARGO_RPC_HANDLER(ADM_in_transit_ops); /// ADM_set_dataset_information DECLARE_MARGO_RPC_HANDLER(ADM_set_dataset_information); /// ADM_set_io_resources DECLARE_MARGO_RPC_HANDLER(ADM_set_io_resources); /// ADM_get_transfer_priority DECLARE_MARGO_RPC_HANDLER(ADM_get_transfer_priority); /// ADM_set_transfer_priority DECLARE_MARGO_RPC_HANDLER(ADM_set_transfer_priority); /// ADM_cancel_transfer DECLARE_MARGO_RPC_HANDLER(ADM_cancel_transfer); /// ADM_get_pending_transfers DECLARE_MARGO_RPC_HANDLER(ADM_get_pending_transfers); /// ADM_set_qos_constraints DECLARE_MARGO_RPC_HANDLER(ADM_set_qos_constraints); /// ADM_get_qos_constraints DECLARE_MARGO_RPC_HANDLER(ADM_get_qos_constraints); /// ADM_define_data_operation DECLARE_MARGO_RPC_HANDLER(ADM_define_data_operation); /// ADM_connect_data_operation DECLARE_MARGO_RPC_HANDLER(ADM_connect_data_operation); /// ADM_finalize_data_operation DECLARE_MARGO_RPC_HANDLER(ADM_finalize_data_operation); /// ADM_link_transfer_to_data_operation DECLARE_MARGO_RPC_HANDLER(ADM_link_transfer_to_data_operation); /// ADM_get_statistics DECLARE_MARGO_RPC_HANDLER(ADM_get_statistics); //} // namespace scord::network::rpc #ifdef __cplusplus }; #endif #endif // SCORD_RPC_HANDLERS_HPP // clang-format on src/scord/scord.cpp +0 −151 Original line number Diff line number Diff line Loading @@ -33,7 +33,6 @@ #include <version.hpp> #include <net/server.hpp> #include <net/proto/rpc_types.h> #include <config/settings.hpp> #include "rpc_handlers.hpp" #include "env.hpp" Loading Loading @@ -200,156 +199,6 @@ main(int argc, char* argv[]) { #undef EXPAND #if 0 const auto rpc_registration_cb = [](auto&& ctx) { LOGGER_INFO(" * Registering RPCs handlers..."); REGISTER_RPC(ctx, "ADM_ping", void, ADM_ping_out_t, ADM_ping, true); REGISTER_RPC(ctx, "ADM_register_job", ADM_register_job_in_t, ADM_register_job_out_t, ADM_register_job, true); REGISTER_RPC(ctx, "ADM_update_job", ADM_update_job_in_t, ADM_update_job_out_t, ADM_update_job, true); REGISTER_RPC(ctx, "ADM_remove_job", ADM_remove_job_in_t, ADM_remove_job_out_t, ADM_remove_job, true); REGISTER_RPC(ctx, "ADM_register_adhoc_storage", ADM_register_adhoc_storage_in_t, ADM_register_adhoc_storage_out_t, ADM_register_adhoc_storage, true); REGISTER_RPC(ctx, "ADM_update_adhoc_storage", ADM_update_adhoc_storage_in_t, ADM_update_adhoc_storage_out_t, ADM_update_adhoc_storage, true); REGISTER_RPC(ctx, "ADM_remove_adhoc_storage", ADM_remove_adhoc_storage_in_t, ADM_remove_adhoc_storage_out_t, ADM_remove_adhoc_storage, true); REGISTER_RPC(ctx, "ADM_deploy_adhoc_storage", ADM_deploy_adhoc_storage_in_t, ADM_deploy_adhoc_storage_out_t, ADM_deploy_adhoc_storage, true); REGISTER_RPC(ctx, "ADM_register_pfs_storage", ADM_register_pfs_storage_in_t, ADM_register_pfs_storage_out_t, ADM_register_pfs_storage, true); REGISTER_RPC( ctx, "ADM_update_pfs_storage", ADM_update_pfs_storage_in_t, ADM_update_pfs_storage_out_t, ADM_update_pfs_storage, true); REGISTER_RPC( ctx, "ADM_remove_pfs_storage", ADM_remove_pfs_storage_in_t, ADM_remove_pfs_storage_out_t, ADM_remove_pfs_storage, true); REGISTER_RPC(ctx, "ADM_input", ADM_input_in_t, ADM_input_out_t, ADM_input, true); REGISTER_RPC(ctx, "ADM_output", ADM_output_in_t, ADM_output_out_t, ADM_output, true); REGISTER_RPC(ctx, "ADM_inout", ADM_inout_in_t, ADM_inout_out_t, ADM_inout, true); REGISTER_RPC(ctx, "ADM_adhoc_context", ADM_adhoc_context_in_t, ADM_adhoc_context_out_t, ADM_adhoc_context, true); REGISTER_RPC(ctx, "ADM_adhoc_context_id", ADM_adhoc_context_id_in_t, ADM_adhoc_context_id_out_t, ADM_adhoc_context_id, true); REGISTER_RPC(ctx, "ADM_adhoc_nodes", ADM_adhoc_nodes_in_t, ADM_adhoc_nodes_out_t, ADM_adhoc_nodes, true); REGISTER_RPC(ctx, "ADM_adhoc_walltime", ADM_adhoc_walltime_in_t, ADM_adhoc_walltime_out_t, ADM_adhoc_walltime, true); REGISTER_RPC(ctx, "ADM_adhoc_access", ADM_adhoc_access_in_t, ADM_adhoc_access_out_t, ADM_adhoc_access, true); REGISTER_RPC( ctx, "ADM_adhoc_distribution", ADM_adhoc_distribution_in_t, ADM_adhoc_distribution_out_t, ADM_adhoc_distribution, true); REGISTER_RPC(ctx, "ADM_adhoc_background_flush", ADM_adhoc_background_flush_in_t, ADM_adhoc_background_flush_out_t, ADM_adhoc_background_flush, true); REGISTER_RPC(ctx, "ADM_in_situ_ops", ADM_in_situ_ops_in_t, ADM_in_situ_ops_out_t, ADM_in_situ_ops, true); REGISTER_RPC(ctx, "ADM_in_transit_ops", ADM_in_transit_ops_in_t, ADM_in_transit_ops_out_t, ADM_in_transit_ops, true); REGISTER_RPC( ctx, "ADM_transfer_datasets", ADM_transfer_datasets_in_t, ADM_transfer_datasets_out_t, ADM_transfer_datasets, true); REGISTER_RPC(ctx, "ADM_set_dataset_information", ADM_set_dataset_information_in_t, ADM_set_dataset_information_out_t, ADM_set_dataset_information, true); REGISTER_RPC(ctx, "ADM_set_io_resources", ADM_set_io_resources_in_t, ADM_set_io_resources_out_t, ADM_set_io_resources, true); REGISTER_RPC(ctx, "ADM_get_transfer_priority", ADM_get_transfer_priority_in_t, ADM_get_transfer_priority_out_t, ADM_get_transfer_priority, true); REGISTER_RPC(ctx, "ADM_set_transfer_priority", ADM_set_transfer_priority_in_t, ADM_set_transfer_priority_out_t, ADM_set_transfer_priority, true); REGISTER_RPC(ctx, "ADM_cancel_transfer", ADM_cancel_transfer_in_t, ADM_cancel_transfer_out_t, ADM_cancel_transfer, true); REGISTER_RPC(ctx, "ADM_get_pending_transfers", ADM_get_pending_transfers_in_t, ADM_get_pending_transfers_out_t, ADM_get_pending_transfers, true); REGISTER_RPC(ctx, "ADM_set_qos_constraints", ADM_set_qos_constraints_in_t, ADM_set_qos_constraints_out_t, ADM_set_qos_constraints, true); REGISTER_RPC(ctx, "ADM_get_qos_constraints", ADM_get_qos_constraints_in_t, ADM_get_qos_constraints_out_t, ADM_get_qos_constraints, true); REGISTER_RPC(ctx, "ADM_define_data_operation", ADM_define_data_operation_in_t, ADM_define_data_operation_out_t, ADM_define_data_operation, true); REGISTER_RPC(ctx, "ADM_connect_data_operation", ADM_connect_data_operation_in_t, ADM_connect_data_operation_out_t, ADM_connect_data_operation, true); REGISTER_RPC(ctx, "ADM_finalize_data_operation", ADM_finalize_data_operation_in_t, ADM_finalize_data_operation_out_t, ADM_finalize_data_operation, true); REGISTER_RPC(ctx, "ADM_link_transfer_to_data_operation", ADM_link_transfer_to_data_operation_in_t, ADM_link_transfer_to_data_operation_out_t, ADM_link_transfer_to_data_operation, true); REGISTER_RPC(ctx, "ADM_get_statistics", ADM_get_statistics_in_t, ADM_get_statistics_out_t, ADM_get_statistics, true); // TODO: add internal RPCs for communication with scord-ctl }; #endif return daemon.run(); } catch(const std::exception& ex) { fmt::print(stderr, Loading Loading
src/common/api/types.cpp +0 −5 Original line number Diff line number Diff line Loading @@ -26,13 +26,8 @@ #include <net/proto/rpc_types.h> #include <net/serialization.hpp> #include <utility> #include <utils/ctype_ptr.hpp> #include <cstdarg> #include <api/convert.hpp> #include <variant> #include <optional> #include <cereal/types/memory.hpp> #include <thallium/serialization/proc_input_archive.hpp> #include "admire_types.hpp" #include "internal_types.hpp" Loading
src/lib/detail/impl.cpp +0 −129 Original line number Diff line number Diff line Loading @@ -27,140 +27,11 @@ #include <net/endpoint.hpp> #include <net/request.hpp> #include <net/serialization.hpp> #include <net/proto/rpc_types.h> #include <api/convert.hpp> #include <admire_types.hpp> #include "impl.hpp" using namespace std::literals; #if 0 void rpc_registration_cb(scord::network::rpc_client* client) { REGISTER_RPC(client, "ADM_ping", void, ADM_ping_out_t, NULL, true); REGISTER_RPC(client, "ADM_register_job", ADM_register_job_in_t, ADM_register_job_out_t, NULL, true); REGISTER_RPC(client, "ADM_update_job", ADM_update_job_in_t, ADM_update_job_out_t, NULL, true); REGISTER_RPC(client, "ADM_remove_job", ADM_remove_job_in_t, ADM_remove_job_out_t, NULL, true); REGISTER_RPC(client, "ADM_register_adhoc_storage", ADM_register_adhoc_storage_in_t, ADM_register_adhoc_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_update_adhoc_storage", ADM_update_adhoc_storage_in_t, ADM_update_adhoc_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_remove_adhoc_storage", ADM_remove_adhoc_storage_in_t, ADM_remove_adhoc_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_deploy_adhoc_storage", ADM_deploy_adhoc_storage_in_t, ADM_deploy_adhoc_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_register_pfs_storage", ADM_register_pfs_storage_in_t, ADM_register_pfs_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_update_pfs_storage", ADM_update_pfs_storage_in_t, ADM_update_pfs_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_remove_pfs_storage", ADM_remove_pfs_storage_in_t, ADM_remove_pfs_storage_out_t, NULL, true); REGISTER_RPC(client, "ADM_input", ADM_input_in_t, ADM_input_out_t, NULL, true); REGISTER_RPC(client, "ADM_output", ADM_output_in_t, ADM_output_out_t, NULL, true); REGISTER_RPC(client, "ADM_inout", ADM_inout_in_t, ADM_inout_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_context", ADM_adhoc_context_in_t, ADM_adhoc_context_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_context_id", ADM_adhoc_context_id_in_t, ADM_adhoc_context_id_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_nodes", ADM_adhoc_nodes_in_t, ADM_adhoc_nodes_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_walltime", ADM_adhoc_walltime_in_t, ADM_adhoc_walltime_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_access", ADM_adhoc_access_in_t, ADM_adhoc_access_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_distribution", ADM_adhoc_distribution_in_t, ADM_adhoc_distribution_out_t, NULL, true); REGISTER_RPC(client, "ADM_adhoc_background_flush", ADM_adhoc_background_flush_in_t, ADM_adhoc_background_flush_out_t, NULL, true); REGISTER_RPC(client, "ADM_in_situ_ops", ADM_in_situ_ops_in_t, ADM_in_situ_ops_out_t, NULL, true); REGISTER_RPC(client, "ADM_in_transit_ops", ADM_in_transit_ops_in_t, ADM_in_transit_ops_out_t, NULL, true); REGISTER_RPC(client, "ADM_transfer_datasets", ADM_transfer_datasets_in_t, ADM_transfer_datasets_out_t, NULL, true); REGISTER_RPC(client, "ADM_set_dataset_information", ADM_set_dataset_information_in_t, ADM_set_dataset_information_out_t, NULL, true); REGISTER_RPC(client, "ADM_set_io_resources", ADM_set_io_resources_in_t, ADM_set_io_resources_out_t, NULL, true); REGISTER_RPC(client, "ADM_get_transfer_priority", ADM_get_transfer_priority_in_t, ADM_get_transfer_priority_out_t, NULL, true); REGISTER_RPC(client, "ADM_set_transfer_priority", ADM_set_transfer_priority_in_t, ADM_set_transfer_priority_out_t, NULL, true); REGISTER_RPC(client, "ADM_cancel_transfer", ADM_cancel_transfer_in_t, ADM_cancel_transfer_out_t, NULL, true); REGISTER_RPC(client, "ADM_get_pending_transfers", ADM_get_pending_transfers_in_t, ADM_get_pending_transfers_out_t, NULL, true); REGISTER_RPC(client, "ADM_set_qos_constraints", ADM_set_qos_constraints_in_t, ADM_set_qos_constraints_out_t, NULL, true); REGISTER_RPC(client, "ADM_get_qos_constraints", ADM_get_qos_constraints_in_t, ADM_get_qos_constraints_out_t, NULL, true); REGISTER_RPC(client, "ADM_define_data_operation", ADM_define_data_operation_in_t, ADM_define_data_operation_out_t, NULL, true); REGISTER_RPC(client, "ADM_connect_data_operation", ADM_connect_data_operation_in_t, ADM_connect_data_operation_out_t, NULL, true); REGISTER_RPC(client, "ADM_finalize_data_operation", ADM_finalize_data_operation_in_t, ADM_finalize_data_operation_out_t, NULL, true); REGISTER_RPC(client, "ADM_link_transfer_to_data_operation", ADM_link_transfer_to_data_operation_in_t, ADM_link_transfer_to_data_operation_out_t, NULL, true); REGISTER_RPC(client, "ADM_get_statistics", ADM_get_statistics_in_t, ADM_get_statistics_out_t, NULL, true); } #endif namespace api { struct remote_procedure { Loading
src/scord/rpc_handlers.cpp +0 −1282 File changed.Preview size limit exceeded, changes collapsed. Show changes
src/scord/rpc_handlers.hpp +1 −94 Original line number Diff line number Diff line Loading @@ -25,6 +25,7 @@ #ifndef SCORD_RPC_HANDLERS_HPP #define SCORD_RPC_HANDLERS_HPP #include <net/request.hpp> #include <net/serialization.hpp> #include <admire_types.hpp> Loading Loading @@ -81,98 +82,4 @@ transfer_datasets(const request& req, admire::job_id job_id, } // namespace scord::network::handlers #include <margo.h> #ifdef __cplusplus extern "C" { #endif // FIXME: cannot be in a namespace due to Margo limitations // namespace scord::network::rpc { /// ADM_input DECLARE_MARGO_RPC_HANDLER(ADM_input); /// ADM_output DECLARE_MARGO_RPC_HANDLER(ADM_output); /// ADM_inout DECLARE_MARGO_RPC_HANDLER(ADM_inout); /// ADM_adhoc_context DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_context); /// ADM_adhoc_context_id DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_context_id); /// ADM_adhoc_nodes DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_nodes) /// ADM_adhoc_walltime DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_walltime); /// ADM_adhoc_access DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_access); /// ADM_adhoc_distribution DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_distribution); /// ADM_adhoc_background_flush DECLARE_MARGO_RPC_HANDLER(ADM_adhoc_background_flush); /// ADM_in_situ_ops DECLARE_MARGO_RPC_HANDLER(ADM_in_situ_ops); /// ADM_in_transit_ops DECLARE_MARGO_RPC_HANDLER(ADM_in_transit_ops); /// ADM_set_dataset_information DECLARE_MARGO_RPC_HANDLER(ADM_set_dataset_information); /// ADM_set_io_resources DECLARE_MARGO_RPC_HANDLER(ADM_set_io_resources); /// ADM_get_transfer_priority DECLARE_MARGO_RPC_HANDLER(ADM_get_transfer_priority); /// ADM_set_transfer_priority DECLARE_MARGO_RPC_HANDLER(ADM_set_transfer_priority); /// ADM_cancel_transfer DECLARE_MARGO_RPC_HANDLER(ADM_cancel_transfer); /// ADM_get_pending_transfers DECLARE_MARGO_RPC_HANDLER(ADM_get_pending_transfers); /// ADM_set_qos_constraints DECLARE_MARGO_RPC_HANDLER(ADM_set_qos_constraints); /// ADM_get_qos_constraints DECLARE_MARGO_RPC_HANDLER(ADM_get_qos_constraints); /// ADM_define_data_operation DECLARE_MARGO_RPC_HANDLER(ADM_define_data_operation); /// ADM_connect_data_operation DECLARE_MARGO_RPC_HANDLER(ADM_connect_data_operation); /// ADM_finalize_data_operation DECLARE_MARGO_RPC_HANDLER(ADM_finalize_data_operation); /// ADM_link_transfer_to_data_operation DECLARE_MARGO_RPC_HANDLER(ADM_link_transfer_to_data_operation); /// ADM_get_statistics DECLARE_MARGO_RPC_HANDLER(ADM_get_statistics); //} // namespace scord::network::rpc #ifdef __cplusplus }; #endif #endif // SCORD_RPC_HANDLERS_HPP // clang-format on
src/scord/scord.cpp +0 −151 Original line number Diff line number Diff line Loading @@ -33,7 +33,6 @@ #include <version.hpp> #include <net/server.hpp> #include <net/proto/rpc_types.h> #include <config/settings.hpp> #include "rpc_handlers.hpp" #include "env.hpp" Loading Loading @@ -200,156 +199,6 @@ main(int argc, char* argv[]) { #undef EXPAND #if 0 const auto rpc_registration_cb = [](auto&& ctx) { LOGGER_INFO(" * Registering RPCs handlers..."); REGISTER_RPC(ctx, "ADM_ping", void, ADM_ping_out_t, ADM_ping, true); REGISTER_RPC(ctx, "ADM_register_job", ADM_register_job_in_t, ADM_register_job_out_t, ADM_register_job, true); REGISTER_RPC(ctx, "ADM_update_job", ADM_update_job_in_t, ADM_update_job_out_t, ADM_update_job, true); REGISTER_RPC(ctx, "ADM_remove_job", ADM_remove_job_in_t, ADM_remove_job_out_t, ADM_remove_job, true); REGISTER_RPC(ctx, "ADM_register_adhoc_storage", ADM_register_adhoc_storage_in_t, ADM_register_adhoc_storage_out_t, ADM_register_adhoc_storage, true); REGISTER_RPC(ctx, "ADM_update_adhoc_storage", ADM_update_adhoc_storage_in_t, ADM_update_adhoc_storage_out_t, ADM_update_adhoc_storage, true); REGISTER_RPC(ctx, "ADM_remove_adhoc_storage", ADM_remove_adhoc_storage_in_t, ADM_remove_adhoc_storage_out_t, ADM_remove_adhoc_storage, true); REGISTER_RPC(ctx, "ADM_deploy_adhoc_storage", ADM_deploy_adhoc_storage_in_t, ADM_deploy_adhoc_storage_out_t, ADM_deploy_adhoc_storage, true); REGISTER_RPC(ctx, "ADM_register_pfs_storage", ADM_register_pfs_storage_in_t, ADM_register_pfs_storage_out_t, ADM_register_pfs_storage, true); REGISTER_RPC( ctx, "ADM_update_pfs_storage", ADM_update_pfs_storage_in_t, ADM_update_pfs_storage_out_t, ADM_update_pfs_storage, true); REGISTER_RPC( ctx, "ADM_remove_pfs_storage", ADM_remove_pfs_storage_in_t, ADM_remove_pfs_storage_out_t, ADM_remove_pfs_storage, true); REGISTER_RPC(ctx, "ADM_input", ADM_input_in_t, ADM_input_out_t, ADM_input, true); REGISTER_RPC(ctx, "ADM_output", ADM_output_in_t, ADM_output_out_t, ADM_output, true); REGISTER_RPC(ctx, "ADM_inout", ADM_inout_in_t, ADM_inout_out_t, ADM_inout, true); REGISTER_RPC(ctx, "ADM_adhoc_context", ADM_adhoc_context_in_t, ADM_adhoc_context_out_t, ADM_adhoc_context, true); REGISTER_RPC(ctx, "ADM_adhoc_context_id", ADM_adhoc_context_id_in_t, ADM_adhoc_context_id_out_t, ADM_adhoc_context_id, true); REGISTER_RPC(ctx, "ADM_adhoc_nodes", ADM_adhoc_nodes_in_t, ADM_adhoc_nodes_out_t, ADM_adhoc_nodes, true); REGISTER_RPC(ctx, "ADM_adhoc_walltime", ADM_adhoc_walltime_in_t, ADM_adhoc_walltime_out_t, ADM_adhoc_walltime, true); REGISTER_RPC(ctx, "ADM_adhoc_access", ADM_adhoc_access_in_t, ADM_adhoc_access_out_t, ADM_adhoc_access, true); REGISTER_RPC( ctx, "ADM_adhoc_distribution", ADM_adhoc_distribution_in_t, ADM_adhoc_distribution_out_t, ADM_adhoc_distribution, true); REGISTER_RPC(ctx, "ADM_adhoc_background_flush", ADM_adhoc_background_flush_in_t, ADM_adhoc_background_flush_out_t, ADM_adhoc_background_flush, true); REGISTER_RPC(ctx, "ADM_in_situ_ops", ADM_in_situ_ops_in_t, ADM_in_situ_ops_out_t, ADM_in_situ_ops, true); REGISTER_RPC(ctx, "ADM_in_transit_ops", ADM_in_transit_ops_in_t, ADM_in_transit_ops_out_t, ADM_in_transit_ops, true); REGISTER_RPC( ctx, "ADM_transfer_datasets", ADM_transfer_datasets_in_t, ADM_transfer_datasets_out_t, ADM_transfer_datasets, true); REGISTER_RPC(ctx, "ADM_set_dataset_information", ADM_set_dataset_information_in_t, ADM_set_dataset_information_out_t, ADM_set_dataset_information, true); REGISTER_RPC(ctx, "ADM_set_io_resources", ADM_set_io_resources_in_t, ADM_set_io_resources_out_t, ADM_set_io_resources, true); REGISTER_RPC(ctx, "ADM_get_transfer_priority", ADM_get_transfer_priority_in_t, ADM_get_transfer_priority_out_t, ADM_get_transfer_priority, true); REGISTER_RPC(ctx, "ADM_set_transfer_priority", ADM_set_transfer_priority_in_t, ADM_set_transfer_priority_out_t, ADM_set_transfer_priority, true); REGISTER_RPC(ctx, "ADM_cancel_transfer", ADM_cancel_transfer_in_t, ADM_cancel_transfer_out_t, ADM_cancel_transfer, true); REGISTER_RPC(ctx, "ADM_get_pending_transfers", ADM_get_pending_transfers_in_t, ADM_get_pending_transfers_out_t, ADM_get_pending_transfers, true); REGISTER_RPC(ctx, "ADM_set_qos_constraints", ADM_set_qos_constraints_in_t, ADM_set_qos_constraints_out_t, ADM_set_qos_constraints, true); REGISTER_RPC(ctx, "ADM_get_qos_constraints", ADM_get_qos_constraints_in_t, ADM_get_qos_constraints_out_t, ADM_get_qos_constraints, true); REGISTER_RPC(ctx, "ADM_define_data_operation", ADM_define_data_operation_in_t, ADM_define_data_operation_out_t, ADM_define_data_operation, true); REGISTER_RPC(ctx, "ADM_connect_data_operation", ADM_connect_data_operation_in_t, ADM_connect_data_operation_out_t, ADM_connect_data_operation, true); REGISTER_RPC(ctx, "ADM_finalize_data_operation", ADM_finalize_data_operation_in_t, ADM_finalize_data_operation_out_t, ADM_finalize_data_operation, true); REGISTER_RPC(ctx, "ADM_link_transfer_to_data_operation", ADM_link_transfer_to_data_operation_in_t, ADM_link_transfer_to_data_operation_out_t, ADM_link_transfer_to_data_operation, true); REGISTER_RPC(ctx, "ADM_get_statistics", ADM_get_statistics_in_t, ADM_get_statistics_out_t, ADM_get_statistics, true); // TODO: add internal RPCs for communication with scord-ctl }; #endif return daemon.run(); } catch(const std::exception& ex) { fmt::print(stderr, Loading