1 2 3 Previous Next 33 Replies Latest reply on Jan 15, 2008 8:24 AM by Tyronne Wickramarathne

    JBM 2.0 JDBCPersistenceManager - volunteers?

    Tim Fox Master

      Hello All-

      For JBM 2.0, the main persistence mechanism is not via JDBC, but we still need to provide a simple JDBC PersistenceManager implementation, that uses JDBC.

      I'm looking for volunteers to implement this.

      The Persistence Manager interface is pretty simple, currently :

      public interface PersistenceManager
      {
       /**
       * Persist a message reference in the specified queue also persisting the message if it is not already
       * persisted
       * @param queue The queue to persist it in
       * @param ref The MessageReference to persist
       * @param tx The transactional context, or null if no transactional context
       * @throws Exception
       */
       void addReference(PersistenceTransaction tx, Queue queue, MessageReference ref) throws Exception;
      
       /**
       * Remove a message reference from persistent storage for the specified queue, also removing the the
       * associated message if it is not in any more queues
       * @param queue The queue to remove from
       * @param ref The MessageReference to remove
       * @param tx The transactional context, or null if no transactional context
       * @throws Exception
       */
       void removeReference(PersistenceTransaction tx, Queue queue, MessageReference ref) throws Exception;
      
       /**
       * Update the delivery count for the specified MessageReference
       *
       * @param queue The queue
       * @param ref The MessageReference
       * @throws Exception
       */
       void updateDeliveryCount(Queue queue, MessageReference ref) throws Exception;
      
       /**
       * Create a PersistenceTransaction
       * @return The PersistenceTransaction
       * @throws Exception
       */
       PersistenceTransaction createTransaction() throws Exception;
      
       /**
       *
       * @param reference
       * @return
       */
       boolean duplicateExists(MessageReference reference);
      
       /**
       * Load the specified queues from persistent storage
       * @param queues The map of queues to load
       * @throws Exception
       */
       void loadQueues(Map<Long, Queue> queues) throws Exception;
      }
      


      The JDBCPersistenceManager implementation should use HIbernate (at least the dialects) to actually do the performance - we don't want to have to provide different configs for different databases as we did in JBM 1.x.

      Any volunteers?

        1 2 3 Previous Next