diff options
author | Brett Walker <brett@digitalmoksha.com> | 2017-12-05 19:43:47 +0300 |
---|---|---|
committer | Stan Hu <stanhu@gmail.com> | 2017-12-05 19:43:47 +0300 |
commit | 02d97d46216b60568fb248f9aeb779528abd8e9c (patch) | |
tree | e8655dbc12e78e2f20e394564eb182b5eeead88f /lib/gitlab/database.rb | |
parent | 784edd654b8ef36535d3c1773b7a43d8f3c19b23 (diff) |
add Gitlab::Database.replication_slots_supported?
Diffstat (limited to 'lib/gitlab/database.rb')
-rw-r--r-- | lib/gitlab/database.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/gitlab/database.rb b/lib/gitlab/database.rb index cd7b4c043da..96922e1a62f 100644 --- a/lib/gitlab/database.rb +++ b/lib/gitlab/database.rb @@ -50,6 +50,10 @@ module Gitlab postgresql? && version.to_f >= 9.3 end + def self.replication_slots_supported? + postgresql? && version.to_f >= 9.4 + end + def self.nulls_last_order(field, direction = 'ASC') order = "#{field} #{direction}" |