Persistent Socket Connections between Rolling Updates on Galaxy - Do They work?

Hey everyone, I have a Meteor app on galaxy that’s only ever needed one server. Whenever I update the code, the server goes down and client apps can’t connect to it temporarily. I’ve assumed for a while that if I had multiple servers running–as the documentation says–“rolling updates” would be performed and there would always be a server for users to connect to, and most importantly socket connections would be maintained between servers transparently to the end user.

Does anyone have an proof and experience of this? Is it really that seamless? Why isn’t it that seamless if you have one server? It seems it might be the right thing to do for galaxy to advertise this capability by gracefully upgrading even just one server. But that’s not the case. As a result I’m worried that it’s even capable of doing it at all.

What has everyone experienced?

We have experienced the same with apps deployed to one container. Our short term solution is to delay the update until the user refreshes the page or closes the browser and comes back. It can also be handy to see the galaxy version of the app so that you know if you’re seeing an outdated version:

// client/startup.js

Meteor.startup(function() {

  if (Meteor.isProduction) {
    
    Meteor.call('getGalaxyVersion', function (err, res) {
      if (err) {
        console.log(err);
      } else {
        console.log(res);
      }
    });

    Meteor._reload.onMigrate(function () {
      return [false];
    });
  }

});

// lib/methods.js
Meteor.methods({

  getGalaxyVersion () {
    return process.env.GALAXY_APP_VERSION_ID;
  }

});