29 worker_guard_{boost::asio::make_work_guard(io_context_.get_executor())},
30 ssl_context_{boost::asio::ssl::context::tlsv13_client}
33 ssl_context_.set_verify_mode(boost::asio::ssl::verify_peer);
52 const kHttpRequestMethod http_method,
const std::string & path,
const std::string & body,
53 const std::unordered_map<std::string, std::string> & headers)
55 auto path_used = path;
58 std::reverse(path_used.begin(), path_used.end());
60 std::reverse(path_used.begin(), path_used.end());
65 RCLCPP_INFO(this->
getLogger(),
"Path %s", path_used.c_str());
68 std::shared_ptr<http_session_base> http_session_ptr;
72 http_session_ptr = std::make_shared<ssl_http_session>(
81 http_session_ptr->setBody(body);
82 http_session_ptr->setHeaders(headers);
83 http_session_ptr->run(
void makeRequest(const kHttpRequestMethod http_method, const std::string &path="/", const std::string &body="", const std::unordered_map< std::string, std::string > &headers={})