I have some pretty old Web service, online for years now. Now I decide to put some rudimental POST function(s) to the same service. I know how to do that, thanks to SOAP example from xFiles (of course). Now, my question is: when I use AsyncOpenUse (net.AsyncOpenUse (net.AsyncOpenUse = 1), the service
did not "catch" any data that I send ?!?. However, if AsyncOpenUse is off, all works well. But, if AsyncOpenUse is off and server-service is also off, the client must wait about 1,5-2 seconds to abort sending of data. This means for every single request to the server, when server is offline, delay to abort is way too long.
How to speed up aborting of sending data to offline server?
Clarion 10, Nettalk 7.40
Code example with AsyncOpenUse = 1, that is no-go version:
net.HeaderOnly = 1 ! Cijelu stranu, dodano novo
net.SetAllHeadersDefault()
net.Pragma_ = 'No-Cache'
net.CacheControl = 'No-Cache'
net.ContentType = 'text/xml' !
net.ContentLength = len(clip(PostString)) !
net.AsyncOpenTimeOut = 300
net.InActiveTimeout = 1200
net.CanUseProxy = 1
net.ConnectionKeepAlive = 0
net.AcceptEncoding = 'win-1250'
net.ContentLength = Len(Clip(PostString))
PacketSent = PostString
PutanjaSOAP = 'http://' &clip(MPB:OPIS9)&clip(':')& Clip(Left(Format(MPB:DATUM3,@n_5))) & '/getInfo'
net.Post(Clip(PutanjaSOAP) , Clip(PostString))