config

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2026 License: Apache-2.0 Imports: 5 Imported by: 2 modules, 3 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var EnvConfig = fromConfigFiles()

Functions

func LoadConfig

func LoadConfig(configPath string) ([]byte, error)

LoadConfig reads configuration data and reports path and read failures. An empty configPath selects ~/.iceberg-go.yaml. A missing implicit home-directory configuration is not an error; LoadConfig returns nil data. Unlike EnvConfig, it ignores GOICEBERG_HOME. Use ParseConfig to decode the YAML and select a catalog.

Types

type CatalogConfig

type CatalogConfig struct {
	CatalogType string       `yaml:"type"`
	URI         string       `yaml:"uri"`
	Output      string       `yaml:"output"`
	Credential  string       `yaml:"credential"`
	Warehouse   string       `yaml:"warehouse"`
	AWSProfile  string       `yaml:"aws-profile"`
	SQLDriver   string       `yaml:"sql-driver"`
	SQLDialect  string       `yaml:"sql-dialect"`
	RestOptions *RestOptions `yaml:"rest,omitempty"`
}

func ParseConfig

func ParseConfig(file []byte, catalogName string) (*CatalogConfig, error)

ParseConfig unmarshals the config file once and resolves the catalog to use. When catalogName is empty, it falls back to the file's default-catalog field and then to the built-in "default" name. It returns the matching CatalogConfig, or nil/nil if no such catalog is defined in the file. A non-nil error means the file could not be parsed and should be surfaced to the user.

type Config

type Config struct {
	DefaultCatalog string                   `yaml:"default-catalog"`
	Catalogs       map[string]CatalogConfig `yaml:"catalog"`
	MaxWorkers     int                      `yaml:"max-workers"`
}

type RestOptions added in v0.6.0

type RestOptions struct {
	SigV4Enabled  bool   `yaml:"sigv4-enabled"`
	SigningName   string `yaml:"signing-name"`
	SigningRegion string `yaml:"signing-region"`
}

Jump to

Keyboard shortcuts

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