Bill
<MvASSIGN NAME="l.calltimeout_value" VALUE="90">
<MvASSIGN NAME="l.now" VALUE="{s.dyn_time_t}">
<MvCALL ACTION="URL"
METHOD="POST|GET"
FIELDS="var1,var2,var3,...">
....SOME CODE HERE...
<MvIF EXPR="{(s.dyn_time_t - l.now) GT (l.calltimeout_value-10)}">
(There's 10 or less seconds left before timeout occurs)
</MvIF>
</MvCALL>
HTH,
Bill M.
Just a guess mind you...
"MvCALL takes a new attribute "TIMEOUT". This value is used if it is
smaller than the configured MvCONFIG_CALL_TIMEOUT value."
It sounds like they're trying to give you a chance to clean things up,
and/or report that the call failed before the call triggers a script
timeout (based on the fact that it's only used if shorter than the
config timeout).
What I don't see, is an obvious way to be sure that the call
completed. I suppose you could look for a closing </html> tag, and
assign l.done to 1 when you see it. Then below the call, you could
'IF l.done "call succeeded" ELSE "call failed"' (or whatever you need
to do in either case).
> Bill
>
>
> >
>
--
Bill Guindon (aka aGorilla)
The best answer to most questions is "it depends".
> "MvCALL takes a new attribute "TIMEOUT". This value is used
> if it is smaller than the configured MvCONFIG_CALL_TIMEOUT value."
Is that v5? Is it me, or does the need to make the timeout smaller not make
any sense? At the moment, I can't think of any time I needed it smaller.
Being able to increase it would make more sense to me.
>I suppose you could look for a closing </html>
> tag, and assign l.done to 1 when you see it.
I think that's be ok if you were calling pages you wrote, otherwise, there
may not be a </html> tag. Some of the pages I have written, (php helper
scripts, etc.) only return raw data and not any html, as nothing gets
displayed to the browser. I am guessing that MvCALL will continue until the
server tells it that the page is done, or the timeout is reached. If so,
then if the call completed, (that is the server told empressa that it was
done), the 1st line after </MvCALL> will be executed. That is where I would
put l.done=1, enclosing it in an "if (NOT MvCALL_ERROR)" condition. (I'm
assuming that it would be set if the timeout is reached, however I don't
believe I've ever tested it.)
Just my 2.3 cents ;)
Bill M.
Yep, it's v5. You'd want to reduce it in an attempt to buy enough
time to clean up (close files, etc.), and report the error. If it
runs until the server times out, then the server just stops the
script, and you have no chance to explain why.
>
> >I suppose you could look for a closing </html>
> > tag, and assign l.done to 1 when you see it.
>
> I think that's be ok if you were calling pages you wrote, otherwise, there
> may not be a </html> tag. Some of the pages I have written, (php helper
> scripts, etc.) only return raw data and not any html, as nothing gets
> displayed to the browser. I am guessing that MvCALL will continue until the
> server tells it that the page is done, or the timeout is reached. If so,
> then if the call completed, (that is the server told empressa that it was
> done), the 1st line after </MvCALL> will be executed. That is where I would
> put l.done=1, enclosing it in an "if (NOT MvCALL_ERROR)" condition. (I'm
> assuming that it would be set if the timeout is reached, however I don't
> believe I've ever tested it.)
Silly me, wasn't even thinking of the MvCALL_Error, yeah, that should
be your trigger. If it's true report the error, otherwise, move on
with your work.
PS: If Bill Weiland jumps in this thread, it's gonna get really tough
to follow ;)
Bill
=============================
Bill Gilligan
Gilligan On-Line
www.gilliganonline.com
727-373-2536
> -----Original Message-----
> From: miva-...@googlegroups.com
> [mailto:miva-...@googlegroups.com] On Behalf Of bi...@billbuilt.com
> Sent: Monday, April 17, 2006 3:38 PM
> To: miva-...@googlegroups.com
> Subject: [miva] Re: mvcall timeout
>
>
But - what is returned when the timeout times out?
Bill
=============================
Bill Gilligan
Gilligan On-Line
www.gilliganonline.com
727-373-2536
> -----Original Message-----
> From: miva-...@googlegroups.com
> [mailto:miva-...@googlegroups.com] On Behalf Of Bill Guindon
> Sent: Monday, April 17, 2006 4:27 PM
> To: miva-...@googlegroups.com
> Subject: [miva] Re: mvcall timeout
>
>
Like...
If mvCall error, then THIS TIMED OUT
Else
Keep going
=============================
Bill Gilligan
Gilligan On-Line
www.gilliganonline.com
727-373-2536
Bill
=============================
Bill Gilligan
Gilligan On-Line
www.gilliganonline.com
727-373-2536
Bill
<MvCALL TIMEOUT="1" ACTION = "{'http://www.domain.com' }" METHOD = "post" FIELDS = "field1,field2
">
<MvEval expr="{ callvalue }">
</MvCall>
With a timeout of "1", it returns the headers and any result generated....
==================================
HTTP/1.1 200 OK Server: Microsoft-IIS/5.0 Date: Tue, 18 Apr 2006 04:24:37 GMT X-Powered-By: ASP.NET
Connection: Keep-Alive Content-Length: 902 Content-Type: text/xml Expires: Tue, 18 Apr 2006 04:24:35
GMT Cache-control: private Set-Cookie:
WT_ID=68.59.51.245-14762768.29778592::20A32AF82164CEE66AC2DFEDF72970F0; path=/; expires=Wed,
18-Apr-2007 04:24:37 GMT S3Y0011076 AND ALL THE NORMAL STUFF YOU WOULD EXPECT....
===============================
With a timeout of 100, generates just the normal stuff..
So - what is it I look for?
Evaling mvcall_error generates nothing.