Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ColumnSchema ¶
type ColumnSchema struct { ColumnName string UdtName string // data_type name CharacterMaximumLength string IsNullable string Order string ColumnDefault string IsPrimary bool }
ColumnSchema define of a column by database schema
func (*ColumnSchema) UpdateByColumnDefinition ¶
func (c *ColumnSchema) UpdateByColumnDefinition(col database.Column)
UpdateByColumnDefinition update column by column definition
type ColumnSchemas ¶
type ColumnSchemas []ColumnSchema
ColumnSchemas array of ColumnSchema
func (ColumnSchemas) GroupByColumnName ¶
func (cols ColumnSchemas) GroupByColumnName() map[string][]ColumnSchema
GroupByColumnName group column schema by column name
type Config ¶
type Config struct { SerectKey string `yaml:"serect_key" json:"-"` VerifyConfig bool `yaml:"verify_config" json:"-"` database.ConnectionInfo `yaml:"database_connection_info" json:"database_connection_info"` ForceRecreate bool `yaml:"force_recreate" json:"force_recreate"` Databases []database.Database `yaml:"databases_list" json:"databases_list"` }
Config contain config for agent
func (Config) DBConnectionString ¶
DBConnectionString get pg connection string
type ExistingColumnByTableName ¶
type ExistingColumnByTableName map[string][]ColumnSchema
ExistingColumnByTableName list of existing column_schema in database
type MissingColumns ¶
type MissingColumns struct { TableName string Columns []ColumnSchema IsCreate bool }
MissingColumns define missing columns and groupted by table name
func (MissingColumns) IsNeedMigrate ¶
func (mcs MissingColumns) IsNeedMigrate() bool
IsNeedMigrate check missing column is needed to make a migrate
Click to show internal directories.
Click to hide internal directories.