Updated README and example
Moves connection closing to finally