Hi!
First, great job with this gem, it helped us a lot!
After the merge of #175 , it is possible to use the shutdown method to close the connections, but what about having a method where it is possible to pass a block which will close the connection after yield it?
Example:
client.closing_connection do
client.logical.read('something')
client.login.write('something')
end
The implementation would be like this:
def closing_connection
yield
ensure
shutdown
end
The code is not 100% correct, it is just to show the ideia.
If you agree, I can send a pull request with this.
Thank you!
Hi!
First, great job with this gem, it helped us a lot!
After the merge of #175 , it is possible to use the
shutdownmethod to close the connections, but what about having a method where it is possible to pass a block which will close the connection after yield it?Example:
The implementation would be like this:
The code is not 100% correct, it is just to show the ideia.
If you agree, I can send a pull request with this.
Thank you!