thanks to all for the comments.

I had not really thought about what would happen with the witango results 
-- I was just kind of hoping that the swish-e output would get piped by 
magic.  I really want the "esp" attribute (aka wysiwim -- what you see is 
what I meant) added to witango 6.

Anyway, it's not important for this case.  As long as the browser doesn't 
time out I'm fine.  I just thought it would be something for them to look 
at to keep naive users from repeatedly reloading the page, and invoking 
multiple perl/swish-e processess.  I'll solve it with a big red note on 
the page.

 Manual indexing via the script is only meant as a supplement to cron 
indexing (using the same script).  Actually it could run very fast, but I 
have a 1 second wait between http requests from swish-e.  I just didn't 
want to run out of threads in apache or witango by flooding the server 
during indexing.



>Yeah, Jim is absolutely correct... I kinda skipped over that and focused 
>more on how you would do it inside of a rows loop.
>
>Since I assume you're using swish-e and the spidering capabilities of 
>it, you're going to have to think about this a little more if you want 
>indexing status to get sent to the browser.
>
>How's this for an idea....
>
>1. Fork the process of doing the index in your shell script so that the 
>external action returns immediately.
>2. have your swish-e call dump it's results to a temporary text file 
>instead of standard output
>3. write another taf file that parses and displays the status 
>information that you're looking for from the temp text file.
>4. have your original taf redirect to that "status displaying" taf.
>5. have the status displaying taf file that reads the temp file, either 
>refresh automatically every so many seconds, or have it be up to the 
>user to click a "refresh" button if they're too impatient to wait a 
>couple minutes for swish-e to finish.
>
>5a. If you don't like the refresh idea, you could probably write 
>something up in a different language besides tango that would do the 
>equivilant of a "tail -f" to the browser with the contents of that temp 
>file.
>
>Thoughts?
>
>/John
>
>
>Bill Conlon wrote:
>
>>of course!  thanks.
>>
>>  
>>
>>>Bill,
>>>
>>>The tango PUSH function pushes the results of the specified action AFTER it
>>>has been processed by the server (by keeping the HTTP connection open and
>>>sending the browser a content-length: unspecified header, then sending
>>>"blocks" of the results HTML), so if you wanted to get results line by line
>>>as they were returned, you'd have to write a shell script that returned a
>>>single result and read an environment variable (a counter).  Then you'd put
>>>your external action in a loop and assign the environment variable to be the
>>>loop counter.
>>>
>>>In other words, the "loop" must be done in Tango and not in your script...
>>>as the PUSH happens after the end of a specified action (in this case your
>>>External Action).
>>>
>>>Hope this helps...
>>>
>>>
>>>Happy Coding!
>>>
>>>Jim Kass
>>>Web Developer
>>>
>>>--
>>>Forestweb: The Source for Industry Intelligence
>>>Best Content -- Most Relevant -- Best Delivery
>>>http://www.forestweb.com
>>>(310) 553 - 0008
>>>
>>>-----Original Message-----
>>>From: Bill Conlon [mailto:[EMAIL PROTECTED]
>>>Sent: Wednesday, November 05, 2003 12:06 PM
>>>To: Witango-Talk
>>>Subject: Witango-Talk: push for external action
>>>
>>>
>>>I am running an external action (shell script to invoke the swish-e
>>>indexer).  From the command line this returns information line by line in
>>>the terminal.  Likewise, it returns the results to witango in
>>>@@request$resultset.
>>>
>>>I would like to push the results, line by line to the browser.  It seems
>>>like push is operating, because the browser does not time out during the
>>>two minute indexing run.  But results are not displayed in the browser
>>>until indexing is complete.
>>>
>>>Within the Extenal action I have a ResultsHTML attribute.  I have tried
>>>both: @@request$results and <@ROWS>@@request$resultset[<@CURROW>,1]<br
>>>/></@ROWS> as the ResultsHTML.  Same results with Mac Mozilla 1.5 and Mac
>>>IE 5.2.
>>>
>>>Any suggestions?
>>>
>>>Bill Conlon
>>>
>>>To the Point
>>>345 California Avenue Suite 2
>>>Palo Alto, CA 94306
>>>
>>>office: 650.327.2175
>>>fax:    650.329.8335
>>>mobile: 650.906.9929
>>>e-mail: mailto:[EMAIL PROTECTED]
>>>web:    http://www.tothept.com
>>>
>>>
>>>________________________________________________________________________
>>>TO UNSUBSCRIBE: Go to http://www.witango.com/maillist.taf
>>>
>>>
>>>________________________________________________________________________
>>>TO UNSUBSCRIBE: Go to http://www.witango.com/maillist.taf
>>>
>>>    
>>>
>>
>>
>>Bill Conlon
>>
>>To the Point
>>345 California Avenue Suite 2
>>Palo Alto, CA 94306
>>
>>office: 650.327.2175
>>fax:    650.329.8335
>>mobile: 650.906.9929
>>e-mail: mailto:[EMAIL PROTECTED]
>>web:    http://www.tothept.com
>>
>>
>>________________________________________________________________________
>>TO UNSUBSCRIBE: Go to http://www.witango.com/maillist.taf
>>
>>  
>>
>
>
>________________________________________________________________________
>TO UNSUBSCRIBE: Go to http://www.witango.com/maillist.taf
>


Bill Conlon

To the Point
345 California Avenue Suite 2
Palo Alto, CA 94306

office: 650.327.2175
fax:    650.329.8335
mobile: 650.906.9929
e-mail: mailto:[EMAIL PROTECTED]
web:    http://www.tothept.com


________________________________________________________________________
TO UNSUBSCRIBE: Go to http://www.witango.com/maillist.taf

Reply via email to