1
0
mirror of https://github.com/taigrr/nats.docs synced 2025-01-18 04:03:23 -08:00

updating docs

This commit is contained in:
ainsley
2019-06-07 10:00:40 -05:00
parent 6958cc239e
commit 548b48b06f
156 changed files with 306 additions and 374 deletions

View File

@@ -2353,11 +2353,12 @@
<section class="normal markdown-section">
<h1 id="queue-subscribers--sharing-work"><a name="queue-subscribers--sharing-work" class="plugin-anchor" href="#queue-subscribers--sharing-work"><i class="fa fa-link" aria-hidden="true"></i></a>Queue Subscribers &amp; Sharing Work</h1>
<p>NATS provides a load balancing feature called queue subscriptions. Using queue subscribers will load balance message delivery across a group of subscribers which can be used to provide application fault tolerance and scale workload processing.</p>
<p>To create a queue subscription, subscribers register a queue name. All subscribers with the same queue name form the queue group. As messages on the registered subject are published, one member of the group is chosen randomly to receive the message. Although queue groups have multiple subscribers, each message is consumed by only one.</p>
<p>One of the great features of NATS is that queue groups are defined by the subscribers, not on the server. Applications can create new queue groups without any server change.</p>
<p>Queue subscribers are ideal for auto scaling as you can add or remove them anytime, without any configuration changes or restarting the server or clients.</p>
<h1 id="queue-subscribers--scalability"><a name="queue-subscribers--scalability" class="plugin-anchor" href="#queue-subscribers--scalability"><i class="fa fa-link" aria-hidden="true"></i></a>Queue Subscribers &amp; Scalability</h1>
<p>NATS provides a built-in load balancing feature called distributed queues. Using queue subscribers will balance message delivery across a group of subscribers which can be used to provide application fault tolerance and scale workload processing.</p>
<p>To create a queue subscription, subscribers register a queue name. All subscribers with the same queue name form the queue group. This requires no configuration. As messages on the registered subject are published, one member of the group is chosen randomly to receive the message. Although queue groups have multiple subscribers, each message is consumed by only one.</p>
<p>One of the great features of NATS is that queue groups are defined by the application and their queue subscribers, not on the server configuration.</p>
<p>Queue subscribers are ideal for scaling services. Scale up is as simple as running another application, scale down is terminating the application with a signal that drains the in flight requests.
This flexibility and lack of any configuration changes makes NATS an excellent service communication technology that can work with all platform technologies.</p>
<div class="graphviz"><code data-viz="dot">
digraph nats_queues {
rankdir=LR
@@ -2418,7 +2419,7 @@ digraph nats_queues {
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Queue Groups","level":"2.5","depth":1,"next":{"title":"Acknowledgements","level":"2.6","depth":1,"path":"developer/concepts/acks.md","ref":"developer/concepts/acks.md","articles":[]},"previous":{"title":"Request-Reply","level":"2.4","depth":1,"path":"developer/concepts/reqreply.md","ref":"developer/concepts/reqreply.md","articles":[]},"dir":"ltr"},"config":{"plugins":["prism","-sharing","-highlight","include-html","toggle-chapters","anchors"],"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"prism":{"lang":{"ascii":"markup","text":"markup"}},"include-html":{},"toggle-chapters":{},"anchors":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","author":"The NATS Maintainers","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"NATS","gitbook":"*","description":"Administrative, developer and conceptual documentation for the NATS messaging system."},"file":{"path":"developer/concepts/queue.md","mtime":"2019-05-30T22:52:52.228Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2019-06-05T22:32:29.333Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Queue Groups","level":"2.5","depth":1,"next":{"title":"Acknowledgements","level":"2.6","depth":1,"path":"developer/concepts/acks.md","ref":"developer/concepts/acks.md","articles":[]},"previous":{"title":"Request-Reply","level":"2.4","depth":1,"path":"developer/concepts/reqreply.md","ref":"developer/concepts/reqreply.md","articles":[]},"dir":"ltr"},"config":{"plugins":["prism","-sharing","-highlight","include-html","toggle-chapters","anchors"],"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"prism":{"lang":{"ascii":"markup","text":"markup"}},"include-html":{},"toggle-chapters":{},"anchors":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","author":"The NATS Maintainers","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"NATS","gitbook":"*","description":"Administrative, developer and conceptual documentation for the NATS messaging system."},"file":{"path":"developer/concepts/queue.md","mtime":"2019-06-07T14:58:27.244Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2019-06-07T14:58:58.173Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>