restart autobahn router without losing 'transaction'

#1

I am looking for a lossless solution to reboot my autobahn router live. What is a good way to do this? The router is obviously responding to rpc calls and pubsub stuff. As long as all my clients will reconnect I don’t have to worry about that. How can I insure that no operations are missed? I have a feeling that just restarting it under load would leave things halfway done, is that the case?

-g

0 Likes

#2

Hi Greg!

This is a highly non-trivial issue.

If you restart under load, in any environment with a high frequency of WAMP messages, it is virtually assured that e.g. some PubSub events are not dispatched or dispatched only to a subset of subscribers, or that one of the messages of a RPC fails.

Some of this may in principle be solvable purely at the level of the router, e.g. storing a list of pushed publications, but others probably won’t.

For the time being, you will need to implement your solution at the application level.

Regards,

Alex

···

Am Freitag, 21. November 2014 01:05:34 UTC+1 schrieb Greg Fausak:

I am looking for a lossless solution to reboot my autobahn router live. What is a good way to do this? The router is obviously responding to rpc calls and pubsub stuff. As long as all my clients will reconnect I don’t have to worry about that. How can I insure that no operations are missed? I have a feeling that just restarting it under load would leave things halfway done, is that the case?

-g

0 Likes

#3

Hi Alex,

Yes, this is a super hard problem! I was just curious if there were any plans to make this inherent?

A router level instruction like:

  • start shutdown

The router would stop allowing new activity. It would complete the current inflight stuff until the inflight buffer was at zero, then shutdown.

One way to implement this might be to stop authorizing all rpc/publish calls at the router. This would stop new work from being injected. Is there a way to look at the current inflight queue to determine when everything has drained?

-g

···

On Fri, Nov 21, 2014 at 5:17 AM, Alexander Gödde alexande...@googlemail.com wrote:

Hi Greg!

This is a highly non-trivial issue.

If you restart under load, in any environment with a high frequency of WAMP messages, it is virtually assured that e.g. some PubSub events are not dispatched or dispatched only to a subset of subscribers, or that one of the messages of a RPC fails.

Some of this may in principle be solvable purely at the level of the router, e.g. storing a list of pushed publications, but others probably won’t.

For the time being, you will need to implement your solution at the application level.

Regards,

Alex

Am Freitag, 21. November 2014 01:05:34 UTC+1 schrieb Greg Fausak:

I am looking for a lossless solution to reboot my autobahn router live. What is a good way to do this? The router is obviously responding to rpc calls and pubsub stuff. As long as all my clients will reconnect I don’t have to worry about that. How can I insure that no operations are missed? I have a feeling that just restarting it under load would leave things halfway done, is that the case?

-g

You received this message because you are subscribed to a topic in the Google Groups “Autobahn” group.

To unsubscribe from this topic, visit https://groups.google.com/d/topic/autobahnws/nKDKluZKhAU/unsubscribe.

To unsubscribe from this group and all its topics, send an email to autobahnws+...@googlegroups.com.

To post to this group, send email to autob...@googlegroups.com.

To view this discussion on the web visit https://groups.google.com/d/msgid/autobahnws/8508b1e5-c1fc-44ff-b85e-6e52b1bf0e15%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Greg Fausak
lgfa...@gmail.com

0 Likes

#4

Hi Greg,

what you outline is essentially the way I’d approach that: triggering graceful shutdown would disallow any further actions/connections, collect all currently unresolved deferreds per connection, close each connection when the former resolve, and then shutdown and stop the reactor. If you want to have an upper bound for the former process, add timers. Etc etc. Can be done, needs to touch deep internals not exposed and given the current backlog, dont hold your breath;)

···

On Fri, Nov 21, 2014 at 5:17 AM, Alexander Gödde alexande...@googlemail.com wrote:

Hi Greg!

This is a highly non-trivial issue.

If you restart under load, in any environment with a high frequency of WAMP messages, it is virtually assured that e.g. some PubSub events are not dispatched or dispatched only to a subset of subscribers, or that one of the messages of a RPC fails.

Some of this may in principle be solvable purely at the level of the router, e.g. storing a list of pushed publications, but others probably won’t.

For the time being, you will need to implement your solution at the application level.

Regards,

Alex

Am Freitag, 21. November 2014 01:05:34 UTC+1 schrieb Greg Fausak:

I am looking for a lossless solution to reboot my autobahn router live. What is a good way to do this? The router is obviously responding to rpc calls and pubsub stuff. As long as all my clients will reconnect I don’t have to worry about that. How can I insure that no operations are missed? I have a feeling that just restarting it under load would leave things halfway done, is that the case?

-g

You received this message because you are subscribed to a topic in the Google Groups “Autobahn” group.

To unsubscribe from this topic, visit https://groups.google.com/d/topic/autobahnws/nKDKluZKhAU/unsubscribe.

To unsubscribe from this group and all its topics, send an email to autobahnws+...@googlegroups.com.

To post to this group, send email to autob...@googlegroups.com.

To view this discussion on the web visit https://groups.google.com/d/msgid/autobahnws/8508b1e5-c1fc-44ff-b85e-6e52b1bf0e15%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.


Greg Fausak
lgfa...@gmail.com

0 Likes