Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 940609
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T21:59:05+00:00 2026-05-15T21:59:05+00:00

If I use durable subscription, can I restart my client and resubscribe without loosing

  • 0

If I use durable subscription, can I restart my client and resubscribe without loosing any messages? (Assuming, my client does not unsubscribe in any way. Lets say it just crashes).

Let me clarify. JMS 1.1 Spec says the following:

9.3.3.2 Reconnecting to a Topic using a Durable Subscription

/* Reconnect to a durable subscription */
session.createDurableSubscriber(newsFeedTopic, "mySubscription");

However, there are some important restrictions to be aware of:

  • The client must be attached to the same Connection.
  • The Destination and subscription name must be the same.
  • If a message selector was specified, it must also be the same.

That “same Connection” part interests me. It is not clear what “same” means in this context.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T21:59:06+00:00Added an answer on May 15, 2026 at 9:59 pm

    In the spec, take a look at 4.3 where it mentions that the Connection object can contain a unique client identifier and 4.3.2 which states…

    The purpose of the client identifier is to associate a connection and its objects
    with a state maintained on behalf of the client by a provider. By definition, the
    client state identified by a client identifier can be ‘in use’ by only one client at
    a time. A JMS provider must prevent concurrently executing clients from using
    it.

    So the intent here is that the durable subscription contains a unique identifier so that when the app resubscribes it can be attached to the correct state-store where messages have been queued up in its absence. Since the preferred way of doing this is to code the identifier in a client-specific connection object, the spec directs you to reconnect using the same connection but in this case that means the same administered object not the same connection handle (to use the WMQ terminology).

    Of course, you don’t need an administered object, the app can generate a connection dynamically. In that case you’d need to arrange for it to use the same client identifier for successive suscriptions.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

use javascript or other method ? have any recommendation?
Use case example: Client A comes to request sales information, enters their zip code
Does anyone know how to configure durable queue on Terracotta server properly? Terracotta stores
use an icon (.png transparent background) for my menu. There isn't any problem for
Use case: I find a piece of code that I do not understand at
Use AES/Rijndael or any symmetric encryption. Encrypt the hidden value using itself as the
Use Case: Admin should be able to create user, and it should not attempt
Use OPENXML to get dt element in MSSQL 2005. How can I get xmlns:dt
use level1\level2\level3; Can someone explain with a simple demo ?
I want to use java.util.ConcurrentLinkedQueue as a non-durable queue for a Servlet. Here's the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.