Class: Judoscale::Config::RuntimeContainer

Inherits:
String
  • Object
show all
Defined in:
lib/judoscale/config.rb

Instance Method Summary collapse

Instance Method Details

#redundant_instance?Boolean

Since Heroku exposes ordinal dyno ‘numbers’, we can tell if the current instance is redundant (and thus skip collecting some metrics sometimes) We don’t have a means of determining that on Render though — so every instance must be considered non-redundant



13
14
15
16
# File 'lib/judoscale/config.rb', line 13

def redundant_instance?
  instance_number = split(".")[1].to_i
  instance_number > 1
end