diff options
Diffstat (limited to 'router.html')
| -rw-r--r-- | router.html | 64 |
1 files changed, 34 insertions, 30 deletions
diff --git a/router.html b/router.html index 1d2bb42..6c6e29e 100644 --- a/router.html +++ b/router.html | |||
| @@ -30,9 +30,6 @@ | |||
| 30 | 30 | ||
| 31 | 31 | ||
| 32 | 32 | ||
| 33 | <link rel="index" title="Index" | ||
| 34 | href="genindex.html"/> | ||
| 35 | <link rel="search" title="Search" href="search.html"/> | ||
| 36 | <link rel="top" title="EventMQ 0 documentation" href="index.html"/> | 33 | <link rel="top" title="EventMQ 0 documentation" href="index.html"/> |
| 37 | <link rel="up" title="API Documentation" href="api.html"/> | 34 | <link rel="up" title="API Documentation" href="api.html"/> |
| 38 | <link rel="next" title="sender – Sender" href="sender.html"/> | 35 | <link rel="next" title="sender – Sender" href="sender.html"/> |
| @@ -64,7 +61,7 @@ | |||
| 64 | 61 | ||
| 65 | 62 | ||
| 66 | <div class="version"> | 63 | <div class="version"> |
| 67 | 0.2.6.3 | 64 | 0.2.6.5 |
| 68 | </div> | 65 | </div> |
| 69 | 66 | ||
| 70 | 67 | ||
| @@ -93,7 +90,7 @@ | |||
| 93 | <li class="toctree-l2"><a class="reference internal" href="jobmanager.html"><code class="docutils literal"><span class="pre">jobmanager</span></code> – Job Manager</a></li> | 90 | <li class="toctree-l2"><a class="reference internal" href="jobmanager.html"><code class="docutils literal"><span class="pre">jobmanager</span></code> – Job Manager</a></li> |
| 94 | <li class="toctree-l2"><a class="reference internal" href="poller.html"><code class="docutils literal"><span class="pre">poller</span></code> – Poller</a></li> | 91 | <li class="toctree-l2"><a class="reference internal" href="poller.html"><code class="docutils literal"><span class="pre">poller</span></code> – Poller</a></li> |
| 95 | <li class="toctree-l2"><a class="reference internal" href="receiver.html"><code class="docutils literal"><span class="pre">receiver</span></code> – Receiver</a></li> | 92 | <li class="toctree-l2"><a class="reference internal" href="receiver.html"><code class="docutils literal"><span class="pre">receiver</span></code> – Receiver</a></li> |
| 96 | <li class="toctree-l2 current"><a class="current reference internal" href="#"><code class="docutils literal"><span class="pre">router</span></code> – Router</a></li> | 93 | <li class="toctree-l2 current"><a class="current reference internal" href=""><code class="docutils literal"><span class="pre">router</span></code> – Router</a></li> |
| 97 | <li class="toctree-l2"><a class="reference internal" href="sender.html"><code class="docutils literal"><span class="pre">sender</span></code> – Sender</a></li> | 94 | <li class="toctree-l2"><a class="reference internal" href="sender.html"><code class="docutils literal"><span class="pre">sender</span></code> – Sender</a></li> |
| 98 | <li class="toctree-l2"><a class="reference internal" href="utils/index.html"><code class="docutils literal"><span class="pre">utils</span></code> – Utilities</a></li> | 95 | <li class="toctree-l2"><a class="reference internal" href="utils/index.html"><code class="docutils literal"><span class="pre">utils</span></code> – Utilities</a></li> |
| 99 | </ul> | 96 | </ul> |
| @@ -121,7 +118,7 @@ | |||
| 121 | <div class="rst-content"> | 118 | <div class="rst-content"> |
| 122 | 119 | ||
| 123 | 120 | ||
| 124 | 121 | ||
| 125 | 122 | ||
| 126 | 123 | ||
| 127 | 124 | ||
| @@ -160,7 +157,7 @@ | |||
| 160 | <col class="field-name" /> | 157 | <col class="field-name" /> |
| 161 | <col class="field-body" /> | 158 | <col class="field-body" /> |
| 162 | <tbody valign="top"> | 159 | <tbody valign="top"> |
| 163 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>scheduler_id</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – unique id of the scheduler to add</td> | 160 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>scheduler_id</strong> (<a class="reference external" href="https://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – unique id of the scheduler to add</td> |
| 164 | </tr> | 161 | </tr> |
| 165 | </tbody> | 162 | </tbody> |
| 166 | </table> | 163 | </table> |
| @@ -175,7 +172,7 @@ | |||
| 175 | <col class="field-body" /> | 172 | <col class="field-body" /> |
| 176 | <tbody valign="top"> | 173 | <tbody valign="top"> |
| 177 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple"> | 174 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple"> |
| 178 | <li><strong>worker_id</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – unique id of the worker to add</li> | 175 | <li><strong>worker_id</strong> (<a class="reference external" href="https://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – unique id of the worker to add</li> |
| 179 | <li><strong>queues</strong> – queue or queues this worker should be a member of</li> | 176 | <li><strong>queues</strong> – queue or queues this worker should be a member of</li> |
| 180 | </ul> | 177 | </ul> |
| 181 | </td> | 178 | </td> |
| @@ -207,13 +204,15 @@ queue.</p> | |||
| 207 | <col class="field-name" /> | 204 | <col class="field-name" /> |
| 208 | <col class="field-body" /> | 205 | <col class="field-body" /> |
| 209 | <tbody valign="top"> | 206 | <tbody valign="top"> |
| 210 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><p class="first"><strong>queue_name</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Name of the queue</p> | 207 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><p class="first"><strong>queue_name</strong> (<a class="reference external" href="https://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Name of the queue</p> |
| 211 | </td> | 208 | </td> |
| 212 | </tr> | 209 | </tr> |
| 213 | <tr class="field-even field"><th class="field-name">Raises:</th><td class="field-body"><ul class="first simple"> | 210 | <tr class="field-even field"><th class="field-name">Raises:</th><td class="field-body"><ul class="first simple"> |
| 214 | <li><code class="xref py py-exc docutils literal"><span class="pre">NoAvailableWorkerSlotsError</span></code> – Raised when there are no available</li> | 211 | <li><code class="xref py py-exc docutils literal"><span class="pre">NoAvailableWorkerSlotsError</span></code> – |
| 215 | <li>slots in any the job managers.</li> | 212 | Raised when there are no available</li> |
| 216 | <li><code class="xref py py-exc docutils literal"><span class="pre">UnknownQueueError</span></code> – Raised when <code class="docutils literal"><span class="pre">queue_name</span></code> is not found in | 213 | <li><strong>slots in any the job managers.</strong> –</li> |
| 214 | <li><code class="xref py py-exc docutils literal"><span class="pre">UnknownQueueError</span></code> – | ||
| 215 | Raised when <code class="docutils literal"><span class="pre">queue_name</span></code> is not found in | ||
| 217 | self.queues</li> | 216 | self.queues</li> |
| 218 | </ul> | 217 | </ul> |
| 219 | </td> | 218 | </td> |
| @@ -231,10 +230,14 @@ self.queues</li> | |||
| 231 | <dl class="method"> | 230 | <dl class="method"> |
| 232 | <dt id="eventmq.router.Router.get_status"> | 231 | <dt id="eventmq.router.Router.get_status"> |
| 233 | <code class="descname">get_status</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#eventmq.router.Router.get_status" title="Permalink to this definition">¶</a></dt> | 232 | <code class="descname">get_status</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#eventmq.router.Router.get_status" title="Permalink to this definition">¶</a></dt> |
| 234 | <dd><dl class="docutils"> | 233 | <dd><table class="docutils field-list" frame="void" rules="none"> |
| 235 | <dt>Return</dt> | 234 | <col class="field-name" /> |
| 236 | <dd>(str) Serialized information about the current state of the router.</dd> | 235 | <col class="field-body" /> |
| 237 | </dl> | 236 | <tbody valign="top"> |
| 237 | <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">(str) Serialized information about the current state of the router.</td> | ||
| 238 | </tr> | ||
| 239 | </tbody> | ||
| 240 | </table> | ||
| 238 | </dd></dl> | 241 | </dd></dl> |
| 239 | 242 | ||
| 240 | <dl class="attribute"> | 243 | <dl class="attribute"> |
| @@ -276,8 +279,8 @@ and announces itself.</p> | |||
| 276 | <col class="field-body" /> | 279 | <col class="field-body" /> |
| 277 | <tbody valign="top"> | 280 | <tbody valign="top"> |
| 278 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple"> | 281 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple"> |
| 279 | <li><strong>sender</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The id of the sender</li> | 282 | <li><strong>sender</strong> (<a class="reference external" href="https://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The id of the sender</li> |
| 280 | <li><strong>msgid</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Unique identifier for this message</li> | 283 | <li><strong>msgid</strong> (<a class="reference external" href="https://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Unique identifier for this message</li> |
| 281 | <li><strong>msg</strong> – The actual message that was sent</li> | 284 | <li><strong>msg</strong> – The actual message that was sent</li> |
| 282 | </ul> | 285 | </ul> |
| 283 | </td> | 286 | </td> |
| @@ -305,7 +308,7 @@ measurements</p> | |||
| 305 | <li><strong>sender</strong> – </li> | 308 | <li><strong>sender</strong> – </li> |
| 306 | <li><strong>msgid</strong> – </li> | 309 | <li><strong>msgid</strong> – </li> |
| 307 | <li><strong>msgid</strong> – </li> | 310 | <li><strong>msgid</strong> – </li> |
| 308 | <li><strong>depth</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#int" title="(in Python v2.7)"><em>int</em></a>) – The recusion depth in retrying when PeerGoneAwayError | 311 | <li><strong>depth</strong> (<a class="reference external" href="https://docs.python.org/library/functions.html#int" title="(in Python v2.7)"><em>int</em></a>) – The recusion depth in retrying when PeerGoneAwayError |
| 309 | is raised.</li> | 312 | is raised.</li> |
| 310 | </ul> | 313 | </ul> |
| 311 | </td> | 314 | </td> |
| @@ -322,11 +325,11 @@ is raised.</li> | |||
| 322 | <col class="field-name" /> | 325 | <col class="field-name" /> |
| 323 | <col class="field-body" /> | 326 | <col class="field-body" /> |
| 324 | <tbody valign="top"> | 327 | <tbody valign="top"> |
| 325 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>unprioritized_iterable</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#iter" title="(in Python v2.7)"><em>iter</em></a>) – Any list, tuple, etc where the | 328 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>unprioritized_iterable</strong> (<a class="reference external" href="https://docs.python.org/library/functions.html#iter" title="(in Python v2.7)"><em>iter</em></a>) – Any list, tuple, etc where the |
| 326 | 0-index key is an integer to use as priority. Largest numbers | 329 | 0-index key is an integer to use as priority. Largest numbers |
| 327 | come first.</td> | 330 | come first.</td> |
| 328 | </tr> | 331 | </tr> |
| 329 | <tr class="field-even field"><th class="field-name">Raises:</th><td class="field-body">IndexError - There was no 0-index element.</td> | 332 | <tr class="field-even field"><th class="field-name">Raises:</th><td class="field-body"><strong>IndexError - There was no 0-index element.</strong> –</td> |
| 330 | </tr> | 333 | </tr> |
| 331 | <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">decsending order list. E.g. ((20, ‘a’), (14, ‘b’), (12, ‘c’))</td> | 334 | <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">decsending order list. E.g. ((20, ‘a’), (14, ‘b’), (12, ‘c’))</td> |
| 332 | </tr> | 335 | </tr> |
| @@ -348,7 +351,8 @@ called. This is used to short circuit message retry attempts.</li> | |||
| 348 | </ul> | 351 | </ul> |
| 349 | </td> | 352 | </td> |
| 350 | </tr> | 353 | </tr> |
| 351 | <tr class="field-even field"><th class="field-name">Raises:</th><td class="field-body"><p class="first last"><code class="xref py py-exc docutils literal"><span class="pre">InvalidMessageError</span></code> – Unable to parse the message</p> | 354 | <tr class="field-even field"><th class="field-name">Raises:</th><td class="field-body"><p class="first last"><code class="xref py py-exc docutils literal"><span class="pre">InvalidMessageError</span></code> – |
| 355 | Unable to parse the message</p> | ||
| 352 | </td> | 356 | </td> |
| 353 | </tr> | 357 | </tr> |
| 354 | </tbody> | 358 | </tbody> |
| @@ -409,7 +413,7 @@ worker slot, so you may see duplicate addresses.</p> | |||
| 409 | <dl class="attribute"> | 413 | <dl class="attribute"> |
| 410 | <dt id="eventmq.router.Router.scheduler_queue"> | 414 | <dt id="eventmq.router.Router.scheduler_queue"> |
| 411 | <code class="descname">scheduler_queue</code><em class="property"> = None</em><a class="headerlink" href="#eventmq.router.Router.scheduler_queue" title="Permalink to this definition">¶</a></dt> | 415 | <code class="descname">scheduler_queue</code><em class="property"> = None</em><a class="headerlink" href="#eventmq.router.Router.scheduler_queue" title="Permalink to this definition">¶</a></dt> |
| 412 | <dd><p><em>Queue for schedulers to use</em></p> | 416 | <dd><p>Queue for schedulers to use:</p> |
| 413 | </dd></dl> | 417 | </dd></dl> |
| 414 | 418 | ||
| 415 | <dl class="attribute"> | 419 | <dl class="attribute"> |
| @@ -437,8 +441,8 @@ Contains dictionaries:</p> | |||
| 437 | <col class="field-body" /> | 441 | <col class="field-body" /> |
| 438 | <tbody valign="top"> | 442 | <tbody valign="top"> |
| 439 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> | 443 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> |
| 440 | <li><strong>socket</strong> (<a class="reference external" href="https://docs.python.org/2/library/socket.html#module-socket" title="(in Python v2.7)"><em>socket</em></a>) – The socket to use for this ack</li> | 444 | <li><strong>socket</strong> (<a class="reference external" href="https://docs.python.org/library/socket.html#module-socket" title="(in Python v2.7)"><em>socket</em></a>) – The socket to use for this ack</li> |
| 441 | <li><strong>recipient</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The recipient id for the ack</li> | 445 | <li><strong>recipient</strong> (<a class="reference external" href="https://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – The recipient id for the ack</li> |
| 442 | <li><strong>msgid</strong> – The unique id that we are acknowledging</li> | 446 | <li><strong>msgid</strong> – The unique id that we are acknowledging</li> |
| 443 | </ul> | 447 | </ul> |
| 444 | </td> | 448 | </td> |
| @@ -463,8 +467,8 @@ needed when building messages</p> | |||
| 463 | <col class="field-body" /> | 467 | <col class="field-body" /> |
| 464 | <tbody valign="top"> | 468 | <tbody valign="top"> |
| 465 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> | 469 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple"> |
| 466 | <li><strong>socket</strong> (<a class="reference external" href="https://docs.python.org/2/library/socket.html#module-socket" title="(in Python v2.7)"><em>socket</em></a>) – the socket to send the heartbeat with</li> | 470 | <li><strong>socket</strong> (<a class="reference external" href="https://docs.python.org/library/socket.html#module-socket" title="(in Python v2.7)"><em>socket</em></a>) – the socket to send the heartbeat with</li> |
| 467 | <li><strong>recipient</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Worker I</li> | 471 | <li><strong>recipient</strong> (<a class="reference external" href="https://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – Worker I</li> |
| 468 | </ul> | 472 | </ul> |
| 469 | </td> | 473 | </td> |
| 470 | </tr> | 474 | </tr> |
| @@ -506,9 +510,9 @@ process receives a SIGHUP from the system.</p> | |||
| 506 | <col class="field-body" /> | 510 | <col class="field-body" /> |
| 507 | <tbody valign="top"> | 511 | <tbody valign="top"> |
| 508 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple"> | 512 | <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple"> |
| 509 | <li><strong>frontend_addr</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – connection string to listen for requests</li> | 513 | <li><strong>frontend_addr</strong> (<a class="reference external" href="https://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – connection string to listen for requests</li> |
| 510 | <li><strong>backend_addr</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – connection string to listen for workers</li> | 514 | <li><strong>backend_addr</strong> (<a class="reference external" href="https://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – connection string to listen for workers</li> |
| 511 | <li><strong>administrative_addr</strong> (<a class="reference external" href="https://docs.python.org/2/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – connection string to listen for emq-cli | 515 | <li><strong>administrative_addr</strong> (<a class="reference external" href="https://docs.python.org/library/functions.html#str" title="(in Python v2.7)"><em>str</em></a>) – connection string to listen for emq-cli |
| 512 | commands on.</li> | 516 | commands on.</li> |
| 513 | </ul> | 517 | </ul> |
| 514 | </td> | 518 | </td> |