Module: ActivePostgres
- Defined in:
- lib/active_postgres.rb,
lib/active_postgres/cli.rb,
lib/active_postgres/logger.rb,
lib/active_postgres/railtie.rb,
lib/active_postgres/secrets.rb,
lib/active_postgres/version.rb,
lib/active_postgres/failover.rb,
lib/active_postgres/overview.rb,
lib/active_postgres/installer.rb,
lib/active_postgres/validator.rb,
lib/active_postgres/credentials.rb,
lib/active_postgres/retry_helper.rb,
lib/active_postgres/ssh_executor.rb,
lib/active_postgres/configuration.rb,
lib/active_postgres/error_handler.rb,
lib/active_postgres/log_sanitizer.rb,
lib/active_postgres/components/ssl.rb,
lib/active_postgres/health_checker.rb,
lib/active_postgres/components/base.rb,
lib/active_postgres/components/core.rb,
lib/active_postgres/deployment_flow.rb,
lib/active_postgres/direct_executor.rb,
lib/active_postgres/rollback_manager.rb,
lib/active_postgres/components/repmgr.rb,
lib/active_postgres/connection_pooler.rb,
lib/active_postgres/performance_tuner.rb,
lib/active_postgres/component_resolver.rb,
lib/active_postgres/components/pgbouncer.rb,
lib/active_postgres/components/extensions.rb,
lib/active_postgres/components/monitoring.rb,
lib/active_postgres/components/pgbackrest.rb,
lib/active_postgres/rails/database_config.rb,
lib/active_postgres/rails/migration_guard.rb,
lib/active_postgres/cluster_deployment_flow.rb,
lib/active_postgres/standby_deployment_flow.rb,
lib/active_postgres/generators/active_postgres/install_generator.rb
Defined Under Namespace
Modules: ComponentResolver, Components, Generators, LogSanitizer, Rails, RetryHelper
Classes: CLI, ClusterDeploymentFlow, Configuration, ConnectionPooler, Credentials, DeploymentFlow, DirectExecutor, Error, ErrorHandler, Failover, HealthChecker, Installer, Logger, Overview, PerformanceTuner, Railtie, RollbackManager, SSHExecutor, Secrets, StandbyDeploymentFlow, Validator
Constant Summary
collapse
- VERSION =
'0.9.5'.freeze
Class Method Summary
collapse
Class Method Details
.failover_to(node_or_host) ⇒ Object
64
65
66
67
68
|
# File 'lib/active_postgres.rb', line 64
def self.failover_to(node_or_host)
config = Configuration.load
failover = Failover.new(config)
failover.promote(node_or_host)
end
|
.root ⇒ Object
54
55
56
|
# File 'lib/active_postgres.rb', line 54
def self.root
File.expand_path('..', __dir__)
end
|
.status ⇒ Object
58
59
60
61
62
|
# File 'lib/active_postgres.rb', line 58
def self.status
config = Configuration.load
health_checker = HealthChecker.new(config)
health_checker.cluster_status
end
|