vsomeip icon indicating copy to clipboard operation
vsomeip copied to clipboard

Never restart stopped TCE

Open joeyoravec opened this issue 1 year ago • 0 comments

Around suspend-to-ram it's likely that SOMEIP-SD and TCP sockets will be impacted by clocks jumping. In case:

  • SOMEIP-SD timeout is detected
  • clear_client_endpoints clears everything and stops the TCE endpoint
  • new OFFER is received

then there's a race condition where:

  • add_routing_info ends up creating a new endpoint
  • old (stopped) endpoint calls restart which clears sending_blocked_
  • new endpoint calls start

and may result in two connected endpoints, depending on execution order. In order to avoid this, never restart a stopped endpoint.

joeyoravec avatar Oct 30 '24 23:10 joeyoravec