client

package
v0.14.0 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2025 License: Apache-2.0 Imports: 22 Imported by: 11 modules, 10 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

View Source
const (
	FlagReadRemote  = "read-remote"
	FlagWriteRemote = "write-remote"
	FlagOplRemote   = "syntax-remote"

	FlagInsecureNoTransportSecurity  = "insecure-disable-transport-security"
	FlagInsecureSkipHostVerification = "insecure-skip-hostname-verification"
	FlagAuthority                    = "authority"
	FlagBlock                        = "block"

	EnvReadRemote  = "KETO_READ_REMOTE"
	EnvWriteRemote = "KETO_WRITE_REMOTE"
	EnvAuthToken   = "KETO_BEARER_TOKEN" //nolint:gosec // just the key, not the value
	EnvAuthority   = "KETO_AUTHORITY"

	ContextKeyTimeout  contextKeys = "timeout"
	ContextKeyDialFunc contextKeys = "dial"
)

Variables

This section is empty.

Functions

func Conn added in v0.14.0

func Conn(ctx context.Context, remote string, details connectionDetails) (*grpc.ClientConn, error)

func GetReadConn added in v0.14.0

func GetReadConn(cmd *cobra.Command) (*grpc.ClientConn, error)

func GetWriteConn added in v0.14.0

func GetWriteConn(cmd *cobra.Command) (*grpc.ClientConn, error)

func RegisterRemoteURLFlags added in v0.14.0

func RegisterRemoteURLFlags(flags *pflag.FlagSet)

Types

type ServerType added in v0.14.0

type ServerType string
const (
	WriteServer ServerType = "write"
	ReadServer  ServerType = "read"
	OplServer   ServerType = "opl"
)

type TestServer added in v0.14.0

type TestServer struct {
	Reg              driver.Registry
	Namespace        *namespace.Namespace
	Addr, FlagRemote string
	Cmd              *cmdx.CommandExecuter
	Server           *grpc.Server
	NewServer        func(ctx context.Context) *grpc.Server
	// contains filtered or unexported fields
}

func NewTestServer added in v0.14.0

func NewTestServer(t *testing.T,
	rw ServerType, nspaces []*namespace.Namespace, newCmd func() *cobra.Command,
	registryOpts ...driver.TestRegistryOption,
) *TestServer

func (*TestServer) Shutdown added in v0.14.0

func (ts *TestServer) Shutdown(t *testing.T)

Jump to

Keyboard shortcuts

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