instance method build_url_hash

Ruby on Rails 7.1.6

Since v6.0.6 Private

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

Signature

build_url_hash()

Return a Hash that can be merged into the main config that represents the passed in url

Source
# File activerecord/lib/active_record/database_configurations/url_config.rb, line 50
        def build_url_hash
          if url.nil? || url.start_with?("jdbc:", "http:", "https:")
            { url: url }
          else
            ConnectionUrlResolver.new(url).to_hash
          end
        end

Defined in activerecord/lib/active_record/database_configurations/url_config.rb line 50 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActiveRecord::DatabaseConfigurations::UrlConfig

Type at least 2 characters to search.

↑↓ navigate · open · esc close