migrations

package
v0.7.1 Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2025 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyHasuraMetadata

func ApplyHasuraMetadata(url, hasuraSecret, hasuraDBName string) error

func ApplyPostgresMigration

func ApplyPostgresMigration(postgresURL string) error

Types

type Configuration

type Configuration struct {
	CustomName        string            `json:"custom_name"`         //nolint: tagliatelle
	CustomRootFields  CustomRootFields  `json:"custom_root_fields"`  //nolint: tagliatelle
	CustomColumnNames map[string]string `json:"custom_column_names"` //nolint: tagliatelle
}

type CreateArrayRelationship

type CreateArrayRelationship struct {
	Type string                      `json:"type"`
	Args CreateArrayRelationshipArgs `json:"args"`
}

type CreateArrayRelationshipArgs

type CreateArrayRelationshipArgs struct {
	Table  Table                        `json:"table"`
	Name   string                       `json:"name"`
	Source string                       `json:"source"`
	Using  CreateArrayRelationshipUsing `json:"using"`
}

type CreateArrayRelationshipUsing

type CreateArrayRelationshipUsing struct {
	ForeignKeyConstraintOn ForeignKeyConstraintOn `json:"foreign_key_constraint_on"` //nolint: tagliatelle
}

type CreateObjectRelationship

type CreateObjectRelationship struct {
	Type string                       `json:"type"`
	Args CreateObjectRelationshipArgs `json:"args"`
}

type CreateObjectRelationshipArgs

type CreateObjectRelationshipArgs struct {
	Table  Table                         `json:"table"`
	Name   string                        `json:"name"`
	Source string                        `json:"source"`
	Using  CreateObjectRelationshipUsing `json:"using"`
}

type CreateObjectRelationshipUsing

type CreateObjectRelationshipUsing struct {
	ForeignKeyConstraintOn []string `json:"foreign_key_constraint_on"` //nolint: tagliatelle
}

type CustomRootFields

type CustomRootFields struct {
	Select          string `json:"select"`
	SelectByPk      string `json:"select_by_pk"`     //nolint: tagliatelle
	SelectAggregate string `json:"select_aggregate"` //nolint: tagliatelle
	Insert          string `json:"insert"`
	InsertOne       string `json:"insert_one"` //nolint: tagliatelle
	Update          string `json:"update"`
	UpdateByPk      string `json:"update_by_pk"` //nolint: tagliatelle
	Delete          string `json:"delete"`
	DeleteByPk      string `json:"delete_by_pk"` //nolint: tagliatelle
}

type DropRelationship added in v0.1.4

type DropRelationship struct {
	Type string               `json:"type"`
	Args DropRelationshipArgs `json:"args"`
}

type DropRelationshipArgs added in v0.1.4

type DropRelationshipArgs struct {
	Table        string `json:"table"`
	Source       string `json:"source"`
	Cascade      bool   `json:"cascade"`
	Relationship string `json:"relationship"`
}

type ForeignKeyConstraintOn

type ForeignKeyConstraintOn struct {
	Table   Table    `json:"table"`
	Columns []string `json:"columns"`
}

type PgTrackTableArgs

type PgTrackTableArgs struct {
	Source        string        `json:"source"`
	Table         Table         `json:"table"`
	Configuration Configuration `json:"configuration"`
}

type Table

type Table struct {
	Schema string `json:"schema"`
	Name   string `json:"name"`
}

type TrackTable

type TrackTable struct {
	Type string           `json:"type"`
	Args PgTrackTableArgs `json:"args"`
}

Jump to

Keyboard shortcuts

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