<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Leah Robert</title>
    <description>The latest articles on DEV Community by Leah Robert (@leahrobert).</description>
    <link>https://dev.to/leahrobert</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F330280%2Fd846c68a-62d1-4d61-ad2e-f90f7e4f54da.jpeg</url>
      <title>DEV Community: Leah Robert</title>
      <link>https://dev.to/leahrobert</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/leahrobert"/>
    <language>en</language>
    <item>
      <title>PubSub+ Message Handling Features: Reject-Message-to-Sender-on-Discard</title>
      <dc:creator>Leah Robert</dc:creator>
      <pubDate>Thu, 19 Aug 2021 14:11:27 +0000</pubDate>
      <link>https://dev.to/solacedevs/pubsub-message-handling-features-reject-message-to-sender-on-discard-3hn7</link>
      <guid>https://dev.to/solacedevs/pubsub-message-handling-features-reject-message-to-sender-on-discard-3hn7</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--gQkotr82--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/08/solace-blog-featured-image_stop-return-to-sender-green.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--gQkotr82--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/08/solace-blog-featured-image_stop-return-to-sender-green.jpg" alt=""&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Thus far in the message handling features blog series we have looked at &lt;a href="https://solace.com/blog/pubsub-messaging-handling-features-message-expiry/"&gt;message expiry&lt;/a&gt; and &lt;a href="https://solace.com/blog/pubsub-message-handling-features-dead-message-queues/"&gt;dead message queues&lt;/a&gt;. In this blog post we will cover the &lt;a href="https://solace.com/blog/delivery-modes-direct-messaging-vs-persistent-messaging/"&gt;persistent messaging&lt;/a&gt; feature Reject Message to Sender on Discard. A long name, and an important &lt;a href="https://solace.com/blog/queues-vs-topic-endpoints/"&gt;endpoint&lt;/a&gt; property for defining certain scenarios when publishers should receive negative acknowledgements. For short, we will refer to the feature in this blog as Reject-to-Sender.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;What is the Reject-to-Sender endpoint property?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Reject-to-Sender defines when a publisher should receive a &lt;a href="https://solace.com/blog/understanding-guaranteed-message-publish-window-sizes-and-acknowledgement/"&gt;negative acknowledgement&lt;/a&gt; if a message is rejected from an endpoint. This property is typically used when there are multiple consumers that require the exact same data. The configuration could look something like the below; each consumer has its own queue, and each queue has the same subscription.&lt;br&gt;&lt;br&gt;
&lt;a href="https://solace.com/wp-content/uploads/2021/08/reject-to-sender_pic-01.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--q-v7gT6H--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/08/reject-to-sender_pic-01-1024x588.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Each of these consumers will receive the same messages because they are using &lt;a href="https://solace.com/blog/delivery-modes-direct-messaging-vs-persistent-messaging/"&gt;persistent delivery&lt;/a&gt; and they all have the same subscription. However, if one consumer is slow or offline, its queue could fill up.&lt;br&gt;&lt;br&gt;
&lt;a href="https://solace.com/wp-content/uploads/2021/08/reject-to-sender_pic-02.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--UhU5kPUk--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/08/reject-to-sender_pic-02-1024x595.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In this scenario, messages could still be stored in Q1 and Q2, but as Q3 is full, it would not have any room for new messages. Reject-to-Sender being enabled on these queues ensures that a message is stored on all 3 queues, or none of the queues. Almost like an ‘all or nothing’ property for endpoints that share subscriptions.&lt;br&gt;&lt;br&gt;
&lt;a href="https://solace.com/wp-content/uploads/2021/08/reject-to-sender_pic-03.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--5Jhvreeq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/08/reject-to-sender_pic-03-1024x587.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;When the message is rejected from Q3, an error (or negative acknowledgement) is sent back to the publisher and the message is not stored on any of the three queues; it is then up to the publisher to resend the message.&lt;/p&gt;

&lt;p&gt;Now, if Q3 had Reject-to-Sender disabled in this scenario, the message would be stored on Q1 and Q2, and the publisher would not receive any error message. This is regardless of whether Q1 and Q2 have the Reject-to-Sender property enabled or not.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;How do I use Reject-to-Sender?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Reject-to-Sender is the property of a &lt;a href="https://solace.com/blog/queues-vs-topic-endpoints/"&gt;guaranteed endpoint&lt;/a&gt; and can be enabled/disabled as an endpoint setting. There are three options when configuring Reject-to-Sender:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;‘When Queue Enabled’ refers to the queue admin status – if the queue is enabled, Reject-to-Sender is enabled

&lt;ul&gt;
&lt;li&gt;
If the queue is administratively shutdown, this queue will not have an impact on sending negative acknowledgements to the publisher. Negative acknowledgements are only sent if a message is rejected &amp;amp; the queue is enabled. This is the most common setting for the Reject-to-Sender property.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;li&gt;‘Always’ treats Reject-to-Sender as enabled even when the queue is administratively shutdown

&lt;ul&gt;
&lt;li&gt;
This is the least common setting for this property as messages would always be negative acknowledged to the publisher when a queue is shutdown.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;li&gt;‘Never’ treats Reject-to-Sender as disabled

&lt;ul&gt;
&lt;li&gt;
This setting is used when a queue should not be included in the ‘all or nothing’ functionality. An example is when a queue bridges data from a Production environment to UAT/Test. If this queue were to fill up, you would not want it to affect Production processing of data.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;By default, Reject-to-Sender is set as ‘When Queue Enabled’ for queues, and is disabled for topic-endpoints.&lt;br&gt;&lt;br&gt;
&lt;a href="https://solace.com/wp-content/uploads/2021/08/reject-to-sender_pic-04.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--NeAwK8cM--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/08/reject-to-sender_pic-04.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;When messages are not able to be saved to a queue, the queue statistics will increment.&lt;br&gt;&lt;br&gt;
&lt;a href="https://solace.com/wp-content/uploads/2021/08/reject-to-sender_pic-05.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--vzoRaHHX--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/08/reject-to-sender_pic-05.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;There is another scenario to consider: a message is published as persistent, however there is no matching subscription on the broker. For this scenario, there is another Reject-to-Sender property located in the authorization object called a &lt;a href="https://docs.solace.com/Overviews/Assigning-Client-Profiles.htm"&gt;Client-Profile&lt;/a&gt;. While I won’t be going into full detail of the Client-Profile object in this blog, the property name is called &lt;a href="https://docs.solace.com/Configuring-and-Managing/Configuring-Client-Profiles.htm#Configur"&gt;Reject-Messages-to-Sender-On-No-Subscription-Match-Discard&lt;/a&gt;. This property ultimately provides the same behaviour as the queue property, but for specific scenarios where there are no subscriptions for a published persistent message.&lt;/p&gt;

&lt;p&gt;If you found this post useful, visit the &lt;a href="https://docs.solace.com/Configuring-and-Managing/Configuring-Queues.htm?Highlight=reject%20message%20to%20sender#Message-Discard-Handling"&gt;queue properties section of our docs&lt;/a&gt;, and our &lt;a href="https://www.solace.dev/"&gt;PubSub+ for Developers&lt;/a&gt; page for more information. If you have any questions about queues and topic endpoints, try posting them to the &lt;a href="https://solace.community/"&gt;Solace Developer Community&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://solace.com/blog/pubsub-message-handling-features-reject-message-to-sender-on-discard/"&gt;PubSub+ Message Handling Features: Reject-Message-to-Sender-on-Discard&lt;/a&gt; appeared first on &lt;a href="https://solace.com"&gt;Solace&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>fordevelopers</category>
    </item>
    <item>
      <title>PubSub+ Message Handling Features: Dead Message Queues</title>
      <dc:creator>Leah Robert</dc:creator>
      <pubDate>Tue, 15 Jun 2021 14:35:32 +0000</pubDate>
      <link>https://dev.to/solacedevs/pubsub-message-handling-features-dead-message-queues-2bla</link>
      <guid>https://dev.to/solacedevs/pubsub-message-handling-features-dead-message-queues-2bla</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--FYstXT67--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/06/solace-blog-featured-image_gravestone-green.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--FYstXT67--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/06/solace-blog-featured-image_gravestone-green.jpg" alt=""&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;In the first blog in this series, I explained the concept of &lt;a href="https://solace.com/blog/pubsub-messaging-handling-features-message-expiry/"&gt;message expiry&lt;/a&gt;, or message-TTL. Here I’ll look at dead message queues (DMQs), which assumes you have background knowledge on &lt;a href="https://solace.com/blog/queues-vs-topic-endpoints/"&gt;Solace endpoints&lt;/a&gt; and &lt;a href="https://solace.com/blog/delivery-modes-direct-messaging-vs-persistent-messaging/"&gt;Solace persistent messaging&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;What is a Dead Message Queue?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;A dead message queue, sometimes referred to as a dead letter queue, is an endpoint to store messages that have lost delivery eligibility in their original endpoint, and stores messages for special processing or delayed consumption.&lt;/p&gt;

&lt;p&gt;You might be wondering how a message can lose delivery eligibility, especially when it is originally published as persistent. There are two ways messages can be deemed ineligible for delivery:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;** **** Message Expiry:** The &lt;a href="https://solace.com/blog/pubsub-messaging-handling-features-message-expiry/"&gt;first post in this series&lt;/a&gt; goes into more detail on message expiry, but as a summary it is when a message is published to an endpoint with a timer, or time-to-live. When this timer expires, the message is removed from the original endpoint and can be deleted or can be moved to a DMQ.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Poison Message:&lt;/strong&gt; The second reason a message can lose delivery eligibility is if it is redelivered from an endpoint to a consumer too many times. This scenario could occur when a consumer is unable to process a message and crashes before sending an &lt;a href="https://solace.com/blog/delivery-modes-direct-messaging-vs-persistent-messaging/"&gt;application acknowledgement&lt;/a&gt;. When that application reconnects to the endpoint, it will receive the same message and would be stuck in a loop. In this case, the message is referred to as a poison message. To ensure an application does not get stuck in this loop, an endpoint can be set to redeliver a message a maximum number of times with the setting ‘Maximum Redelivery Count’. Once exceeded, the message will be removed from the endpoint or can be moved to a DMQ.
&lt;a href="https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-01.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--4NWjEEVW--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-01.png" alt=""&gt;&lt;/a&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;How do I use a Dead Message Queue with Solace PubSub+ Event Broker?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;A DMQ on Solace PubSub+ Event Broker is configured as a normal queue and can be created in the same manner on the Queue page of PubSub+ Broker Manager.&lt;br&gt;&lt;br&gt;
&lt;a href="https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-02.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--adjVfb5Y--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-02.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Once created, the DMQ is configured on the original endpoint in the ‘DMQ Name’ field.&lt;br&gt;&lt;br&gt;
&lt;a href="https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-03.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--twmPQOTl--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-03.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Note that messages will not be moved into a DMQ unless they are published with the flag ‘DMQ-Eligible’. Without this set, the messages will be deleted from the original queue when they lose delivery eligibility.&lt;/p&gt;

&lt;p&gt;That is an important point that bears repeating: &lt;strong&gt;&lt;em&gt;Messages must be DMQ-Eligible!&lt;br&gt;&lt;br&gt;
&lt;a href="https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-04.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--5WO9ODAC--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-04-1024x376.png" alt=""&gt;&lt;/a&gt;&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;** ** If you want messages that expire to go to a DMQ, you need:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Queue with ‘Respect-TTL’ enabled, a DMQ configured, and optionally a ‘Maximum-TTL’ specified&lt;/li&gt;
&lt;li&gt;Published messages can have a ‘Message-TTL’ and must be ‘DMQ-Eligible’&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-05.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--el3qYVVv--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-05.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you want messages that reach the maximum redelivery count to go to a DMQ, you need:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Queue with ‘Maximum Redelivery Count’ set (Redeliver Forever disabled), and a DMQ configured&lt;/li&gt;
&lt;li&gt;Published messages must be ‘DMQ-Eligible’&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-06.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--dEy9CeNp--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-06-1024x336.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;When a message moves from an endpoint to its DMQ, the below highlighted statistics will reflect this.&lt;br&gt;&lt;br&gt;
&lt;a href="https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-07.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--uDX88alT--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/06/dmq-post_pic-07.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Why would I use a DMQ?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;A DMQ is useful for special processing when messages are unable to be consumed on their original endpoint. This could be for expedited processing of orders, or the DMQ consumer may process the message in a different way than the original consumer.&lt;/p&gt;

&lt;p&gt;Take for example an order management system that must process orders in a timely manner. For orders that are not processed in the desired amount of time, they could be expired to a dead message queue for expedited processing.&lt;/p&gt;

&lt;p&gt;Another good example is error handling: a message that can’t be consumed from the original queue is moved to a DMQ to be inspected and processed.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;I hope I’ve helped you feel more comfortable with what DMQs are and how to use them. If you found this post useful, you might want to check out the &lt;a href="https://docs.solace.com/Solace-JMS-API/Setting-Message-Properties.htm"&gt;message properties section of our docs&lt;/a&gt;, and our &lt;a href="https://www.solace.dev/"&gt;PubSub+ for Developers&lt;/a&gt; page for more information. If you have any questions about queues and topic endpoints, try posting them to the &lt;a href="https://solace.community/"&gt;Solace Developer Community&lt;/a&gt;!&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://solace.com/blog/pubsub-message-handling-features-dead-message-queues/"&gt;PubSub+ Message Handling Features: Dead Message Queues&lt;/a&gt; appeared first on &lt;a href="https://solace.com"&gt;Solace&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>fordevelopers</category>
    </item>
    <item>
      <title>PubSub+ Messaging Handling Features: Message Expiry</title>
      <dc:creator>Leah Robert</dc:creator>
      <pubDate>Tue, 11 May 2021 13:15:07 +0000</pubDate>
      <link>https://dev.to/solacedevs/pubsub-messaging-handling-features-message-expiry-ajo</link>
      <guid>https://dev.to/solacedevs/pubsub-messaging-handling-features-message-expiry-ajo</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--D1JLn1R6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/04/solace-blog-featured-image_hourglass-green.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--D1JLn1R6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/04/solace-blog-featured-image_hourglass-green.jpg" alt=""&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Message handling features can help administrators and developers control how messages behave on the event broker and how they are received by consumers. This is the first in a series of blog posts in which I’ll introduce the various message handling features supported by Solace &lt;a href="https://solace.com/products/event-broker/"&gt;PubSub+ Event Brokers&lt;/a&gt;, starting with message expiry. Before reading this you should be familiar with both &lt;a href="https://solace.com/blog/queues-vs-topic-endpoints/"&gt;Solace endpoints&lt;/a&gt; and &lt;a href="https://solace.com/blog/delivery-modes-direct-messaging-vs-persistent-messaging/"&gt;Solace persistent messaging&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;What is Message Expiry?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Message expiry is a timer that dictates the lifespan of the message. The message will persist on an endpoint until that timer expires. Without this timer, a message will persist on a Solace endpoint indefinitely, or until it is consumed by an application or deleted by an administrator.&lt;/p&gt;

&lt;p&gt;Message expiry is also commonly referred to as ‘message time-to-live’ or ‘message-TTL’.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;How do I use message expiry with Solace PubSub+ Event Broker?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;When considering message expiry, you need to consider a couple of required configurations. First, your endpoint must ‘Respect-TTL’ – this setting informs the endpoint to actively check messages for a TTL value. Next, you must set the TTL for the message.&lt;/p&gt;

&lt;p&gt;There are two options to set the TTL:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Set ‘Maximum TTL’ on the endpoint. This will apply to all messages that are stored in the endpoint and is measured in seconds.&lt;/li&gt;
&lt;li&gt;The publisher optionally sets the ‘Message-TTL’ on the message before sending it. This method allows the publisher to decide how long each message should live and if each message requires a TTL. This value is measured in milliseconds.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--NR4FrM6M--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/04/message-expiry-01-1024x396.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--NR4FrM6M--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/04/message-expiry-01-1024x396.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It is possible to set both the Message-TTL and the queue Max-TTL. The lower of the two is used for expiry.&lt;/p&gt;

&lt;p&gt;Once a message has expired, the default behavior is that the message is deleted from the endpoint. It is also possible to have the message move to a Dead-Message-Queue, for special error or behaviour handling. When a message is expired from the endpoint, the discard statistics will reflect this.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--YwbnqrtS--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/04/message-expiry-02-1024x482.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--YwbnqrtS--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2021/04/message-expiry-02-1024x482.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;What are some use cases for message expiry?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Message expiry, especially when set on the queue itself, is particularly useful in development environments where messages are sent to queues and are not consumed. To prevent the queue from filling up, you can use TTL to remove messages from a development queue as needed.&lt;/p&gt;

&lt;p&gt;A use case example of message expiry could be an order management system that must process orders in a timely manner. For orders that are not processed in the desired amount of time, they could be expired to a Dead-Message-Queue for special, expedited processing or for error handling.&lt;/p&gt;

&lt;p&gt;Another example could be an application that receives flight statuses. If a flight status is not consumed within a couple of hours, possibly due to the consuming application being unavailable, the flight status may no longer be relevant and is no longer required. The message could then be expired and removed from the endpoint.&lt;/p&gt;

&lt;p&gt;If you found this post useful, visit the &lt;a href="https://docs.solace.com/Solace-JMS-API/Setting-Message-Properties.htm"&gt;message properties section of our docs&lt;/a&gt;, and our &lt;a href="https://www.solace.dev/"&gt;PubSub+ for Developers&lt;/a&gt; page for more information. If you have any questions about queues and topic endpoints, post them to the &lt;a href="https://solace.community/"&gt;Solace Developer Community&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://solace.com/blog/pubsub-messaging-handling-features-message-expiry/"&gt;PubSub+ Messaging Handling Features: Message Expiry&lt;/a&gt; appeared first on &lt;a href="https://solace.com"&gt;Solace&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>fordevelopers</category>
    </item>
    <item>
      <title>Understanding Solace Delivery Modes: Promotion &amp; Demotion</title>
      <dc:creator>Leah Robert</dc:creator>
      <pubDate>Fri, 23 Oct 2020 13:02:49 +0000</pubDate>
      <link>https://dev.to/solacedevs/understanding-solace-delivery-modes-promotion-demotion-5165</link>
      <guid>https://dev.to/solacedevs/understanding-solace-delivery-modes-promotion-demotion-5165</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--8icwP-ap--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/10/solace-blog-featured-image_promotion-demotion.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--8icwP-ap--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/10/solace-blog-featured-image_promotion-demotion.jpg" alt=""&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;In a previous blog post I explained the two delivery modes that Solace supports: &lt;a href="https://solace.com/blog/delivery-modes-direct-messaging-vs-persistent-messaging/"&gt;direct messaging and persistent messaging&lt;/a&gt;, which is also called guaranteed messaging. In this blog post I will explain the promotion and demotion of messages.&lt;/p&gt;

&lt;p&gt;Before diving in to message promotion and demotion, it’s important to understand the basics of &lt;a href="https://solace.com/blog/publish-subscribe-messaging-pattern/"&gt;publish/subscribe messaging&lt;/a&gt;. In short, it’s a message exchange pattern that lets applications send (publish) information (as messages) to a topic (a message property represented by a text string) that indicates what the message is about, and applications that want that kind of information can subscribe to receive all messages with topics that indicate information they want to receive. This makes it easy and efficient to fan messages out to any number of interested applications without any configuration or overhead.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/10/message-promotion-demotion_pic-01.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--x5uG6RMO--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/10/message-promotion-demotion_pic-01-1024x698.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Another thing you need to understand before we dive in to message promotion and demotion is that &lt;a href="https://solace.com/blog/topic-subscription-queues/"&gt;topics can be mapped to queues&lt;/a&gt;. A topic subscription (i.e. that is, the means by which applications express interest in a given topic) can be applied to a queue. A &lt;a href="https://solace.com/blog/queues-vs-topic-endpoints/"&gt;queue&lt;/a&gt; is an object on the Solace &lt;a href="https://solace.com/products/event-broker/"&gt;PubSub+ Event Broker&lt;/a&gt; that stores messages (hence the term “persistent”) for an application to receive later. Applying a topic subscription to a queue means messages matching that subscription will be received and buffered by the queue.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/10/message-promotion-demotion_pic-02.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--dc8YE7xr--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/10/message-promotion-demotion_pic-02.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Message Promotion
&lt;/h2&gt;

&lt;p&gt;Message promotion occurs when a message that was published as direct ends up on an endpoint, which effectively guarantees its delivery. A direct message can end up on an endpoint when the endpoint’s topic subscription matches the message’s topic. In the below example, we can see the direct message is published to topic “a/b/c”. The queue subscription is “a/b/&amp;gt;”, which matches the published topic. The message is still received by the direct subscriber because of the subscription “a/b/c” and is also saved in the queue.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/10/message-promotion-demotion_pic-03.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--LpipkVrc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/10/message-promotion-demotion_pic-03-1024x429.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It is important to note that the message saved onto the queue has a change in delivery mode. Because the message was published as direct but is now saved in a queue making it act as a guaranteed or persistent message, the event broker changes the delivery mode to Solace ‘non-persistent’ to indicate to the consuming application that the message was promoted.&lt;/p&gt;

&lt;h2&gt;
  
  
  Message Demotion
&lt;/h2&gt;

&lt;p&gt;Message demotion, on the other hand, occurs when a message published as persistent matches a direct topic subscription. In this case the message delivery mode is changed from ‘persistent’ to ‘direct’ for the direct subscriber, but the message is still acknowledged to the publishing application once it has been saved in the receiving endpoint(s).&lt;/p&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/10/message-promotion-demotion_pic-04.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--aMGQKcBX--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/10/message-promotion-demotion_pic-04-1024x429.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Considerations
&lt;/h2&gt;

&lt;p&gt;It’s important to know that direct messages, even when promoted, are never acknowledged to the initial publisher. When a higher quality of service is required, you should always publish messages as persistent.&lt;/p&gt;

&lt;p&gt;You need to be wary of message promotion, because it can put unwanted backpressure on saving messages to an endpoint. Message promotion should be avoided whenever possible by ensuring that endpoint subscriptions do not match published direct messages.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;I hope I’ve helped you understand the concept of message promotion and demotion. If you found this post useful, visit &lt;a href="https://docs.solace.com/PubSub-Basics/Core-Concepts-Message-Delivery-Modes.htm#Message"&gt;this section of our docs&lt;/a&gt;, and our &lt;a href="https://www.solace.dev/"&gt;PubSub+ for Developers&lt;/a&gt; page for more information. If you have any questions about message promotion and demotion, our &lt;a href="https://solace.community/"&gt;developer community&lt;/a&gt; is a great place to pose questions and see what your fellow developers are talking about.&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://solace.com/blog/message-promotion-demotion/"&gt;Understanding Solace Delivery Modes: Promotion &amp;amp; Demotion&lt;/a&gt; appeared first on &lt;a href="https://solace.com"&gt;Solace&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>fordevelopers</category>
    </item>
    <item>
      <title>Understanding Solace Delivery Modes: Direct Messaging vs. Persistent Messaging</title>
      <dc:creator>Leah Robert</dc:creator>
      <pubDate>Thu, 24 Sep 2020 19:21:28 +0000</pubDate>
      <link>https://dev.to/solacedevs/understanding-solace-delivery-modes-direct-messaging-vs-persistent-messaging-2he3</link>
      <guid>https://dev.to/solacedevs/understanding-solace-delivery-modes-direct-messaging-vs-persistent-messaging-2he3</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--NqbU5CDv--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2019/07/chat-app-blog-featured-image.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--NqbU5CDv--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2019/07/chat-app-blog-featured-image.jpg" alt=""&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Solace supports two main delivery modes, also known as qualities of service: &lt;strong&gt;direct messaging&lt;/strong&gt; that delivers a message one time at most, and &lt;strong&gt;persistent messaging&lt;/strong&gt; that guarantees delivery &lt;em&gt;at least&lt;/em&gt; once.&lt;/p&gt;

&lt;p&gt;This short blog series will provide an overview of the delivery modes and an overview of message promotion and demotion.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Direct Messaging&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Direct messaging is over Transmission Control Protocol (TCP) and is therefore a reliable method of moving data. You can think of it as a ‘fire and forget’ model, where the publishing application sends the data to the Solace event broker and does not expect confirmation that the message was received.&lt;/p&gt;

&lt;p&gt;Direct messaging is used when data is not always required on the consuming end – as an example, consider GPS location updates. A consuming application would still have enough information about a vehicles location even if it misses a few updates, so receiving every single message is nice, but not critical, in this scenario.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Persistent Messaging&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Persistent messaging is also over TCP but has an additional set of acknowledgements beyond those used by TCP itself. When a message is sent as persistent, the broker acknowledges receipt of that message when the message is saved in an &lt;a href="https://solace.com/blog/queues-vs-topic-endpoints/"&gt;endpoint&lt;/a&gt; on the broker.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/09/delivery-modes-1.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--UfCy7els--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/09/delivery-modes-1.png" alt="Persistent messaging"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;To ensure message delivery, a message is also acknowledged by a consuming application once it has been received from the Solace event broker and has been processed. There are two acknowledgments that occur on the consuming side; one to confirm the application has received the message (Transport/API ACK), and one to confirm the application is done with the message (Application/Client ACK). The first acknowledgement allows the Solace event broker to send more messages to the consuming application – this increases efficiency as the consuming application will have buffered a set of messages ready to be processed. The second acknowledgement is sent when the consuming application is done processing the message and no longer requires that data – this acknowledgment removes the message from the endpoint on the Solace event broker.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/09/delivery-modes-2.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--fqMgIzU7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/09/delivery-modes-2.png" alt="persistent messaging vs direct messaging"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Persistent messaging with Solace occurs between the publishing application and the broker, and between the broker and the consuming application. If the consuming application is not connected or cannot keep up with the publishing application, the messages are stored in endpoints on the Solace event broker.&lt;/p&gt;

&lt;p&gt;Persistent messaging is used when data &lt;em&gt;must&lt;/em&gt; be received by the consuming application, even if they are offline, and data can’t be lost. An example is an online store where any loss in messages could mean a missed revenue opportunity, lost customer, or a too-late decision to replenish inventory of a hot-selling product.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Exactly Once Delivery&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;In most situations, Solace’s persistent messaging quality of service provides exactly once delivery of messages where data is received, processed, and acknowledged. However, a message can be sent to a consumer multiple times when acknowledgements are not received as expected by the broker.&lt;/p&gt;

&lt;p&gt;If a message is sent to a consuming application and the API ACK is received, the broker knows the consuming application has the message but has not yet completed processing of that message. If the consuming application were to disconnect from and reconnect to the broker, Solace would resend the message to the consuming application to ensure it will be processed. In this situation, the consuming application would need to verify if it has already processed the data and send the Application ACK to the broker to remove the message from the endpoint.&lt;/p&gt;

&lt;p&gt;This safety mechanism ensures the data is received by the consuming application and there is no message loss. Consuming applications should have duplicate message handling for this exact situation. Solace also supports &lt;a href="https://solace.com/blog/transactional-messaging-solace/"&gt;transactions&lt;/a&gt;, should your message flow require ACID properties.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/09/delivery-modes-3.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--nK8NU89i--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/09/delivery-modes-3-1024x616.png" alt="Exactly Once Delivery"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;How Do I Set Delivery Mode?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;On the publishing side, the delivery mode is dependent on the message property ‘Delivery Mode’. This property can be set to ‘DIRECT’ or to ‘PERSISTENT’. Below is an example of how this is set in the Solace Java API, &lt;a href="https://docs.solace.com/API-Developer-Online-Ref-Documentation/java/index.html"&gt;JCSMP&lt;/a&gt;:&lt;/p&gt;

&lt;p&gt;&lt;code&gt;Message.setDeliveryMode(‘PERSISTENT’);&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Note: queues can have topic subscriptions applied to them to get a publish-subscribe persistent messaging exchange pattern. You can read more in &lt;a href="https://solace.com/blog/topic-subscription-queues/"&gt;this blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The consuming side delivery mode is dependent on how the consuming application subscribes to the data. If the application applies a topic subscription to its connection, it receives data via direct messaging. If the application binds to an endpoint, it will receive the data in a persistent manner.&lt;/p&gt;

&lt;p&gt;To summarize the Solace delivery modes, direct messaging is an example of at most once delivery, where data is sent in a reliable manner, but is not guaranteed. Guaranteed or persistent messaging is an example of at least once delivery, where data will be guaranteed to reach its destination.&lt;/p&gt;

&lt;p&gt;In the next blog post in this series, I will explain how messages can be promoted and demoted. I hope this post has helped you understand the concept of message delivery modes. If you found this post useful, visit this &lt;a href="https://docs.solace.com/PubSub-Basics/Core-Concepts-Message-Delivery-Modes.htm"&gt;section of our docs&lt;/a&gt;, and our &lt;a href="https://www.solace.dev/"&gt;PubSub+ for Developers&lt;/a&gt; page for more information. If you have any questions about message delivery modes, try posting them to the &lt;a href="https://solace.community/"&gt;Solace Developer Community&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://solace.com/blog/delivery-modes-direct-messaging-vs-persistent-messaging/"&gt;Understanding Solace Delivery Modes: Direct Messaging vs. Persistent Messaging&lt;/a&gt; appeared first on &lt;a href="https://solace.com"&gt;Solace&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>fordevelopers</category>
    </item>
    <item>
      <title>Understanding Solace Endpoints: Message Queue Access Types for Consumers</title>
      <dc:creator>Leah Robert</dc:creator>
      <pubDate>Wed, 29 Apr 2020 12:00:00 +0000</pubDate>
      <link>https://dev.to/solacedevs/understanding-solace-endpoints-message-queue-access-types-for-consumers-42en</link>
      <guid>https://dev.to/solacedevs/understanding-solace-endpoints-message-queue-access-types-for-consumers-42en</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--bMt7Z8K1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2019/08/solace-default-blog-thumbnail-600x285.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--bMt7Z8K1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2019/08/solace-default-blog-thumbnail-600x285.jpg" alt="Further thoughts on FPGA co-processing and performance"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The concept of message queues is fundamental in message-oriented middleware (MOM) and a constant topic of discussion for Solace users. Generally speaking, a queue is defined as a storage area where a message is stored until it is consumed by an application, or it expires. A queue provides the guarantee that the message will never be lost even if the consuming application is unavailable or if the message broker crashes. Note that in addition to writing this blog post, I’ve also presented this concept in &lt;a href="https://www.youtube.com/watch?v=j2CHbCwzfY0&amp;amp;feature=youtu.be"&gt;a video you can watch here&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Solace endpoints are objects created on the event broker to persist messages. There are two types of endpoints: a queue endpoint (usually just called a queue) and a topic endpoint. I &lt;a href="https://solace.com/blog/queues-vs-topic-endpoints/"&gt;detailed the differences here&lt;/a&gt; if you want to learn more, and in this post I’ll explain the two consumer patterns you have to choose from, how they differ, and when you should use each.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;a href="https://solace.com/wp-content/uploads/2020/04/endpoint-consumer-pattern-post_pic-01.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--03ov0Xw7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/04/endpoint-consumer-pattern-post_pic-01-300x182.png" alt=""&gt;&lt;/a&gt;
&lt;/h2&gt;

&lt;h2&gt;
  
  
  Solace Message Queue Access Types
&lt;/h2&gt;

&lt;p&gt;In Solace &lt;a href="https://solace.com/products/event-broker/"&gt;PubSub+ Event Broker&lt;/a&gt;, a message from a queue can be consumed by only one application, even though multiple applications can be bound to the queue. Based on the use case, a queue can have two access types for consumers: exclusive and non-exclusive.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/04/endpoint-consumer-pattern-post_pic-02.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--zOaKsnPa--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/04/endpoint-consumer-pattern-post_pic-02-300x163.png" alt="solace message queue access types"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Exclusive Queue (Fault Tolerance Pattern)
&lt;/h3&gt;

&lt;p&gt;When an application disconnects from the event broker, the endpoint it was connected to will buffer and save the messages destined for that application. If the application does not connect for a long period of time and the incoming message rate does not slow, the queue could run the risk of filling up. There is also the case where a consuming application cannot have downtime when processing time-sensitive data.&lt;/p&gt;

&lt;p&gt;Using an exclusive queue, a developer could connect multiple instances of an application to the same queue to ensure messages are always processed. The first instance to connect, or bind, to the queue will receive all messages; should that instance of the application disconnect, the next instance that connected to the queue is prepared to take over activity and start consuming. This provides a fault tolerant method to consuming data from a queue without any downtime.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/04/endpoint-consumer-pattern-post_pic-03.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--lmvS6lnq--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/04/endpoint-consumer-pattern-post_pic-03.png" alt="solace message queue exclusive access type"&gt;&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Note: Topic endpoints do not support multiple consumers when set as exclusive, therefore this fault tolerant consumer pattern only applies to queues.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;For the developers out there, it may be useful to know there is an &lt;a href="https://solace.com/samples/solace-samples-java/feature_active-flow-indication/"&gt;Active Consumer Indication&lt;/a&gt; which indicates to a previously standby consumer they are now the active consumer. This can be useful for grouped applications to function properly in a fault tolerant consumer pattern.&lt;/p&gt;

&lt;h3&gt;
  
  
  Non-Exclusive Queue (Competing Consumer Pattern)
&lt;/h3&gt;

&lt;p&gt;For some use cases, the ingress rate (publish message rate) may be too fast for a single endpoint consumer to keep up. It may be required to have multiple instances of an application share an endpoint and consume data in a load-balancing manner.&lt;/p&gt;

&lt;p&gt;A Solace non-exclusive endpoint allows multiple connections to bind to it and messages are round robin distributed to those connected applications. There is also a consideration for the speed of each consuming application, meaning that messages will be sent to the consumer based on how fast or slow the consumer is. Based on the acknowledgment rate from the consumer, the broker will deliver the messages at the appropriate rate. This is often referred to as a competing consumer pattern.&lt;/p&gt;

&lt;p&gt;For example, in the below diagram, both Application A and Application B will get messages. If both applications are processing messages at the same rate, the broker will deliver an equal number of messages to both apps. However, if Application B slows down, then based on the acknowledgment rate back from Application B, the broker will be able to identify Application B as a slow consumer and send the messages at the appropriate rate to Application B. The broker takes care that consumer applications are never pressured, and therefore acts as a shock absorber.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/04/endpoint-consumer-pattern-post_pic-04.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--jWs9oe9u--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/04/endpoint-consumer-pattern-post_pic-04.png" alt="solace message queue non-exclusive access type"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Both a queue and topic endpoint support this ability. While its default state is to support only one consumer, a non-exclusive topic endpoint can support multiple consumers.&lt;/p&gt;

&lt;h2&gt;
  
  
  Considerations
&lt;/h2&gt;

&lt;p&gt;The maximum number of consumers on a single endpoint can be configured on the endpoint itself, with the following exceptions which only allow for one consumer:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The endpoint is an exclusive topic endpoint&lt;/li&gt;
&lt;li&gt;The endpoint is a &lt;a href="https://solace.com/blog/solace-endpoints-durable-vs-non-durable/"&gt;non-durable endpoint&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Access Type Setup
&lt;/h2&gt;

&lt;p&gt;The good news is that all this complex logic is done by the broker behind the scene without any manual intervention by the administrator. The only thing that an administrator must decide is whether the queue is exclusive or non-exclusive. This can be done while the queue is being created or can also be done at a later date.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/04/endpoint-consumer-pattern-post_pic-05.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--V9UKngga--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/04/endpoint-consumer-pattern-post_pic-05.png" alt="edit solace message queue settings"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This Solace message queue property can be changed without any downtime. Changing this at runtime will cause consumers to disconnect, however, properly written applications should automatically reconnect; when they do, the queue will start behaving with the changed value.&lt;/p&gt;

&lt;h2&gt;
  
  
  Which consumer pattern should you use?
&lt;/h2&gt;

&lt;p&gt;The access type to use will depend on the exact use case. Both access types have their benefits. The main deciding factor should be whether message ordering is important and if applications need to run in parallel to increase the overall throughput.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/04/endpoint-consumer-pattern-post_pic-06.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--AEez8S9_--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/04/endpoint-consumer-pattern-post_pic-06.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;These two access types can be combined together for some complex use case requirements like sticky load balancing or consumer group pattern. Read the blog post on &lt;a href="https://solace.com/blog/sticky-load-balancing-in-solace-pubsub-event-broker/"&gt;sticky load balancing&lt;/a&gt; for a detailed explanation.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;I hope this post has helped you understand the concept of access types, and how and when each access type should be used. If you found this post useful, you can visit the &lt;a href="https://docs.solace.com/PubSub-Basics/Endpoints.htm#Queues"&gt;queues section of our docs&lt;/a&gt; and our &lt;a href="https://www.solace.dev/"&gt;PubSub+ for Developers page&lt;/a&gt; for more information. You can also check out some &lt;a href="https://github.com/SolaceTraining/solace-simple-guaranteed-pubsub"&gt;sample code on Github.&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;You can also read more in my series about understanding Solace endpoints by visiting the posts below:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://solace.com/blog/queues-vs-topic-endpoints/"&gt;Understanding Solace Endpoints: Queues vs. Topic Endpoints&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://solace.com/blog/solace-endpoints-durable-vs-non-durable/"&gt;Understanding Solace Endpoints: Durable vs. Non-Durable&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Here’s the video version of this post that I mentioned above:  &lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://solace.com/blog/solace-message-queue-access-types/"&gt;Understanding Solace Endpoints: Message Queue Access Types for Consumers&lt;/a&gt; appeared first on &lt;a href="https://solace.com"&gt;Solace&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>solace</category>
      <category>pubsub</category>
    </item>
    <item>
      <title>Understanding Solace Endpoints: Durable vs. Non-Durable</title>
      <dc:creator>Leah Robert</dc:creator>
      <pubDate>Tue, 25 Feb 2020 19:14:30 +0000</pubDate>
      <link>https://dev.to/solacedevs/understanding-solace-endpoints-durable-vs-non-durable-53gd</link>
      <guid>https://dev.to/solacedevs/understanding-solace-endpoints-durable-vs-non-durable-53gd</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--whtiAn8C--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/02/DARK-Understanding-Solace-Endpoints-Durability.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--whtiAn8C--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/02/DARK-Understanding-Solace-Endpoints-Durability.png" alt=""&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;An endpoint’s purpose is to buffer messages for a consuming application. Some applications require all messages, whereas other applications require this guarantee only while they are connected. Solace supports both functionalities with durable and non-durable endpoints. In this post (&lt;a href="https://youtu.be/eRN8S9VgcZU"&gt;and this video&lt;/a&gt;) I’ll explain how durability affects endpoints and their contents.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Introduction to Solace Endpoints&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Solace endpoints are objects created on the event broker to persist messages. There are two types of endpoints: a queue endpoint (usually just called a queue) and a topic endpoint. For the differences between the two, check out my other &lt;a href="https://solace.com/blog/queues-vs-topic-endpoints/"&gt;blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--i2GTZq2t--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/02/understanding-solace-endpoints-durability_pic-1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--i2GTZq2t--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/02/understanding-solace-endpoints-durability_pic-1.png" alt="Understanding Solace Endpoints: Durability"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Durable Endpoints&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;A durable endpoint is one that stays on the Solace broker until it is explicitly deleted. This endpoint can be created by an administrator, or dynamically created by an application. Durable endpoints are most often used when consuming applications require all messages including those received by the event broker when the application is disconnected.&lt;/p&gt;

&lt;p&gt;As an example, imagine an order processing application. A consuming application must receive all order events to ensure each one is processed; any missed events could mean a loss in revenue. A durable endpoint would be used to ensure the consuming application receives all order events, even if they disconnect.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Non-durable Endpoints&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;A non-durable endpoint, also known as a temporary endpoint, has a shorter lifecycle and can only be created by an application. The endpoint has a lifespan of the client that created it, with an additional 60 seconds in case of unexpected disconnect. The 60 seconds provides the client with some time to reconnect to the endpoint before it and its contents are deleted from the Solace broker.&lt;/p&gt;

&lt;p&gt;An example use case with non-durable endpoints could be an online search for flights. While connected to the system, a consumer would want to see all the available flights at that time. Should they disconnect, they would only want the latest search results and no stale results from a previous search. A non-durable endpoint could be used to buffer these search results while ensuring old results from previous searches are not present.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Permissions and Access&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Message storage is a valuable resource on the event broker and administrators may want to control what applications have access to. Through the &lt;a href="https://docs.solace.com/Configuring-and-Managing/Configuring-Client-Profiles.htm#Config-Guaranteed-Params"&gt;client-profile&lt;/a&gt; object, an administrator can separately control whether an application is able to dynamically create its own durable or non-durable endpoints, and how many it is able to create.&lt;/p&gt;

&lt;p&gt;Endpoints also have their own permissions to control which applications can consume from them, modify them, and remove them. These permissions are set when the endpoint is initially created. If a client application creates an endpoint, it is automatically the owner of that endpoint and has full access to it.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--TSxY_AhV--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/02/understanding-solace-endpoints-durability_pic-2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--TSxY_AhV--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/02/understanding-solace-endpoints-durability_pic-2.png" alt="Endpoints owner"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It is also important to note that queues created by administrators cannot be removed by client applications, regardless of the permissions set on that endpoint.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Durable vs Non-Durable Endpoints&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;A durable endpoint can be created and deleted by administrators or applications; if created by an administrator, an application cannot delete the endpoint. Durable endpoints persist with a &lt;a href="https://docs.solace.com/Overviews/Redundancy-and-Fault-Tolerance-Overview.htm"&gt;high availability&lt;/a&gt; (HA) failover and with a &lt;a href="https://docs.solace.com/Overviews/Data-Center-Replication-Overview.htm"&gt;data replication&lt;/a&gt; (DR) failover. Non-durable endpoints can only be provisioned by applications and will remain on the broker if the client is connected, plus an additional 60 seconds for unexpected disconnects. Non-durable endpoints persist over HA failovers, however, due to the manual intervention required do not persist over DR failovers.&lt;/p&gt;

&lt;p&gt;Durable endpoints can support multiple consumers, dependent on &lt;a href="https://docs.solace.com/PubSub-Basics/Endpoints.htm#Durable"&gt;further configurations&lt;/a&gt; of that endpoint. Non-durable endpoints only support a single consumer, and the lifespan of that endpoint is dependent on that consumer.&lt;/p&gt;

&lt;p&gt;The name for durable endpoints must be defined by the administrator or application that provisions it, while non-durable endpoints also provide automatically generated names.&lt;br&gt;&lt;br&gt;
 &lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--cxVprdZR--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/02/understanding-solace-endpoints-durability_pic-3.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--cxVprdZR--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/02/understanding-solace-endpoints-durability_pic-3.jpg" alt="Durable vs non-durable endpoints"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Which durability should you use?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Your endpoint durability will relate exactly to the quality of service required by the consuming application. If your application requires all messages even when a disconnect occurs, a durable endpoint should be used. If your application can tolerate loss, or only requires messages while it is connected, a non-durable endpoint can be used.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;I hope this post has helped you understand the concept of endpoint durability, and how durability affects the two types of endpoints that Solace supports, along with their contents. In case you missed the link above, I’ve embedded below a video version of the same content. If you found this post useful, you can visit the &lt;a href="https://docs.solace.com/PubSub-Basics/Endpoints.htm"&gt;endpoints section of our docs&lt;/a&gt; and our &lt;a href="https://www.solace.dev/"&gt;PubSub+ for Developers&lt;/a&gt; page for more information. You can also check out some &lt;a href="https://github.com/SolaceTraining/solace-simple-guaranteed-pubsub"&gt;sample code on Github.&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you have any questions about queues and topic endpoints, try posting them to the &lt;a href="https://solace.community/"&gt;Solace Developer Community&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://solace.com/blog/solace-endpoints-durable-vs-non-durable/"&gt;Understanding Solace Endpoints: Durable vs. Non-Durable&lt;/a&gt; appeared first on &lt;a href="https://solace.com"&gt;Solace&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>fordevelopers</category>
      <category>solace</category>
      <category>pubsub</category>
    </item>
    <item>
      <title>Understanding Solace Endpoints: Queues vs. Topic Endpoints</title>
      <dc:creator>Leah Robert</dc:creator>
      <pubDate>Mon, 03 Feb 2020 21:23:29 +0000</pubDate>
      <link>https://dev.to/solacedevs/understanding-solace-endpoints-queues-vs-topic-endpoints-3mp</link>
      <guid>https://dev.to/solacedevs/understanding-solace-endpoints-queues-vs-topic-endpoints-3mp</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--7zyFyvAU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/01/blog-featured-image_registry.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--7zyFyvAU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/01/blog-featured-image_registry.jpg" alt=""&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;One of the most frequent questions customers ask me is “What is the difference between a queue vs. a topic endpoint?”. While both queues and topic endpoints persist messages, it’s important to understand what they are, how they’re different, and when each one should be used.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Introduction to Solace Endpoints&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://docs.solace.com/PubSub-Basics/Endpoints.htm"&gt;Solace endpoints&lt;/a&gt; are objects created on the event broker to persist messages. There are two types of endpoints: queue endpoints (usually just called queues) and topic endpoints.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/01/queues-vs-topic-endpoints_pic-0.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--ZmyYATxd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/01/queues-vs-topic-endpoints_pic-0.png" alt="queue endpoint and topic endpoint"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Topic Endpoints vs Topics&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Before we talk about queues vs. topic endpoints, it’s important to note that a topic endpoint is &lt;em&gt;not&lt;/em&gt; the same thing as a topic. Topics are a message property the event broker uses to route messages to their destination, and they aren’t administratively configured on the event broker. Topic endpoints, on the other hand, are objects that define the storage of messages for a consuming application, and they &lt;em&gt;do&lt;/em&gt; need to be provisioned on the event broker. Topic endpoints are more closely related to queues than to topics, as confusing as that can seem at first.&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Common Characteristics of All Endpoints&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;Before we compare queues and topic endpoints, let’s take a high-level look at endpoints in general:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://solace.com/blog/topic-subscription-queues/"&gt;&lt;strong&gt;Topic Subscriptions&lt;/strong&gt;&lt;/a&gt; &lt;strong&gt;:&lt;/strong&gt; A consuming application uses subscriptions to route messages towards it. Solace endpoints can have topic subscriptions applied to attract messages to the endpoint where a consuming application receives the messages from.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;a href="https://docs.solace.com/Solace-PubSub-Messaging-APIs/API-Developer-Guide/Using-Selectors.htm#using_selectors"&gt;Selectors&lt;/a&gt;:&lt;/strong&gt; A conditional statement applied to an endpoint by a consuming application to filter messages by their header and user properties.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;a href="https://docs.solace.com/PubSub-Basics/Endpoints.htm#Browsing_Queues"&gt;Queue Browsing&lt;/a&gt;:&lt;/strong&gt; A consuming applications’ ability to read messages from a queue without removing them from the queue.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Queue vs. Topic&lt;/strong&gt;  &lt;strong&gt;Endpoints&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Sending by Name:&lt;/strong&gt; A producing application has the option to send a message directly to a queue by referencing that queue by its name in the message properties. A producing application cannot, however, reference topic endpoints by name, and therefore only persist messages routed to the topic subscription applied to the topic endpoint.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Support for Multiple Topic Subscriptions:&lt;/strong&gt; Queues support multiple topic subscriptions. This allows for topic aggregation to a single consuming application. Topic endpoints support a single subscription; should that subscription change, all messages persisted to the topic endpoint are deleted. Messages persisted in queues are unaffected by subscription changes.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Application of Selectors:&lt;/strong&gt; Selectors can be applied to either type of endpoint to apply conditional logic, but the two endpoints differ in &lt;em&gt;when&lt;/em&gt; the conditional is processed. With queues, selectors are processed at egress, and with topic endpoints they are processed on ingress. This means that queues persist every message even if they don’t match the selector, while with topic endpoints messages are only persisted if they match both the topic subscription &lt;em&gt;and&lt;/em&gt; the selector.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Support for Multiple Consumers:&lt;/strong&gt; &lt;a href="https://docs.solace.com/PubSub-Basics/Endpoints.htm#Queue_Access_Types"&gt;Queues support multiple consumers&lt;/a&gt;, providing a fault tolerant option should a consuming application disconnect from the queue. Topic endpoints support a single consumer, matching the functionality of a JMS durable subscription.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Ability to Read Without Removal:&lt;/strong&gt; Finally, a queue can be read from without removing messages, whereas topic endpoints require the removal of messages to be read.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://solace.com/wp-content/uploads/2020/01/queues-vs-topic-endpoints_pic-1.png"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--FQGVU8Rd--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://solace.com/wp-content/uploads/2020/01/queues-vs-topic-endpoints_pic-1.png" alt="Queue vs topic endpoints"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Which endpoint should you use?&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;With all of that said, lets look at the question of queue vs. topic. Queues are used more often because of their support for more subscriptions, and more consumers, and the ability to read without removal which is very handy for troubleshooting and special processing.&lt;/p&gt;

&lt;p&gt;Topic endpoints may be better if you want to apply selector processing sooner to filter messages and not necessarily save them to the endpoint. Also, note that topic endpoints were originally created to support durable subscriptions in JMS, and is the only option for JMS durable subscribers.&lt;/p&gt;

&lt;p&gt;I hope this post has helped you understand the matter of queue vs topic endpoint. If you found this post useful, visit the &lt;a href="https://docs.solace.com/PubSub-Basics/Endpoints.htm"&gt;endpoints section of our docs&lt;/a&gt;, and our &lt;a href="https://www.solace.dev/"&gt;PubSub+ for Developers&lt;/a&gt; page for more information. If you have any questions about queues and topic endpoints, try posting them to the &lt;a href="https://solace.community/"&gt;Solace Developer Community&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://solace.com/blog/queues-vs-topic-endpoints/"&gt;Understanding Solace Endpoints: Queues vs. Topic Endpoints&lt;/a&gt; appeared first on &lt;a href="https://solace.com"&gt;Solace&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>solace</category>
      <category>pubsub</category>
    </item>
  </channel>
</rss>
