Re: HTAnchors lifetime

Ave Cesare.

> (Can you suggest for any counter of pending Requests inside libwww?)

U can manage it between HTLoad and terminateHandler.

> I'm passing to the Library more and more requests as the need arises
> from an asynchronous source, [...]

Then u need HTAnchor_delete. Did u try it?

> So I wonder if Anchors are really usefull at all for my application.

Good idea to have less anchors.

use HTRequest_setOutputFormat(request, WWW_SOURCE).

> I'm using a Jen Megger's patch of HTHost.c [...]

No effect on anchors.

> This way I try exploiting [CGI(s) in paralle]

While just one thread use the libw3, ok.

> Maybe it implies other unsuspected dependancies 
> between Requests and Anchors?

It may have. 

HTAnchor_delete is not safe. 
But with WWW_SOURCE format it could walk...

Your goal is less mem leak. 
It may have. 
I'm not sure...

Let guess u did

 HTLoadAbsolute(url, request);

Then when u want to remove anchors,
it could be more efficient to do;

   HTAnchor_delete(HTAnchor_findAddress(url));

rather than 

   HTAnchor_delete(HTRequest_anchor(request));




Michel.




PS

Sorry fpr late answer. 
I can write in the list only from home not from job.
I don't know and don't care WHY?

Cesare Pietra wrote:
> 
> -------- Original Message --------
> Subject: Re: HTAnchors lifetime
> Date: Tue, 23 Oct 2001 10:11:22 +0200
> From: "Cesare Pietra" <cesare.pietra@netikos.com>
> Organization: netikos
> To: "Michel Philip" <philipm@altern.org>
> References: <002b01c15b09$229f67f0$150516ac@netikos.com>
> <3BD5086F.E86C02B5@altern.org>
> 
> Unfortunately I never can tell for sure if all the submitted requests
> have
> been completed at a given time.
> (Can you suggest for any counter of pending Requests inside libwww?)
> I'm passing to the Library more and more requests as the need arises
> from an
> asynchronous source, and it should be desirable if I could delete
> Anchors
> bound to a specific Request as it terminates.
> The hyperdocuments my applications is going to retreive are poor html
> plain-text pages without any embedded links.
> So I wonder if Anchors are really usefull at all for my application.
> 
> In addition, I have to say (if it can somehow help you to understand my
> problem) I'm using a Jen Megger's patch of HTHost.c module to be able to
> open more then one socket connection to the same host.
> Yes I read everything about pipelining and performance issues, but I'm
> doing
> like that in order to avoid the remote web server to slow down the
> entire
> work invoking a CGI at a time.  This way I try exploiting parallelism in
> executions of CGI themselves.
> Maybe it implies other unsuspected dependancies between Requests and
> Anchors?
> 
> Tips are welcome.
> Thanks in advance,
> Cesare

Received on Friday, 2 November 2001 05:42:45 UTC