Is Julies agent FAQ about recycle() still valid in Domino 6 also?
I’ve seen lot’s of session.recycle() being used. FAQ says you don’t have to do that… What exactly are the things we need to recycle? Best practises?
Is Julies agent FAQ about recycle() still valid in Domino 6 also?
I’ve seen lot’s of session.recycle() being used. FAQ says you don’t have to do that… What exactly are the things we need to recycle? Best practises?
Subject: Java memory and recycle
As far as I’m aware, yes, the advice still stands. The Java object model for Domino comprises classes and interfaces which are “wrappers” to the core C (or is it C++?) code within Notes. This hasn’t changed between R5 and ND6.x, so if you want to avoid memory leaks and what-have-you, you still need to recycle objects.
I’ve seen contradicting opinions with regards recycling the Session object, but given that it has a recycle() method, I’d say it’s required, else why offer it to the developer?
If you’re done with the Session – especially in multi-threaded / connection pooling applications – I say go for it. It can’t hurt.
This article may offer up more information:
http://www-10.lotus.com/ldd/today.nsf/0/c18beec15f55f1ef85256d66005c7da9
HTH
–
Subject: RE: Java memory and recycle
There are several layers of API’s, but the first level used by the backend classes is C++ wrappers around lower level stuff which is mostly C code.
As for recycle, it’s a good idea to recycle the Session object after you are done with it. This closes down and cleans out your DIIOP connection (if you are using one) and does a few other cleanup tasks if you are using a local Session.
Joseph Millar
Principal Software Engineer
Brightline Technology