adapter

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: Jul 23, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	DB                 *gorm.DB
	JWTSecret          string
	IAM                *config.IAMConfig
	WorkerProvisioning *service.WorkerProvisioningService
	SmsSender          sms.SmsSender
	WorkerAuth         *config.WorkerAuthConfig
}

Config aggregates all dependencies that either edition might need. Fields only used by one variant are passed as nil by the other.

func (Config) ToDeps

func (c Config) ToDeps() account.Deps

ToDeps converts the adapter Config to account Deps.

type Edition

type Edition interface {
	Auth() account.AuthProvider
	User() account.UserRepository
	Org() account.OrgRepository
	Department() account.DepartmentRepository
	Permission() account.PermissionProvider
	TokenParser() account.TokenParser
}

Edition aggregates all adapter implementations for the current build variant. The concrete edition (oss or enterprise) is selected at build time via //go:build tags.

func NewEdition

func NewEdition(cfg Config) Edition

NewEdition returns the oss (open-source) edition. Selected at build time when no -tags enterprise is passed.

Directories

Path Synopsis
oss

Jump to

Keyboard shortcuts

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