开发者

msxml XMLHTTPRequest and timeout

开发者 https://www.devze.com 2022-12-22 12:09 出处:网络
what determins the timeout value for XMLHTTPRequest (msxml version) send method? I\'m calling it from MS Sql server and the server profiler shows me \'completed\' after 30 seconds, the same ha开发者_S

what determins the timeout value for XMLHTTPRequest (msxml version) send method? I'm calling it from MS Sql server and the server profiler shows me 'completed' after 30 seconds, the same ha开发者_StackOverflow中文版ppens when calling it through client programm calling stored proc. I set the client connection timeout to 120 sec. So im thinking it must be msxml that cancels send method after 30 secs. Any ideas?


Im suprised noone could/wanted to answer me but anyway i figured it out. When XMLHTTPRequest makes post the default timeout is 30 seconds. It can be modified setting the property 'setTimeouts'. In my case i did it in sql stored proc so:

EXEC sp_OASetProperty @objectID, 'setTimeouts',resolveTimeout,connectTimeout,sendTimeout,receiveTimeout

EXEC sp_OASetProperty @objectID, 'setTimeouts','120000','120000','120000','120000'

where @objectID is id from creating the MSXML2.ServerXMLHTTP object.

0

精彩评论

暂无评论...
验证码 换一张
取 消