update socket commnunication