93 & #94 added a notion of keep alives to graphql-ws-client. But the implementation caused the connection to drop whenever no messages were received for the specified period. This isn't how I'd usually expect a keep alive to work though - I'd usually expect it to send pings during inactive periods, and only drop the connection if a few of those pings were not replied to.
This PR implements that behaviour instead. It's a slightly breaking change over the earlier implementation, but that was not yet released so that seems fine.
93 & #94 added a notion of keep alives to graphql-ws-client. But the implementation caused the connection to drop whenever no messages were received for the specified period. This isn't how I'd usually expect a keep alive to work though - I'd usually expect it to send pings during inactive periods, and only drop the connection if a few of those pings were not replied to.
This PR implements that behaviour instead. It's a slightly breaking change over the earlier implementation, but that was not yet released so that seems fine.