class PerconaMigrator::DSN

Represents the 'DSN' argument of Percona's pt-online-schema-change See www.percona.com/doc/percona-toolkit/2.0/pt-online-schema-change.html#dsn-options

Attributes

database[R]
table_name[R]

Public Class Methods

new(database, table_name) click to toggle source

Constructor

@param database [String, Symbol] @param table_name [String, Symbol]

# File lib/percona_migrator/dsn.rb, line 11
def initialize(database, table_name)
  @database = database
  @table_name = table_name
end

Public Instance Methods

to_s() click to toggle source

Returns the pt-online-schema-change DSN string. See www.percona.com/doc/percona-toolkit/2.0/pt-online-schema-change.html#dsn-options

# File lib/percona_migrator/dsn.rb, line 18
def to_s
  "D=#{database},t=#{table_name}"
end