Class JDBCConsumer

    • Constructor Detail

      • JDBCConsumer

        public JDBCConsumer​(JDBCMessageStore store)
        Initialize consumer
        Parameters:
        store - - JDBC message store
    • Method Detail

      • receive

        public MessageContext receive()
        Select and return the first element in current table
        Specified by:
        receive in interface MessageConsumer
        Returns:
        - Select and return the first element from the table
      • ack

        public boolean ack()
        Ack on success message sending by processor
        Specified by:
        ack in interface MessageConsumer
        Returns:
        Success of removing
      • cleanup

        public boolean cleanup()
        Cleanup the consumer
        Specified by:
        cleanup in interface MessageConsumer
        Returns:
        Success of cleaning
      • isAlive

        public boolean isAlive()
        Check JDBC consumer is alive
        Specified by:
        isAlive in interface MessageConsumer
        Returns:
        consumer status
      • setAlive

        public void setAlive​(boolean isAlive)
        Set isAlive flag in JDBC consumer
        Specified by:
        setAlive in interface MessageConsumer
        Parameters:
        isAlive - status
      • setId

        public void setId​(int id)
        Set consumer id
        Specified by:
        setId in interface MessageConsumer
        Parameters:
        id - ID
      • getId

        public String getId()
        Get consumer id
        Specified by:
        getId in interface MessageConsumer
        Returns:
        consumerId - Consumer identifier