IBM Collaboration Solutions (Lotus) support wants to help you take full advantage of your products. Join us for our Open Mic webcasts as technical experts share their knowledge and answer your questions.
These webcasts are designed to address specific topics and provide an in-depth and focused technical exchange in a convenient online webcast format.
Topic: Designing multi-threaded Domino Java applications
Day: Wednesday, March 6, 2013
Time: 11:00 AM EST (16:00 UTC/GMT, UTC-5 hours) for 60 minutes
For more information about our Open Mic webcasts, visit the IBM Collaboration Solutions Support Open Mics page.
|Presentation & Demo|
|Audio Replay (MP3 file)|
Designing multi-threaded Domino Java applications Open Mic Mar 6 2013 (edited).mp3
Link to forum post related to this event.
Q. What about using the native notes lock methods? (i.e. Document.lock)
A. The document lock is a very heavy method. Not perfomant used for thread synchronization. Document lock involves communication with a central server.
Q. I believe document locking only affects front-end edit access to the document. It does not affect back-end modifications.
A. Correct, locking is to keep other users from interfering.
Q. If you recycle a Java Object using the Recycle() method,is it safe then to re-get your object?
A. Yes, you'll go back to the database and it will be reinstantiated.
Note: Never recycle within a finalized clause; the result would be either a hang or a crash.
Q. Are you talking about writing Java agents or just talking about writing external Java classes that use Domino classes?
A. The examples shown are Java applications that utilize our Notes.jar file call into Domino to access your information.
Q. There's no way to find any techniques using a Java agent if I wanted to do multi-threading with one session, is that correct?
A. You can do it but I wouldn't recommend it. It doesn't buy you enough performance wise. Agents are not really the vehicle for servicing Web requests. You really need a free-standing server application for that or an add-in.
If you're doing things that don't involve operations on the same database you can actually pass that session to another thread and use it. I would never cross databases on two threads; it's not going to work that well for you long term. But if you want to talk to different databases that could be done or make external calls to off servers.
Domino Designer Help topics
Rate this page:
Copyright and trademark information
IBM, the IBM logo and ibm.com are trademarks of International Business Machines Corp., registered in many jurisdictions worldwide. Other product and service names might be trademarks of IBM or other companies. A current list of IBM trademarks is available on the Web at "Copyright and trademark information" at www.ibm.com/legal/copytrade.shtml.