getting TSVconn in session start hook handler

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

getting TSVconn in session start hook handler

Gaurav Bansal
Hi all,
I have created a session-start-hook (TS_EVENT_HTTP_SSN_START) handler namely "ssn_start_plugin(TSCont contp, TSEvent event, void *edata)". In this function, i need TSVConn. Is there any api using which i can get TSVConn in ssn_start_plugin function using either contp or edata (which is TSHttpSsn here).

I tried the following approach :
int
ssn_start_plugin(TSCont contp, TSEvent event, void *edata)
{
    TSVConn connection;
    connection = TSTransformOutputVConnGet(contp);
.....

Can anyone please let me know if this is the right way ? OR is there some way to get it using TSHttpSsn also.
thanks,
gaurav
Reply | Threaded
Open this post in threaded view
|

Re: getting TSVconn in session start hook handler

Persia Aziz
TSTransformOutputVConnGet takes TSVConn  not TSHttpSsn. I could not find any API that takes TSHttpSsn and returns TSVConn.

I have made a PR for this:




Syeda Persia Aziz
Software Developer
Yahoo! Inc.
Champaign, Illinois


On Tuesday, October 31, 2017, 6:34:25 AM CDT, Gaurav Bansal <[hidden email]> wrote:


Hi all,
I have created a session-start-hook (TS_EVENT_HTTP_SSN_START) handler namely "ssn_start_plugin(TSCont contp, TSEvent event, void *edata)". In this function, i need TSVConn. Is there any api using which i can get TSVConn in ssn_start_plugin function using either contp or edata (which is TSHttpSsn here).

I tried the following approach :
int
ssn_start_plugin(TSCont contp, TSEvent event, void *edata)
{
    TSVConn connection;
    connection = TSTransformOutputVConnGet(contp);
.....

Can anyone please let me know if this is the right way ? OR is there some way to get it using TSHttpSsn also.
thanks,
gaurav
Reply | Threaded
Open this post in threaded view
|

Re: getting TSVconn in session start hook handler

Steven Hunter
try using web store or play store related apps or ext...

On Tue, Oct 31, 2017 at 8:09 AM, Persia Aziz <[hidden email]> wrote:
TSTransformOutputVConnGet takes TSVConn  not TSHttpSsn. I could not find any API that takes TSHttpSsn and returns TSVConn.

I have made a PR for this:




Syeda Persia Aziz
Software Developer
Yahoo! Inc.
Champaign, Illinois


On Tuesday, October 31, 2017, 6:34:25 AM CDT, Gaurav Bansal <[hidden email]> wrote:


Hi all,
I have created a session-start-hook (TS_EVENT_HTTP_SSN_START) handler namely "ssn_start_plugin(TSCont contp, TSEvent event, void *edata)". In this function, i need TSVConn. Is there any api using which i can get TSVConn in ssn_start_plugin function using either contp or edata (which is TSHttpSsn here).

I tried the following approach :
int
ssn_start_plugin(TSCont contp, TSEvent event, void *edata)
{
    TSVConn connection;
    connection = TSTransformOutputVConnGet(contp);
.....

Can anyone please let me know if this is the right way ? OR is there some way to get it using TSHttpSsn also.
thanks,
gaurav

Reply | Threaded
Open this post in threaded view
|

Re: getting TSVconn in session start hook handler

Leif Hedstrom
In reply to this post by Persia Aziz


On Oct 31, 2017, at 9:09 AM, Persia Aziz <[hidden email]> wrote:

TSTransformOutputVConnGet takes TSVConn  not TSHttpSsn. I could not find any API that takes TSHttpSsn and returns TSVConn.


This should be proposed / discussed the normal way, as documented in

https://cwiki.apache.org/confluence/display/TS/API+Review+Process


— leif