Hello,

This is what is in the Httpstst example:


void __fastcall THttpTestForm::SslHttpCli1SslCliNewSession(TObject *Sender,

Pointer SslSession, bool WasReused, bool &IncRefCount)

{

TSslHttpCli* HttpCli;

// SslCliNewSession/SslCliGetSession allow external, client-side session

// caching.

if (!SessCacheCheckBox->Checked)

return;

HttpCli = (TSslHttpCli*)Sender;

if (!WasReused) {

FMyExternalSslSessionCache->CacheCliSession(SslSession,

HttpCli->CtrlSocket->PeerAddr +

HttpCli->CtrlSocket->PeerPort,

IncRefCount);

Display("! New SSL session");

}

else

Display("! SSL Session reused");

}

//---------------------------------------------------------------------------

void __fastcall THttpTestForm::SslHttpCli1SslCliGetSession(TObject *Sender,

Pointer &SslSession, bool &FreeSession)

{

TSslHttpCli* HttpCli;

// SslCliNewSession/SslCliGetSession allow external, client-side session

// caching.

if (!SessCacheCheckBox->Checked)

return;

HttpCli = (TSslHttpCli*)Sender;

SslSession = FMyExternalSslSessionCache->GetCliSession(

HttpCli->CtrlSocket->PeerAddr +

HttpCli->CtrlSocket->PeerPort,

FreeSession);

FreeSession = TRUE;

}

//---------------------------------------------------------------------------
Now the parameters changed in the server code! I found the signatures and
converted them to C++ but what's the equvalent of WasReused??

void __fastcall ReverseProxyThread::ReverseProxyNewSSLSession(TObject
*Sender, Pointer SslSession, Pointer SessId, int Idlen, bool
&AddToInternalCache)
{
    THttpMTConnection* HttpCli;
    // SslCliNewSession/SslCliGetSession allow external, client-side session
    // caching.
    HttpCli = (THttpMTConnection*)Sender;
    if (!WasReused) {
          FMyExternalSslSessionCache->CacheCliSession(SslSession,
          HttpCli->PeerAddr +
          HttpCli->PeerPort,
          IncRefCount);
    }
}
//---------------------------------------------------------------------------
void __fastcall ReverseProxyThread::ReverseProxyGetSSLSession(TObject
*Sender, Pointer &SslSession, Pointer SessId, int Idlen, bool &IncRefCount);
{
    THttpMTConnection* HttpCli;
    // SslCliNewSession/SslCliGetSession allow external, client-side session
    // caching.
    HttpCli = (THttpMTConnection*)Sender;
    SslSession  = FMyExternalSslSessionCache->GetCliSession(
          HttpCli->PeerAddr +
          HttpCli->PeerPort,
          FreeSession);
    FreeSession = TRUE;
}
//---------------------------------------------------------------------------

Could you help? Let me elaborate the problem: I believe there are two caches
and we do NOT want to use the "internal" one, right? Sorry but it is not as
clear you said...

Regards,

SZ
On Mon, Feb 16, 2009 at 10:44 AM, Arno Garrels <[email protected]> wrote:

> Fastream Technologies wrote:
> > I got compiler errors when I last tried to integrate the avl cache!
> > Can you send me a C++ example?
>
> Look at the sample OverbyteIcsHttpsTst.cbproj in the ICS V7 SVN repository.
> Server-side caching just uses different events, their names are
> self-explanatory.
>
> --
> Arno Garrels
>
> >
> > Regards,
> >
> > SZ
> >
> > On Sun, Feb 15, 2009 at 7:50 PM, Arno Garrels <[email protected]>
> > wrote:
> >
> >> Fastream Technologies wrote:
> >>
> >>> Currently I get 20 SSL TPS local-to-local. When keep-alive is
> >>> enabled, this goes up to 2000.
> >>
> >> Do you use a SSL session cache, either the built-in OpenSSl session
> >> cache or (IMHO faster) the ICS AVL session cache?
> >>
> >> --
> >> Arno Garrels
>
-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to