Request mingle sync-data.
(state, from_node, revoked=None, **kwargs)
| 375 | |
| 376 | @inspect_command(visible=False) |
| 377 | def hello(state, from_node, revoked=None, **kwargs): |
| 378 | """Request mingle sync-data.""" |
| 379 | # pylint: disable=redefined-outer-name |
| 380 | # XXX Note that this redefines `revoked`: |
| 381 | # Outside of this scope that is a function. |
| 382 | if from_node != state.hostname: |
| 383 | logger.info('sync with %s', from_node) |
| 384 | if revoked: |
| 385 | worker_state.revoked.update(revoked) |
| 386 | # Do not send expired items to the other worker. |
| 387 | worker_state.revoked.purge() |
| 388 | return { |
| 389 | 'revoked': worker_state.revoked._data, |
| 390 | 'clock': state.app.clock.forward(), |
| 391 | } |
| 392 | |
| 393 | |
| 394 | @inspect_command(default_timeout=0.2) |