Better connection management