Synchronization of connection.get()

to avoid sum cuncurency problems