node

package
v0.111.0 Latest Latest
Warning

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

Go to latest
Published: Sep 29, 2022 License: Apache-2.0 Imports: 23 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BuildInfo

type BuildInfo struct {
	Version, Commit, Date, BuiltBy string
}

type GitHubAuthDemo

type GitHubAuthDemo struct {
	ClientID     string
	ClientSecret string
}

type Node

type Node struct {
	// contains filtered or unexported fields
}

func New

func New(ctx context.Context, info BuildInfo, wundergraphDir string, log abstractlogger.Logger) *Node

func (*Node) Close added in v0.90.24

func (n *Node) Close() error

func (*Node) HandleGracefulShutdown added in v0.110.0

func (n *Node) HandleGracefulShutdown(gracefulTimeoutInSeconds int)

func (*Node) Shutdown added in v0.90.24

func (n *Node) Shutdown(ctx context.Context) error

func (*Node) StartBlocking

func (n *Node) StartBlocking(opts ...Option) error

type Option

type Option func(options *options)

func WithConfigFileChange added in v0.91.0

func WithConfigFileChange(event chan struct{}) Option

func WithDebugMode

func WithDebugMode(enable bool) Option

func WithDevMode added in v0.102.0

func WithDevMode() Option

WithDevMode will set cookie secrets to a static, insecure, string This way, you stay logged in during development Should never be used in production

func WithFileSystemConfig

func WithFileSystemConfig(configFilePath string) Option

func WithForceHttpsRedirects

func WithForceHttpsRedirects(forceHttpsRedirects bool) Option

func WithGitHubAuthDemo

func WithGitHubAuthDemo(authDemo GitHubAuthDemo) Option

func WithGlobalRateLimit

func WithGlobalRateLimit(requests int, perDuration time.Duration) Option

func WithInsecureCookies

func WithInsecureCookies() Option

func WithIntrospection

func WithIntrospection(enable bool) Option

func WithStaticWunderNodeConfig

func WithStaticWunderNodeConfig(config WunderNodeConfig) Option

type Server added in v0.110.0

type Server struct {
	GracefulShutdownTimeout int64
	KeepAlive               int64
	ReadTimeout             int64
	WriteTimeout            int64
	IdleTimeout             int64
}

type WunderNodeConfig added in v0.110.0

type WunderNodeConfig struct {
	Server *Server
	Api    *apihandler.Api
}

func CreateConfig added in v0.110.0

func CreateConfig(graphConfig *wgpb.WunderGraphConfiguration) WunderNodeConfig

Jump to

Keyboard shortcuts

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