ocdav

package
v2.19.7 Latest Latest
Warning

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

Go to latest
Published: May 13, 2024 License: Apache-2.0 Imports: 34 Imported by: 2

Documentation

Index

Constants

View Source
const (
	// ServerName to use when announcing the service to the registry
	ServerName = "ocdav"
)

Variables

This section is empty.

Functions

func Service

func Service(opts ...Option) (micro.Service, error)

Service initializes the ocdav service and underlying http server.

Types

type Option

type Option func(o *Options)

Option defines a single option function.

func Address

func Address(val string) Option

Address provides a function to set the address option.

func AllowCredentials added in v2.13.0

func AllowCredentials(val bool) Option

AllowCredentials provides a function to set the AllowCredentials option.

func AllowDepthInfinity added in v2.16.0

func AllowDepthInfinity(val bool) Option

func AllowedHeaders added in v2.13.0

func AllowedHeaders(val []string) Option

AllowedHeaders provides a function to set the AllowedHeaders option.

func AllowedMethods added in v2.13.0

func AllowedMethods(val []string) Option

AllowedMethods provides a function to set the AllowedMethods option.

func AllowedOrigins added in v2.13.0

func AllowedOrigins(val []string) Option

AllowedOrigins provides a function to set the AllowedOrigins option.

func Broker added in v2.11.0

func Broker(b broker.Broker) Option

Broker provides a function to set the Broker option.

func Context

func Context(val context.Context) Option

Context provides a function to set the context option.

func Edition added in v2.3.1

func Edition(val string) Option

Edition provides a function to set the Edition config option.

func FavoriteManager

func FavoriteManager(val favorite.Manager) Option

FavoriteManager provides a function to set the FavoriteManager option.

func FilesNamespace

func FilesNamespace(val string) Option

FilesNamespace provides a function to set the FilesNamespace config option.

func GatewaySelector added in v2.15.0

func GatewaySelector(val pool.Selectable[gateway.GatewayAPIClient]) Option

GatewaySelector provides a function to set the GatewaySelector option.

func GatewaySvc

func GatewaySvc(val string) Option

GatewaySvc provides a function to set the GatewaySvc config option.

func Insecure

func Insecure(val bool) Option

Insecure provides a function to set the Insecure config option.

func ItemNameInvalidChars added in v2.13.0

func ItemNameInvalidChars(chars []string) Option

ItemNameInvalidChars provides a function to set forbidden characters in file or folder names

func ItemNameMaxLength added in v2.13.0

func ItemNameMaxLength(i int) Option

ItemNameMaxLength provides a function to set the maximum length of a file or folder name

func JWTSecret

func JWTSecret(s string) Option

JWTSecret provides a function to set the jwt secret option.

func LockSystem

func LockSystem(val ocdav.LockSystem) Option

LockSystem provides a function to set the LockSystem option.

func Logger

func Logger(val zerolog.Logger) Option

Logger provides a function to set the logger option.

func MachineAuthAPIKey added in v2.7.0

func MachineAuthAPIKey(s string) Option

MachineAuthAPIKey provides a function to set the machine auth api key option.

func MetricsEnabled added in v2.11.0

func MetricsEnabled(val bool) Option

MetricsEnabled provides a function to set the MetricsEnabled config option.

func MetricsNamespace added in v2.11.0

func MetricsNamespace(val string) Option

MetricsNamespace provides a function to set the MetricsNamespace config option.

func MetricsSubsystem added in v2.11.0

func MetricsSubsystem(val string) Option

MetricsSubsystem provides a function to set the MetricsSubsystem config option.

func Name

func Name(val string) Option

Name provides a function to set the Name option.

func OCMNamespace added in v2.17.0

func OCMNamespace(val string) Option

OCMNamespace provides a function to set the OCMNamespace config option.

func Prefix

func Prefix(val string) Option

Prefix provides a function to set the prefix config option.

func Product added in v2.3.1

func Product(val string) Option

Product provides a function to set the Product config option.

func ProductName added in v2.3.1

func ProductName(val string) Option

ProductName provides a function to set the ProductName config option.

func ProductVersion added in v2.4.0

func ProductVersion(val string) Option

ProductVersion provides a function to set the ProductVersion config option.

func PublicURL

func PublicURL(val string) Option

PublicURL provides a function to set the PublicURL config option.

func SharesNamespace

func SharesNamespace(val string) Option

SharesNamespace provides a function to set the SharesNamespace config option.

func TLSConfig

func TLSConfig(config *tls.Config) Option

TLSConfig provides a function to set the TLSConfig option.

func Timeout

func Timeout(val int64) Option

Timeout provides a function to set the Timeout config option.

func Tracing

func Tracing(endpoint, collector string) Option

Tracing enables tracing Deprecated: use WithTracingEndpoint and WithTracingEnabled, Collector is unused

func Version added in v2.3.1

func Version(val string) Option

Version provides a function to set the Version config option.

func VersionString added in v2.3.1

func VersionString(val string) Option

VersionString provides a function to set the VersionString config option.

func WebdavNamespace

func WebdavNamespace(val string) Option

WebdavNamespace provides a function to set the WebdavNamespace config option.

func WithTraceProvider added in v2.15.0

func WithTraceProvider(provider trace.TracerProvider) Option

WithTraceProvider option

func WithTracingEnabled added in v2.19.0

func WithTracingEnabled(enabled bool) Option

WithTracingEnabled option

func WithTracingEndpoint added in v2.19.0

func WithTracingEndpoint(endpoint string) Option

WithTracingEndpoint option

func WithTracingExporter added in v2.14.0

func WithTracingExporter(exporter string) Option

WithTracingExporter option Deprecated: unused

func WithTracingInsecure added in v2.14.0

func WithTracingInsecure() Option

WithTracingInsecure option

func WithTracingTransportCredentials added in v2.19.0

func WithTracingTransportCredentials(v credentials.TransportCredentials) Option

WithTracingTransportCredentials option

type Options

type Options struct {
	TLSConfig *tls.Config
	Broker    broker.Broker
	Address   string
	Logger    zerolog.Logger
	Context   context.Context
	// Metrics   *metrics.Metrics
	// Flags     []cli.Flag
	Name      string
	JWTSecret string

	FavoriteManager favorite.Manager
	GatewaySelector pool.Selectable[gateway.GatewayAPIClient]

	TracingEnabled              bool
	TracingInsecure             bool
	TracingEndpoint             string
	TracingTransportCredentials credentials.TransportCredentials

	TraceProvider trace.TracerProvider

	MetricsEnabled   bool
	MetricsNamespace string
	MetricsSubsystem string

	AllowCredentials   bool
	AllowedOrigins     []string
	AllowedHeaders     []string
	AllowedMethods     []string
	AllowDepthInfinity bool
	// contains filtered or unexported fields
}

Options defines the available options for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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