use SocketAgent interface

test on local machine.