Koen, I reimplement the destructor:
WtApplication::~WtApplication() {
dboSession_->~Session();
connection_->~SqlConnection();
}
Too view running sessions in PostgreSQL:
$ sudo su postgres -c psql postgres # connect
postgres=# SELECT * FROM pg_stat_activity; # lista as sessões
or
postgres=# SELECT COUNT (*) FROM pg_stat_activity;
Thank you,
John
On 03/16/2011 05:52 PM, Koen Deforche wrote:
> Hey John,
>
> 2011/3/16 John Robson <[email protected]>:
>>> Do you also delete the Wt::Dbo::backend::Postgres object when your Wt
>>> session exits?
>>
>> No, where I use this? in the class destructor? How?
>
> See examples/blog/view/BlogView.[hC] and examples/blog/BlogSession.[hC]
>
> You should reimplement the destructor of a widget or the application,
> or embed the connection and session objects directly in these classes.
>
> Regards,
> koen
------------------------------------------------------------------------------
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d
_______________________________________________
witty-interest mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/witty-interest