add some feature for udp

support udp; modify event interface