Add socket management.