pythonpostgresqlopenshifthigh-availabilitydowntime

PostgreSQL high availability on Openshift gear


I have been testing the Openshift Online platform for several months now (using the free 3 gears option). I setup several python applications and also the very basic python application (just using the Openshift python template) and outside monitoring, which also kept the applications alive (= non idling).

My findings are that the applications are restarted every cca 14 days. And basically not available for cca 5-20 mins. In order to have 0 downtime the HA scalable setup is advised.

This is typically declared as 2+ gears for application server (e.g. python ) with HA proxy setup + 1 gear for the database (PostgreSQL in my case).

I wonder whether the DB gear would not be also restarted from time to time as it is in non-scaled application case?

Uptime Logs for python application:

Latest Events (up, down, start, pause)  Export Logs
Event   Date-Time   Reason  Duration

 Up 04-07-2014 19:03:10 OK  53 hrs, 11 mins
 Down   04-07-2014 18:54:48 --- 0 hrs, 8 mins
 Up 04-07-2014 18:48:51 OK  0 hrs, 5 mins
 Down   04-07-2014 18:45:29 --- 0 hrs, 3 mins
 Up 02-07-2014 22:52:56 OK  43 hrs, 52 mins
 Down   02-07-2014 22:32:38 --- 0 hrs, 20 mins
 Up 23-06-2014 11:41:43 OK  226 hrs, 50 mins
 Down   23-06-2014 11:27:05 --- 0 hrs, 14 mins   
 Up 03-06-2014 04:00:05 OK  487 hrs, 27 mins
 Down   03-06-2014 03:50:22 --- 0 hrs, 9 mins

Solution

  • Currently our database gears aren't scalable. This is something that will be resolved in the near future. However for now, its best to use a DBaaS as a work around. Thankfully we have several options on marketplace.openshift.com and you can easily tie those into your existing applications.