The problem is to get response for requests that are being redirected.
Here is an example scenario:
1) Firefox loads page process1.php. It returns: "Process1->Process2"
and redirects to process2.php.
2) Firefox loads page process2.php. It returns: "Process2->Process3"
and redirects to process3.php.
3) Firefox loads page process3.php and it returns: "Process3 Finish!"
I am using nsITraceableChannel to register a nsIStreamListner every
time the on-http-examine-response event is received (three times in
this case). But it seems that the same http channel is reused for all
three requests and so, I am getting only "Process3 Finish!" in all
three stream-listeners.
Is it possible to get even "Process1->Process2" and "Process2-
>Process3" responses, which I can see in Wireshark?
Honza
That is not in fact the case. There's a new channel for each redirect,
but each new channel gets the listener from the previous channel (since
that's where the data needs to go in the end from the final channel).
Response bodies from redirects are not generally passed on to the necko
consumer unless the redirect fails, just like the consumer doesn't get
OnStartRequest/OnStopRequest for redirects.
> Is it possible to get even "Process1->Process2" and "Process2-
>> Process3" responses, which I can see in Wireshark?
Not without changing necko in some way.
-Boris
Honza