We’re using ei to create a connection from Swift as an Erlang node to an Erlang (Elixir) app. We’re running into a strange issue where we want to make a synchronous call over Erlang’s rpc but still need to respond to TICK messages coming in to keep the connection alive.
Is there a recommended pattern to do this? We could fire and forget the rpc call then detect the response message in our blocking receive loop but then we loose the benefit of making a synchronous call.
The receive loop will currently sometimes “steal” to response message from our rpc call.