Documentation ¶
Index ¶
- Variables
- type Config
- type Ksql
- func (s *Ksql) Close() error
- func (s *Ksql) Drop() error
- func (s *Ksql) Lock() error
- func (s *Ksql) Open(url string) (database.Driver, error)
- func (s *Ksql) Run(migration io.Reader) error
- func (s *Ksql) SetVersion(version int, dirty bool) error
- func (s *Ksql) Unlock() error
- func (s *Ksql) Version() (version int, dirty bool, err error)
- type MigrationResult
- type MigrationRow
Constants ¶
This section is empty.
Variables ¶
View Source
var CreateMigrationStreamSQL = `` /* 201-byte string literal not displayed */
View Source
var CreateMigrationTableSQL = `` /* 195-byte string literal not displayed */
View Source
var LatestSchemaMigrationSql = `SELECT * FROM migrations WHERE rowtime = %v LIMIT 1;`
View Source
var LatestSchemaRowTimeSQL = `SELECT * FROM schema_migrations WHERE type = 'schema' LIMIT 1;`
Functions ¶
This section is empty.
Types ¶
type Ksql ¶
type Ksql struct { Url string HttpUrl string Instance interface{} CurrentVersion int MigrationSequence []string LastRunMigration []byte // todo: make []string IsDirty bool FirstRun bool Client *http.Client Config *Config }
func (*Ksql) SetVersion ¶
Adds a new record with the current migration version and it's dirty state
type MigrationResult ¶
type MigrationResult struct {
Row MigrationRow
}
type MigrationRow ¶
type MigrationRow struct {
Columns []interface{}
}
Click to show internal directories.
Click to hide internal directories.