This close function only applies to connection-specific parts and the stream-interface entry may soon disappear. Move this to the connection instead.