replace rpc with servlet