- Powered by Domino 8.5.2 Domino Accelerator Pack
- Reduce network traffic
Lotus Triple Search DominoExperts + Blogs + R8 forum -> General Domino Talk

 Servlets - Instantiating NotesFactory in init

Tomas NielsenPost date: 2007-02-13 20:44

I will do a test to instantiate the Domino session in the init method of a servlet. For example opening a database and a view and then use the notes objects for the lifespan of the servlet and then dispose of them during the destroy().

The gain would be that you get a servlet that starts extremely fast and with the database and views open you should get performance like a domino application glued to the hood of a turbo charged SAAB!

I have always wanted to test this. Most likely there's going to be some kind of memory leak but we will see.

Has anyone tried this before?

Tomas NielsenPost date: 2007-02-18 23:47

I have tested this now and I can not recommend it.

It does work to open the session and database in the init() and then recycle it in destroy().

However if you want to take the server down it will stop when taking down then nserver.exe task and you have to kill it to get it down.

I have tried to leave a stress test tool against the servlet overnight (75 requests per second against the servlet) and it works fine, no memory leaks that are noticeable.

But since the server behaves unstable it is simply not worth the extra little performance you gain by doing the pre opening of databases and views.

RSS feed
Subscribe to Forum

Share this page

Top posters
Tomas Nielsen212
Joacim Boive27
Fredrik Stöckel27
Niklas Waller13
Kenneth Haggman11
Bryan Kuhn10
Daniel Lehtihet9
Jonas Israelsson8