diff --git a/examples/workflow_api/basic-examples/bare-metal-bag-of-tasks-programmatic-platform/BareMetalBagOfTasksProgrammaticPlatform.cpp b/examples/workflow_api/basic-examples/bare-metal-bag-of-tasks-programmatic-platform/BareMetalBagOfTasksProgrammaticPlatform.cpp index 6998ccec5e..2716d15e28 100755 --- a/examples/workflow_api/basic-examples/bare-metal-bag-of-tasks-programmatic-platform/BareMetalBagOfTasksProgrammaticPlatform.cpp +++ b/examples/workflow_api/basic-examples/bare-metal-bag-of-tasks-programmatic-platform/BareMetalBagOfTasksProgrammaticPlatform.cpp @@ -85,26 +85,20 @@ class PlatformCreator { // Add routes { sg4::LinkInRoute network_link_in_route{network_link}; - zone->add_route(compute_host->get_netpoint(), - wms_host->get_netpoint(), - nullptr, - nullptr, + zone->add_route(compute_host, + wms_host, {network_link_in_route}); } { sg4::LinkInRoute network_link_in_route{loopback_WMSHost}; - zone->add_route(wms_host->get_netpoint(), - wms_host->get_netpoint(), - nullptr, - nullptr, + zone->add_route(wms_host, + wms_host, {network_link_in_route}); } { sg4::LinkInRoute network_link_in_route{loopback_ComputeHost}; - zone->add_route(compute_host->get_netpoint(), - compute_host->get_netpoint(), - nullptr, - nullptr, + zone->add_route(compute_host, + compute_host, {network_link_in_route}); } diff --git a/src/wrench/simgrid_S4U_util/S4U_PendingCommunication.cpp b/src/wrench/simgrid_S4U_util/S4U_PendingCommunication.cpp index 104c070302..465d570960 100755 --- a/src/wrench/simgrid_S4U_util/S4U_PendingCommunication.cpp +++ b/src/wrench/simgrid_S4U_util/S4U_PendingCommunication.cpp @@ -112,10 +112,8 @@ namespace wrench { if (finished_recv == comm_ptr) { mess_ptr->cancel(); -// comm_ptr->wait(); } else if (finished_recv == mess_ptr) { comm_ptr->cancel(); -// mess_ptr->wait(); } #ifdef MESSAGE_MANAGER @@ -129,7 +127,6 @@ namespace wrench { if (this->comm_ptr) { try { this->comm_ptr->wait_for(timeout); - return nullptr; } catch (simgrid::NetworkFailureException &e) { if (this->operation_type == S4U_PendingCommunication::OperationType::SENDING) { throw ExecutionException(std::make_shared( @@ -149,8 +146,8 @@ namespace wrench { } } else if (this->mess_ptr) { this->mess_ptr->wait_for(timeout); - return nullptr; } + return nullptr; } } diff --git a/test/services/storage_services/StorageServiceProxy/StorageServiceProxyBasicTest.cpp b/test/services/storage_services/StorageServiceProxy/StorageServiceProxyBasicTest.cpp index c1146472ee..7120eb7eb7 100755 --- a/test/services/storage_services/StorageServiceProxy/StorageServiceProxyBasicTest.cpp +++ b/test/services/storage_services/StorageServiceProxy/StorageServiceProxyBasicTest.cpp @@ -274,35 +274,27 @@ void StorageServiceProxyBasicTest::do_BasicFunctionality_test(bool arg, std::str { - simgrid::s4u::Engine::get_instance()->netzone_by_name_or_null("AS0")->add_route(simgrid::s4u::Host::by_name("Remote")->get_netpoint(), - simgrid::s4u::Host::by_name("Client")->get_netpoint(), - nullptr, - nullptr, + simgrid::s4u::Engine::get_instance()->netzone_by_name_or_null("AS0")->add_route(simgrid::s4u::Host::by_name("Remote"), + simgrid::s4u::Host::by_name("Client"), {simgrid::s4u::LinkInRoute(simgrid::s4u::Link::by_name("link12")), simgrid::s4u::LinkInRoute(simgrid::s4u::Link::by_name("link13"))}); } { - simgrid::s4u::Engine::get_instance()->netzone_by_name_or_null("AS0")->add_route(simgrid::s4u::Host::by_name("Target")->get_netpoint(), - simgrid::s4u::Host::by_name("Client")->get_netpoint(), - nullptr, - nullptr, + simgrid::s4u::Engine::get_instance()->netzone_by_name_or_null("AS0")->add_route(simgrid::s4u::Host::by_name("Target"), + simgrid::s4u::Host::by_name("Client"), {simgrid::s4u::LinkInRoute(simgrid::s4u::Link::by_name("link12")), simgrid::s4u::LinkInRoute(simgrid::s4u::Link::by_name("link23"))}); } } else { { - simgrid::s4u::Engine::get_instance()->netzone_by_name_or_null("AS0")->add_route(simgrid::s4u::Host::by_name("Target")->get_netpoint(), - simgrid::s4u::Host::by_name("Client")->get_netpoint(), - nullptr, - nullptr, + simgrid::s4u::Engine::get_instance()->netzone_by_name_or_null("AS0")->add_route(simgrid::s4u::Host::by_name("Target"), + simgrid::s4u::Host::by_name("Client"), {simgrid::s4u::LinkInRoute(simgrid::s4u::Link::by_name("backdoor"))}); } { - simgrid::s4u::Engine::get_instance()->netzone_by_name_or_null("AS0")->add_route(simgrid::s4u::Host::by_name("Remote")->get_netpoint(), - simgrid::s4u::Host::by_name("Client")->get_netpoint(), - nullptr, - nullptr, + simgrid::s4u::Engine::get_instance()->netzone_by_name_or_null("AS0")->add_route(simgrid::s4u::Host::by_name("Remote"), + simgrid::s4u::Host::by_name("Client"), {simgrid::s4u::LinkInRoute(simgrid::s4u::Link::by_name("backdoor"))}); } } diff --git a/test/simulation/S4U_SimulationTest.cpp b/test/simulation/S4U_SimulationTest.cpp index 34e932a776..27c72420df 100755 --- a/test/simulation/S4U_SimulationTest.cpp +++ b/test/simulation/S4U_SimulationTest.cpp @@ -311,6 +311,7 @@ void S4U_SimulationTest::do_basicAPI_Test() { simulation->init(&argc, argv); + // Setting up the platform ASSERT_NO_THROW(simulation->instantiatePlatform(platform_file_path));