| 763 | } |
| 764 | |
| 765 | bool endpoint_manager_impl::create_routing_root(std::shared_ptr<local_server>& _root, const transport_protocol_e& _type, |
| 766 | bool& _is_socket_activated, const std::shared_ptr<routing_host>& _host) { |
| 767 | |
| 768 | std::stringstream its_endpoint_path_ss; |
| 769 | its_endpoint_path_ss << utility::get_base_path(configuration_->get_network()) << VSOMEIP_ROUTING_CLIENT; |
| 770 | const std::string its_endpoint_path = its_endpoint_path_ss.str(); |
| 771 | |
| 772 | std::shared_ptr<local_acceptor> acceptor; |
| 773 | |
| 774 | VSOMEIP_INFO << "Creating routing root with transport protocol: " << (_type == transport_protocol_e::UDS ? "UDS" : "TCP"); |
| 775 | |
| 776 | if (configuration_->is_local_routing() || (is_uds_preferred_ && _type == transport_protocol_e::UDS)) { |
| 777 | #if defined(__linux__) || defined(__QNX__) |
| 778 | if (!create_local_uds_acceptor(acceptor, its_endpoint_path, _is_socket_activated)) { |
| 779 | return false; |
| 780 | } |
| 781 | #else |
| 782 | if (!create_fallback_tcp_acceptor(acceptor)) { |
| 783 | return false; |
| 784 | } |
| 785 | _is_socket_activated = false; |
| 786 | #endif // __linux__ || __QNX__ |
| 787 | } else { |
| 788 | if (!create_local_tcp_acceptor(acceptor)) { |
| 789 | return false; |
| 790 | } |
| 791 | _is_socket_activated = false; |
| 792 | } |
| 793 | |
| 794 | setup_root_server(_root, acceptor, _host); |
| 795 | return true; |
| 796 | } |
| 797 | |
| 798 | instance_t endpoint_manager_impl::find_instance(service_t _service, boardnet_endpoint* const _endpoint) const { |
| 799 | instance_t its_instance(0xFFFF); |
no test coverage detected