Results 1 to 2 of 2

Thread: Quartz integr.: tx-related bug in LocalDataSourceJobStore?

  1. #1
    Join Date
    Sep 2004
    Posts
    23

    Default Quartz integr.: tx-related bug in LocalDataSourceJobStore?

    There is something I don't understand in LocalDataSourceJobStore. Why does it define getConnection and getNonManagedTxConnection so as they use the same DataSource? In my understanding, one of the two must be an XA datasource, and the other must not, so it seems to me there could possibly be a problem here.

    In fact, I think this is the cause of the following problem I have. I want to use quartz in a spring context that is instantiated from an MDB. It seems WebSphere only instantiates the first bean when a message arrives, and does so in a transaction (CMT): while the context starts, quartz initialization code is executed which calls "commit" on the connection which should be non-managed, and this fails with a message regarding global and local transaction (I think, this may even fail before, when the same code executes setAutoCommit(false)).

    Isn't this an oversight in the implementation of LocalDataSourceJobStore?

  2. #2
    Join Date
    Sep 2004
    Posts
    23

    Default Re: Quartz integr.: tx-related bug in LocalDataSourceJobStor

    Quote Originally Posted by immanuel
    There is something I don't understand in LocalDataSourceJobStore. Why does it define getConnection and getNonManagedTxConnection so as they use the same DataSource? In my understanding, one of the two must be an XA datasource, and the other must not, so it seems to me there could possibly be a problem here.

    In fact, I think this is the cause of the following problem I have. I want to use quartz in a spring context that is instantiated from an MDB. It seems WebSphere only instantiates the first bean when a message arrives, and does so in a transaction (CMT): while the context starts, quartz initialization code is executed which calls "commit" on the connection which should be non-managed, and this fails with a message regarding global and local transaction (I think, this may even fail before, when the same code executes setAutoCommit(false)).

    Isn't this an oversight in the implementation of LocalDataSourceJobStore?
    No opinions on this? More specifically, what puzzles me a bit is the fact that the bean factory is created in the ejbCreate method, which is called in a transaction context. Shouldn't this be done in the setMessageDrivenContext method which is called before this, and outside a transaction context (but with access to UserTransaction and so on)?

Similar Threads

  1. Replies: 3
    Last Post: May 4th, 2010, 03:23 AM
  2. Migrating to new version of Quartz
    By ramkris in forum Container
    Replies: 4
    Last Post: Nov 15th, 2005, 02:51 AM
  3. Quartz - Statefull Jobs
    By nandhusriram in forum Container
    Replies: 1
    Last Post: Sep 7th, 2005, 01:11 PM
  4. Quartz question
    By kuns in forum Container
    Replies: 3
    Last Post: Jul 11th, 2005, 03:03 PM
  5. Quartz - Couldn't retrieve job
    By newreaders in forum Container
    Replies: 4
    Last Post: Jun 1st, 2005, 08:12 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •