請問一下,客戶端在調用一個遠程對象的函數時,怎樣設置其超時時間?也就是說,如果遠程對象操作時間過長,客戶端不準備等待,它該怎么辦? 就象是連接數據庫超時一樣,它總得有一個超時的時間吧,請教客戶端該怎樣設置其超時時間? 我知道通過編程的方式可以 Hashtable props = new Hashtable(); props["name"] = "tcp_rem"; props["timeout"] = 3000;//設置超時時間 TcpChannel _tcpChannel = new TcpChannel(props, null, null); ChannelServices.RegisterChannel(_tcpChannel, false); 哪么通過配置文件,如何設置timeout?
- 1 回答
- 0 關注
- 841 瀏覽
添加回答
舉報
0/150
提交
取消