You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@trafficserver.apache.org by Daniel Morilha <dm...@gmail.com> on 2013/09/11 19:24:51 UTC
How to properly use TSFetchUrl
Hi,
I am looking for some help to understand the TSFetchUrl api (which btw is
poorly documented).
I see it accepts a string for the request, an sockaddr pointer for the
server to connect, a continuation and so on.
The one or two examples I've found connect to localhost and use the TS to
hit the final destination.
I was wondering if that should always be the case.
I am trying to fetch some assets, process them, cache and later use them
when necessary, somewhat similar to ESI, and for that it looks that looping
TS is pure overhead.
Is there any API to hook into name resolution (preferably async) that I can
use?
Any considerations on that subject would be welcomed.
Thanks,
--
Daniel Morilha (dmorilha@gmail.com)
Re: How to properly use TSFetchUrl
Posted by Brian Geffon <br...@apache.org>.
Looking at the code it appears that it does absolutely nothing except set
the addr info so that it's available for API calls. The final destination
will be determined via parsing the request and normal remap.
Brian
On Wed, Sep 11, 2013 at 10:24 AM, Daniel Morilha <dm...@gmail.com> wrote:
> Hi,
>
> I am looking for some help to understand the TSFetchUrl api (which btw is
> poorly documented).
>
> I see it accepts a string for the request, an sockaddr pointer for the
> server to connect, a continuation and so on.
>
> The one or two examples I've found connect to localhost and use the TS to
> hit the final destination.
>
> I was wondering if that should always be the case.
>
> I am trying to fetch some assets, process them, cache and later use them
> when necessary, somewhat similar to ESI, and for that it looks that looping
> TS is pure overhead.
>
> Is there any API to hook into name resolution (preferably async) that I
> can use?
>
> Any considerations on that subject would be welcomed.
> Thanks,
> --
> Daniel Morilha (dmorilha@gmail.com)
>