Opened 17 years ago

Closed 17 years ago

#887 closed defect (fixed)

Internal job queue may start the same job more than once if running BASE on multiple Tomcat instances

Reported by: Nicklas Nordborg Owned by: everyone
Priority: minor Milestone: BASE 2.6
Component: core Version:
Keywords: Cc:

Description

There have been reports on the mailing list that although only a single job was registered it produced multiple results. The cause may have been that multiple Tomcat instances were running against the same database. The problem was reproducable in the original system, but disappeared when only one instance was left running. Starting the other instance again didn't make the problem come back. This is, however, not unexpected since the problem in the first place must have happened because of unfortunate timing between the different Tomcat instances.

For more info see: http://www.mail-archive.com/basedb-users@lists.sourceforge.net/msg00989.html

It may be hard to reproduce this problem, since it depends on the timing of checking the job queue between two different processes/threads. Inserting some debug code (Thread.sleep) at strategic places may help (DO NOT FORGET TO REMOVE IT AFTERWARDS!).

If we find a problem with the internal job queue, it may also be needed to check if the job agents handle this properly.

Change History (2)

comment:1 by Nicklas Nordborg, 17 years ago

Milestone: BASE 2.5.1BASE 2.6

comment:2 by Nicklas Nordborg, 17 years ago

Resolution: fixed
Status: newclosed

(In [4098]) Fixes #887: Internal job queue may start the same job more than once if running BASE on multiple Tomcat instances

As it turned out, the checks were already implemented by the job agent code and just needed to be copied into the internal job queue code.

Note: See TracTickets for help on using tickets.