Results 1 to 2 of 2

Thread: Jdbc channel message store design question

  1. #1
    Join Date
    Nov 2006
    Location
    NJ
    Posts
    27

    Default Jdbc channel message store design question

    Hi,
    I have used the JdbcChannelMessageStore and it does use the database as a queue.
    What I really want is to back a queue channel with a table only for the sake of disaster recovery. What I mean by that is :
    a. When a message is put on the queue, I want it stored in the table
    b. When the message is consumed, I want it removed from the table
    c. When the queue channel is initialized, I want to load all channel+region specific messages in the table (that were left in there because the application crashed) into the queue.

    I do not see the need to query the table every time a message is consumed from the queue. This is an expensive operation given the locking complexity.
    So I have 2 questions:
    1. Why does the current implementation query the database instead of just getting the message off the in-memory queue and then deleting it from the table?
    2. How can I avoid polling the table using the provided interfaces?
    Regards,
    Hari.

  2. #2
    Join Date
    Mar 2010
    Location
    Gtr Philadelphia, PA
    Posts
    2,028

    Default

    This sounds like a reasonable idea (at least for a single-instance application).

    Contributions are always welcome: https://github.com/SpringSource/spri...ion-extensions

    Thanks!
    Gary P. Russell
    Spring Integration Team
    SpringSource, a division of VMware

Posting Permissions

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