Re: [API PROPOSAL] TSHttpTxnServerPush

2016-09-08 Thread Masakazu Kitajo
I just wrote documentation. You can see it on the Pull Request too. https://github.com/apache/trafficserver/pull/833 TSHttpTxnServerPush Synopsis #include Description Push a content to a client with Server Push mechanism. This API works only if the protocol of a transaction supports Server

Re: [API PROPOSAL] TSHttpTxnServerPush

2016-09-08 Thread Alan Carroll
I would like some documentation for this API call. I have to clean up an unrelated mess because functions were added but never documented, so let's avoid that in the future.

Re: [API PROPOSAL] TSHttpTxnServerPush

2016-09-08 Thread Masakazu Kitajo
Passing a URL string go against the recent approach. However, what if TSHttpTxnCacheLookupUrlSet had not been introduced? Do we choose passing a URL object for this API? Is there any reason for using URL objects across the APIs except consistency? I think both consistency and convenience are for m

Re: [API PROPOSAL] TSHttpTxnServerPush

2016-08-17 Thread Masakazu Kitajo
> This is the approach that the recent TSHttpTxnCacheLookupUrlGet API took. We > should take a consistent approach across the API. Its confusing and harder > than necessary when some APIs take strings and some take TS objects. As I wrote on the second to last mail, I guess the URLs would come fr

Re: [API PROPOSAL] TSHttpTxnServerPush

2016-08-17 Thread James Peach
> On Aug 17, 2016, at 9:36 AM, Masakazu Kitajo wrote: > > I realized that URL class isn't exposed as a part of TS API. None of > APIs receive it explicitly, and TSMLoc is used instead. This is the approach that the recent TSHttpTxnCacheLookupUrlGet API took. We should take a consistent approac

Re: [API PROPOSAL] TSHttpTxnServerPush

2016-08-17 Thread Masakazu Kitajo
I realized that URL class isn't exposed as a part of TS API. None of APIs receive it explicitly, and TSMLoc is used instead. Also, I couldn't overload the API because it's not C++ but C. So, I think passing URLs as strings is a reasonable way, and it is the only option for now. I'm going to start

Re: [API PROPOSAL] TSHttpTxnServerPush

2016-08-06 Thread Masakazu Kitajo
What do you think about providing the both interfaces? I'm fine with passing URL objects internally. However, I guess there are cases that URL strings comes from out of TS APIs such as databases, results of some processing, etc. Though people can create URL objects easily, it needs few more boring

Re: [API PROPOSAL] TSHttpTxnServerPush

2016-08-05 Thread Leif Hedstrom
> On Aug 4, 2016, at 8:15 PM, James Peach wrote: > > >> On Aug 1, 2016, at 12:18 AM, Masakazu Kitajo wrote: >> >> Hi all, >> >> I'd like to add a new API to support Server Push[1] introduced by HTTP/2. >> >> void TSHttpTxnServerPush(TSHttpTxn txnp, const char *url, int url_len) > > I thi

Re: [API PROPOSAL] TSHttpTxnServerPush

2016-08-04 Thread James Peach
> On Aug 1, 2016, at 12:18 AM, Masakazu Kitajo wrote: > > Hi all, > > I'd like to add a new API to support Server Push[1] introduced by HTTP/2. > >void TSHttpTxnServerPush(TSHttpTxn txnp, const char *url, int url_len) I think the direction we are moving in is to pass URLs as URL objects r