globalconfig

package
v1.11.4 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2023 License: Apache-2.0 Imports: 36 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GlobalConfig

type GlobalConfig struct {
	Domain string
	Port   string

	AllLang            []string
	SessionTimeOut     int
	ServiceTimeOut     time.Duration
	MaxMultipartMemory int64
	DateFormat         string
	PageSize           uint64
	ExtractSize        uint64
	FeedFormat         string
	FeedSize           uint64

	StaticFileSystem http.FileSystem
	FaviconPath      string
	Page404Url       string

	InitCtx          context.Context
	Logger           log.Logger // for init phase (have the context)
	LoggerGetter     log.LoggerGetter
	TracerProvider   *sdktrace.TracerProvider
	Tracer           trace.Tracer
	LangPicturePaths map[string]string

	DialOptions     []grpc.DialOption
	SessionService  sessionservice.SessionService
	TemplateService templateservice.TemplateService
	SaltService     loginservice.SaltService
	SettingsService sessionservice.SessionService
	LoginService    loginservice.FullLoginService
	RightClient     adminclient.RightClient
	ProfileService  profileservice.AdvancedProfileService

	// lazy service
	MarkdownServiceAddr string
	MarkdownService     markdownservice.MarkdownService

	// lazy & only adresses (instance need specific data)
	WikiServiceAddr  string
	ForumServiceAddr string
	BlogServiceAddr  string
}

func Init

func Init(serviceName string, version string, parsedConfig parser.ParsedConfig, err error) (*GlobalConfig, trace.Span)

func (*GlobalConfig) ExtractAdminConfig

func (c *GlobalConfig) ExtractAdminConfig() config.AdminConfig

func (*GlobalConfig) ExtractAuthConfig

func (c *GlobalConfig) ExtractAuthConfig() config.AuthConfig

func (*GlobalConfig) ExtractLocalesConfig

func (c *GlobalConfig) ExtractLocalesConfig() config.LocalesConfig

func (*GlobalConfig) ExtractLoginConfig

func (c *GlobalConfig) ExtractLoginConfig() config.LoginConfig

func (*GlobalConfig) ExtractProfileConfig

func (c *GlobalConfig) ExtractProfileConfig() config.ProfileConfig

func (*GlobalConfig) ExtractSettingsConfig

func (c *GlobalConfig) ExtractSettingsConfig() config.SettingsConfig

func (*GlobalConfig) ExtractSiteConfig

func (c *GlobalConfig) ExtractSiteConfig() config.SiteConfig

func (*GlobalConfig) GetLogger

func (c *GlobalConfig) GetLogger() log.Logger

func (*GlobalConfig) GetLoggerGetter

func (c *GlobalConfig) GetLoggerGetter() log.LoggerGetter

func (*GlobalConfig) GetServiceTimeOut

func (c *GlobalConfig) GetServiceTimeOut() time.Duration

func (*GlobalConfig) MakeBlogConfig

func (c *GlobalConfig) MakeBlogConfig(widgetConfig parser.WidgetConfig) (config.BlogConfig, bool)

func (*GlobalConfig) MakeForumConfig

func (c *GlobalConfig) MakeForumConfig(widgetConfig parser.WidgetConfig) (config.ForumConfig, bool)

func (*GlobalConfig) MakeWidgetConfig

func (c *GlobalConfig) MakeWidgetConfig(widgetConfig parser.WidgetConfig) (config.RemoteWidgetConfig, bool)

func (*GlobalConfig) MakeWikiConfig

func (c *GlobalConfig) MakeWikiConfig(widgetConfig parser.WidgetConfig) (config.WikiConfig, bool)

Jump to

Keyboard shortcuts

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