1 Reply Latest reply on Feb 24, 2004 6:50 PM by Alexey Loubyansky

    Timeout on Autonumber

    jesper6tv Newbie

      JBoss 3.2.3, with Postgres 3.x
      We are experiencing timeouts when Autonumber is used. It seems that several different entity beans try to get the next integer, but timeouts. We have ported from 3.0.8 to 3.2.3 recently.

      Exception:
      TransactionRolledbackException in method: public abstract java.lang.Integer org.jboss.varia.autonumber.AutoNumber.getValue() throws java.rmi.RemoteException, causedBy:
      java.lang.RuntimeException: Transaction marked for rollback, possibly a timeout

      Changelog 3.2.3RC1 says:
      varia/src/main/org/jboss/varia/autonumber/AutoNumberFactory.java
      comments: Synchronize the class methods so that this class is thread safe. See [ 825942 ] AutoNumberFactory not thread safe.

      I guess the syncronization cause the timeouts.

      Have anyone experienced same problems?

      Deploying an Autonumber for each entity, does not help(?), since the Factory use a static syncronized method.