improve ConnectionActor
cleanup
cleanup
fix compile warning