Before this PR, the current running time was being inspected to decide if the
vm lifetime could be extended. But since vm lifetime is absolute and not relative
this check is now removed.
This commit updates vmpooler gem dependencies in Gemfile and gemspec files. Without this change vmpooler is pinned to out of date version of multiple libraries.
This commit adds detection for redis connection failures to pool_manager. When a connection fails the error will be raised to executeforcing the connection to be re-established. Without this change, when a redis connection fails, it generates a redis connection error, which is swallowed by a rescue for StandardError, preventing the manager application component from recovering in the case of a redis connection failure.
This commit pins all the `Dockerfile` to Jruby 9.2.9. This is an
attempt to narrow down if the JRuby 9.2.11 is the reason for the
StackOverflow we were seeing or if there is something strange going on
with an update to the Gemfiles.
This commit switches the early `return` in `migrate_vm`'s connection
pooling block to a `break`, since `return` implies you are returning
something from a method and I don't think `migrate_vm` wants to do that.
This is a place where a partial type system like Sorbet seems useful
because then we'd have some idea about what the intended return is here.
This commit drops the `has_` prefix from several `?` style methods
because that's against the ruby style guide and redundant for a method
ending in `?`.
Prior to this commit the codebase used the `zero?` method for comparing
to 0 on some places and not in others.
This commit makes all comparison to zero consistently use the `==`.
This commit fixes a bug in update_clone_target where I believe `=` was
intended, not `==` because `==` just goes to the void context here.
Thanks Rubocop Lint/Void!
This commit updates places where previously we were casting both terms
in a float division into floats in order to ensure that float division
occurs to use the `fdiv` method, which will always do float division and
is available on both `Floats` and `Integers` because they are
both `Numeric`.
This commit updates the dashboard to use `URI.parse` instead of `Kernel#open`
because open can potentially open files on the server and has other
possible security issues.
Also updated the logger to use `File.open` as it is more explicit and
doesn't have the extra potential for abuse like `Kernel#open`
https://rubocop.readthedocs.io/en/latest/cops_security/#securityopen
As far as I can tell, this variable doesn't exist before this assignment
and is immediately overwritten with the result of the method call so I
don't think it needs to be here?
Prior to this commit there were a couple locations where exceptions were
saved to `_e` but weren't used in the handler except to re-raise the
exception, which simply calling the `raise` keyword will do without a
provided argument.
This commit removes the unnecessary assignment of the exception to a
variable and simply uses `raise` instead.
This commit:
* explicitly defines some short variable names that
generally make sense in the codebase.
* set numeric comparisons to be enforced instead of the predicate style
This commit adds the extra_config option to vmpooler to allow specifying additional configuration files to load from. Without this change vmpooler does not offer a mechanism to provide additional configuration files for the application.