class UrlConfig

Ruby on Rails 8.1.2

Since v6.0.6

Available in: v6.0.6 v6.1.7.10 v7.0.10 v7.1.6 v7.2.3 v8.0.4 v8.1.2

Active Record Database Url Config

A UrlConfig object is created for each database configuration entry that is created from a URL. This can either be a URL string or a hash with a URL in place of the config hash.

A URL config:

postgres://localhost/foo

Becomes:

#<ActiveRecord::DatabaseConfigurations::UrlConfig:0x00007fdc3238f340
  @env_name="default_env", @name="primary",
  @config={adapter: "postgresql", database: "foo", host: "localhost"},
  @url="postgres://localhost/foo">

See ActiveRecord::DatabaseConfigurations for more info.

Inherits from

ActiveRecord::DatabaseConfigurations::HashConfig

Attributes

Methods (defined here)

Private methods

(3) Implementation detail — not part of the public API.

Methods (inherited)

From ActiveRecord::DatabaseConfigurations::HashConfig (22)

Type at least 2 characters to search.

↑↓ navigate · open · esc close