document precise behavior and error handling
close bad connections