golang

package
v0.0.0-...-797e501 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 16, 2021 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RenderDBTX

func RenderDBTX(dst *ast.Prj, src *sql.Ctx) error

RenderDBTX emits a dbtx.go file which contains some sql utilities.

func RenderFiles

func RenderFiles(dst *ast.Prj, src *sql.Ctx) error

RenderFiles normalizes the given migrations and embeds them.

func RenderMigrations

func RenderMigrations(dst *ast.Prj, src *sql.Ctx) error

RenderMigrations expects the result from files.go (RenderFiles). TODO how to solve multiple mysql/mariadb migrations due to concurrent k8s replicas? => some DB based locking?

func RenderOptions

func RenderOptions(dst *ast.Prj, modName, pkgName string, dialect sql.Dialect) error

RenderOptions renders sql specific connection options.

func RenderSQL

func RenderSQL(dst *ast.Prj, src *sql.Ctx) error

RenderSQL takes the sql context and emits the according options.go (contains connection options), files.go (contains migration files) and migrations.go (contains migration logic).

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL