pkg

package
v0.0.0-...-f7332af Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2023 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

View Source
const (
	BackfillConnectionKey     = "game.kruise.io/connection"
	BackfillConnectedTag      = "game.kruise.io/connected"
	OpenMatchLabelSelectorKey = "game.kruise.io/owner-gss"
	GameNameProfileKey        = "game_name"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Allocator

type Allocator struct {
	GameServerLister v1alpha1Lister.GameServerLister
	GameServerClient v1alpha1client.Interface

	BackendClient  pb.BackendServiceClient
	BackendConn    *grpc.ClientConn
	FrontendClient pb.FrontendServiceClient
	FrontendConn   *grpc.ClientConn

	MatchFunctionEndpoint string
	MatchFunctionPort     int32

	GameServerLabelSelector string
	ProfileName             string
	GameServerSetNames      string

	//GameServersReSyncInterval time.Duration
	MatchPullingInterval time.Duration
	// contains filtered or unexported fields
}

func NewAllocator

func NewAllocator(options *Options) (allocator *Allocator, err error)

func (*Allocator) Run

func (a *Allocator) Run()

type Options

type Options struct {
	MatchFunctionEndpoint     string
	MatchFunctionPort         int
	BackendEndpoint           string
	BackendPort               int
	FrontendEndpoint          string
	FrontendPort              int
	Config                    *rest.Config
	GameServerLabelSelector   string
	GameServersReSyncInterval time.Duration
	MatchPullingInterval      time.Duration
	ProfileName               string
	GameServerSetNames        string
}

func (*Options) GetBackendConn

func (o *Options) GetBackendConn() (string, error)

GetBackendConn return backend conn of open-match service

func (*Options) GetFrontendConn

func (o *Options) GetFrontendConn() (string, error)

GetFrontendConn return backend conn of open-match service

Jump to

Keyboard shortcuts

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