| 2201 | } |
| 2202 | |
| 2203 | void routing_manager_impl::on_subscribe_nack(client_t _client, service_t _service, instance_t _instance, eventgroup_t _eventgroup, |
| 2204 | bool _remove, remote_subscription_id_t _id) { |
| 2205 | auto its_eventgroup = find_eventgroup(_service, _instance, _eventgroup); |
| 2206 | if (its_eventgroup) { |
| 2207 | auto its_subscription = its_eventgroup->get_remote_subscription(_id); |
| 2208 | if (its_subscription) { |
| 2209 | its_subscription->set_client_state(_client, remote_subscription_state_e::SUBSCRIPTION_NACKED); |
| 2210 | |
| 2211 | auto its_parent = its_subscription->get_parent(); |
| 2212 | if (its_parent) { |
| 2213 | its_parent->set_client_state(_client, remote_subscription_state_e::SUBSCRIPTION_NACKED); |
| 2214 | if (!its_subscription->is_pending()) { |
| 2215 | its_eventgroup->remove_remote_subscription(_id); |
| 2216 | } |
| 2217 | } |
| 2218 | |
| 2219 | if (discovery_) { |
| 2220 | discovery_->update_remote_subscription(its_subscription); |
| 2221 | VSOMEIP_INFO << "REMOTE SUBSCRIBE(" << hex4(_client) << "): [" << hex4(_service) << "." << hex4(_instance) << "." |
| 2222 | << hex4(_eventgroup) << "] from " << its_subscription->get_subscriber()->get_address() << ":" |
| 2223 | << its_subscription->get_subscriber()->get_port() |
| 2224 | << (its_subscription->get_subscriber()->is_reliable() ? " reliable" : " unreliable") |
| 2225 | << " was not accepted. id=" << hex4(_id); |
| 2226 | } |
| 2227 | if (_remove) |
| 2228 | its_eventgroup->remove_remote_subscription(_id); |
| 2229 | } |
| 2230 | } |
| 2231 | } |
| 2232 | |
| 2233 | return_code_e routing_manager_impl::check_error(const byte_t* _data, length_t /*_size*/, instance_t _instance) const { |
| 2234 |
no test coverage detected