Documentation ¶
Index ¶
- Constants
- Variables
- func AddFriends(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) error
- func AddGroupUsers(ctx context.Context, logger *zap.Logger, db *sql.DB, router MessageRouter, ...) error
- func AuthenticateApple(ctx context.Context, logger *zap.Logger, db *sql.DB, client *social.Client, ...) (string, string, bool, error)
- func AuthenticateCustom(ctx context.Context, logger *zap.Logger, db *sql.DB, customID, username string, ...) (string, string, bool, error)
- func AuthenticateDevice(ctx context.Context, logger *zap.Logger, db *sql.DB, deviceID, username string, ...) (string, string, bool, error)
- func AuthenticateEmail(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) (string, string, bool, error)
- func AuthenticateFacebook(ctx context.Context, logger *zap.Logger, db *sql.DB, client *social.Client, ...) (string, string, bool, bool, error)
- func AuthenticateFacebookInstantGame(ctx context.Context, logger *zap.Logger, db *sql.DB, client *social.Client, ...) (string, string, bool, error)
- func AuthenticateGameCenter(ctx context.Context, logger *zap.Logger, db *sql.DB, client *social.Client, ...) (string, string, bool, error)
- func AuthenticateGoogle(ctx context.Context, logger *zap.Logger, db *sql.DB, client *social.Client, ...) (string, string, bool, error)
- func AuthenticateSteam(ctx context.Context, logger *zap.Logger, db *sql.DB, client *social.Client, ...) (string, string, string, bool, error)
- func AuthenticateUsername(ctx context.Context, logger *zap.Logger, db *sql.DB, username, password string) (string, error)
- func BanGroupUsers(ctx context.Context, logger *zap.Logger, db *sql.DB, router MessageRouter, ...) error
- func BanUsers(ctx context.Context, logger *zap.Logger, db *sql.DB, sessionCache SessionCache, ...) error
- func BlockFriends(ctx context.Context, logger *zap.Logger, db *sql.DB, currentUser uuid.UUID, ...) error
- func BlugeInMemoryConfig() bluge.Config
- func BlugeWalkDocument(data interface{}, path []string, doc *bluge.Document)
- func ChannelMessageSend(ctx context.Context, logger *zap.Logger, db *sql.DB, router MessageRouter, ...) (*rtapi.ChannelMessageAck, error)
- func ChannelMessageUpdate(ctx context.Context, logger *zap.Logger, db *sql.DB, router MessageRouter, ...) (*rtapi.ChannelMessageAck, error)
- func ChannelMessagesList(ctx context.Context, logger *zap.Logger, db *sql.DB, caller uuid.UUID, ...) (*api.ChannelMessageList, error)
- func CheckConfig(logger *zap.Logger, config Config) map[string]string
- func CheckRuntime(logger *zap.Logger, config Config) error
- func CheckRuntimeProviderGo(logger *zap.Logger, rootPath string, paths []string) error
- func CheckRuntimeProviderJavascript(logger *zap.Logger, config Config) error
- func CheckRuntimeProviderLua(logger *zap.Logger, config Config, paths []string) error
- func CreateGroup(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) (*api.Group, error)
- func DbConnect(ctx context.Context, logger *zap.Logger, config Config) (*sql.DB, string)
- func DeleteAccount(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) error
- func DeleteFriends(ctx context.Context, logger *zap.Logger, db *sql.DB, currentUser uuid.UUID, ...) error
- func DeleteGroup(ctx context.Context, logger *zap.Logger, db *sql.DB, groupID uuid.UUID, ...) error
- func DeleteUser(ctx context.Context, tx *sql.Tx, userID uuid.UUID) (int64, error)
- func DemoteGroupUsers(ctx context.Context, logger *zap.Logger, db *sql.DB, router MessageRouter, ...) error
- func ExecuteInTx(ctx context.Context, tx Tx, fn func() error) (err error)
- func ExecuteRetryable(fn func() error) error
- func ExportAccount(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID) (*console.AccountExport, error)
- func FileRead(rootPath, relPath string) (*os.File, error)
- func GetAccount(ctx context.Context, logger *zap.Logger, db *sql.DB, tracker Tracker, ...) (*api.Account, error)
- func GetAccounts(ctx context.Context, logger *zap.Logger, db *sql.DB, tracker Tracker, ...) ([]*api.Account, error)
- func GetChannelMessages(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID) ([]*api.ChannelMessage, error)
- func GetFriendIDs(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID) (*api.FriendList, error)
- func GetGroups(ctx context.Context, logger *zap.Logger, db *sql.DB, ids []string) ([]*api.Group, error)
- func GetPurchaseByTransactionID(ctx context.Context, logger *zap.Logger, db *sql.DB, transactionID string) (string, *api.ValidatedPurchase, error)
- func GetRandomUsers(ctx context.Context, logger *zap.Logger, db *sql.DB, tracker Tracker, ...) ([]*api.User, error)
- func GetRuntimePaths(logger *zap.Logger, rootPath string) ([]string, error)
- func GetUsers(ctx context.Context, logger *zap.Logger, db *sql.DB, tracker Tracker, ...) (*api.Users, error)
- func GroupDeleteAll(ctx context.Context, logger *zap.Logger, tx *sql.Tx, userID uuid.UUID) error
- func HashFromId(id uuid.UUID) [6]byte
- func JoinGroup(ctx context.Context, logger *zap.Logger, db *sql.DB, router MessageRouter, ...) error
- func KickGroupUsers(ctx context.Context, logger *zap.Logger, db *sql.DB, router MessageRouter, ...) error
- func LeaderboardList(logger *zap.Logger, leaderboardCache LeaderboardCache, ...) (*api.LeaderboardList, error)
- func LeaderboardRecordDelete(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) error
- func LeaderboardRecordReadAll(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID) ([]*api.LeaderboardRecord, error)
- func LeaderboardRecordWrite(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) (*api.LeaderboardRecord, error)
- func LeaderboardRecordsDeleteAll(ctx context.Context, logger *zap.Logger, tx *sql.Tx, userID uuid.UUID) error
- func LeaderboardRecordsHaystack(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) ([]*api.LeaderboardRecord, error)
- func LeaderboardRecordsList(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) (*api.LeaderboardRecordList, error)
- func LeaderboardsGet(leaderboardCache LeaderboardCache, leaderboardIDs []string) []*api.Leaderboard
- func LeaveGroup(ctx context.Context, logger *zap.Logger, db *sql.DB, router MessageRouter, ...) error
- func LinkApple(ctx context.Context, logger *zap.Logger, db *sql.DB, config Config, ...) error
- func LinkCustom(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) error
- func LinkDevice(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) error
- func LinkEmail(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) error
- func LinkFacebook(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) error
- func LinkFacebookInstantGame(ctx context.Context, logger *zap.Logger, db *sql.DB, config Config, ...) error
- func LinkGameCenter(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) error
- func LinkGoogle(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) error
- func LinkSteam(ctx context.Context, logger *zap.Logger, db *sql.DB, config Config, ...) error
- func ListFriends(ctx context.Context, logger *zap.Logger, db *sql.DB, tracker Tracker, ...) (*api.FriendList, error)
- func ListGroupUsers(ctx context.Context, logger *zap.Logger, db *sql.DB, tracker Tracker, ...) (*api.GroupUserList, error)
- func ListGroups(ctx context.Context, logger *zap.Logger, db *sql.DB, name, langTag string, ...) (*api.GroupList, error)
- func ListPurchases(ctx context.Context, logger *zap.Logger, db *sql.DB, userID string, limit int, ...) (*api.PurchaseList, error)
- func ListUserGroups(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) (*api.UserGroupList, error)
- func ListWalletLedger(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) ([]*walletLedger, string, string, error)
- func MapMatchIndexEntry(id string, in *MatchIndexEntry, logger *zap.Logger) (*bluge.Document, error)
- func MapMatchmakerIndex(id string, in *MatchmakerIndex) (*bluge.Document, error)
- func MultiUpdate(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) ([]*api.StorageObjectAck, []*runtime.WalletUpdateResult, error)
- func NewConfig(logger *zap.Logger) *config
- func NewJSONFileLogger(consoleLogger *zap.Logger, fileName string, level zapcore.Level, ...) *zap.Logger
- func NewJSONLogger(output *os.File, level zapcore.Level, format LoggingFormat) *zap.Logger
- func NewJsLogger(r *goja.Runtime, logger *zap.Logger, fields ...zap.Field) (goja.Value, error)
- func NewMultiLogger(loggers ...*zap.Logger) *zap.Logger
- func NewRotatingJSONFileLogger(consoleLogger *zap.Logger, config Config, level zapcore.Level, ...) *zap.Logger
- func NewRuntime(ctx context.Context, logger, startupLogger *zap.Logger, db *sql.DB, ...) (*Runtime, *RuntimeInfo, error)
- func NewRuntimeGoContext(ctx context.Context, node string, env map[string]string, ...) context.Context
- func NewRuntimeGoLogger(logger *zap.Logger) nkruntime.Logger
- func NewRuntimeJavascriptNakamaModule(logger *zap.Logger, db *sql.DB, protojsonMarshaler *protojson.MarshalOptions, ...) *runtimeJavascriptNakamaModule
- func NewRuntimeJsContext(r *goja.Runtime, node string, env goja.Value, mode RuntimeExecutionMode, ...) *goja.Object
- func NewRuntimeJsInitContext(r *goja.Runtime, node string, env map[string]string) *goja.Object
- func NewRuntimeLuaContext(l *lua.LState, node string, env *lua.LTable, mode RuntimeExecutionMode, ...) *lua.LTable
- func NewRuntimeProviderGo(ctx context.Context, logger, startupLogger *zap.Logger, db *sql.DB, ...) ([]string, map[string]RuntimeRpcFunction, map[string]RuntimeBeforeRtFunction, ...)
- func NewRuntimeProviderJS(logger, startupLogger *zap.Logger, db *sql.DB, ...) ([]string, map[string]RuntimeRpcFunction, map[string]RuntimeBeforeRtFunction, ...)
- func NewRuntimeProviderLua(logger, startupLogger *zap.Logger, db *sql.DB, ...) ([]string, map[string]RuntimeRpcFunction, map[string]RuntimeBeforeRtFunction, ...)
- func NewSocketWsAcceptor(logger *zap.Logger, config Config, sessionRegistry SessionRegistry, ...) func(http.ResponseWriter, *http.Request)
- func NodeToHash(node string) [6]byte
- func NotificationDelete(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) error
- func NotificationList(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) (*api.NotificationList, error)
- func NotificationSave(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) error
- func NotificationSend(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) error
- func OpenBit32(l *lua.LState) int
- func OpenOs(L *lua.LState) int
- func OpenPackage(moduleCache *RuntimeLuaModuleCache) func(L *lua.LState) int
- func ParseQueryString(query string) (bluge.Query, error)
- func PromoteGroupUsers(ctx context.Context, logger *zap.Logger, db *sql.DB, router MessageRouter, ...) error
- func RedirectStdLog(logger *zap.Logger)
- func RuntimeJsConvertJsValue(jv interface{}) interface{}
- func RuntimeLuaConvertLuaTable(lv *lua.LTable) map[string]interface{}
- func RuntimeLuaConvertLuaValue(lv lua.LValue) interface{}
- func RuntimeLuaConvertMap(l *lua.LState, data map[string]interface{}) *lua.LTable
- func RuntimeLuaConvertMapInt64(l *lua.LState, data map[string]int64) *lua.LTable
- func RuntimeLuaConvertMapString(l *lua.LState, data map[string]string) *lua.LTable
- func RuntimeLuaConvertValue(l *lua.LState, val interface{}) lua.LValue
- func SessionLogout(config Config, sessionCache SessionCache, userID uuid.UUID, ...) error
- func SessionRefresh(ctx context.Context, logger *zap.Logger, db *sql.DB, config Config, ...) (uuid.UUID, string, map[string]string, error)
- func SetupLogging(tmpLogger *zap.Logger, config Config) (*zap.Logger, *zap.Logger)
- func StackdriverLevelEncoder(l zapcore.Level, enc zapcore.PrimitiveArrayEncoder)
- func StatusError(code codes.Code, msg string, cause error) error
- func StorageDeleteObjects(ctx context.Context, logger *zap.Logger, db *sql.DB, authoritativeDelete bool, ...) (codes.Code, error)
- func StorageListObjects(ctx context.Context, logger *zap.Logger, db *sql.DB, caller uuid.UUID, ...) (*api.StorageObjectList, codes.Code, error)
- func StorageListObjectsAll(ctx context.Context, logger *zap.Logger, db *sql.DB, authoritative bool, ...) (*api.StorageObjectList, error)
- func StorageListObjectsPublicReadUser(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) (*api.StorageObjectList, error)
- func StorageListObjectsUser(ctx context.Context, logger *zap.Logger, db *sql.DB, authoritative bool, ...) (*api.StorageObjectList, error)
- func StorageReadAllUserObjects(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID) ([]*api.StorageObject, error)
- func StorageReadObjects(ctx context.Context, logger *zap.Logger, db *sql.DB, caller uuid.UUID, ...) (*api.StorageObjects, error)
- func StorageWriteObjects(ctx context.Context, logger *zap.Logger, db *sql.DB, authoritativeWrite bool, ...) (*api.StorageObjectAcks, codes.Code, error)
- func StreamToChannelId(stream PresenceStream) (string, error)
- func TournamentAddAttempt(ctx context.Context, logger *zap.Logger, db *sql.DB, cache LeaderboardCache, ...) error
- func TournamentCreate(ctx context.Context, logger *zap.Logger, cache LeaderboardCache, ...) error
- func TournamentDelete(ctx context.Context, cache LeaderboardCache, rankCache LeaderboardRankCache, ...) error
- func TournamentJoin(ctx context.Context, logger *zap.Logger, db *sql.DB, cache LeaderboardCache, ...) error
- func TournamentList(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) (*api.TournamentList, error)
- func TournamentRecordWrite(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) (*api.LeaderboardRecord, error)
- func TournamentRecordsHaystack(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) ([]*api.LeaderboardRecord, error)
- func TournamentRecordsList(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) (*api.TournamentRecordList, error)
- func TournamentsGet(ctx context.Context, logger *zap.Logger, db *sql.DB, tournamentIDs []string) ([]*api.Tournament, error)
- func UnbanUsers(ctx context.Context, logger *zap.Logger, db *sql.DB, sessionCache SessionCache, ...) error
- func UnlinkApple(ctx context.Context, logger *zap.Logger, db *sql.DB, config Config, ...) error
- func UnlinkCustom(ctx context.Context, logger *zap.Logger, db *sql.DB, id uuid.UUID, ...) error
- func UnlinkDevice(ctx context.Context, logger *zap.Logger, db *sql.DB, id uuid.UUID, ...) error
- func UnlinkEmail(ctx context.Context, logger *zap.Logger, db *sql.DB, id uuid.UUID, ...) error
- func UnlinkFacebook(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) error
- func UnlinkFacebookInstantGame(ctx context.Context, logger *zap.Logger, db *sql.DB, config Config, ...) error
- func UnlinkGameCenter(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) error
- func UnlinkGoogle(ctx context.Context, logger *zap.Logger, db *sql.DB, ...) error
- func UnlinkSteam(ctx context.Context, logger *zap.Logger, db *sql.DB, config Config, ...) error
- func UpdateAccounts(ctx context.Context, logger *zap.Logger, db *sql.DB, updates []*accountUpdate) error
- func UpdateGroup(ctx context.Context, logger *zap.Logger, db *sql.DB, groupID uuid.UUID, ...) error
- func UpdateWalletLedger(ctx context.Context, logger *zap.Logger, db *sql.DB, id uuid.UUID, ...) (*walletLedger, error)
- func UpdateWallets(ctx context.Context, logger *zap.Logger, db *sql.DB, updates []*walletUpdate, ...) ([]*runtime.WalletUpdateResult, error)
- func UserExistsAndDoesNotBlock(ctx context.Context, db *sql.DB, checkUserID, blocksUserID uuid.UUID) (bool, error)
- func ValidatePurchaseGoogle(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) (*api.ValidatePurchaseResponse, error)
- func ValidatePurchaseHuawei(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) (*api.ValidatePurchaseResponse, error)
- func ValidatePurchasesApple(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, ...) (*api.ValidatePurchaseResponse, error)
- type AmbiguousCommitError
- type ApiServer
- func (s *ApiServer) AddFriends(ctx context.Context, in *api.AddFriendsRequest) (*emptypb.Empty, error)
- func (s *ApiServer) AddGroupUsers(ctx context.Context, in *api.AddGroupUsersRequest) (*emptypb.Empty, error)
- func (s *ApiServer) AuthenticateApple(ctx context.Context, in *api.AuthenticateAppleRequest) (*api.Session, error)
- func (s *ApiServer) AuthenticateCustom(ctx context.Context, in *api.AuthenticateCustomRequest) (*api.Session, error)
- func (s *ApiServer) AuthenticateDevice(ctx context.Context, in *api.AuthenticateDeviceRequest) (*api.Session, error)
- func (s *ApiServer) AuthenticateEmail(ctx context.Context, in *api.AuthenticateEmailRequest) (*api.Session, error)
- func (s *ApiServer) AuthenticateFacebook(ctx context.Context, in *api.AuthenticateFacebookRequest) (*api.Session, error)
- func (s *ApiServer) AuthenticateFacebookInstantGame(ctx context.Context, in *api.AuthenticateFacebookInstantGameRequest) (*api.Session, error)
- func (s *ApiServer) AuthenticateGameCenter(ctx context.Context, in *api.AuthenticateGameCenterRequest) (*api.Session, error)
- func (s *ApiServer) AuthenticateGoogle(ctx context.Context, in *api.AuthenticateGoogleRequest) (*api.Session, error)
- func (s *ApiServer) AuthenticateSteam(ctx context.Context, in *api.AuthenticateSteamRequest) (*api.Session, error)
- func (s *ApiServer) BanGroupUsers(ctx context.Context, in *api.BanGroupUsersRequest) (*emptypb.Empty, error)
- func (s *ApiServer) BlockFriends(ctx context.Context, in *api.BlockFriendsRequest) (*emptypb.Empty, error)
- func (s *ApiServer) CreateGroup(ctx context.Context, in *api.CreateGroupRequest) (*api.Group, error)
- func (s *ApiServer) DeleteFriends(ctx context.Context, in *api.DeleteFriendsRequest) (*emptypb.Empty, error)
- func (s *ApiServer) DeleteGroup(ctx context.Context, in *api.DeleteGroupRequest) (*emptypb.Empty, error)
- func (s *ApiServer) DeleteLeaderboardRecord(ctx context.Context, in *api.DeleteLeaderboardRecordRequest) (*emptypb.Empty, error)
- func (s *ApiServer) DeleteNotifications(ctx context.Context, in *api.DeleteNotificationsRequest) (*emptypb.Empty, error)
- func (s *ApiServer) DeleteStorageObjects(ctx context.Context, in *api.DeleteStorageObjectsRequest) (*emptypb.Empty, error)
- func (s *ApiServer) DemoteGroupUsers(ctx context.Context, in *api.DemoteGroupUsersRequest) (*emptypb.Empty, error)
- func (s *ApiServer) Event(ctx context.Context, in *api.Event) (*emptypb.Empty, error)
- func (s *ApiServer) GetAccount(ctx context.Context, in *emptypb.Empty) (*api.Account, error)
- func (s *ApiServer) GetUsers(ctx context.Context, in *api.GetUsersRequest) (*api.Users, error)
- func (s *ApiServer) Healthcheck(ctx context.Context, in *emptypb.Empty) (*emptypb.Empty, error)
- func (s *ApiServer) ImportFacebookFriends(ctx context.Context, in *api.ImportFacebookFriendsRequest) (*emptypb.Empty, error)
- func (s *ApiServer) ImportSteamFriends(ctx context.Context, in *api.ImportSteamFriendsRequest) (*emptypb.Empty, error)
- func (s *ApiServer) JoinGroup(ctx context.Context, in *api.JoinGroupRequest) (*emptypb.Empty, error)
- func (s *ApiServer) JoinTournament(ctx context.Context, in *api.JoinTournamentRequest) (*emptypb.Empty, error)
- func (s *ApiServer) KickGroupUsers(ctx context.Context, in *api.KickGroupUsersRequest) (*emptypb.Empty, error)
- func (s *ApiServer) LeaveGroup(ctx context.Context, in *api.LeaveGroupRequest) (*emptypb.Empty, error)
- func (s *ApiServer) LinkApple(ctx context.Context, in *api.AccountApple) (*emptypb.Empty, error)
- func (s *ApiServer) LinkCustom(ctx context.Context, in *api.AccountCustom) (*emptypb.Empty, error)
- func (s *ApiServer) LinkDevice(ctx context.Context, in *api.AccountDevice) (*emptypb.Empty, error)
- func (s *ApiServer) LinkEmail(ctx context.Context, in *api.AccountEmail) (*emptypb.Empty, error)
- func (s *ApiServer) LinkFacebook(ctx context.Context, in *api.LinkFacebookRequest) (*emptypb.Empty, error)
- func (s *ApiServer) LinkFacebookInstantGame(ctx context.Context, in *api.AccountFacebookInstantGame) (*emptypb.Empty, error)
- func (s *ApiServer) LinkGameCenter(ctx context.Context, in *api.AccountGameCenter) (*emptypb.Empty, error)
- func (s *ApiServer) LinkGoogle(ctx context.Context, in *api.AccountGoogle) (*emptypb.Empty, error)
- func (s *ApiServer) LinkSteam(ctx context.Context, in *api.LinkSteamRequest) (*emptypb.Empty, error)
- func (s *ApiServer) ListChannelMessages(ctx context.Context, in *api.ListChannelMessagesRequest) (*api.ChannelMessageList, error)
- func (s *ApiServer) ListFriends(ctx context.Context, in *api.ListFriendsRequest) (*api.FriendList, error)
- func (s *ApiServer) ListGroupUsers(ctx context.Context, in *api.ListGroupUsersRequest) (*api.GroupUserList, error)
- func (s *ApiServer) ListGroups(ctx context.Context, in *api.ListGroupsRequest) (*api.GroupList, error)
- func (s *ApiServer) ListLeaderboardRecords(ctx context.Context, in *api.ListLeaderboardRecordsRequest) (*api.LeaderboardRecordList, error)
- func (s *ApiServer) ListLeaderboardRecordsAroundOwner(ctx context.Context, in *api.ListLeaderboardRecordsAroundOwnerRequest) (*api.LeaderboardRecordList, error)
- func (s *ApiServer) ListMatches(ctx context.Context, in *api.ListMatchesRequest) (*api.MatchList, error)
- func (s *ApiServer) ListNotifications(ctx context.Context, in *api.ListNotificationsRequest) (*api.NotificationList, error)
- func (s *ApiServer) ListStorageObjects(ctx context.Context, in *api.ListStorageObjectsRequest) (*api.StorageObjectList, error)
- func (s *ApiServer) ListTournamentRecords(ctx context.Context, in *api.ListTournamentRecordsRequest) (*api.TournamentRecordList, error)
- func (s *ApiServer) ListTournamentRecordsAroundOwner(ctx context.Context, in *api.ListTournamentRecordsAroundOwnerRequest) (*api.TournamentRecordList, error)
- func (s *ApiServer) ListTournaments(ctx context.Context, in *api.ListTournamentsRequest) (*api.TournamentList, error)
- func (s *ApiServer) ListUserGroups(ctx context.Context, in *api.ListUserGroupsRequest) (*api.UserGroupList, error)
- func (s *ApiServer) PromoteGroupUsers(ctx context.Context, in *api.PromoteGroupUsersRequest) (*emptypb.Empty, error)
- func (s *ApiServer) ReadStorageObjects(ctx context.Context, in *api.ReadStorageObjectsRequest) (*api.StorageObjects, error)
- func (s *ApiServer) RpcFunc(ctx context.Context, in *api.Rpc) (*api.Rpc, error)
- func (s *ApiServer) RpcFuncHttp(w http.ResponseWriter, r *http.Request)
- func (s *ApiServer) SessionLogout(ctx context.Context, in *api.SessionLogoutRequest) (*emptypb.Empty, error)
- func (s *ApiServer) SessionRefresh(ctx context.Context, in *api.SessionRefreshRequest) (*api.Session, error)
- func (s *ApiServer) Stop()
- func (s *ApiServer) UnlinkApple(ctx context.Context, in *api.AccountApple) (*emptypb.Empty, error)
- func (s *ApiServer) UnlinkCustom(ctx context.Context, in *api.AccountCustom) (*emptypb.Empty, error)
- func (s *ApiServer) UnlinkDevice(ctx context.Context, in *api.AccountDevice) (*emptypb.Empty, error)
- func (s *ApiServer) UnlinkEmail(ctx context.Context, in *api.AccountEmail) (*emptypb.Empty, error)
- func (s *ApiServer) UnlinkFacebook(ctx context.Context, in *api.AccountFacebook) (*emptypb.Empty, error)
- func (s *ApiServer) UnlinkFacebookInstantGame(ctx context.Context, in *api.AccountFacebookInstantGame) (*emptypb.Empty, error)
- func (s *ApiServer) UnlinkGameCenter(ctx context.Context, in *api.AccountGameCenter) (*emptypb.Empty, error)
- func (s *ApiServer) UnlinkGoogle(ctx context.Context, in *api.AccountGoogle) (*emptypb.Empty, error)
- func (s *ApiServer) UnlinkSteam(ctx context.Context, in *api.AccountSteam) (*emptypb.Empty, error)
- func (s *ApiServer) UpdateAccount(ctx context.Context, in *api.UpdateAccountRequest) (*emptypb.Empty, error)
- func (s *ApiServer) UpdateGroup(ctx context.Context, in *api.UpdateGroupRequest) (*emptypb.Empty, error)
- func (s *ApiServer) ValidatePurchaseApple(ctx context.Context, in *api.ValidatePurchaseAppleRequest) (*api.ValidatePurchaseResponse, error)
- func (s *ApiServer) ValidatePurchaseGoogle(ctx context.Context, in *api.ValidatePurchaseGoogleRequest) (*api.ValidatePurchaseResponse, error)
- func (s *ApiServer) ValidatePurchaseHuawei(ctx context.Context, in *api.ValidatePurchaseHuaweiRequest) (*api.ValidatePurchaseResponse, error)
- func (s *ApiServer) WriteLeaderboardRecord(ctx context.Context, in *api.WriteLeaderboardRecordRequest) (*api.LeaderboardRecord, error)
- func (s *ApiServer) WriteStorageObjects(ctx context.Context, in *api.WriteStorageObjectsRequest) (*api.StorageObjectAcks, error)
- func (s *ApiServer) WriteTournamentRecord(ctx context.Context, in *api.WriteTournamentRecordRequest) (*api.LeaderboardRecord, error)
- type BlugeResult
- type ChannelIdToStreamResult
- type Config
- type ConsoleConfig
- type ConsoleServer
- func (s *ConsoleServer) AddUser(ctx context.Context, in *console.AddUserRequest) (*emptypb.Empty, error)
- func (s *ConsoleServer) Authenticate(ctx context.Context, in *console.AuthenticateRequest) (*console.ConsoleSession, error)
- func (s *ConsoleServer) BanAccount(ctx context.Context, in *console.AccountId) (*emptypb.Empty, error)
- func (s *ConsoleServer) CallApiEndpoint(ctx context.Context, in *console.CallApiEndpointRequest) (*console.CallApiEndpointResponse, error)
- func (s *ConsoleServer) CallRpcEndpoint(ctx context.Context, in *console.CallApiEndpointRequest) (*console.CallApiEndpointResponse, error)
- func (s *ConsoleServer) DeleteAccount(ctx context.Context, in *console.AccountDeleteRequest) (*emptypb.Empty, error)
- func (s *ConsoleServer) DeleteAccounts(ctx context.Context, in *emptypb.Empty) (*emptypb.Empty, error)
- func (s *ConsoleServer) DeleteFriend(ctx context.Context, in *console.DeleteFriendRequest) (*emptypb.Empty, error)
- func (s *ConsoleServer) DeleteGroupUser(ctx context.Context, in *console.DeleteGroupUserRequest) (*emptypb.Empty, error)
- func (s *ConsoleServer) DeleteLeaderboard(ctx context.Context, in *console.LeaderboardRequest) (*emptypb.Empty, error)
- func (s *ConsoleServer) DeleteLeaderboardRecord(ctx context.Context, in *console.DeleteLeaderboardRecordRequest) (*emptypb.Empty, error)
- func (s *ConsoleServer) DeleteStorage(ctx context.Context, in *emptypb.Empty) (*emptypb.Empty, error)
- func (s *ConsoleServer) DeleteStorageObject(ctx context.Context, in *console.DeleteStorageObjectRequest) (*emptypb.Empty, error)
- func (s *ConsoleServer) DeleteUser(ctx context.Context, in *console.Username) (*emptypb.Empty, error)
- func (s *ConsoleServer) DeleteWalletLedger(ctx context.Context, in *console.DeleteWalletLedgerRequest) (*emptypb.Empty, error)
- func (s *ConsoleServer) ExportAccount(ctx context.Context, in *console.AccountId) (*console.AccountExport, error)
- func (s *ConsoleServer) GetAccount(ctx context.Context, in *console.AccountId) (*console.Account, error)
- func (s *ConsoleServer) GetConfig(ctx context.Context, in *emptypb.Empty) (*console.Config, error)
- func (s *ConsoleServer) GetFriends(ctx context.Context, in *console.AccountId) (*api.FriendList, error)
- func (s *ConsoleServer) GetGroups(ctx context.Context, in *console.AccountId) (*api.UserGroupList, error)
- func (s *ConsoleServer) GetLeaderboard(ctx context.Context, in *console.LeaderboardRequest) (*console.Leaderboard, error)
- func (s *ConsoleServer) GetMatchState(ctx context.Context, in *console.MatchStateRequest) (*console.MatchState, error)
- func (s *ConsoleServer) GetRuntime(ctx context.Context, in *emptypb.Empty) (*console.RuntimeInfo, error)
- func (s *ConsoleServer) GetStatus(ctx context.Context, in *emptypb.Empty) (*console.StatusList, error)
- func (s *ConsoleServer) GetStorage(ctx context.Context, in *api.ReadStorageObjectId) (*api.StorageObject, error)
- func (s *ConsoleServer) GetWalletLedger(ctx context.Context, in *console.GetWalletLedgerRequest) (*console.WalletLedgerList, error)
- func (s *ConsoleServer) ListAccounts(ctx context.Context, in *console.ListAccountsRequest) (*console.AccountList, error)
- func (s *ConsoleServer) ListApiEndpoints(ctx context.Context, _ *emptypb.Empty) (*console.ApiEndpointList, error)
- func (s *ConsoleServer) ListLeaderboardRecords(ctx context.Context, in *api.ListLeaderboardRecordsRequest) (*api.LeaderboardRecordList, error)
- func (s *ConsoleServer) ListLeaderboards(ctx context.Context, _ *emptypb.Empty) (*console.LeaderboardList, error)
- func (s *ConsoleServer) ListMatches(ctx context.Context, in *api.ListMatchesRequest) (*api.MatchList, error)
- func (s *ConsoleServer) ListPurchases(ctx context.Context, in *console.ListPurchasesRequest) (*api.PurchaseList, error)
- func (s *ConsoleServer) ListStorage(ctx context.Context, in *console.ListStorageRequest) (*console.StorageList, error)
- func (s *ConsoleServer) ListStorageCollections(ctx context.Context, in *emptypb.Empty) (*console.StorageCollectionsList, error)
- func (s *ConsoleServer) ListUsers(ctx context.Context, in *emptypb.Empty) (*console.UserList, error)
- func (s *ConsoleServer) Stop()
- func (s *ConsoleServer) UnbanAccount(ctx context.Context, in *console.AccountId) (*emptypb.Empty, error)
- func (s *ConsoleServer) UnlinkApple(ctx context.Context, in *console.AccountId) (*emptypb.Empty, error)
- func (s *ConsoleServer) UnlinkCustom(ctx context.Context, in *console.AccountId) (*emptypb.Empty, error)
- func (s *ConsoleServer) UnlinkDevice(ctx context.Context, in *console.UnlinkDeviceRequest) (*emptypb.Empty, error)
- func (s *ConsoleServer) UnlinkEmail(ctx context.Context, in *console.AccountId) (*emptypb.Empty, error)
- func (s *ConsoleServer) UnlinkFacebook(ctx context.Context, in *console.AccountId) (*emptypb.Empty, error)
- func (s *ConsoleServer) UnlinkFacebookInstantGame(ctx context.Context, in *console.AccountId) (*emptypb.Empty, error)
- func (s *ConsoleServer) UnlinkGameCenter(ctx context.Context, in *console.AccountId) (*emptypb.Empty, error)
- func (s *ConsoleServer) UnlinkGoogle(ctx context.Context, in *console.AccountId) (*emptypb.Empty, error)
- func (s *ConsoleServer) UnlinkSteam(ctx context.Context, in *console.AccountId) (*emptypb.Empty, error)
- func (s *ConsoleServer) UpdateAccount(ctx context.Context, in *console.UpdateAccountRequest) (*emptypb.Empty, error)
- func (s *ConsoleServer) WriteStorageObject(ctx context.Context, in *console.WriteStorageObjectRequest) (*api.StorageObjectAck, error)
- type ConsoleTokenClaims
- type DatabaseConfig
- type DeferredMessage
- type ErrorCauser
- type IAPAppleConfig
- type IAPConfig
- type IAPGoogleConfig
- type IAPHuaweiConfig
- type LSentinelType
- type Leaderboard
- func (l *Leaderboard) GetAuthoritative() bool
- func (l *Leaderboard) GetCreateTime() int64
- func (l *Leaderboard) GetId() string
- func (l *Leaderboard) GetMetadata() map[string]interface{}
- func (l *Leaderboard) GetOperator() string
- func (l *Leaderboard) GetReset() string
- func (l *Leaderboard) GetSortOrder() string
- func (l *Leaderboard) IsTournament() bool
- type LeaderboardCache
- type LeaderboardConfig
- type LeaderboardListCursor
- type LeaderboardRankCache
- type LeaderboardScheduler
- type LeaderboardSchedulerCallback
- type LeaderboardWithExpiry
- type LocalLeaderboardCache
- func (l *LocalLeaderboardCache) Create(ctx context.Context, id string, authoritative bool, sortOrder, operator int, ...) (*Leaderboard, error)
- func (l *LocalLeaderboardCache) CreateTournament(ctx context.Context, id string, authoritative bool, sortOrder, operator int, ...) (*Leaderboard, error)
- func (l *LocalLeaderboardCache) Delete(ctx context.Context, id string) error
- func (l *LocalLeaderboardCache) Get(id string) *Leaderboard
- func (l *LocalLeaderboardCache) GetAllLeaderboards() []*Leaderboard
- func (l *LocalLeaderboardCache) Insert(id string, authoritative bool, sortOrder, operator int, ...)
- func (l *LocalLeaderboardCache) InsertTournament(id string, authoritative bool, sortOrder, operator int, ...)
- func (l *LocalLeaderboardCache) List(categoryStart, categoryEnd, limit int, cursor *LeaderboardListCursor) ([]*Leaderboard, *LeaderboardListCursor, error)
- func (l *LocalLeaderboardCache) ListTournaments(now int64, categoryStart, categoryEnd int, startTime, endTime int64, limit int, ...) ([]*Leaderboard, *TournamentListCursor, error)
- func (l *LocalLeaderboardCache) RefreshAllLeaderboards(ctx context.Context) error
- func (l *LocalLeaderboardCache) Remove(id string)
- type LocalLeaderboardRankCache
- func (l *LocalLeaderboardRankCache) Delete(leaderboardId string, expiryUnix int64, ownerID uuid.UUID) bool
- func (l *LocalLeaderboardRankCache) DeleteLeaderboard(leaderboardId string, expiryUnix int64) bool
- func (l *LocalLeaderboardRankCache) Fill(leaderboardId string, expiryUnix int64, records []*api.LeaderboardRecord)
- func (l *LocalLeaderboardRankCache) Get(leaderboardId string, expiryUnix int64, ownerID uuid.UUID) int64
- func (l *LocalLeaderboardRankCache) Insert(leaderboardId string, expiryUnix int64, sortOrder int, ownerID uuid.UUID, ...) int64
- func (l *LocalLeaderboardRankCache) TrimExpired(nowUnix int64) bool
- type LocalLeaderboardScheduler
- type LocalMatchRegistry
- func (r *LocalMatchRegistry) Count() int
- func (r *LocalMatchRegistry) CreateMatch(ctx context.Context, logger *zap.Logger, createFn RuntimeMatchCreateFunction, ...) (string, error)
- func (r *LocalMatchRegistry) GetMatch(ctx context.Context, id string) (*api.Match, error)
- func (r *LocalMatchRegistry) GetState(ctx context.Context, id uuid.UUID, node string) ([]*rtapi.UserPresence, int64, string, error)
- func (r *LocalMatchRegistry) Join(id uuid.UUID, presences []*MatchPresence)
- func (r *LocalMatchRegistry) JoinAttempt(ctx context.Context, id uuid.UUID, node string, userID, sessionID uuid.UUID, ...) (bool, bool, bool, string, string, []*MatchPresence)
- func (r *LocalMatchRegistry) Kick(stream PresenceStream, presences []*MatchPresence)
- func (r *LocalMatchRegistry) Leave(id uuid.UUID, presences []*MatchPresence)
- func (r *LocalMatchRegistry) ListMatches(ctx context.Context, limit int, authoritative *wrapperspb.BoolValue, ...) ([]*api.Match, error)
- func (r *LocalMatchRegistry) NewMatch(logger *zap.Logger, id uuid.UUID, core RuntimeMatchCore, stopped *atomic.Bool, ...) (*MatchHandler, error)
- func (r *LocalMatchRegistry) RemoveMatch(id uuid.UUID, stream PresenceStream)
- func (r *LocalMatchRegistry) SendData(id uuid.UUID, node string, userID, sessionID uuid.UUID, ...)
- func (r *LocalMatchRegistry) Signal(ctx context.Context, id, data string) (string, error)
- func (r *LocalMatchRegistry) Stop(graceSeconds int) chan struct{}
- func (r *LocalMatchRegistry) UpdateMatchLabel(id uuid.UUID, tickRate int, handlerName, label string, createTime int64) error
- type LocalMatchmaker
- func (m *LocalMatchmaker) Add(presences []*MatchmakerPresence, sessionID, partyId, query string, ...) (string, error)
- func (m *LocalMatchmaker) RemoveParty(partyID, ticket string) error
- func (m *LocalMatchmaker) RemovePartyAll(partyID string) error
- func (m *LocalMatchmaker) RemoveSession(sessionID, ticket string) error
- func (m *LocalMatchmaker) RemoveSessionAll(sessionID string) error
- func (m *LocalMatchmaker) Stop()
- type LocalMessageRouter
- func (r *LocalMessageRouter) SendDeferred(logger *zap.Logger, messages []*DeferredMessage)
- func (r *LocalMessageRouter) SendToPresenceIDs(logger *zap.Logger, presenceIDs []*PresenceID, envelope *rtapi.Envelope, ...)
- func (r *LocalMessageRouter) SendToStream(logger *zap.Logger, stream PresenceStream, envelope *rtapi.Envelope, ...)
- type LocalMetrics
- func (m *LocalMetrics) Api(name string, elapsed time.Duration, recvBytes, sentBytes int64, isErr bool)
- func (m *LocalMetrics) ApiAfter(name string, elapsed time.Duration, isErr bool)
- func (m *LocalMetrics) ApiBefore(name string, elapsed time.Duration, isErr bool)
- func (m *LocalMetrics) CountDroppedEvents(delta int64)
- func (m *LocalMetrics) CountWebsocketClosed(delta int64)
- func (m *LocalMetrics) CountWebsocketOpened(delta int64)
- func (m *LocalMetrics) CustomCounter(name string, tags map[string]string, delta int64)
- func (m *LocalMetrics) CustomGauge(name string, tags map[string]string, value float64)
- func (m *LocalMetrics) CustomTimer(name string, tags map[string]string, value time.Duration)
- func (m *LocalMetrics) GaugeAuthoritativeMatches(value float64)
- func (m *LocalMetrics) GaugeJsRuntimes(value float64)
- func (m *LocalMetrics) GaugeLuaRuntimes(value float64)
- func (m *LocalMetrics) GaugePresences(value float64)
- func (m *LocalMetrics) GaugeRuntimes(value float64)
- func (m *LocalMetrics) GaugeSessions(value float64)
- func (m *LocalMetrics) Message(recvBytes int64, isErr bool)
- func (m *LocalMetrics) MessageBytesSent(sentBytes int64)
- func (m *LocalMetrics) PresenceEvent(dequeueElapsed, processElapsed time.Duration)
- func (m *LocalMetrics) SnapshotLatencyMs() float64
- func (m *LocalMetrics) SnapshotRateSec() float64
- func (m *LocalMetrics) SnapshotRecvKbSec() float64
- func (m *LocalMetrics) SnapshotSentKbSec() float64
- func (m *LocalMetrics) Stop(logger *zap.Logger)
- type LocalPartyRegistry
- func (p *LocalPartyRegistry) Create(open bool, maxSize int, presence *rtapi.UserPresence) *PartyHandler
- func (p *LocalPartyRegistry) Delete(id uuid.UUID)
- func (p *LocalPartyRegistry) Join(id uuid.UUID, presences []*Presence)
- func (p *LocalPartyRegistry) Leave(id uuid.UUID, presences []*Presence)
- func (p *LocalPartyRegistry) PartyAccept(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string, ...) error
- func (p *LocalPartyRegistry) PartyClose(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string) error
- func (p *LocalPartyRegistry) PartyDataSend(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string, ...) error
- func (p *LocalPartyRegistry) PartyJoinRequest(ctx context.Context, id uuid.UUID, node string, presence *Presence) (bool, error)
- func (p *LocalPartyRegistry) PartyJoinRequestList(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string) ([]*rtapi.UserPresence, error)
- func (p *LocalPartyRegistry) PartyMatchmakerAdd(ctx context.Context, id uuid.UUID, node, sessionID, fromNode, query string, ...) (string, []*PresenceID, error)
- func (p *LocalPartyRegistry) PartyMatchmakerRemove(ctx context.Context, id uuid.UUID, node, sessionID, fromNode, ticket string) error
- func (p *LocalPartyRegistry) PartyPromote(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string, ...) error
- func (p *LocalPartyRegistry) PartyRemove(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string, ...) error
- type LocalSessionCache
- func (s *LocalSessionCache) Add(userID uuid.UUID, sessionExp int64, sessionToken string, refreshExp int64, ...)
- func (s *LocalSessionCache) Ban(userIDs []uuid.UUID)
- func (s *LocalSessionCache) IsValidRefresh(userID uuid.UUID, exp int64, token string) bool
- func (s *LocalSessionCache) IsValidSession(userID uuid.UUID, exp int64, token string) bool
- func (s *LocalSessionCache) Remove(userID uuid.UUID, sessionExp int64, sessionToken string, refreshExp int64, ...)
- func (s *LocalSessionCache) RemoveAll(userID uuid.UUID)
- func (s *LocalSessionCache) Stop()
- func (s *LocalSessionCache) Unban(userIDs []uuid.UUID)
- type LocalSessionRegistry
- func (r *LocalSessionRegistry) Add(session Session)
- func (r *LocalSessionRegistry) Count() int
- func (r *LocalSessionRegistry) Disconnect(ctx context.Context, sessionID uuid.UUID, reason ...runtime.PresenceReason) error
- func (r *LocalSessionRegistry) Get(sessionID uuid.UUID) Session
- func (r *LocalSessionRegistry) Remove(sessionID uuid.UUID)
- func (r *LocalSessionRegistry) SingleSession(ctx context.Context, tracker Tracker, userID, sessionID uuid.UUID)
- func (r *LocalSessionRegistry) Stop()
- type LocalStatusHandler
- type LocalStreamManager
- func (m *LocalStreamManager) UserJoin(stream PresenceStream, userID, sessionID uuid.UUID, hidden, persistence bool, ...) (bool, bool, error)
- func (m *LocalStreamManager) UserLeave(stream PresenceStream, userID, sessionID uuid.UUID) error
- func (m *LocalStreamManager) UserUpdate(stream PresenceStream, userID, sessionID uuid.UUID, hidden, persistence bool, ...) (bool, error)
- type LocalTracker
- func (t *LocalTracker) Count() int
- func (t *LocalTracker) CountByStream(stream PresenceStream) int
- func (t *LocalTracker) CountByStreamModeFilter(modes map[uint8]*uint8) map[*PresenceStream]int32
- func (t *LocalTracker) GetBySessionIDStreamUserID(node string, sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID) *PresenceMeta
- func (t *LocalTracker) GetLocalBySessionIDStreamUserID(sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID) *PresenceMeta
- func (t *LocalTracker) ListByStream(stream PresenceStream, includeHidden bool, includeNotHidden bool) []*Presence
- func (t *LocalTracker) ListLocalSessionIDByStream(stream PresenceStream) []uuid.UUID
- func (t *LocalTracker) ListNodesForStream(stream PresenceStream) map[string]struct{}
- func (t *LocalTracker) ListPresenceIDByStream(stream PresenceStream) []*PresenceID
- func (t *LocalTracker) SetMatchJoinListener(f func(id uuid.UUID, joins []*MatchPresence))
- func (t *LocalTracker) SetMatchLeaveListener(f func(id uuid.UUID, leaves []*MatchPresence))
- func (t *LocalTracker) SetPartyJoinListener(f func(id uuid.UUID, joins []*Presence))
- func (t *LocalTracker) SetPartyLeaveListener(f func(id uuid.UUID, leaves []*Presence))
- func (t *LocalTracker) Stop()
- func (t *LocalTracker) StreamExists(stream PresenceStream) bool
- func (t *LocalTracker) Track(ctx context.Context, sessionID uuid.UUID, stream PresenceStream, ...) (bool, bool)
- func (t *LocalTracker) TrackMulti(ctx context.Context, sessionID uuid.UUID, ops []*TrackerOp, userID uuid.UUID, ...) bool
- func (t *LocalTracker) Untrack(sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID)
- func (t *LocalTracker) UntrackAll(sessionID uuid.UUID, reason runtime.PresenceReason)
- func (t *LocalTracker) UntrackByStream(stream PresenceStream)
- func (t *LocalTracker) UntrackLocalByModes(sessionID uuid.UUID, modes map[uint8]struct{}, skipStream PresenceStream)
- func (t *LocalTracker) UntrackLocalByStream(stream PresenceStream)
- func (t *LocalTracker) UntrackMulti(sessionID uuid.UUID, streams []*PresenceStream, userID uuid.UUID)
- func (t *LocalTracker) Update(ctx context.Context, sessionID uuid.UUID, stream PresenceStream, ...) bool
- type LoggerConfig
- type LoggingFormat
- type MatchConfig
- type MatchDataMessage
- func (m *MatchDataMessage) GetData() []byte
- func (m *MatchDataMessage) GetHidden() bool
- func (m *MatchDataMessage) GetNodeId() string
- func (m *MatchDataMessage) GetOpCode() int64
- func (m *MatchDataMessage) GetPersistence() bool
- func (m *MatchDataMessage) GetReason() runtime.PresenceReason
- func (m *MatchDataMessage) GetReceiveTime() int64
- func (m *MatchDataMessage) GetReliable() bool
- func (m *MatchDataMessage) GetSessionId() string
- func (m *MatchDataMessage) GetStatus() string
- func (m *MatchDataMessage) GetUserId() string
- func (m *MatchDataMessage) GetUsername() string
- type MatchFnId
- type MatchGetStateResult
- type MatchHandler
- func (mh *MatchHandler) CreateTime() int64
- func (mh *MatchHandler) HandlerName() string
- func (mh *MatchHandler) Label() string
- func (mh *MatchHandler) QueueData(m *MatchDataMessage)
- func (mh *MatchHandler) QueueGetState(ctx context.Context, resultCh chan<- *MatchGetStateResult) bool
- func (mh *MatchHandler) QueueJoin(joins []*MatchPresence, mark bool) bool
- func (mh *MatchHandler) QueueJoinAttempt(ctx context.Context, resultCh chan<- *MatchJoinAttemptResult, ...) bool
- func (mh *MatchHandler) QueueLeave(leaves []*MatchPresence) bool
- func (mh *MatchHandler) QueueSignal(ctx context.Context, resultCh chan<- *MatchSignalResult, data string) bool
- func (mh *MatchHandler) QueueTerminate(graceSeconds int) bool
- func (mh *MatchHandler) Stop()
- func (mh *MatchHandler) TickRate() int
- type MatchIndexEntry
- type MatchJoinAttemptResult
- type MatchJoinMarker
- type MatchJoinMarkerList
- type MatchNamesListFunction
- type MatchPresence
- func (p *MatchPresence) GetHidden() bool
- func (p *MatchPresence) GetNodeId() string
- func (p *MatchPresence) GetPersistence() bool
- func (p *MatchPresence) GetReason() runtime.PresenceReason
- func (p *MatchPresence) GetSessionId() string
- func (p *MatchPresence) GetStatus() string
- func (p *MatchPresence) GetUserId() string
- func (p *MatchPresence) GetUsername() string
- type MatchPresenceList
- func (m *MatchPresenceList) Contains(presence *PresenceID) bool
- func (m *MatchPresenceList) FilterPresenceIDs(ids []*PresenceID) []*PresenceID
- func (m *MatchPresenceList) Join(joins []*MatchPresence) []*MatchPresence
- func (m *MatchPresenceList) Leave(leaves []*MatchPresence) []*MatchPresence
- func (m *MatchPresenceList) ListPresenceIDs() []*PresenceID
- func (m *MatchPresenceList) ListPresences() []*MatchPresence
- func (m *MatchPresenceList) Size() int
- type MatchPresenceListItem
- type MatchProvider
- type MatchRegistry
- type MatchSignalResult
- type Matchmaker
- type MatchmakerConfig
- type MatchmakerEntry
- type MatchmakerIndex
- type MatchmakerPresence
- func (p *MatchmakerPresence) GetHidden() bool
- func (p *MatchmakerPresence) GetNodeId() string
- func (p *MatchmakerPresence) GetPersistence() bool
- func (p *MatchmakerPresence) GetReason() runtime.PresenceReason
- func (p *MatchmakerPresence) GetSessionId() string
- func (p *MatchmakerPresence) GetStatus() string
- func (p *MatchmakerPresence) GetUserId() string
- func (p *MatchmakerPresence) GetUsername() string
- type MessageRouter
- type MethodName
- type Metrics
- type MetricsConfig
- type MetricsGrpcHandler
- func (m *MetricsGrpcHandler) HandleConn(context.Context, stats.ConnStats)
- func (m *MetricsGrpcHandler) HandleRPC(ctx context.Context, rs stats.RPCStats)
- func (m *MetricsGrpcHandler) TagConn(ctx context.Context, _ *stats.ConnTagInfo) context.Context
- func (m *MetricsGrpcHandler) TagRPC(ctx context.Context, info *stats.RPCTagInfo) context.Context
- type OrderedTournaments
- type PartyHandler
- func (p *PartyHandler) Accept(sessionID, node string, presence *rtapi.UserPresence) error
- func (p *PartyHandler) Close(sessionID, node string) error
- func (p *PartyHandler) DataSend(sessionID, node string, opCode int64, data []byte) error
- func (p *PartyHandler) Join(presences []*Presence)
- func (p *PartyHandler) JoinRequest(presence *Presence) (bool, error)
- func (p *PartyHandler) JoinRequestList(sessionID, node string) ([]*rtapi.UserPresence, error)
- func (p *PartyHandler) Leave(presences []*Presence)
- func (p *PartyHandler) MatchmakerAdd(sessionID, node, query string, minCount, maxCount int, ...) (string, []*PresenceID, error)
- func (p *PartyHandler) MatchmakerRemove(sessionID, node, ticket string) error
- func (p *PartyHandler) Promote(sessionID, node string, presence *rtapi.UserPresence) error
- func (p *PartyHandler) Remove(sessionID, node string, presence *rtapi.UserPresence) error
- type PartyRegistry
- type Pipeline
- type Presence
- func (p *Presence) GetHidden() bool
- func (p *Presence) GetNodeId() string
- func (p *Presence) GetPersistence() bool
- func (p *Presence) GetReason() runtime.PresenceReason
- func (p *Presence) GetSessionId() string
- func (p *Presence) GetStatus() string
- func (p *Presence) GetUserId() string
- func (p *Presence) GetUsername() string
- type PresenceEvent
- type PresenceID
- type PresenceMeta
- type PresenceStream
- type RankAsc
- type RankCache
- type RankDesc
- type RedirectStdLogWriter
- type Runtime
- func (r *Runtime) AfterAddFriends() RuntimeAfterAddFriendsFunction
- func (r *Runtime) AfterAddGroupUsers() RuntimeAfterAddGroupUsersFunction
- func (r *Runtime) AfterAuthenticateApple() RuntimeAfterAuthenticateAppleFunction
- func (r *Runtime) AfterAuthenticateCustom() RuntimeAfterAuthenticateCustomFunction
- func (r *Runtime) AfterAuthenticateDevice() RuntimeAfterAuthenticateDeviceFunction
- func (r *Runtime) AfterAuthenticateEmail() RuntimeAfterAuthenticateEmailFunction
- func (r *Runtime) AfterAuthenticateFacebook() RuntimeAfterAuthenticateFacebookFunction
- func (r *Runtime) AfterAuthenticateFacebookInstantGame() RuntimeAfterAuthenticateFacebookInstantGameFunction
- func (r *Runtime) AfterAuthenticateGameCenter() RuntimeAfterAuthenticateGameCenterFunction
- func (r *Runtime) AfterAuthenticateGoogle() RuntimeAfterAuthenticateGoogleFunction
- func (r *Runtime) AfterAuthenticateSteam() RuntimeAfterAuthenticateSteamFunction
- func (r *Runtime) AfterBanGroupUsers() RuntimeAfterBanGroupUsersFunction
- func (r *Runtime) AfterBlockFriends() RuntimeAfterBlockFriendsFunction
- func (r *Runtime) AfterCreateGroup() RuntimeAfterCreateGroupFunction
- func (r *Runtime) AfterDeleteFriends() RuntimeAfterDeleteFriendsFunction
- func (r *Runtime) AfterDeleteGroup() RuntimeAfterDeleteGroupFunction
- func (r *Runtime) AfterDeleteLeaderboardRecord() RuntimeAfterDeleteLeaderboardRecordFunction
- func (r *Runtime) AfterDeleteNotification() RuntimeAfterDeleteNotificationFunction
- func (r *Runtime) AfterDeleteStorageObjects() RuntimeAfterDeleteStorageObjectsFunction
- func (r *Runtime) AfterDemoteGroupUsers() RuntimeAfterDemoteGroupUsersFunction
- func (r *Runtime) AfterEvent() RuntimeAfterEventFunction
- func (r *Runtime) AfterGetAccount() RuntimeAfterGetAccountFunction
- func (r *Runtime) AfterGetUsers() RuntimeAfterGetUsersFunction
- func (r *Runtime) AfterImportFacebookFriends() RuntimeAfterImportFacebookFriendsFunction
- func (r *Runtime) AfterImportSteamFriends() RuntimeAfterImportSteamFriendsFunction
- func (r *Runtime) AfterJoinGroup() RuntimeAfterJoinGroupFunction
- func (r *Runtime) AfterJoinTournament() RuntimeAfterJoinTournamentFunction
- func (r *Runtime) AfterKickGroupUsers() RuntimeAfterKickGroupUsersFunction
- func (r *Runtime) AfterLeaveGroup() RuntimeAfterLeaveGroupFunction
- func (r *Runtime) AfterLinkApple() RuntimeAfterLinkAppleFunction
- func (r *Runtime) AfterLinkCustom() RuntimeAfterLinkCustomFunction
- func (r *Runtime) AfterLinkDevice() RuntimeAfterLinkDeviceFunction
- func (r *Runtime) AfterLinkEmail() RuntimeAfterLinkEmailFunction
- func (r *Runtime) AfterLinkFacebook() RuntimeAfterLinkFacebookFunction
- func (r *Runtime) AfterLinkFacebookInstantGame() RuntimeAfterLinkFacebookInstantGameFunction
- func (r *Runtime) AfterLinkGameCenter() RuntimeAfterLinkGameCenterFunction
- func (r *Runtime) AfterLinkGoogle() RuntimeAfterLinkGoogleFunction
- func (r *Runtime) AfterLinkSteam() RuntimeAfterLinkSteamFunction
- func (r *Runtime) AfterListChannelMessages() RuntimeAfterListChannelMessagesFunction
- func (r *Runtime) AfterListFriends() RuntimeAfterListFriendsFunction
- func (r *Runtime) AfterListGroupUsers() RuntimeAfterListGroupUsersFunction
- func (r *Runtime) AfterListGroups() RuntimeAfterListGroupsFunction
- func (r *Runtime) AfterListLeaderboardRecords() RuntimeAfterListLeaderboardRecordsFunction
- func (r *Runtime) AfterListLeaderboardRecordsAroundOwner() RuntimeAfterListLeaderboardRecordsAroundOwnerFunction
- func (r *Runtime) AfterListMatches() RuntimeAfterListMatchesFunction
- func (r *Runtime) AfterListNotifications() RuntimeAfterListNotificationsFunction
- func (r *Runtime) AfterListStorageObjects() RuntimeAfterListStorageObjectsFunction
- func (r *Runtime) AfterListTournamentRecords() RuntimeAfterListTournamentRecordsFunction
- func (r *Runtime) AfterListTournamentRecordsAroundOwner() RuntimeAfterListTournamentRecordsAroundOwnerFunction
- func (r *Runtime) AfterListTournaments() RuntimeAfterListTournamentsFunction
- func (r *Runtime) AfterListUserGroups() RuntimeAfterListUserGroupsFunction
- func (r *Runtime) AfterPromoteGroupUsers() RuntimeAfterPromoteGroupUsersFunction
- func (r *Runtime) AfterReadStorageObjects() RuntimeAfterReadStorageObjectsFunction
- func (r *Runtime) AfterRt(id string) RuntimeAfterRtFunction
- func (r *Runtime) AfterSessionLogout() RuntimeAfterSessionLogoutFunction
- func (r *Runtime) AfterSessionRefresh() RuntimeAfterSessionRefreshFunction
- func (r *Runtime) AfterUnlinkApple() RuntimeAfterUnlinkAppleFunction
- func (r *Runtime) AfterUnlinkCustom() RuntimeAfterUnlinkCustomFunction
- func (r *Runtime) AfterUnlinkDevice() RuntimeAfterUnlinkDeviceFunction
- func (r *Runtime) AfterUnlinkEmail() RuntimeAfterUnlinkEmailFunction
- func (r *Runtime) AfterUnlinkFacebook() RuntimeAfterUnlinkFacebookFunction
- func (r *Runtime) AfterUnlinkFacebookInstantGame() RuntimeAfterUnlinkFacebookInstantGameFunction
- func (r *Runtime) AfterUnlinkGameCenter() RuntimeAfterUnlinkGameCenterFunction
- func (r *Runtime) AfterUnlinkGoogle() RuntimeAfterUnlinkGoogleFunction
- func (r *Runtime) AfterUnlinkSteam() RuntimeAfterUnlinkSteamFunction
- func (r *Runtime) AfterUpdateAccount() RuntimeAfterUpdateAccountFunction
- func (r *Runtime) AfterUpdateGroup() RuntimeAfterUpdateGroupFunction
- func (r *Runtime) AfterValidatePurchaseApple() RuntimeAfterValidatePurchaseAppleFunction
- func (r *Runtime) AfterValidatePurchaseGoogle() RuntimeAfterValidatePurchaseGoogleFunction
- func (r *Runtime) AfterValidatePurchaseHuawei() RuntimeAfterValidatePurchaseHuaweiFunction
- func (r *Runtime) AfterWriteLeaderboardRecord() RuntimeAfterWriteLeaderboardRecordFunction
- func (r *Runtime) AfterWriteStorageObjects() RuntimeAfterWriteStorageObjectsFunction
- func (r *Runtime) AfterWriteTournamentRecord() RuntimeAfterWriteTournamentRecordFunction
- func (r *Runtime) BeforeAddFriends() RuntimeBeforeAddFriendsFunction
- func (r *Runtime) BeforeAddGroupUsers() RuntimeBeforeAddGroupUsersFunction
- func (r *Runtime) BeforeAuthenticateApple() RuntimeBeforeAuthenticateAppleFunction
- func (r *Runtime) BeforeAuthenticateCustom() RuntimeBeforeAuthenticateCustomFunction
- func (r *Runtime) BeforeAuthenticateDevice() RuntimeBeforeAuthenticateDeviceFunction
- func (r *Runtime) BeforeAuthenticateEmail() RuntimeBeforeAuthenticateEmailFunction
- func (r *Runtime) BeforeAuthenticateFacebook() RuntimeBeforeAuthenticateFacebookFunction
- func (r *Runtime) BeforeAuthenticateFacebookInstantGame() RuntimeBeforeAuthenticateFacebookInstantGameFunction
- func (r *Runtime) BeforeAuthenticateGameCenter() RuntimeBeforeAuthenticateGameCenterFunction
- func (r *Runtime) BeforeAuthenticateGoogle() RuntimeBeforeAuthenticateGoogleFunction
- func (r *Runtime) BeforeAuthenticateSteam() RuntimeBeforeAuthenticateSteamFunction
- func (r *Runtime) BeforeBanGroupUsers() RuntimeBeforeBanGroupUsersFunction
- func (r *Runtime) BeforeBlockFriends() RuntimeBeforeBlockFriendsFunction
- func (r *Runtime) BeforeCreateGroup() RuntimeBeforeCreateGroupFunction
- func (r *Runtime) BeforeDeleteFriends() RuntimeBeforeDeleteFriendsFunction
- func (r *Runtime) BeforeDeleteGroup() RuntimeBeforeDeleteGroupFunction
- func (r *Runtime) BeforeDeleteLeaderboardRecord() RuntimeBeforeDeleteLeaderboardRecordFunction
- func (r *Runtime) BeforeDeleteNotification() RuntimeBeforeDeleteNotificationFunction
- func (r *Runtime) BeforeDeleteStorageObjects() RuntimeBeforeDeleteStorageObjectsFunction
- func (r *Runtime) BeforeDemoteGroupUsers() RuntimeBeforeDemoteGroupUsersFunction
- func (r *Runtime) BeforeEvent() RuntimeBeforeEventFunction
- func (r *Runtime) BeforeGetAccount() RuntimeBeforeGetAccountFunction
- func (r *Runtime) BeforeGetUsers() RuntimeBeforeGetUsersFunction
- func (r *Runtime) BeforeImportFacebookFriends() RuntimeBeforeImportFacebookFriendsFunction
- func (r *Runtime) BeforeImportSteamFriends() RuntimeBeforeImportSteamFriendsFunction
- func (r *Runtime) BeforeJoinGroup() RuntimeBeforeJoinGroupFunction
- func (r *Runtime) BeforeJoinTournament() RuntimeBeforeJoinTournamentFunction
- func (r *Runtime) BeforeKickGroupUsers() RuntimeBeforeKickGroupUsersFunction
- func (r *Runtime) BeforeLeaveGroup() RuntimeBeforeLeaveGroupFunction
- func (r *Runtime) BeforeLinkApple() RuntimeBeforeLinkAppleFunction
- func (r *Runtime) BeforeLinkCustom() RuntimeBeforeLinkCustomFunction
- func (r *Runtime) BeforeLinkDevice() RuntimeBeforeLinkDeviceFunction
- func (r *Runtime) BeforeLinkEmail() RuntimeBeforeLinkEmailFunction
- func (r *Runtime) BeforeLinkFacebook() RuntimeBeforeLinkFacebookFunction
- func (r *Runtime) BeforeLinkFacebookInstantGame() RuntimeBeforeLinkFacebookInstantGameFunction
- func (r *Runtime) BeforeLinkGameCenter() RuntimeBeforeLinkGameCenterFunction
- func (r *Runtime) BeforeLinkGoogle() RuntimeBeforeLinkGoogleFunction
- func (r *Runtime) BeforeLinkSteam() RuntimeBeforeLinkSteamFunction
- func (r *Runtime) BeforeListChannelMessages() RuntimeBeforeListChannelMessagesFunction
- func (r *Runtime) BeforeListFriends() RuntimeBeforeListFriendsFunction
- func (r *Runtime) BeforeListGroupUsers() RuntimeBeforeListGroupUsersFunction
- func (r *Runtime) BeforeListGroups() RuntimeBeforeListGroupsFunction
- func (r *Runtime) BeforeListLeaderboardRecords() RuntimeBeforeListLeaderboardRecordsFunction
- func (r *Runtime) BeforeListLeaderboardRecordsAroundOwner() RuntimeBeforeListLeaderboardRecordsAroundOwnerFunction
- func (r *Runtime) BeforeListMatches() RuntimeBeforeListMatchesFunction
- func (r *Runtime) BeforeListNotifications() RuntimeBeforeListNotificationsFunction
- func (r *Runtime) BeforeListStorageObjects() RuntimeBeforeListStorageObjectsFunction
- func (r *Runtime) BeforeListTournamentRecords() RuntimeBeforeListTournamentRecordsFunction
- func (r *Runtime) BeforeListTournamentRecordsAroundOwner() RuntimeBeforeListTournamentRecordsAroundOwnerFunction
- func (r *Runtime) BeforeListTournaments() RuntimeBeforeListTournamentsFunction
- func (r *Runtime) BeforeListUserGroups() RuntimeBeforeListUserGroupsFunction
- func (r *Runtime) BeforePromoteGroupUsers() RuntimeBeforePromoteGroupUsersFunction
- func (r *Runtime) BeforeReadStorageObjects() RuntimeBeforeReadStorageObjectsFunction
- func (r *Runtime) BeforeRt(id string) RuntimeBeforeRtFunction
- func (r *Runtime) BeforeSessionLogout() RuntimeBeforeSessionLogoutFunction
- func (r *Runtime) BeforeSessionRefresh() RuntimeBeforeSessionRefreshFunction
- func (r *Runtime) BeforeUnlinkApple() RuntimeBeforeUnlinkAppleFunction
- func (r *Runtime) BeforeUnlinkCustom() RuntimeBeforeUnlinkCustomFunction
- func (r *Runtime) BeforeUnlinkDevice() RuntimeBeforeUnlinkDeviceFunction
- func (r *Runtime) BeforeUnlinkEmail() RuntimeBeforeUnlinkEmailFunction
- func (r *Runtime) BeforeUnlinkFacebook() RuntimeBeforeUnlinkFacebookFunction
- func (r *Runtime) BeforeUnlinkFacebookInstantGame() RuntimeBeforeUnlinkFacebookInstantGameFunction
- func (r *Runtime) BeforeUnlinkGameCenter() RuntimeBeforeUnlinkGameCenterFunction
- func (r *Runtime) BeforeUnlinkGoogle() RuntimeBeforeUnlinkGoogleFunction
- func (r *Runtime) BeforeUnlinkSteam() RuntimeBeforeUnlinkSteamFunction
- func (r *Runtime) BeforeUpdateAccount() RuntimeBeforeUpdateAccountFunction
- func (r *Runtime) BeforeUpdateGroup() RuntimeBeforeUpdateGroupFunction
- func (r *Runtime) BeforeValidatePurchaseApple() RuntimeBeforeValidatePurchaseAppleFunction
- func (r *Runtime) BeforeValidatePurchaseGoogle() RuntimeBeforeValidatePurchaseGoogleFunction
- func (r *Runtime) BeforeValidatePurchaseHuawei() RuntimeBeforeValidatePurchaseHuaweiFunction
- func (r *Runtime) BeforeWriteLeaderboardRecord() RuntimeBeforeWriteLeaderboardRecordFunction
- func (r *Runtime) BeforeWriteStorageObjects() RuntimeBeforeWriteStorageObjectsFunction
- func (r *Runtime) BeforeWriteTournamentRecord() RuntimeBeforeWriteTournamentRecordFunction
- func (r *Runtime) Event() RuntimeEventCustomFunction
- func (r *Runtime) EventSessionEnd() RuntimeEventSessionEndFunction
- func (r *Runtime) EventSessionStart() RuntimeEventSessionStartFunction
- func (r *Runtime) LeaderboardReset() RuntimeLeaderboardResetFunction
- func (r *Runtime) MatchCreateFunction() RuntimeMatchCreateFunction
- func (r *Runtime) MatchmakerMatched() RuntimeMatchmakerMatchedFunction
- func (r *Runtime) Rpc(id string) RuntimeRpcFunction
- func (r *Runtime) TournamentEnd() RuntimeTournamentEndFunction
- func (r *Runtime) TournamentReset() RuntimeTournamentResetFunction
- type RuntimeAfterAddFriendsFunction
- type RuntimeAfterAddGroupUsersFunction
- type RuntimeAfterAuthenticateAppleFunction
- type RuntimeAfterAuthenticateCustomFunction
- type RuntimeAfterAuthenticateDeviceFunction
- type RuntimeAfterAuthenticateEmailFunction
- type RuntimeAfterAuthenticateFacebookFunction
- type RuntimeAfterAuthenticateFacebookInstantGameFunction
- type RuntimeAfterAuthenticateGameCenterFunction
- type RuntimeAfterAuthenticateGoogleFunction
- type RuntimeAfterAuthenticateSteamFunction
- type RuntimeAfterBanGroupUsersFunction
- type RuntimeAfterBlockFriendsFunction
- type RuntimeAfterCreateGroupFunction
- type RuntimeAfterDeleteFriendsFunction
- type RuntimeAfterDeleteGroupFunction
- type RuntimeAfterDeleteLeaderboardRecordFunction
- type RuntimeAfterDeleteNotificationFunction
- type RuntimeAfterDeleteStorageObjectsFunction
- type RuntimeAfterDemoteGroupUsersFunction
- type RuntimeAfterEventFunction
- type RuntimeAfterGetAccountFunction
- type RuntimeAfterGetUsersFunction
- type RuntimeAfterImportFacebookFriendsFunction
- type RuntimeAfterImportSteamFriendsFunction
- type RuntimeAfterJoinGroupFunction
- type RuntimeAfterJoinTournamentFunction
- type RuntimeAfterKickGroupUsersFunction
- type RuntimeAfterLeaveGroupFunction
- type RuntimeAfterLinkAppleFunction
- type RuntimeAfterLinkCustomFunction
- type RuntimeAfterLinkDeviceFunction
- type RuntimeAfterLinkEmailFunction
- type RuntimeAfterLinkFacebookFunction
- type RuntimeAfterLinkFacebookInstantGameFunction
- type RuntimeAfterLinkGameCenterFunction
- type RuntimeAfterLinkGoogleFunction
- type RuntimeAfterLinkSteamFunction
- type RuntimeAfterListChannelMessagesFunction
- type RuntimeAfterListFriendsFunction
- type RuntimeAfterListGroupUsersFunction
- type RuntimeAfterListGroupsFunction
- type RuntimeAfterListLeaderboardRecordsAroundOwnerFunction
- type RuntimeAfterListLeaderboardRecordsFunction
- type RuntimeAfterListMatchesFunction
- type RuntimeAfterListNotificationsFunction
- type RuntimeAfterListStorageObjectsFunction
- type RuntimeAfterListTournamentRecordsAroundOwnerFunction
- type RuntimeAfterListTournamentRecordsFunction
- type RuntimeAfterListTournamentsFunction
- type RuntimeAfterListUserGroupsFunction
- type RuntimeAfterPromoteGroupUsersFunction
- type RuntimeAfterReadStorageObjectsFunction
- type RuntimeAfterReqFunctions
- type RuntimeAfterRtFunction
- type RuntimeAfterSessionLogoutFunction
- type RuntimeAfterSessionRefreshFunction
- type RuntimeAfterUnlinkAppleFunction
- type RuntimeAfterUnlinkCustomFunction
- type RuntimeAfterUnlinkDeviceFunction
- type RuntimeAfterUnlinkEmailFunction
- type RuntimeAfterUnlinkFacebookFunction
- type RuntimeAfterUnlinkFacebookInstantGameFunction
- type RuntimeAfterUnlinkGameCenterFunction
- type RuntimeAfterUnlinkGoogleFunction
- type RuntimeAfterUnlinkSteamFunction
- type RuntimeAfterUpdateAccountFunction
- type RuntimeAfterUpdateGroupFunction
- type RuntimeAfterValidatePurchaseAppleFunction
- type RuntimeAfterValidatePurchaseGoogleFunction
- type RuntimeAfterValidatePurchaseHuaweiFunction
- type RuntimeAfterWriteLeaderboardRecordFunction
- type RuntimeAfterWriteStorageObjectsFunction
- type RuntimeAfterWriteTournamentRecordFunction
- type RuntimeBeforeAddFriendsFunction
- type RuntimeBeforeAddGroupUsersFunction
- type RuntimeBeforeAuthenticateAppleFunction
- type RuntimeBeforeAuthenticateCustomFunction
- type RuntimeBeforeAuthenticateDeviceFunction
- type RuntimeBeforeAuthenticateEmailFunction
- type RuntimeBeforeAuthenticateFacebookFunction
- type RuntimeBeforeAuthenticateFacebookInstantGameFunction
- type RuntimeBeforeAuthenticateGameCenterFunction
- type RuntimeBeforeAuthenticateGoogleFunction
- type RuntimeBeforeAuthenticateSteamFunction
- type RuntimeBeforeBanGroupUsersFunction
- type RuntimeBeforeBlockFriendsFunction
- type RuntimeBeforeCreateGroupFunction
- type RuntimeBeforeDeleteFriendsFunction
- type RuntimeBeforeDeleteGroupFunction
- type RuntimeBeforeDeleteLeaderboardRecordFunction
- type RuntimeBeforeDeleteNotificationFunction
- type RuntimeBeforeDeleteStorageObjectsFunction
- type RuntimeBeforeDemoteGroupUsersFunction
- type RuntimeBeforeEventFunction
- type RuntimeBeforeGetAccountFunction
- type RuntimeBeforeGetUsersFunction
- type RuntimeBeforeImportFacebookFriendsFunction
- type RuntimeBeforeImportSteamFriendsFunction
- type RuntimeBeforeJoinGroupFunction
- type RuntimeBeforeJoinTournamentFunction
- type RuntimeBeforeKickGroupUsersFunction
- type RuntimeBeforeLeaveGroupFunction
- type RuntimeBeforeLinkAppleFunction
- type RuntimeBeforeLinkCustomFunction
- type RuntimeBeforeLinkDeviceFunction
- type RuntimeBeforeLinkEmailFunction
- type RuntimeBeforeLinkFacebookFunction
- type RuntimeBeforeLinkFacebookInstantGameFunction
- type RuntimeBeforeLinkGameCenterFunction
- type RuntimeBeforeLinkGoogleFunction
- type RuntimeBeforeLinkSteamFunction
- type RuntimeBeforeListChannelMessagesFunction
- type RuntimeBeforeListFriendsFunction
- type RuntimeBeforeListGroupUsersFunction
- type RuntimeBeforeListGroupsFunction
- type RuntimeBeforeListLeaderboardRecordsAroundOwnerFunction
- type RuntimeBeforeListLeaderboardRecordsFunction
- type RuntimeBeforeListMatchesFunction
- type RuntimeBeforeListNotificationsFunction
- type RuntimeBeforeListStorageObjectsFunction
- type RuntimeBeforeListTournamentRecordsAroundOwnerFunction
- type RuntimeBeforeListTournamentRecordsFunction
- type RuntimeBeforeListTournamentsFunction
- type RuntimeBeforeListUserGroupsFunction
- type RuntimeBeforePromoteGroupUsersFunction
- type RuntimeBeforeReadStorageObjectsFunction
- type RuntimeBeforeReqFunctions
- type RuntimeBeforeRtFunction
- type RuntimeBeforeSessionLogoutFunction
- type RuntimeBeforeSessionRefreshFunction
- type RuntimeBeforeUnlinkAppleFunction
- type RuntimeBeforeUnlinkCustomFunction
- type RuntimeBeforeUnlinkDeviceFunction
- type RuntimeBeforeUnlinkEmailFunction
- type RuntimeBeforeUnlinkFacebookFunction
- type RuntimeBeforeUnlinkFacebookInstantGameFunction
- type RuntimeBeforeUnlinkGameCenterFunction
- type RuntimeBeforeUnlinkGoogleFunction
- type RuntimeBeforeUnlinkSteamFunction
- type RuntimeBeforeUpdateAccountFunction
- type RuntimeBeforeUpdateGroupFunction
- type RuntimeBeforeValidatePurchaseAppleFunction
- type RuntimeBeforeValidatePurchaseGoogleFunction
- type RuntimeBeforeValidatePurchaseHuaweiFunction
- type RuntimeBeforeWriteLeaderboardRecordFunction
- type RuntimeBeforeWriteStorageObjectsFunction
- type RuntimeBeforeWriteTournamentRecordFunction
- type RuntimeConfig
- type RuntimeEventCustomFunction
- type RuntimeEventFunction
- type RuntimeEventFunctions
- type RuntimeEventQueue
- type RuntimeEventSessionEndFunction
- type RuntimeEventSessionStartFunction
- type RuntimeExecutionMode
- type RuntimeGoInitializer
- func (ri *RuntimeGoInitializer) RegisterAfterAddFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterAddGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateApple(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateCustom(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateDevice(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateEmail(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateFacebook(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateFacebookInstantGame(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateGameCenter(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateGoogle(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateSteam(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterBanGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterBlockFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterCreateGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterDeleteFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterDeleteGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterDeleteLeaderboardRecord(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterDeleteNotification(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterDeleteStorageObjects(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterDemoteGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterEvent(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterGetAccount(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterGetUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterImportFacebookFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterImportSteamFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterJoinGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterJoinTournament(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterKickGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterLeaveGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterLinkApple(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterLinkCustom(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterLinkDevice(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterLinkEmail(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterLinkFacebook(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterLinkFacebookInstantGame(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterLinkGameCenter(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterLinkGoogle(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterLinkSteam(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListChannelMessages(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListGroups(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListLeaderboardRecords(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListLeaderboardRecordsAroundOwner(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListMatches(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListNotifications(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListStorageObjects(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListTournamentRecords(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListTournamentRecordsAroundOwner(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListTournaments(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterListUserGroups(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterPromoteGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterReadStorageObjects(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterRt(id string, ...) error
- func (ri *RuntimeGoInitializer) RegisterAfterSessionLogout(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterSessionRefresh(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterUnlinkApple(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterUnlinkCustom(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterUnlinkDevice(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterUnlinkEmail(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterUnlinkFacebook(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterUnlinkFacebookInstantGame(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterUnlinkGameCenter(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterUnlinkGoogle(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterUnlinkSteam(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterUpdateAccount(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterUpdateGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterValidatePurchaseApple(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterValidatePurchaseGoogle(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterValidatePurchaseHuawei(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterWriteLeaderboardRecord(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterWriteStorageObjects(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterAfterWriteTournamentRecord(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterBeforeAddFriends(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeAddGroupUsers(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateApple(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateCustom(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateDevice(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateEmail(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateFacebook(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateFacebookInstantGame(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateGameCenter(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateGoogle(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateSteam(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeBanGroupUsers(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeBlockFriends(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeCreateGroup(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeDeleteFriends(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeDeleteGroup(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeDeleteLeaderboardRecord(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeDeleteNotification(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeDeleteStorageObjects(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeDemoteGroupUsers(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeEvent(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeGetAccount(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterBeforeGetUsers(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeImportFacebookFriends(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeImportSteamFriends(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeJoinGroup(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeJoinTournament(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeKickGroupUsers(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeLeaveGroup(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeLinkApple(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeLinkCustom(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeLinkDevice(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeLinkEmail(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeLinkFacebook(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeLinkFacebookInstantGame(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeLinkGameCenter(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeLinkGoogle(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeLinkSteam(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListChannelMessages(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListFriends(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListGroupUsers(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListGroups(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListLeaderboardRecords(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListLeaderboardRecordsAroundOwner(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListMatches(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListNotifications(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListStorageObjects(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListTournamentRecords(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListTournamentRecordsAroundOwner(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListTournaments(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeListUserGroups(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforePromoteGroupUsers(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeReadStorageObjects(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeRt(id string, ...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeSessionLogout(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeSessionRefresh(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkApple(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkCustom(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkDevice(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkEmail(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkFacebook(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkFacebookInstantGame(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkGameCenter(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkGoogle(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkSteam(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeUpdateAccount(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeUpdateGroup(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeValidatePurchaseApple(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeValidatePurchaseGoogle(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeValidatePurchaseHuawei(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeWriteLeaderboardRecord(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeWriteStorageObjects(...) error
- func (ri *RuntimeGoInitializer) RegisterBeforeWriteTournamentRecord(...) error
- func (ri *RuntimeGoInitializer) RegisterEvent(fn func(ctx context.Context, logger runtime.Logger, evt *api.Event)) error
- func (ri *RuntimeGoInitializer) RegisterEventSessionEnd(fn func(ctx context.Context, logger runtime.Logger, evt *api.Event)) error
- func (ri *RuntimeGoInitializer) RegisterEventSessionStart(fn func(ctx context.Context, logger runtime.Logger, evt *api.Event)) error
- func (ri *RuntimeGoInitializer) RegisterLeaderboardReset(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterMatch(name string, ...) error
- func (ri *RuntimeGoInitializer) RegisterMatchmakerMatched(...) error
- func (ri *RuntimeGoInitializer) RegisterRpc(id string, ...) error
- func (ri *RuntimeGoInitializer) RegisterTournamentEnd(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- func (ri *RuntimeGoInitializer) RegisterTournamentReset(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, ...) error) error
- type RuntimeGoLogger
- func (l *RuntimeGoLogger) Debug(format string, v ...interface{})
- func (l *RuntimeGoLogger) Error(format string, v ...interface{})
- func (l *RuntimeGoLogger) Fields() map[string]interface{}
- func (l *RuntimeGoLogger) Info(format string, v ...interface{})
- func (l *RuntimeGoLogger) Warn(format string, v ...interface{})
- func (l *RuntimeGoLogger) WithField(key string, v interface{}) nkruntime.Logger
- func (l *RuntimeGoLogger) WithFields(fields map[string]interface{}) nkruntime.Logger
- type RuntimeGoMatchCore
- func (r *RuntimeGoMatchCore) BroadcastMessage(opCode int64, data []byte, presences []runtime.Presence, ...) error
- func (r *RuntimeGoMatchCore) BroadcastMessageDeferred(opCode int64, data []byte, presences []runtime.Presence, ...) error
- func (r *RuntimeGoMatchCore) Cancel()
- func (r *RuntimeGoMatchCore) Cleanup()
- func (r *RuntimeGoMatchCore) CreateTime() int64
- func (r *RuntimeGoMatchCore) GetState(state interface{}) (string, error)
- func (r *RuntimeGoMatchCore) HandlerName() string
- func (r *RuntimeGoMatchCore) Label() string
- func (r *RuntimeGoMatchCore) MatchInit(presenceList *MatchPresenceList, ...) (interface{}, int, error)
- func (r *RuntimeGoMatchCore) MatchJoin(tick int64, state interface{}, joins []*MatchPresence) (interface{}, error)
- func (r *RuntimeGoMatchCore) MatchJoinAttempt(tick int64, state interface{}, userID, sessionID uuid.UUID, username string, ...) (interface{}, bool, string, error)
- func (r *RuntimeGoMatchCore) MatchKick(presences []runtime.Presence) error
- func (r *RuntimeGoMatchCore) MatchLabelUpdate(label string) error
- func (r *RuntimeGoMatchCore) MatchLeave(tick int64, state interface{}, leaves []*MatchPresence) (interface{}, error)
- func (r *RuntimeGoMatchCore) MatchLoop(tick int64, state interface{}, inputCh <-chan *MatchDataMessage) (interface{}, error)
- func (r *RuntimeGoMatchCore) MatchSignal(tick int64, state interface{}, data string) (interface{}, string, error)
- func (r *RuntimeGoMatchCore) MatchTerminate(tick int64, state interface{}, graceSeconds int) (interface{}, error)
- func (r *RuntimeGoMatchCore) TickRate() int
- type RuntimeGoNakamaModule
- func (n *RuntimeGoNakamaModule) AccountDeleteId(ctx context.Context, userID string, recorded bool) error
- func (n *RuntimeGoNakamaModule) AccountExportId(ctx context.Context, userID string) (string, error)
- func (n *RuntimeGoNakamaModule) AccountGetId(ctx context.Context, userID string) (*api.Account, error)
- func (n *RuntimeGoNakamaModule) AccountUpdateId(ctx context.Context, userID, username string, metadata map[string]interface{}, ...) error
- func (n *RuntimeGoNakamaModule) AccountsGetId(ctx context.Context, userIDs []string) ([]*api.Account, error)
- func (n *RuntimeGoNakamaModule) AuthenticateApple(ctx context.Context, token, username string, create bool) (string, string, bool, error)
- func (n *RuntimeGoNakamaModule) AuthenticateCustom(ctx context.Context, id, username string, create bool) (string, string, bool, error)
- func (n *RuntimeGoNakamaModule) AuthenticateDevice(ctx context.Context, id, username string, create bool) (string, string, bool, error)
- func (n *RuntimeGoNakamaModule) AuthenticateEmail(ctx context.Context, email, password, username string, create bool) (string, string, bool, error)
- func (n *RuntimeGoNakamaModule) AuthenticateFacebook(ctx context.Context, token string, importFriends bool, username string, ...) (string, string, bool, error)
- func (n *RuntimeGoNakamaModule) AuthenticateFacebookInstantGame(ctx context.Context, signedPlayerInfo string, username string, create bool) (string, string, bool, error)
- func (n *RuntimeGoNakamaModule) AuthenticateGameCenter(ctx context.Context, playerID, bundleID string, timestamp int64, ...) (string, string, bool, error)
- func (n *RuntimeGoNakamaModule) AuthenticateGoogle(ctx context.Context, token, username string, create bool) (string, string, bool, error)
- func (n *RuntimeGoNakamaModule) AuthenticateSteam(ctx context.Context, token, username string, create bool) (string, string, bool, error)
- func (n *RuntimeGoNakamaModule) AuthenticateTokenGenerate(userID, username string, exp int64, vars map[string]string) (string, int64, error)
- func (n *RuntimeGoNakamaModule) ChannelIdBuild(ctx context.Context, target string, chanType runtime.ChannelType) (string, error)
- func (n *RuntimeGoNakamaModule) ChannelMessageSend(ctx context.Context, channelId string, content map[string]interface{}, ...) (*rtapi.ChannelMessageAck, error)
- func (n *RuntimeGoNakamaModule) ChannelMessageUpdate(ctx context.Context, channelId, messageId string, ...) (*rtapi.ChannelMessageAck, error)
- func (n *RuntimeGoNakamaModule) Event(ctx context.Context, evt *api.Event) error
- func (n *RuntimeGoNakamaModule) FriendsList(ctx context.Context, userID string, limit int, state *int, cursor string) ([]*api.Friend, string, error)
- func (n *RuntimeGoNakamaModule) GroupCreate(ctx context.Context, ...) (*api.Group, error)
- func (n *RuntimeGoNakamaModule) GroupDelete(ctx context.Context, id string) error
- func (n *RuntimeGoNakamaModule) GroupUpdate(ctx context.Context, ...) error
- func (n *RuntimeGoNakamaModule) GroupUserJoin(ctx context.Context, groupID, userID, username string) error
- func (n *RuntimeGoNakamaModule) GroupUserLeave(ctx context.Context, groupID, userID, username string) error
- func (n *RuntimeGoNakamaModule) GroupUsersAdd(ctx context.Context, callerID, groupID string, userIDs []string) error
- func (n *RuntimeGoNakamaModule) GroupUsersDemote(ctx context.Context, callerID, groupID string, userIDs []string) error
- func (n *RuntimeGoNakamaModule) GroupUsersKick(ctx context.Context, callerID, groupID string, userIDs []string) error
- func (n *RuntimeGoNakamaModule) GroupUsersList(ctx context.Context, id string, limit int, state *int, cursor string) ([]*api.GroupUserList_GroupUser, string, error)
- func (n *RuntimeGoNakamaModule) GroupUsersPromote(ctx context.Context, callerID, groupID string, userIDs []string) error
- func (n *RuntimeGoNakamaModule) GroupsGetId(ctx context.Context, groupIDs []string) ([]*api.Group, error)
- func (n *RuntimeGoNakamaModule) GroupsList(ctx context.Context, name, langTag string, members *int, open *bool, limit int, ...) ([]*api.Group, string, error)
- func (n *RuntimeGoNakamaModule) LeaderboardCreate(ctx context.Context, id string, authoritative bool, ...) error
- func (n *RuntimeGoNakamaModule) LeaderboardDelete(ctx context.Context, id string) error
- func (n *RuntimeGoNakamaModule) LeaderboardList(categoryStart, categoryEnd, limit int, cursor string) (*api.LeaderboardList, error)
- func (n *RuntimeGoNakamaModule) LeaderboardRecordDelete(ctx context.Context, id, ownerID string) error
- func (n *RuntimeGoNakamaModule) LeaderboardRecordWrite(ctx context.Context, id, ownerID, username string, score, subscore int64, ...) (*api.LeaderboardRecord, error)
- func (n *RuntimeGoNakamaModule) LeaderboardRecordsList(ctx context.Context, id string, ownerIDs []string, limit int, cursor string, ...) ([]*api.LeaderboardRecord, []*api.LeaderboardRecord, string, string, error)
- func (n *RuntimeGoNakamaModule) LeaderboardsGetId(ctx context.Context, IDs []string) ([]*api.Leaderboard, error)
- func (n *RuntimeGoNakamaModule) LinkApple(ctx context.Context, userID, token string) error
- func (n *RuntimeGoNakamaModule) LinkCustom(ctx context.Context, userID, customID string) error
- func (n *RuntimeGoNakamaModule) LinkDevice(ctx context.Context, userID, deviceID string) error
- func (n *RuntimeGoNakamaModule) LinkEmail(ctx context.Context, userID, email, password string) error
- func (n *RuntimeGoNakamaModule) LinkFacebook(ctx context.Context, userID, username, token string, importFriends bool) error
- func (n *RuntimeGoNakamaModule) LinkFacebookInstantGame(ctx context.Context, userID, signedPlayerInfo string) error
- func (n *RuntimeGoNakamaModule) LinkGameCenter(ctx context.Context, userID, playerID, bundleID string, timestamp int64, ...) error
- func (n *RuntimeGoNakamaModule) LinkGoogle(ctx context.Context, userID, token string) error
- func (n *RuntimeGoNakamaModule) LinkSteam(ctx context.Context, userID, username, token string, importFriends bool) error
- func (n *RuntimeGoNakamaModule) MatchCreate(ctx context.Context, module string, params map[string]interface{}) (string, error)
- func (n *RuntimeGoNakamaModule) MatchGet(ctx context.Context, id string) (*api.Match, error)
- func (n *RuntimeGoNakamaModule) MatchList(ctx context.Context, limit int, authoritative bool, label string, ...) ([]*api.Match, error)
- func (n *RuntimeGoNakamaModule) MatchSignal(ctx context.Context, id string, data string) (string, error)
- func (n *RuntimeGoNakamaModule) MetricsCounterAdd(name string, tags map[string]string, delta int64)
- func (n *RuntimeGoNakamaModule) MetricsGaugeSet(name string, tags map[string]string, value float64)
- func (n *RuntimeGoNakamaModule) MetricsTimerRecord(name string, tags map[string]string, value time.Duration)
- func (n *RuntimeGoNakamaModule) MultiUpdate(ctx context.Context, accountUpdates []*runtime.AccountUpdate, ...) ([]*api.StorageObjectAck, []*runtime.WalletUpdateResult, error)
- func (n *RuntimeGoNakamaModule) NotificationSend(ctx context.Context, userID, subject string, content map[string]interface{}, ...) error
- func (n *RuntimeGoNakamaModule) NotificationsSend(ctx context.Context, notifications []*runtime.NotificationSend) error
- func (n *RuntimeGoNakamaModule) PurchaseGetByTransactionId(ctx context.Context, transactionID string) (string, *api.ValidatedPurchase, error)
- func (n *RuntimeGoNakamaModule) PurchaseValidateApple(ctx context.Context, userID, receipt string, passwordOverride ...string) (*api.ValidatePurchaseResponse, error)
- func (n *RuntimeGoNakamaModule) PurchaseValidateGoogle(ctx context.Context, userID, receipt string) (*api.ValidatePurchaseResponse, error)
- func (n *RuntimeGoNakamaModule) PurchaseValidateHuawei(ctx context.Context, userID, signature, inAppPurchaseData string) (*api.ValidatePurchaseResponse, error)
- func (n *RuntimeGoNakamaModule) PurchasesList(ctx context.Context, userID string, limit int, cursor string) (*api.PurchaseList, error)
- func (n *RuntimeGoNakamaModule) ReadFile(relPath string) (*os.File, error)
- func (n *RuntimeGoNakamaModule) SessionDisconnect(ctx context.Context, sessionID string, reason ...runtime.PresenceReason) error
- func (n *RuntimeGoNakamaModule) SessionLogout(userID, token, refreshToken string) error
- func (n *RuntimeGoNakamaModule) SetEventFn(fn RuntimeEventCustomFunction)
- func (n *RuntimeGoNakamaModule) StorageDelete(ctx context.Context, deletes []*runtime.StorageDelete) error
- func (n *RuntimeGoNakamaModule) StorageList(ctx context.Context, userID, collection string, limit int, cursor string) ([]*api.StorageObject, string, error)
- func (n *RuntimeGoNakamaModule) StorageRead(ctx context.Context, reads []*runtime.StorageRead) ([]*api.StorageObject, error)
- func (n *RuntimeGoNakamaModule) StorageWrite(ctx context.Context, writes []*runtime.StorageWrite) ([]*api.StorageObjectAck, error)
- func (n *RuntimeGoNakamaModule) StreamClose(mode uint8, subject, subcontext, label string) error
- func (n *RuntimeGoNakamaModule) StreamCount(mode uint8, subject, subcontext, label string) (int, error)
- func (n *RuntimeGoNakamaModule) StreamSend(mode uint8, subject, subcontext, label, data string, ...) error
- func (n *RuntimeGoNakamaModule) StreamSendRaw(mode uint8, subject, subcontext, label string, msg *rtapi.Envelope, ...) error
- func (n *RuntimeGoNakamaModule) StreamUserGet(mode uint8, subject, subcontext, label, userID, sessionID string) (runtime.PresenceMeta, error)
- func (n *RuntimeGoNakamaModule) StreamUserJoin(mode uint8, subject, subcontext, label, userID, sessionID string, ...) (bool, error)
- func (n *RuntimeGoNakamaModule) StreamUserKick(mode uint8, subject, subcontext, label string, presence runtime.Presence) error
- func (n *RuntimeGoNakamaModule) StreamUserLeave(mode uint8, subject, subcontext, label, userID, sessionID string) error
- func (n *RuntimeGoNakamaModule) StreamUserList(mode uint8, subject, subcontext, label string, ...) ([]runtime.Presence, error)
- func (n *RuntimeGoNakamaModule) StreamUserUpdate(mode uint8, subject, subcontext, label, userID, sessionID string, ...) error
- func (n *RuntimeGoNakamaModule) TournamentAddAttempt(ctx context.Context, id, ownerID string, count int) error
- func (n *RuntimeGoNakamaModule) TournamentCreate(ctx context.Context, id string, authoritative bool, ...) error
- func (n *RuntimeGoNakamaModule) TournamentDelete(ctx context.Context, id string) error
- func (n *RuntimeGoNakamaModule) TournamentJoin(ctx context.Context, id, ownerID, username string) error
- func (n *RuntimeGoNakamaModule) TournamentList(ctx context.Context, categoryStart, categoryEnd, startTime, endTime, limit int, ...) (*api.TournamentList, error)
- func (n *RuntimeGoNakamaModule) TournamentRecordWrite(ctx context.Context, id, ownerID, username string, score, subscore int64, ...) (*api.LeaderboardRecord, error)
- func (n *RuntimeGoNakamaModule) TournamentRecordsHaystack(ctx context.Context, id, ownerID string, limit int, expiry int64) ([]*api.LeaderboardRecord, error)
- func (n *RuntimeGoNakamaModule) TournamentRecordsList(ctx context.Context, tournamentId string, ownerIDs []string, limit int, ...) ([]*api.LeaderboardRecord, []*api.LeaderboardRecord, string, string, error)
- func (n *RuntimeGoNakamaModule) TournamentsGetId(ctx context.Context, tournamentIDs []string) ([]*api.Tournament, error)
- func (n *RuntimeGoNakamaModule) UnlinkApple(ctx context.Context, userID, token string) error
- func (n *RuntimeGoNakamaModule) UnlinkCustom(ctx context.Context, userID, customID string) error
- func (n *RuntimeGoNakamaModule) UnlinkDevice(ctx context.Context, userID, deviceID string) error
- func (n *RuntimeGoNakamaModule) UnlinkEmail(ctx context.Context, userID, email string) error
- func (n *RuntimeGoNakamaModule) UnlinkFacebook(ctx context.Context, userID, token string) error
- func (n *RuntimeGoNakamaModule) UnlinkFacebookInstantGame(ctx context.Context, userID, signedPlayerInfo string) error
- func (n *RuntimeGoNakamaModule) UnlinkGameCenter(ctx context.Context, userID, playerID, bundleID string, timestamp int64, ...) error
- func (n *RuntimeGoNakamaModule) UnlinkGoogle(ctx context.Context, userID, token string) error
- func (n *RuntimeGoNakamaModule) UnlinkSteam(ctx context.Context, userID, token string) error
- func (n *RuntimeGoNakamaModule) UserGroupsList(ctx context.Context, userID string, limit int, state *int, cursor string) ([]*api.UserGroupList_UserGroup, string, error)
- func (n *RuntimeGoNakamaModule) UsersBanId(ctx context.Context, userIDs []string) error
- func (n *RuntimeGoNakamaModule) UsersGetId(ctx context.Context, userIDs []string, facebookIDs []string) ([]*api.User, error)
- func (n *RuntimeGoNakamaModule) UsersGetRandom(ctx context.Context, count int) ([]*api.User, error)
- func (n *RuntimeGoNakamaModule) UsersGetUsername(ctx context.Context, usernames []string) ([]*api.User, error)
- func (n *RuntimeGoNakamaModule) UsersUnbanId(ctx context.Context, userIDs []string) error
- func (n *RuntimeGoNakamaModule) WalletLedgerList(ctx context.Context, userID string, limit int, cursor string) ([]runtime.WalletLedgerItem, string, error)
- func (n *RuntimeGoNakamaModule) WalletLedgerUpdate(ctx context.Context, itemID string, metadata map[string]interface{}) (runtime.WalletLedgerItem, error)
- func (n *RuntimeGoNakamaModule) WalletUpdate(ctx context.Context, userID string, changeset map[string]int64, ...) (map[string]int64, map[string]int64, error)
- func (n *RuntimeGoNakamaModule) WalletsUpdate(ctx context.Context, updates []*runtime.WalletUpdate, updateLedger bool) ([]*runtime.WalletUpdateResult, error)
- type RuntimeInfo
- type RuntimeJS
- type RuntimeJSModule
- type RuntimeJSModuleCache
- type RuntimeJavaScriptMatchCore
- func (rm *RuntimeJavaScriptMatchCore) Cancel()
- func (rm *RuntimeJavaScriptMatchCore) Cleanup()
- func (rm *RuntimeJavaScriptMatchCore) CreateTime() int64
- func (rm *RuntimeJavaScriptMatchCore) GetState(state interface{}) (string, error)
- func (rm *RuntimeJavaScriptMatchCore) HandlerName() string
- func (rm *RuntimeJavaScriptMatchCore) Label() string
- func (rm *RuntimeJavaScriptMatchCore) MatchInit(presenceList *MatchPresenceList, ...) (interface{}, int, error)
- func (rm *RuntimeJavaScriptMatchCore) MatchJoin(tick int64, state interface{}, joins []*MatchPresence) (interface{}, error)
- func (rm *RuntimeJavaScriptMatchCore) MatchJoinAttempt(tick int64, state interface{}, userID, sessionID uuid.UUID, username string, ...) (interface{}, bool, string, error)
- func (rm *RuntimeJavaScriptMatchCore) MatchLeave(tick int64, state interface{}, leaves []*MatchPresence) (interface{}, error)
- func (rm *RuntimeJavaScriptMatchCore) MatchLoop(tick int64, state interface{}, inputCh <-chan *MatchDataMessage) (interface{}, error)
- func (rm *RuntimeJavaScriptMatchCore) MatchSignal(tick int64, state interface{}, data string) (interface{}, string, error)
- func (rm *RuntimeJavaScriptMatchCore) MatchTerminate(tick int64, state interface{}, graceSeconds int) (interface{}, error)
- func (rm *RuntimeJavaScriptMatchCore) TickRate() int
- type RuntimeJavascriptCallbacks
- type RuntimeJavascriptInitModule
- type RuntimeJavascriptLocalCache
- type RuntimeJavascriptMatchHandlers
- type RuntimeLeaderboardResetFunction
- type RuntimeLua
- type RuntimeLuaCallbacks
- type RuntimeLuaLocalCache
- type RuntimeLuaMatchCore
- func (r *RuntimeLuaMatchCore) Cancel()
- func (r *RuntimeLuaMatchCore) Cleanup()
- func (r *RuntimeLuaMatchCore) CreateTime() int64
- func (r *RuntimeLuaMatchCore) GetState(state interface{}) (string, error)
- func (r *RuntimeLuaMatchCore) HandlerName() string
- func (r *RuntimeLuaMatchCore) Label() string
- func (r *RuntimeLuaMatchCore) MatchInit(presenceList *MatchPresenceList, ...) (interface{}, int, error)
- func (r *RuntimeLuaMatchCore) MatchJoin(tick int64, state interface{}, joins []*MatchPresence) (interface{}, error)
- func (r *RuntimeLuaMatchCore) MatchJoinAttempt(tick int64, state interface{}, userID, sessionID uuid.UUID, username string, ...) (interface{}, bool, string, error)
- func (r *RuntimeLuaMatchCore) MatchLeave(tick int64, state interface{}, leaves []*MatchPresence) (interface{}, error)
- func (r *RuntimeLuaMatchCore) MatchLoop(tick int64, state interface{}, inputCh <-chan *MatchDataMessage) (interface{}, error)
- func (r *RuntimeLuaMatchCore) MatchSignal(tick int64, state interface{}, data string) (interface{}, string, error)
- func (r *RuntimeLuaMatchCore) MatchTerminate(tick int64, state interface{}, graceSeconds int) (interface{}, error)
- func (r *RuntimeLuaMatchCore) TickRate() int
- type RuntimeLuaModule
- type RuntimeLuaModuleCache
- type RuntimeLuaNakamaModule
- type RuntimeMatchCore
- func NewRuntimeGoMatchCore(logger *zap.Logger, module string, matchRegistry MatchRegistry, ...) (RuntimeMatchCore, error)
- func NewRuntimeJavascriptMatchCore(logger *zap.Logger, module string, db *sql.DB, ...) (RuntimeMatchCore, error)
- func NewRuntimeLuaMatchCore(logger *zap.Logger, module string, db *sql.DB, ...) (RuntimeMatchCore, error)
- type RuntimeMatchCreateFunction
- type RuntimeMatchDeferMessageFunction
- type RuntimeMatchmakerMatchedFunction
- type RuntimeProviderJS
- func (rp *RuntimeProviderJS) AfterReq(ctx context.Context, id string, logger *zap.Logger, userID, username string, ...) error
- func (rp *RuntimeProviderJS) AfterRt(ctx context.Context, id string, logger *zap.Logger, userID, username string, ...) error
- func (rp *RuntimeProviderJS) BeforeReq(ctx context.Context, id string, logger *zap.Logger, userID, username string, ...) (interface{}, error, codes.Code)
- func (rp *RuntimeProviderJS) BeforeRt(ctx context.Context, id string, logger *zap.Logger, userID, username string, ...) (*rtapi.Envelope, error)
- func (rp *RuntimeProviderJS) Get(ctx context.Context) (*RuntimeJS, error)
- func (rp *RuntimeProviderJS) LeaderboardReset(ctx context.Context, leaderboard *api.Leaderboard, reset int64) error
- func (rp *RuntimeProviderJS) MatchmakerMatched(ctx context.Context, entries []*MatchmakerEntry) (string, bool, error)
- func (rp *RuntimeProviderJS) Put(r *RuntimeJS)
- func (rp *RuntimeProviderJS) Rpc(ctx context.Context, id string, headers, queryParams map[string][]string, ...) (string, error, codes.Code)
- func (rp *RuntimeProviderJS) TournamentEnd(ctx context.Context, tournament *api.Tournament, end, reset int64) error
- func (rp *RuntimeProviderJS) TournamentReset(ctx context.Context, tournament *api.Tournament, end, reset int64) error
- type RuntimeProviderLua
- func (rp *RuntimeProviderLua) AfterReq(ctx context.Context, id string, logger *zap.Logger, userID, username string, ...) error
- func (rp *RuntimeProviderLua) AfterRt(ctx context.Context, id string, logger *zap.Logger, userID, username string, ...) error
- func (rp *RuntimeProviderLua) BeforeReq(ctx context.Context, id string, logger *zap.Logger, userID, username string, ...) (interface{}, error, codes.Code)
- func (rp *RuntimeProviderLua) BeforeRt(ctx context.Context, id string, logger *zap.Logger, userID, username string, ...) (*rtapi.Envelope, error)
- func (rp *RuntimeProviderLua) Get(ctx context.Context) (*RuntimeLua, error)
- func (rp *RuntimeProviderLua) LeaderboardReset(ctx context.Context, leaderboard *api.Leaderboard, reset int64) error
- func (rp *RuntimeProviderLua) MatchmakerMatched(ctx context.Context, entries []*MatchmakerEntry) (string, bool, error)
- func (rp *RuntimeProviderLua) Put(r *RuntimeLua)
- func (rp *RuntimeProviderLua) Rpc(ctx context.Context, id string, headers, queryParams map[string][]string, ...) (string, error, codes.Code)
- func (rp *RuntimeProviderLua) TournamentEnd(ctx context.Context, tournament *api.Tournament, end, reset int64) error
- func (rp *RuntimeProviderLua) TournamentReset(ctx context.Context, tournament *api.Tournament, end, reset int64) error
- type RuntimeRpcFunction
- type RuntimeTournamentEndFunction
- type RuntimeTournamentResetFunction
- type Scannable
- type Session
- type SessionCache
- type SessionConfig
- type SessionFormat
- type SessionRegistry
- type SessionTokenClaims
- type SocialConfig
- type SocialConfigApple
- type SocialConfigFacebookInstantGame
- type SocialConfigFacebookLimitedLogin
- type SocialConfigSteam
- type SocketConfig
- type StatusHandler
- type StatusRegistry
- func (s *StatusRegistry) Follow(sessionID uuid.UUID, userIDs map[uuid.UUID]struct{})
- func (s *StatusRegistry) Queue(userID uuid.UUID, joins, leaves []*rtapi.UserPresence)
- func (s *StatusRegistry) Stop()
- func (s *StatusRegistry) Unfollow(sessionID uuid.UUID, userIDs []uuid.UUID)
- func (s *StatusRegistry) UnfollowAll(sessionID uuid.UUID)
- type StorageOpDelete
- type StorageOpDeletes
- type StorageOpWrite
- type StorageOpWrites
- type StreamManager
- type TournamentListCursor
- type Tracker
- type TrackerConfig
- type TrackerOp
- type Tx
- type TxnRestartError
- type ValidatableQuery
Constants ¶
const ( NotificationCodeDmRequest int32 = -1 NotificationCodeFriendRequest int32 = -2 NotificationCodeFriendAccept int32 = -3 NotificationCodeGroupAdd int32 = -4 NotificationCodeGroupJoinRequest int32 = -5 NotificationCodeFriendJoinGame int32 = -6 NotificationCodeSingleSocket int32 = -7 )
const ( LeaderboardSortOrderAscending = iota LeaderboardSortOrderDescending )
const ( LeaderboardOperatorBest = iota LeaderboardOperatorSet LeaderboardOperatorIncrement LeaderboardOperatorDecrement )
const ( ChannelMessageTypeChat int32 = iota ChannelMessageTypeChatUpdate ChannelMessageTypeChatRemove ChannelMessageTypeGroupJoin ChannelMessageTypeGroupAdd ChannelMessageTypeGroupLeave ChannelMessageTypeGroupKick ChannelMessageTypeGroupPromote ChannelMessageTypeGroupBan ChannelMessageTypeGroupDemote )
const ( StreamModeNotifications uint8 = iota StreamModeStatus StreamModeChannel StreamModeGroup StreamModeDM StreamModeMatchRelayed StreamModeMatchAuthoritative StreamModeParty )
const API_PREFIX = "/nakama.api.Nakama/"
const INIT_MODULE_FN_NAME = "InitModule"
const JsEntrypointFilename = "index.js"
const LTSentinel = lua.LValueType(-1)
const ObfuscationString = "REDACTED"
const RTAPI_PREFIX = "*rtapi.Envelope_"
Variables ¶
var ( ErrLeaderboardNotFound = errors.New("leaderboard not found") ErrLeaderboardAuthoritative = errors.New("leaderboard only allows authoritative submissions") ErrLeaderboardInvalidCursor = errors.New("leaderboard cursor invalid") ErrInvalidOperator = errors.New("invalid operator") )
var ( ErrSessionTokenInvalid = errors.New("session token invalid") ErrRefreshTokenInvalid = errors.New("refresh token invalid") )
var ( MatchFilterValue = uint8(0) MatchFilterPtr = &MatchFilterValue MatchFilterRelayed = map[uint8]*uint8{StreamModeMatchRelayed: MatchFilterPtr} MatchLabelMaxBytes = 2048 )
var ( Bit32LibName = "bit32" Bit32Default64 = int64(math.Pow(2, 32) - 1) )
var ( ErrNodeNotFound = errors.New("node not found") ErrSessionNotFound = errors.New("session not found") )
var API_PREFIX_LOWERCASE = strings.ToLower(API_PREFIX)
var BlugeKeywordAnalyzer = analyzer.NewKeywordAnalyzer()
var ErrAccountNotFound = errors.New("account not found")
var ErrChannelMessageUpdateNotFound = errors.New("channel message not found")
var ErrDatabaseDriverMismatch = errors.New("database driver mismatch")
var ErrMatchStopped = errors.New("match stopped")
var ErrPartyNotFound = errors.New("party not found")
var ErrPurchasesListInvalidCursor = errors.New("purchases list cursor invalid")
var ErrRowsAffectedCount = errors.New("rows_affected_count")
var (
ErrRuntimeRPCNotFound = errors.New("RPC function not found")
)
var ErrSessionQueueFull = errors.New("session outgoing queue full")
var LSentinel = lua.LValue(&LSentinelType{})
var ( OperatorIntToEnum = map[int]api.Operator{ LeaderboardOperatorBest: api.Operator_BEST, LeaderboardOperatorSet: api.Operator_SET, LeaderboardOperatorIncrement: api.Operator_INCREMENT, LeaderboardOperatorDecrement: api.Operator_DECREMENT, } )
var RTAPI_PREFIX_LOWERCASE = strings.ToLower(RTAPI_PREFIX)
Functions ¶
func AddFriends ¶
func AddGroupUsers ¶
func AuthenticateApple ¶
func AuthenticateCustom ¶
func AuthenticateDevice ¶
func AuthenticateEmail ¶
func AuthenticateFacebook ¶
func AuthenticateGameCenter ¶
func AuthenticateGoogle ¶
func AuthenticateSteam ¶
func AuthenticateUsername ¶
func BanGroupUsers ¶
func BlockFriends ¶
func BlugeInMemoryConfig ¶ added in v3.10.0
func BlugeWalkDocument ¶ added in v3.9.0
func ChannelMessageSend ¶ added in v3.5.0
func ChannelMessageSend(ctx context.Context, logger *zap.Logger, db *sql.DB, router MessageRouter, channelStream PresenceStream, channelId, content, senderId, senderUsername string, persist bool) (*rtapi.ChannelMessageAck, error)
func ChannelMessageUpdate ¶ added in v3.6.0
func ChannelMessageUpdate(ctx context.Context, logger *zap.Logger, db *sql.DB, router MessageRouter, channelStream PresenceStream, channelId, messageId, content, senderId, senderUsername string, persist bool) (*rtapi.ChannelMessageAck, error)
func ChannelMessagesList ¶
func CheckRuntimeProviderGo ¶
func CheckRuntimeProviderLua ¶
func CreateGroup ¶
func DeleteAccount ¶
func DeleteFriends ¶
func DeleteGroup ¶
func DemoteGroupUsers ¶
func ExecuteInTx ¶
ExecuteInTx runs fn inside tx which should already have begun. *WARNING*: Do not execute any statements on the supplied tx before calling this function. ExecuteInTx will only retry statements that are performed within the supplied closure (fn). Any statements performed on the tx before ExecuteInTx is invoked will *not* be re-run if the transaction needs to be retried.
fn is subject to the same restrictions as the fn passed to ExecuteTx.
func ExecuteRetryable ¶
ExecuteRetryable Retry functions that perform non-transactional database operations.
func ExportAccount ¶
func GetAccount ¶
func GetAccounts ¶
func GetChannelMessages ¶
func GetFriendIDs ¶
func GetFriendIDs(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID) (*api.FriendList, error)
Only used to get all friend IDs for the console. NOTE: Not intended for use in client/runtime APIs.
func GetPurchaseByTransactionID ¶ added in v3.2.0
func GetRandomUsers ¶ added in v3.5.0
func GroupDeleteAll ¶
func HashFromId ¶
func KickGroupUsers ¶
func LeaderboardList ¶ added in v3.4.0
func LeaderboardList(logger *zap.Logger, leaderboardCache LeaderboardCache, categoryStart, categoryEnd, limit int, cursor *LeaderboardListCursor) (*api.LeaderboardList, error)
func LeaderboardRecordDelete ¶
func LeaderboardRecordWrite ¶
func LeaderboardRecordWrite(ctx context.Context, logger *zap.Logger, db *sql.DB, leaderboardCache LeaderboardCache, rankCache LeaderboardRankCache, caller uuid.UUID, leaderboardId, ownerID, username string, score, subscore int64, metadata string, overrideOperator api.Operator) (*api.LeaderboardRecord, error)
func LeaderboardRecordsList ¶
func LeaderboardRecordsList(ctx context.Context, logger *zap.Logger, db *sql.DB, leaderboardCache LeaderboardCache, rankCache LeaderboardRankCache, leaderboardId string, limit *wrapperspb.Int32Value, cursor string, ownerIds []string, overrideExpiry int64) (*api.LeaderboardRecordList, error)
func LeaderboardsGet ¶ added in v3.4.0
func LeaderboardsGet(leaderboardCache LeaderboardCache, leaderboardIDs []string) []*api.Leaderboard
func LeaveGroup ¶
func LinkCustom ¶
func LinkDevice ¶
func LinkFacebook ¶
func LinkFacebookInstantGame ¶
func LinkGameCenter ¶
func LinkGoogle ¶
func ListFriends ¶
func ListGroupUsers ¶
func ListGroups ¶
func ListPurchases ¶ added in v3.2.0
func ListUserGroups ¶
func ListUserGroups(ctx context.Context, logger *zap.Logger, db *sql.DB, userID uuid.UUID, limit int, state *wrapperspb.Int32Value, cursor string) (*api.UserGroupList, error)
func ListWalletLedger ¶
func MapMatchIndexEntry ¶ added in v3.9.0
func MapMatchmakerIndex ¶ added in v3.9.0
func MapMatchmakerIndex(id string, in *MatchmakerIndex) (*bluge.Document, error)
func MultiUpdate ¶
func MultiUpdate(ctx context.Context, logger *zap.Logger, db *sql.DB, accountUpdates []*accountUpdate, storageWrites StorageOpWrites, walletUpdates []*walletUpdate, updateLedger bool) ([]*api.StorageObjectAck, []*runtime.WalletUpdateResult, error)
func NewConfig ¶
NewConfig constructs a Config struct which represents server settings, and populates it with default values.
func NewJSONFileLogger ¶
func NewJSONLogger ¶
func NewJsLogger ¶
func NewRuntime ¶
func NewRuntime(ctx context.Context, logger, startupLogger *zap.Logger, db *sql.DB, protojsonMarshaler *protojson.MarshalOptions, protojsonUnmarshaler *protojson.UnmarshalOptions, config Config, socialClient *social.Client, leaderboardCache LeaderboardCache, leaderboardRankCache LeaderboardRankCache, leaderboardScheduler LeaderboardScheduler, sessionRegistry SessionRegistry, sessionCache SessionCache, matchRegistry MatchRegistry, tracker Tracker, metrics Metrics, streamManager StreamManager, router MessageRouter) (*Runtime, *RuntimeInfo, error)
func NewRuntimeGoContext ¶
func NewRuntimeJavascriptNakamaModule ¶
func NewRuntimeJavascriptNakamaModule(logger *zap.Logger, db *sql.DB, protojsonMarshaler *protojson.MarshalOptions, protojsonUnmarshaler *protojson.UnmarshalOptions, config Config, socialClient *social.Client, leaderboardCache LeaderboardCache, rankCache LeaderboardRankCache, localCache *RuntimeJavascriptLocalCache, leaderboardScheduler LeaderboardScheduler, sessionRegistry SessionRegistry, sessionCache SessionCache, matchRegistry MatchRegistry, tracker Tracker, streamManager StreamManager, router MessageRouter, eventFn RuntimeEventCustomFunction, matchCreateFn RuntimeMatchCreateFunction) *runtimeJavascriptNakamaModule
func NewRuntimeJsContext ¶
func NewRuntimeJsInitContext ¶
func NewRuntimeLuaContext ¶
func NewRuntimeProviderGo ¶
func NewRuntimeProviderGo(ctx context.Context, logger, startupLogger *zap.Logger, db *sql.DB, protojsonMarshaler *protojson.MarshalOptions, config Config, socialClient *social.Client, leaderboardCache LeaderboardCache, leaderboardRankCache LeaderboardRankCache, leaderboardScheduler LeaderboardScheduler, sessionRegistry SessionRegistry, sessionCache SessionCache, matchRegistry MatchRegistry, tracker Tracker, metrics Metrics, streamManager StreamManager, router MessageRouter, rootPath string, paths []string, eventQueue *RuntimeEventQueue, matchProvider *MatchProvider) ([]string, map[string]RuntimeRpcFunction, map[string]RuntimeBeforeRtFunction, map[string]RuntimeAfterRtFunction, *RuntimeBeforeReqFunctions, *RuntimeAfterReqFunctions, RuntimeMatchmakerMatchedFunction, RuntimeTournamentEndFunction, RuntimeTournamentResetFunction, RuntimeLeaderboardResetFunction, *RuntimeEventFunctions, func() []string, error)
func NewRuntimeProviderJS ¶
func NewRuntimeProviderJS(logger, startupLogger *zap.Logger, db *sql.DB, protojsonMarshaler *protojson.MarshalOptions, protojsonUnmarshaler *protojson.UnmarshalOptions, config Config, socialClient *social.Client, leaderboardCache LeaderboardCache, leaderboardRankCache LeaderboardRankCache, leaderboardScheduler LeaderboardScheduler, sessionRegistry SessionRegistry, sessionCache SessionCache, matchRegistry MatchRegistry, tracker Tracker, metrics Metrics, streamManager StreamManager, router MessageRouter, eventFn RuntimeEventCustomFunction, path, entrypoint string, matchProvider *MatchProvider) ([]string, map[string]RuntimeRpcFunction, map[string]RuntimeBeforeRtFunction, map[string]RuntimeAfterRtFunction, *RuntimeBeforeReqFunctions, *RuntimeAfterReqFunctions, RuntimeMatchmakerMatchedFunction, RuntimeTournamentEndFunction, RuntimeTournamentResetFunction, RuntimeLeaderboardResetFunction, error)
func NewRuntimeProviderLua ¶
func NewRuntimeProviderLua(logger, startupLogger *zap.Logger, db *sql.DB, protojsonMarshaler *protojson.MarshalOptions, protojsonUnmarshaler *protojson.UnmarshalOptions, config Config, socialClient *social.Client, leaderboardCache LeaderboardCache, leaderboardRankCache LeaderboardRankCache, leaderboardScheduler LeaderboardScheduler, sessionRegistry SessionRegistry, sessionCache SessionCache, matchRegistry MatchRegistry, tracker Tracker, metrics Metrics, streamManager StreamManager, router MessageRouter, eventFn RuntimeEventCustomFunction, rootPath string, paths []string, matchProvider *MatchProvider) ([]string, map[string]RuntimeRpcFunction, map[string]RuntimeBeforeRtFunction, map[string]RuntimeAfterRtFunction, *RuntimeBeforeReqFunctions, *RuntimeAfterReqFunctions, RuntimeMatchmakerMatchedFunction, RuntimeTournamentEndFunction, RuntimeTournamentResetFunction, RuntimeLeaderboardResetFunction, error)
func NewSocketWsAcceptor ¶
func NewSocketWsAcceptor(logger *zap.Logger, config Config, sessionRegistry SessionRegistry, sessionCache SessionCache, statusRegistry *StatusRegistry, matchmaker Matchmaker, tracker Tracker, metrics Metrics, runtime *Runtime, protojsonMarshaler *protojson.MarshalOptions, protojsonUnmarshaler *protojson.UnmarshalOptions, pipeline *Pipeline) func(http.ResponseWriter, *http.Request)
func NodeToHash ¶
func NotificationDelete ¶
func NotificationList ¶
func NotificationSave ¶
func NotificationSend ¶
func OpenPackage ¶
func OpenPackage(moduleCache *RuntimeLuaModuleCache) func(L *lua.LState) int
func PromoteGroupUsers ¶
func RedirectStdLog ¶ added in v3.4.0
func RuntimeJsConvertJsValue ¶ added in v3.3.0
func RuntimeJsConvertJsValue(jv interface{}) interface{}
func RuntimeLuaConvertMap ¶
func RuntimeLuaConvertValue ¶
func SessionLogout ¶ added in v3.2.0
func SessionRefresh ¶
func SetupLogging ¶
func StackdriverLevelEncoder ¶
func StackdriverLevelEncoder(l zapcore.Level, enc zapcore.PrimitiveArrayEncoder)
func StatusError ¶
Helper function for creating status errors that wrap underlying causes, usually DB errors.
func StorageDeleteObjects ¶
func StorageListObjects ¶
func StorageListObjectsAll ¶
func StorageListObjectsUser ¶
func StorageReadObjects ¶
func StorageWriteObjects ¶
func StreamToChannelId ¶
func StreamToChannelId(stream PresenceStream) (string, error)
func TournamentAddAttempt ¶
func TournamentCreate ¶
func TournamentCreate(ctx context.Context, logger *zap.Logger, cache LeaderboardCache, scheduler LeaderboardScheduler, leaderboardId string, authoritative bool, sortOrder, operator int, resetSchedule, metadata, title, description string, category, startTime, endTime, duration, maxSize, maxNumScore int, joinRequired bool) error
func TournamentDelete ¶
func TournamentDelete(ctx context.Context, cache LeaderboardCache, rankCache LeaderboardRankCache, scheduler LeaderboardScheduler, leaderboardId string) error
func TournamentJoin ¶
func TournamentList ¶
func TournamentList(ctx context.Context, logger *zap.Logger, db *sql.DB, leaderboardCache LeaderboardCache, categoryStart, categoryEnd, startTime, endTime, limit int, cursor *TournamentListCursor) (*api.TournamentList, error)
func TournamentRecordWrite ¶
func TournamentRecordWrite(ctx context.Context, logger *zap.Logger, db *sql.DB, leaderboardCache LeaderboardCache, rankCache LeaderboardRankCache, caller uuid.UUID, tournamentId string, ownerId uuid.UUID, username string, score, subscore int64, metadata string, overrideOperator api.Operator) (*api.LeaderboardRecord, error)
func TournamentRecordsList ¶
func TournamentRecordsList(ctx context.Context, logger *zap.Logger, db *sql.DB, leaderboardCache LeaderboardCache, rankCache LeaderboardRankCache, tournamentId string, ownerIds []string, limit *wrapperspb.Int32Value, cursor string, overrideExpiry int64) (*api.TournamentRecordList, error)
func TournamentsGet ¶
func UnbanUsers ¶
func UnlinkApple ¶
func UnlinkCustom ¶
func UnlinkDevice ¶
func UnlinkEmail ¶
func UnlinkFacebook ¶
func UnlinkGameCenter ¶
func UnlinkGoogle ¶
func UnlinkSteam ¶
func UpdateAccounts ¶
func UpdateGroup ¶
func UpdateWalletLedger ¶
func UpdateWallets ¶
func ValidatePurchaseGoogle ¶ added in v3.2.0
func ValidatePurchaseHuawei ¶ added in v3.2.0
Types ¶
type AmbiguousCommitError ¶
type AmbiguousCommitError struct {
// contains filtered or unexported fields
}
AmbiguousCommitError represents an error that left a transaction in an ambiguous state: unclear if it committed or not.
type ApiServer ¶
type ApiServer struct { apigrpc.UnimplementedNakamaServer // contains filtered or unexported fields }
func StartApiServer ¶
func StartApiServer(logger *zap.Logger, startupLogger *zap.Logger, db *sql.DB, protojsonMarshaler *protojson.MarshalOptions, protojsonUnmarshaler *protojson.UnmarshalOptions, config Config, socialClient *social.Client, leaderboardCache LeaderboardCache, leaderboardRankCache LeaderboardRankCache, sessionRegistry SessionRegistry, sessionCache SessionCache, statusRegistry *StatusRegistry, matchRegistry MatchRegistry, matchmaker Matchmaker, tracker Tracker, router MessageRouter, metrics Metrics, pipeline *Pipeline, runtime *Runtime) *ApiServer
func (*ApiServer) AddFriends ¶
func (*ApiServer) AddGroupUsers ¶
func (*ApiServer) AuthenticateApple ¶
func (*ApiServer) AuthenticateCustom ¶
func (*ApiServer) AuthenticateDevice ¶
func (*ApiServer) AuthenticateEmail ¶
func (*ApiServer) AuthenticateFacebook ¶
func (*ApiServer) AuthenticateFacebookInstantGame ¶
func (*ApiServer) AuthenticateGameCenter ¶
func (*ApiServer) AuthenticateGoogle ¶
func (*ApiServer) AuthenticateSteam ¶
func (*ApiServer) BanGroupUsers ¶
func (*ApiServer) BlockFriends ¶
func (*ApiServer) CreateGroup ¶
func (*ApiServer) DeleteFriends ¶
func (*ApiServer) DeleteGroup ¶
func (*ApiServer) DeleteLeaderboardRecord ¶
func (*ApiServer) DeleteNotifications ¶
func (*ApiServer) DeleteStorageObjects ¶
func (*ApiServer) DemoteGroupUsers ¶
func (*ApiServer) GetAccount ¶
func (*ApiServer) Healthcheck ¶
func (*ApiServer) ImportFacebookFriends ¶
func (*ApiServer) ImportSteamFriends ¶ added in v3.1.0
func (*ApiServer) JoinTournament ¶
func (*ApiServer) KickGroupUsers ¶
func (*ApiServer) LeaveGroup ¶
func (*ApiServer) LinkCustom ¶
func (*ApiServer) LinkDevice ¶
func (*ApiServer) LinkFacebook ¶
func (*ApiServer) LinkFacebookInstantGame ¶
func (*ApiServer) LinkGameCenter ¶
func (*ApiServer) LinkGoogle ¶
func (*ApiServer) ListChannelMessages ¶
func (s *ApiServer) ListChannelMessages(ctx context.Context, in *api.ListChannelMessagesRequest) (*api.ChannelMessageList, error)
func (*ApiServer) ListFriends ¶
func (s *ApiServer) ListFriends(ctx context.Context, in *api.ListFriendsRequest) (*api.FriendList, error)
func (*ApiServer) ListGroupUsers ¶
func (s *ApiServer) ListGroupUsers(ctx context.Context, in *api.ListGroupUsersRequest) (*api.GroupUserList, error)
func (*ApiServer) ListGroups ¶
func (*ApiServer) ListLeaderboardRecords ¶
func (s *ApiServer) ListLeaderboardRecords(ctx context.Context, in *api.ListLeaderboardRecordsRequest) (*api.LeaderboardRecordList, error)
func (*ApiServer) ListLeaderboardRecordsAroundOwner ¶
func (s *ApiServer) ListLeaderboardRecordsAroundOwner(ctx context.Context, in *api.ListLeaderboardRecordsAroundOwnerRequest) (*api.LeaderboardRecordList, error)
func (*ApiServer) ListMatches ¶
func (*ApiServer) ListNotifications ¶
func (s *ApiServer) ListNotifications(ctx context.Context, in *api.ListNotificationsRequest) (*api.NotificationList, error)
func (*ApiServer) ListStorageObjects ¶
func (s *ApiServer) ListStorageObjects(ctx context.Context, in *api.ListStorageObjectsRequest) (*api.StorageObjectList, error)
func (*ApiServer) ListTournamentRecords ¶
func (s *ApiServer) ListTournamentRecords(ctx context.Context, in *api.ListTournamentRecordsRequest) (*api.TournamentRecordList, error)
func (*ApiServer) ListTournamentRecordsAroundOwner ¶
func (s *ApiServer) ListTournamentRecordsAroundOwner(ctx context.Context, in *api.ListTournamentRecordsAroundOwnerRequest) (*api.TournamentRecordList, error)
func (*ApiServer) ListTournaments ¶
func (s *ApiServer) ListTournaments(ctx context.Context, in *api.ListTournamentsRequest) (*api.TournamentList, error)
func (*ApiServer) ListUserGroups ¶
func (s *ApiServer) ListUserGroups(ctx context.Context, in *api.ListUserGroupsRequest) (*api.UserGroupList, error)
func (*ApiServer) PromoteGroupUsers ¶
func (*ApiServer) ReadStorageObjects ¶
func (s *ApiServer) ReadStorageObjects(ctx context.Context, in *api.ReadStorageObjectsRequest) (*api.StorageObjects, error)
func (*ApiServer) RpcFuncHttp ¶
func (s *ApiServer) RpcFuncHttp(w http.ResponseWriter, r *http.Request)
func (*ApiServer) SessionLogout ¶ added in v3.2.0
func (*ApiServer) SessionRefresh ¶
func (*ApiServer) UnlinkApple ¶
func (*ApiServer) UnlinkCustom ¶
func (*ApiServer) UnlinkDevice ¶
func (*ApiServer) UnlinkEmail ¶
func (*ApiServer) UnlinkFacebook ¶
func (*ApiServer) UnlinkFacebookInstantGame ¶
func (*ApiServer) UnlinkGameCenter ¶
func (*ApiServer) UnlinkGoogle ¶
func (*ApiServer) UnlinkSteam ¶
func (*ApiServer) UpdateAccount ¶
func (*ApiServer) UpdateGroup ¶
func (*ApiServer) ValidatePurchaseApple ¶ added in v3.2.0
func (s *ApiServer) ValidatePurchaseApple(ctx context.Context, in *api.ValidatePurchaseAppleRequest) (*api.ValidatePurchaseResponse, error)
func (*ApiServer) ValidatePurchaseGoogle ¶ added in v3.2.0
func (s *ApiServer) ValidatePurchaseGoogle(ctx context.Context, in *api.ValidatePurchaseGoogleRequest) (*api.ValidatePurchaseResponse, error)
func (*ApiServer) ValidatePurchaseHuawei ¶ added in v3.2.0
func (s *ApiServer) ValidatePurchaseHuawei(ctx context.Context, in *api.ValidatePurchaseHuaweiRequest) (*api.ValidatePurchaseResponse, error)
func (*ApiServer) WriteLeaderboardRecord ¶
func (s *ApiServer) WriteLeaderboardRecord(ctx context.Context, in *api.WriteLeaderboardRecordRequest) (*api.LeaderboardRecord, error)
func (*ApiServer) WriteStorageObjects ¶
func (s *ApiServer) WriteStorageObjects(ctx context.Context, in *api.WriteStorageObjectsRequest) (*api.StorageObjectAcks, error)
func (*ApiServer) WriteTournamentRecord ¶
func (s *ApiServer) WriteTournamentRecord(ctx context.Context, in *api.WriteTournamentRecordRequest) (*api.LeaderboardRecord, error)
type BlugeResult ¶ added in v3.9.0
type BlugeResult struct {
Hits []*blugeMatch
}
func IterateBlugeMatches ¶ added in v3.9.0
func IterateBlugeMatches(dmi search.DocumentMatchIterator, loadFields map[string]struct{}, logger *zap.Logger) (*BlugeResult, error)
type ChannelIdToStreamResult ¶
type ChannelIdToStreamResult struct {
Stream PresenceStream
}
Wrapper type to avoid allocating a stream struct when the input is invalid.
func ChannelIdToStream ¶
func ChannelIdToStream(channelID string) (*ChannelIdToStreamResult, error)
type Config ¶
type Config interface { GetName() string GetDataDir() string GetShutdownGraceSec() int GetLogger() *LoggerConfig GetMetrics() *MetricsConfig GetSession() *SessionConfig GetSocket() *SocketConfig GetDatabase() *DatabaseConfig GetSocial() *SocialConfig GetRuntime() *RuntimeConfig GetMatch() *MatchConfig GetTracker() *TrackerConfig GetConsole() *ConsoleConfig GetLeaderboard() *LeaderboardConfig GetMatchmaker() *MatchmakerConfig GetIAP() *IAPConfig Clone() (Config, error) }
Config interface is the Nakama core configuration.
type ConsoleConfig ¶
type ConsoleConfig struct { Port int `yaml:"port" json:"port" usage:"The port for accepting connections for the embedded console, listening on all interfaces."` Address string `` /* 157-byte string literal not displayed */ MaxMessageSizeBytes int64 `` /* 154-byte string literal not displayed */ ReadTimeoutMs int `yaml:"read_timeout_ms" json:"read_timeout_ms" usage:"Maximum duration in milliseconds for reading the entire request."` WriteTimeoutMs int `` /* 130-byte string literal not displayed */ IdleTimeoutMs int `` /* 151-byte string literal not displayed */ Username string `yaml:"username" json:"username" usage:"Username for the embedded console. Default username is 'admin'."` Password string `yaml:"password" json:"password" usage:"Password for the embedded console. Default password is 'password'."` TokenExpirySec int64 `yaml:"token_expiry_sec" json:"token_expiry_sec" usage:"Token expiry in seconds. Default 86400."` SigningKey string `yaml:"signing_key" json:"signing_key" usage:"Key used to sign console session tokens."` }
ConsoleConfig is configuration relevant to the embedded console.
func NewConsoleConfig ¶
func NewConsoleConfig() *ConsoleConfig
NewConsoleConfig creates a new ConsoleConfig struct.
type ConsoleServer ¶
type ConsoleServer struct { console.UnimplementedConsoleServer // contains filtered or unexported fields }
func StartConsoleServer ¶
func StartConsoleServer(logger *zap.Logger, startupLogger *zap.Logger, db *sql.DB, config Config, tracker Tracker, router MessageRouter, sessionCache SessionCache, statusHandler StatusHandler, runtimeInfo *RuntimeInfo, matchRegistry MatchRegistry, configWarnings map[string]string, serverVersion string, leaderboardCache LeaderboardCache, leaderboardRankCache LeaderboardRankCache, api *ApiServer, cookie string) *ConsoleServer
func (*ConsoleServer) AddUser ¶
func (s *ConsoleServer) AddUser(ctx context.Context, in *console.AddUserRequest) (*emptypb.Empty, error)
func (*ConsoleServer) Authenticate ¶
func (s *ConsoleServer) Authenticate(ctx context.Context, in *console.AuthenticateRequest) (*console.ConsoleSession, error)
func (*ConsoleServer) BanAccount ¶
func (*ConsoleServer) CallApiEndpoint ¶
func (s *ConsoleServer) CallApiEndpoint(ctx context.Context, in *console.CallApiEndpointRequest) (*console.CallApiEndpointResponse, error)
func (*ConsoleServer) CallRpcEndpoint ¶
func (s *ConsoleServer) CallRpcEndpoint(ctx context.Context, in *console.CallApiEndpointRequest) (*console.CallApiEndpointResponse, error)
func (*ConsoleServer) DeleteAccount ¶
func (s *ConsoleServer) DeleteAccount(ctx context.Context, in *console.AccountDeleteRequest) (*emptypb.Empty, error)
func (*ConsoleServer) DeleteAccounts ¶
func (*ConsoleServer) DeleteFriend ¶
func (s *ConsoleServer) DeleteFriend(ctx context.Context, in *console.DeleteFriendRequest) (*emptypb.Empty, error)
func (*ConsoleServer) DeleteGroupUser ¶
func (s *ConsoleServer) DeleteGroupUser(ctx context.Context, in *console.DeleteGroupUserRequest) (*emptypb.Empty, error)
func (*ConsoleServer) DeleteLeaderboard ¶
func (s *ConsoleServer) DeleteLeaderboard(ctx context.Context, in *console.LeaderboardRequest) (*emptypb.Empty, error)
func (*ConsoleServer) DeleteLeaderboardRecord ¶
func (s *ConsoleServer) DeleteLeaderboardRecord(ctx context.Context, in *console.DeleteLeaderboardRecordRequest) (*emptypb.Empty, error)
func (*ConsoleServer) DeleteStorage ¶
func (*ConsoleServer) DeleteStorageObject ¶
func (s *ConsoleServer) DeleteStorageObject(ctx context.Context, in *console.DeleteStorageObjectRequest) (*emptypb.Empty, error)
func (*ConsoleServer) DeleteUser ¶
func (*ConsoleServer) DeleteWalletLedger ¶
func (s *ConsoleServer) DeleteWalletLedger(ctx context.Context, in *console.DeleteWalletLedgerRequest) (*emptypb.Empty, error)
func (*ConsoleServer) ExportAccount ¶
func (s *ConsoleServer) ExportAccount(ctx context.Context, in *console.AccountId) (*console.AccountExport, error)
func (*ConsoleServer) GetAccount ¶
func (*ConsoleServer) GetFriends ¶
func (s *ConsoleServer) GetFriends(ctx context.Context, in *console.AccountId) (*api.FriendList, error)
func (*ConsoleServer) GetGroups ¶
func (s *ConsoleServer) GetGroups(ctx context.Context, in *console.AccountId) (*api.UserGroupList, error)
func (*ConsoleServer) GetLeaderboard ¶
func (s *ConsoleServer) GetLeaderboard(ctx context.Context, in *console.LeaderboardRequest) (*console.Leaderboard, error)
func (*ConsoleServer) GetMatchState ¶
func (s *ConsoleServer) GetMatchState(ctx context.Context, in *console.MatchStateRequest) (*console.MatchState, error)
func (*ConsoleServer) GetRuntime ¶
func (s *ConsoleServer) GetRuntime(ctx context.Context, in *emptypb.Empty) (*console.RuntimeInfo, error)
func (*ConsoleServer) GetStatus ¶
func (s *ConsoleServer) GetStatus(ctx context.Context, in *emptypb.Empty) (*console.StatusList, error)
func (*ConsoleServer) GetStorage ¶
func (s *ConsoleServer) GetStorage(ctx context.Context, in *api.ReadStorageObjectId) (*api.StorageObject, error)
func (*ConsoleServer) GetWalletLedger ¶
func (s *ConsoleServer) GetWalletLedger(ctx context.Context, in *console.GetWalletLedgerRequest) (*console.WalletLedgerList, error)
func (*ConsoleServer) ListAccounts ¶
func (s *ConsoleServer) ListAccounts(ctx context.Context, in *console.ListAccountsRequest) (*console.AccountList, error)
func (*ConsoleServer) ListApiEndpoints ¶
func (s *ConsoleServer) ListApiEndpoints(ctx context.Context, _ *emptypb.Empty) (*console.ApiEndpointList, error)
func (*ConsoleServer) ListLeaderboardRecords ¶
func (s *ConsoleServer) ListLeaderboardRecords(ctx context.Context, in *api.ListLeaderboardRecordsRequest) (*api.LeaderboardRecordList, error)
func (*ConsoleServer) ListLeaderboards ¶
func (s *ConsoleServer) ListLeaderboards(ctx context.Context, _ *emptypb.Empty) (*console.LeaderboardList, error)
func (*ConsoleServer) ListMatches ¶
func (s *ConsoleServer) ListMatches(ctx context.Context, in *api.ListMatchesRequest) (*api.MatchList, error)
func (*ConsoleServer) ListPurchases ¶ added in v3.2.0
func (s *ConsoleServer) ListPurchases(ctx context.Context, in *console.ListPurchasesRequest) (*api.PurchaseList, error)
func (*ConsoleServer) ListStorage ¶
func (s *ConsoleServer) ListStorage(ctx context.Context, in *console.ListStorageRequest) (*console.StorageList, error)
func (*ConsoleServer) ListStorageCollections ¶
func (s *ConsoleServer) ListStorageCollections(ctx context.Context, in *emptypb.Empty) (*console.StorageCollectionsList, error)
func (*ConsoleServer) Stop ¶
func (s *ConsoleServer) Stop()
func (*ConsoleServer) UnbanAccount ¶
func (*ConsoleServer) UnlinkApple ¶
func (*ConsoleServer) UnlinkCustom ¶
func (*ConsoleServer) UnlinkDevice ¶
func (s *ConsoleServer) UnlinkDevice(ctx context.Context, in *console.UnlinkDeviceRequest) (*emptypb.Empty, error)
func (*ConsoleServer) UnlinkEmail ¶
func (*ConsoleServer) UnlinkFacebook ¶
func (*ConsoleServer) UnlinkFacebookInstantGame ¶
func (*ConsoleServer) UnlinkGameCenter ¶
func (*ConsoleServer) UnlinkGoogle ¶
func (*ConsoleServer) UnlinkSteam ¶
func (*ConsoleServer) UpdateAccount ¶
func (s *ConsoleServer) UpdateAccount(ctx context.Context, in *console.UpdateAccountRequest) (*emptypb.Empty, error)
func (*ConsoleServer) WriteStorageObject ¶
func (s *ConsoleServer) WriteStorageObject(ctx context.Context, in *console.WriteStorageObjectRequest) (*api.StorageObjectAck, error)
type ConsoleTokenClaims ¶
type ConsoleTokenClaims struct { Username string `json:"usn,omitempty"` Email string `json:"ema,omitempty"` Role console.UserRole `json:"rol,omitempty"` ExpiresAt int64 `json:"exp,omitempty"` Cookie string `json:"cki,omitempty"` }
func (*ConsoleTokenClaims) Valid ¶
func (stc *ConsoleTokenClaims) Valid() error
type DatabaseConfig ¶
type DatabaseConfig struct { Addresses []string `` /* 135-byte string literal not displayed */ ConnMaxLifetimeMs int `` /* 199-byte string literal not displayed */ MaxOpenConns int `yaml:"max_open_conns" json:"max_open_conns" usage:"Maximum number of allowed open connections to the database. Default 100."` MaxIdleConns int `` /* 135-byte string literal not displayed */ DnsScanIntervalSec int `` /* 171-byte string literal not displayed */ }
DatabaseConfig is configuration relevant to the Database storage.
func NewDatabaseConfig ¶
func NewDatabaseConfig() *DatabaseConfig
NewDatabaseConfig creates a new DatabaseConfig struct.
type DeferredMessage ¶
type DeferredMessage struct { PresenceIDs []*PresenceID Envelope *rtapi.Envelope Reliable bool }
Deferred message expected to be batched with other deferred messages. All deferred messages in a batch are expected to be for the same stream/mode and share a logger context.
type ErrorCauser ¶
type ErrorCauser interface { // Cause returns the proximate cause of this error. Cause() error }
ErrorCauser is the type implemented by an error that remembers its cause.
ErrorCauser is intentionally equivalent to the causer interface used by the github.com/pkg/errors package.
type IAPAppleConfig ¶ added in v3.2.0
type IAPAppleConfig struct {
}type IAPConfig ¶ added in v3.2.0
type IAPConfig struct { Apple *IAPAppleConfig `yaml:"apple" json:"apple" usage:"Apple App Store purchase validation configuration."` Google *IAPGoogleConfig `yaml:"google" json:"google" usage:"Google Play Store purchase validation configuration."` Huawei *IAPHuaweiConfig `yaml:"huawei" json:"huawei" usage:"Huawei purchase validation configuration."` }
func NewIAPConfig ¶ added in v3.2.0
func NewIAPConfig() *IAPConfig
type IAPGoogleConfig ¶ added in v3.2.0
type IAPHuaweiConfig ¶ added in v3.2.0
type IAPHuaweiConfig struct { PublicKey string `yaml:"public_key" json:"public_key" usage:"Huawei IAP store Base64 encoded Public Key."` ClientID string `yaml:"client_id" json:"client_id" usage:"Huawei OAuth client secret."` ClientSecret string `yaml:"client_secret" json:"client_secret" usage:"Huawei OAuth app client secret."` }
type LSentinelType ¶
func (*LSentinelType) String ¶
func (s *LSentinelType) String() string
func (*LSentinelType) Type ¶
func (s *LSentinelType) Type() lua.LValueType
type Leaderboard ¶
type Leaderboard struct { Id string Authoritative bool SortOrder int Operator int ResetScheduleStr string ResetSchedule *cronexpr.Expression Metadata string CreateTime int64 Category int Description string Duration int EndTime int64 JoinRequired bool MaxSize int MaxNumScore int Title string StartTime int64 }
func (*Leaderboard) GetAuthoritative ¶
func (l *Leaderboard) GetAuthoritative() bool
func (*Leaderboard) GetCreateTime ¶
func (l *Leaderboard) GetCreateTime() int64
func (*Leaderboard) GetId ¶
func (l *Leaderboard) GetId() string
func (*Leaderboard) GetMetadata ¶
func (l *Leaderboard) GetMetadata() map[string]interface{}
func (*Leaderboard) GetOperator ¶
func (l *Leaderboard) GetOperator() string
func (*Leaderboard) GetReset ¶
func (l *Leaderboard) GetReset() string
func (*Leaderboard) GetSortOrder ¶
func (l *Leaderboard) GetSortOrder() string
func (*Leaderboard) IsTournament ¶
func (l *Leaderboard) IsTournament() bool
type LeaderboardCache ¶
type LeaderboardCache interface { Get(id string) *Leaderboard GetAllLeaderboards() []*Leaderboard RefreshAllLeaderboards(ctx context.Context) error Create(ctx context.Context, id string, authoritative bool, sortOrder, operator int, resetSchedule, metadata string) (*Leaderboard, error) Insert(id string, authoritative bool, sortOrder, operator int, resetSchedule, metadata string, createTime int64) List(categoryStart, categoryEnd, limit int, cursor *LeaderboardListCursor) ([]*Leaderboard, *LeaderboardListCursor, error) CreateTournament(ctx context.Context, id string, authoritative bool, sortOrder, operator int, resetSchedule, metadata, title, description string, category, startTime, endTime, duration, maxSize, maxNumScore int, joinRequired bool) (*Leaderboard, error) InsertTournament(id string, authoritative bool, sortOrder, operator int, resetSchedule, metadata, title, description string, category, duration, maxSize, maxNumScore int, joinRequired bool, createTime, startTime, endTime int64) ListTournaments(now int64, categoryStart, categoryEnd int, startTime, endTime int64, limit int, cursor *TournamentListCursor) ([]*Leaderboard, *TournamentListCursor, error) Delete(ctx context.Context, id string) error Remove(id string) }
func NewLocalLeaderboardCache ¶
func NewLocalLeaderboardCache(logger, startupLogger *zap.Logger, db *sql.DB) LeaderboardCache
type LeaderboardConfig ¶
type LeaderboardConfig struct { BlacklistRankCache []string `` /* 211-byte string literal not displayed */ CallbackQueueSize int `` /* 175-byte string literal not displayed */ CallbackQueueWorkers int `` /* 170-byte string literal not displayed */ }
LeaderboardConfig is configuration relevant to the leaderboard system.
func NewLeaderboardConfig ¶
func NewLeaderboardConfig() *LeaderboardConfig
NewLeaderboardConfig creates a new LeaderboardConfig struct.
type LeaderboardListCursor ¶ added in v3.4.0
type LeaderboardListCursor = TournamentListCursor
type LeaderboardRankCache ¶
type LeaderboardRankCache interface { Get(leaderboardId string, expiryUnix int64, ownerID uuid.UUID) int64 Fill(leaderboardId string, expiryUnix int64, records []*api.LeaderboardRecord) Insert(leaderboardId string, expiryUnix int64, sortOrder int, ownerID uuid.UUID, score, subscore int64) int64 Delete(leaderboardId string, expiryUnix int64, ownerID uuid.UUID) bool DeleteLeaderboard(leaderboardId string, expiryUnix int64) bool TrimExpired(nowUnix int64) bool }
func NewLocalLeaderboardRankCache ¶
func NewLocalLeaderboardRankCache(startupLogger *zap.Logger, db *sql.DB, config *LeaderboardConfig, leaderboardCache LeaderboardCache) LeaderboardRankCache
type LeaderboardScheduler ¶
type LeaderboardScheduler interface { Start(runtime *Runtime) Pause() Resume() Stop() Update() }
func NewLocalLeaderboardScheduler ¶
func NewLocalLeaderboardScheduler(logger *zap.Logger, db *sql.DB, config Config, cache LeaderboardCache, rankCache LeaderboardRankCache) LeaderboardScheduler
type LeaderboardSchedulerCallback ¶
type LeaderboardSchedulerCallback struct {
// contains filtered or unexported fields
}
type LeaderboardWithExpiry ¶
type LocalLeaderboardCache ¶
func (*LocalLeaderboardCache) Create ¶
func (l *LocalLeaderboardCache) Create(ctx context.Context, id string, authoritative bool, sortOrder, operator int, resetSchedule, metadata string) (*Leaderboard, error)
func (*LocalLeaderboardCache) CreateTournament ¶
func (*LocalLeaderboardCache) Delete ¶
func (l *LocalLeaderboardCache) Delete(ctx context.Context, id string) error
func (*LocalLeaderboardCache) Get ¶
func (l *LocalLeaderboardCache) Get(id string) *Leaderboard
func (*LocalLeaderboardCache) GetAllLeaderboards ¶
func (l *LocalLeaderboardCache) GetAllLeaderboards() []*Leaderboard
func (*LocalLeaderboardCache) InsertTournament ¶
func (*LocalLeaderboardCache) List ¶ added in v3.4.0
func (l *LocalLeaderboardCache) List(categoryStart, categoryEnd, limit int, cursor *LeaderboardListCursor) ([]*Leaderboard, *LeaderboardListCursor, error)
func (*LocalLeaderboardCache) ListTournaments ¶
func (l *LocalLeaderboardCache) ListTournaments(now int64, categoryStart, categoryEnd int, startTime, endTime int64, limit int, cursor *TournamentListCursor) ([]*Leaderboard, *TournamentListCursor, error)
func (*LocalLeaderboardCache) RefreshAllLeaderboards ¶
func (l *LocalLeaderboardCache) RefreshAllLeaderboards(ctx context.Context) error
func (*LocalLeaderboardCache) Remove ¶
func (l *LocalLeaderboardCache) Remove(id string)
type LocalLeaderboardRankCache ¶
func (*LocalLeaderboardRankCache) DeleteLeaderboard ¶
func (l *LocalLeaderboardRankCache) DeleteLeaderboard(leaderboardId string, expiryUnix int64) bool
func (*LocalLeaderboardRankCache) Fill ¶
func (l *LocalLeaderboardRankCache) Fill(leaderboardId string, expiryUnix int64, records []*api.LeaderboardRecord)
func (*LocalLeaderboardRankCache) TrimExpired ¶
func (l *LocalLeaderboardRankCache) TrimExpired(nowUnix int64) bool
type LocalLeaderboardScheduler ¶
func (*LocalLeaderboardScheduler) Pause ¶
func (ls *LocalLeaderboardScheduler) Pause()
func (*LocalLeaderboardScheduler) Resume ¶
func (ls *LocalLeaderboardScheduler) Resume()
func (*LocalLeaderboardScheduler) Start ¶
func (ls *LocalLeaderboardScheduler) Start(runtime *Runtime)
func (*LocalLeaderboardScheduler) Stop ¶
func (ls *LocalLeaderboardScheduler) Stop()
func (*LocalLeaderboardScheduler) Update ¶
func (ls *LocalLeaderboardScheduler) Update()
type LocalMatchRegistry ¶
type LocalMatchRegistry struct {
// contains filtered or unexported fields
}
func (*LocalMatchRegistry) Count ¶
func (r *LocalMatchRegistry) Count() int
func (*LocalMatchRegistry) CreateMatch ¶
func (r *LocalMatchRegistry) CreateMatch(ctx context.Context, logger *zap.Logger, createFn RuntimeMatchCreateFunction, module string, params map[string]interface{}) (string, error)
func (*LocalMatchRegistry) Join ¶
func (r *LocalMatchRegistry) Join(id uuid.UUID, presences []*MatchPresence)
func (*LocalMatchRegistry) JoinAttempt ¶
func (*LocalMatchRegistry) Kick ¶
func (r *LocalMatchRegistry) Kick(stream PresenceStream, presences []*MatchPresence)
func (*LocalMatchRegistry) Leave ¶
func (r *LocalMatchRegistry) Leave(id uuid.UUID, presences []*MatchPresence)
func (*LocalMatchRegistry) ListMatches ¶
func (r *LocalMatchRegistry) ListMatches(ctx context.Context, limit int, authoritative *wrapperspb.BoolValue, label *wrapperspb.StringValue, minSize *wrapperspb.Int32Value, maxSize *wrapperspb.Int32Value, queryString *wrapperspb.StringValue) ([]*api.Match, error)
func (*LocalMatchRegistry) NewMatch ¶
func (r *LocalMatchRegistry) NewMatch(logger *zap.Logger, id uuid.UUID, core RuntimeMatchCore, stopped *atomic.Bool, params map[string]interface{}) (*MatchHandler, error)
func (*LocalMatchRegistry) RemoveMatch ¶
func (r *LocalMatchRegistry) RemoveMatch(id uuid.UUID, stream PresenceStream)
func (*LocalMatchRegistry) Stop ¶
func (r *LocalMatchRegistry) Stop(graceSeconds int) chan struct{}
func (*LocalMatchRegistry) UpdateMatchLabel ¶
type LocalMatchmaker ¶
func (*LocalMatchmaker) Add ¶
func (m *LocalMatchmaker) Add(presences []*MatchmakerPresence, sessionID, partyId, query string, minCount, maxCount int, stringProperties map[string]string, numericProperties map[string]float64) (string, error)
func (*LocalMatchmaker) RemoveParty ¶
func (m *LocalMatchmaker) RemoveParty(partyID, ticket string) error
func (*LocalMatchmaker) RemovePartyAll ¶
func (m *LocalMatchmaker) RemovePartyAll(partyID string) error
func (*LocalMatchmaker) RemoveSession ¶
func (m *LocalMatchmaker) RemoveSession(sessionID, ticket string) error
func (*LocalMatchmaker) RemoveSessionAll ¶
func (m *LocalMatchmaker) RemoveSessionAll(sessionID string) error
func (*LocalMatchmaker) Stop ¶
func (m *LocalMatchmaker) Stop()
type LocalMessageRouter ¶
type LocalMessageRouter struct {
// contains filtered or unexported fields
}
func (*LocalMessageRouter) SendDeferred ¶
func (r *LocalMessageRouter) SendDeferred(logger *zap.Logger, messages []*DeferredMessage)
func (*LocalMessageRouter) SendToPresenceIDs ¶
func (r *LocalMessageRouter) SendToPresenceIDs(logger *zap.Logger, presenceIDs []*PresenceID, envelope *rtapi.Envelope, reliable bool)
func (*LocalMessageRouter) SendToStream ¶
func (r *LocalMessageRouter) SendToStream(logger *zap.Logger, stream PresenceStream, envelope *rtapi.Envelope, reliable bool)
type LocalMetrics ¶ added in v3.6.0
type LocalMetrics struct { PrometheusScope tally.Scope // contains filtered or unexported fields }
func NewLocalMetrics ¶ added in v3.6.0
func (*LocalMetrics) ApiAfter ¶ added in v3.6.0
func (m *LocalMetrics) ApiAfter(name string, elapsed time.Duration, isErr bool)
func (*LocalMetrics) ApiBefore ¶ added in v3.6.0
func (m *LocalMetrics) ApiBefore(name string, elapsed time.Duration, isErr bool)
func (*LocalMetrics) CountDroppedEvents ¶ added in v3.6.0
func (m *LocalMetrics) CountDroppedEvents(delta int64)
Increment the number of dropped events.
func (*LocalMetrics) CountWebsocketClosed ¶ added in v3.6.0
func (m *LocalMetrics) CountWebsocketClosed(delta int64)
Increment the number of closed WS connections.
func (*LocalMetrics) CountWebsocketOpened ¶ added in v3.6.0
func (m *LocalMetrics) CountWebsocketOpened(delta int64)
Increment the number of opened WS connections.
func (*LocalMetrics) CustomCounter ¶ added in v3.6.0
func (m *LocalMetrics) CustomCounter(name string, tags map[string]string, delta int64)
CustomCounter adds the given delta to a counter with the specified name and tags.
func (*LocalMetrics) CustomGauge ¶ added in v3.6.0
func (m *LocalMetrics) CustomGauge(name string, tags map[string]string, value float64)
CustomGauge sets the given value to a gauge with the specified name and tags.
func (*LocalMetrics) CustomTimer ¶ added in v3.6.0
CustomTimer records the given value to a timer with the specified name and tags.
func (*LocalMetrics) GaugeAuthoritativeMatches ¶ added in v3.6.0
func (m *LocalMetrics) GaugeAuthoritativeMatches(value float64)
Set the absolute value of currently running authoritative matches.
func (*LocalMetrics) GaugeJsRuntimes ¶ added in v3.6.0
func (m *LocalMetrics) GaugeJsRuntimes(value float64)
Set the absolute value of currently allocated JavaScript runtime VMs.
func (*LocalMetrics) GaugeLuaRuntimes ¶ added in v3.6.0
func (m *LocalMetrics) GaugeLuaRuntimes(value float64)
Set the absolute value of currently allocated Lua runtime VMs.
func (*LocalMetrics) GaugePresences ¶ added in v3.6.0
func (m *LocalMetrics) GaugePresences(value float64)
Set the absolute value of currently tracked presences.
func (*LocalMetrics) GaugeRuntimes ¶ added in v3.6.0
func (m *LocalMetrics) GaugeRuntimes(value float64)
Set the absolute value of currently allocated Lua runtime VMs.
func (*LocalMetrics) GaugeSessions ¶ added in v3.6.0
func (m *LocalMetrics) GaugeSessions(value float64)
Set the absolute value of currently active sessions.
func (*LocalMetrics) Message ¶ added in v3.6.0
func (m *LocalMetrics) Message(recvBytes int64, isErr bool)
func (*LocalMetrics) MessageBytesSent ¶ added in v3.6.0
func (m *LocalMetrics) MessageBytesSent(sentBytes int64)
func (*LocalMetrics) PresenceEvent ¶ added in v3.6.0
func (m *LocalMetrics) PresenceEvent(dequeueElapsed, processElapsed time.Duration)
Count presence events and time their processing.
func (*LocalMetrics) SnapshotLatencyMs ¶ added in v3.6.0
func (m *LocalMetrics) SnapshotLatencyMs() float64
func (*LocalMetrics) SnapshotRateSec ¶ added in v3.6.0
func (m *LocalMetrics) SnapshotRateSec() float64
func (*LocalMetrics) SnapshotRecvKbSec ¶ added in v3.6.0
func (m *LocalMetrics) SnapshotRecvKbSec() float64
func (*LocalMetrics) SnapshotSentKbSec ¶ added in v3.6.0
func (m *LocalMetrics) SnapshotSentKbSec() float64
func (*LocalMetrics) Stop ¶ added in v3.6.0
func (m *LocalMetrics) Stop(logger *zap.Logger)
type LocalPartyRegistry ¶
type LocalPartyRegistry struct {
// contains filtered or unexported fields
}
func (*LocalPartyRegistry) Create ¶
func (p *LocalPartyRegistry) Create(open bool, maxSize int, presence *rtapi.UserPresence) *PartyHandler
func (*LocalPartyRegistry) Delete ¶
func (p *LocalPartyRegistry) Delete(id uuid.UUID)
func (*LocalPartyRegistry) Join ¶
func (p *LocalPartyRegistry) Join(id uuid.UUID, presences []*Presence)
func (*LocalPartyRegistry) Leave ¶
func (p *LocalPartyRegistry) Leave(id uuid.UUID, presences []*Presence)
func (*LocalPartyRegistry) PartyAccept ¶
func (p *LocalPartyRegistry) PartyAccept(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string, presence *rtapi.UserPresence) error
func (*LocalPartyRegistry) PartyClose ¶
func (*LocalPartyRegistry) PartyDataSend ¶
func (*LocalPartyRegistry) PartyJoinRequest ¶
func (*LocalPartyRegistry) PartyJoinRequestList ¶
func (p *LocalPartyRegistry) PartyJoinRequestList(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string) ([]*rtapi.UserPresence, error)
func (*LocalPartyRegistry) PartyMatchmakerAdd ¶
func (*LocalPartyRegistry) PartyMatchmakerRemove ¶
func (*LocalPartyRegistry) PartyPromote ¶
func (p *LocalPartyRegistry) PartyPromote(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string, presence *rtapi.UserPresence) error
func (*LocalPartyRegistry) PartyRemove ¶
func (p *LocalPartyRegistry) PartyRemove(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string, presence *rtapi.UserPresence) error
type LocalSessionCache ¶ added in v3.2.0
func (*LocalSessionCache) Ban ¶ added in v3.2.0
func (s *LocalSessionCache) Ban(userIDs []uuid.UUID)
func (*LocalSessionCache) IsValidRefresh ¶ added in v3.2.0
func (*LocalSessionCache) IsValidSession ¶ added in v3.2.0
func (*LocalSessionCache) RemoveAll ¶ added in v3.2.0
func (s *LocalSessionCache) RemoveAll(userID uuid.UUID)
func (*LocalSessionCache) Stop ¶ added in v3.2.0
func (s *LocalSessionCache) Stop()
func (*LocalSessionCache) Unban ¶ added in v3.2.0
func (s *LocalSessionCache) Unban(userIDs []uuid.UUID)
type LocalSessionRegistry ¶
type LocalSessionRegistry struct {
// contains filtered or unexported fields
}
func (*LocalSessionRegistry) Add ¶
func (r *LocalSessionRegistry) Add(session Session)
func (*LocalSessionRegistry) Count ¶
func (r *LocalSessionRegistry) Count() int
func (*LocalSessionRegistry) Disconnect ¶
func (r *LocalSessionRegistry) Disconnect(ctx context.Context, sessionID uuid.UUID, reason ...runtime.PresenceReason) error
func (*LocalSessionRegistry) Remove ¶
func (r *LocalSessionRegistry) Remove(sessionID uuid.UUID)
func (*LocalSessionRegistry) SingleSession ¶ added in v3.7.0
func (*LocalSessionRegistry) Stop ¶
func (r *LocalSessionRegistry) Stop()
type LocalStatusHandler ¶
type LocalStatusHandler struct {
// contains filtered or unexported fields
}
func (*LocalStatusHandler) GetStatus ¶
func (s *LocalStatusHandler) GetStatus(ctx context.Context) ([]*console.StatusList_Status, error)
type LocalStreamManager ¶
type LocalStreamManager struct {
// contains filtered or unexported fields
}
func (*LocalStreamManager) UserJoin ¶
func (m *LocalStreamManager) UserJoin(stream PresenceStream, userID, sessionID uuid.UUID, hidden, persistence bool, status string) (bool, bool, error)
func (*LocalStreamManager) UserLeave ¶
func (m *LocalStreamManager) UserLeave(stream PresenceStream, userID, sessionID uuid.UUID) error
func (*LocalStreamManager) UserUpdate ¶
func (m *LocalStreamManager) UserUpdate(stream PresenceStream, userID, sessionID uuid.UUID, hidden, persistence bool, status string) (bool, error)
type LocalTracker ¶
func (*LocalTracker) Count ¶
func (t *LocalTracker) Count() int
func (*LocalTracker) CountByStream ¶
func (t *LocalTracker) CountByStream(stream PresenceStream) int
func (*LocalTracker) CountByStreamModeFilter ¶
func (t *LocalTracker) CountByStreamModeFilter(modes map[uint8]*uint8) map[*PresenceStream]int32
func (*LocalTracker) GetBySessionIDStreamUserID ¶
func (t *LocalTracker) GetBySessionIDStreamUserID(node string, sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID) *PresenceMeta
func (*LocalTracker) GetLocalBySessionIDStreamUserID ¶
func (t *LocalTracker) GetLocalBySessionIDStreamUserID(sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID) *PresenceMeta
func (*LocalTracker) ListByStream ¶
func (t *LocalTracker) ListByStream(stream PresenceStream, includeHidden bool, includeNotHidden bool) []*Presence
func (*LocalTracker) ListLocalSessionIDByStream ¶
func (t *LocalTracker) ListLocalSessionIDByStream(stream PresenceStream) []uuid.UUID
func (*LocalTracker) ListNodesForStream ¶
func (t *LocalTracker) ListNodesForStream(stream PresenceStream) map[string]struct{}
func (*LocalTracker) ListPresenceIDByStream ¶
func (t *LocalTracker) ListPresenceIDByStream(stream PresenceStream) []*PresenceID
func (*LocalTracker) SetMatchJoinListener ¶
func (t *LocalTracker) SetMatchJoinListener(f func(id uuid.UUID, joins []*MatchPresence))
func (*LocalTracker) SetMatchLeaveListener ¶
func (t *LocalTracker) SetMatchLeaveListener(f func(id uuid.UUID, leaves []*MatchPresence))
func (*LocalTracker) SetPartyJoinListener ¶
func (t *LocalTracker) SetPartyJoinListener(f func(id uuid.UUID, joins []*Presence))
func (*LocalTracker) SetPartyLeaveListener ¶
func (t *LocalTracker) SetPartyLeaveListener(f func(id uuid.UUID, leaves []*Presence))
func (*LocalTracker) Stop ¶
func (t *LocalTracker) Stop()
func (*LocalTracker) StreamExists ¶
func (t *LocalTracker) StreamExists(stream PresenceStream) bool
func (*LocalTracker) Track ¶
func (t *LocalTracker) Track(ctx context.Context, sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID, meta PresenceMeta, allowIfFirstForSession bool) (bool, bool)
func (*LocalTracker) TrackMulti ¶ added in v3.1.0
func (*LocalTracker) Untrack ¶
func (t *LocalTracker) Untrack(sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID)
func (*LocalTracker) UntrackAll ¶
func (t *LocalTracker) UntrackAll(sessionID uuid.UUID, reason runtime.PresenceReason)
func (*LocalTracker) UntrackByStream ¶
func (t *LocalTracker) UntrackByStream(stream PresenceStream)
func (*LocalTracker) UntrackLocalByModes ¶ added in v3.7.0
func (t *LocalTracker) UntrackLocalByModes(sessionID uuid.UUID, modes map[uint8]struct{}, skipStream PresenceStream)
func (*LocalTracker) UntrackLocalByStream ¶
func (t *LocalTracker) UntrackLocalByStream(stream PresenceStream)
func (*LocalTracker) UntrackMulti ¶ added in v3.1.0
func (t *LocalTracker) UntrackMulti(sessionID uuid.UUID, streams []*PresenceStream, userID uuid.UUID)
func (*LocalTracker) Update ¶
func (t *LocalTracker) Update(ctx context.Context, sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID, meta PresenceMeta, allowIfFirstForSession bool) bool
type LoggerConfig ¶
type LoggerConfig struct { Level string `yaml:"level" json:"level" usage:"Log level to set. Valid values are 'debug', 'info', 'warn', 'error'. Default 'info'."` Stdout bool `yaml:"stdout" json:"stdout" usage:"Log to standard console output (as well as to a file if set). Default true."` File string `` /* 135-byte string literal not displayed */ Rotation bool `yaml:"rotation" json:"rotation" usage:"Rotate log files. Default is false."` // Reference: https://godoc.org/gopkg.in/natefinch/lumberjack.v2 MaxSize int `` /* 139-byte string literal not displayed */ MaxAge int `` /* 195-byte string literal not displayed */ MaxBackups int `` /* 188-byte string literal not displayed */ LocalTime bool `` /* 184-byte string literal not displayed */ Compress bool `yaml:"compress" json:"compress" usage:"This determines if the rotated log files should be compressed using gzip."` Format string `yaml:"format" json:"format" usage:"Set logging output format. Can either be 'JSON' or 'Stackdriver'. Default is 'JSON'."` }
LoggerConfig is configuration relevant to logging levels and output.
func NewLoggerConfig ¶
func NewLoggerConfig() *LoggerConfig
NewLoggerConfig creates a new LoggerConfig struct.
type LoggingFormat ¶
type LoggingFormat int8
const ( JSONFormat LoggingFormat = iota - 1 StackdriverFormat )
type MatchConfig ¶
type MatchConfig struct { InputQueueSize int `` /* 181-byte string literal not displayed */ CallQueueSize int `` /* 176-byte string literal not displayed */ SignalQueueSize int `` /* 191-byte string literal not displayed */ JoinAttemptQueueSize int `` /* 174-byte string literal not displayed */ DeferredQueueSize int `` /* 190-byte string literal not displayed */ JoinMarkerDeadlineMs int `` /* 198-byte string literal not displayed */ MaxEmptySec int `` /* 198-byte string literal not displayed */ LabelUpdateIntervalMs int `` /* 150-byte string literal not displayed */ }
MatchConfig is configuration relevant to authoritative realtime multiplayer matches.
func NewMatchConfig ¶
func NewMatchConfig() *MatchConfig
NewMatchConfig creates a new MatchConfig struct.
type MatchDataMessage ¶
type MatchDataMessage struct { UserID uuid.UUID SessionID uuid.UUID Username string Node string OpCode int64 Data []byte Reliable bool ReceiveTime int64 }
func (*MatchDataMessage) GetData ¶
func (m *MatchDataMessage) GetData() []byte
func (*MatchDataMessage) GetHidden ¶
func (m *MatchDataMessage) GetHidden() bool
func (*MatchDataMessage) GetNodeId ¶
func (m *MatchDataMessage) GetNodeId() string
func (*MatchDataMessage) GetOpCode ¶
func (m *MatchDataMessage) GetOpCode() int64
func (*MatchDataMessage) GetPersistence ¶
func (m *MatchDataMessage) GetPersistence() bool
func (*MatchDataMessage) GetReason ¶ added in v3.2.0
func (m *MatchDataMessage) GetReason() runtime.PresenceReason
func (*MatchDataMessage) GetReceiveTime ¶
func (m *MatchDataMessage) GetReceiveTime() int64
func (*MatchDataMessage) GetReliable ¶
func (m *MatchDataMessage) GetReliable() bool
func (*MatchDataMessage) GetSessionId ¶
func (m *MatchDataMessage) GetSessionId() string
func (*MatchDataMessage) GetStatus ¶
func (m *MatchDataMessage) GetStatus() string
func (*MatchDataMessage) GetUserId ¶
func (m *MatchDataMessage) GetUserId() string
func (*MatchDataMessage) GetUsername ¶
func (m *MatchDataMessage) GetUsername() string
type MatchGetStateResult ¶
type MatchGetStateResult struct { Error error Presences []*MatchPresence Tick int64 State string }
type MatchHandler ¶
type MatchHandler struct { JoinMarkerList *MatchJoinMarkerList PresenceList *MatchPresenceList Core RuntimeMatchCore // Identification not (directly) controlled by match init. ID uuid.UUID Node string IDStr string Stream PresenceStream // Configuration set by match init. Rate int64 // contains filtered or unexported fields }
func NewMatchHandler ¶
func NewMatchHandler(logger *zap.Logger, config Config, sessionRegistry SessionRegistry, matchRegistry MatchRegistry, router MessageRouter, core RuntimeMatchCore, id uuid.UUID, node string, stopped *atomic.Bool, params map[string]interface{}) (*MatchHandler, error)
func (*MatchHandler) CreateTime ¶ added in v3.1.2
func (mh *MatchHandler) CreateTime() int64
func (*MatchHandler) HandlerName ¶ added in v3.1.2
func (mh *MatchHandler) HandlerName() string
func (*MatchHandler) Label ¶
func (mh *MatchHandler) Label() string
func (*MatchHandler) QueueData ¶
func (mh *MatchHandler) QueueData(m *MatchDataMessage)
func (*MatchHandler) QueueGetState ¶
func (mh *MatchHandler) QueueGetState(ctx context.Context, resultCh chan<- *MatchGetStateResult) bool
func (*MatchHandler) QueueJoin ¶
func (mh *MatchHandler) QueueJoin(joins []*MatchPresence, mark bool) bool
func (*MatchHandler) QueueJoinAttempt ¶
func (*MatchHandler) QueueLeave ¶
func (mh *MatchHandler) QueueLeave(leaves []*MatchPresence) bool
func (*MatchHandler) QueueSignal ¶ added in v3.8.0
func (mh *MatchHandler) QueueSignal(ctx context.Context, resultCh chan<- *MatchSignalResult, data string) bool
func (*MatchHandler) QueueTerminate ¶
func (mh *MatchHandler) QueueTerminate(graceSeconds int) bool
func (*MatchHandler) Stop ¶
func (mh *MatchHandler) Stop()
Stop the match handler and clean up all its resources.
func (*MatchHandler) TickRate ¶ added in v3.1.2
func (mh *MatchHandler) TickRate() int
type MatchIndexEntry ¶
type MatchJoinAttemptResult ¶ added in v3.8.0
type MatchJoinMarker ¶
type MatchJoinMarker struct {
// contains filtered or unexported fields
}
Used to monitor when match presences begin and complete their match join process.
type MatchJoinMarkerList ¶
func NewMatchJoinMarkerList ¶
func NewMatchJoinMarkerList(config Config, tickRate int64) *MatchJoinMarkerList
func (*MatchJoinMarkerList) Add ¶
func (m *MatchJoinMarkerList) Add(presence *MatchPresence, currentTick int64)
func (*MatchJoinMarkerList) ClearExpired ¶
func (m *MatchJoinMarkerList) ClearExpired(tick int64) []*MatchPresence
func (*MatchJoinMarkerList) Mark ¶
func (m *MatchJoinMarkerList) Mark(sessionID uuid.UUID)
type MatchNamesListFunction ¶
type MatchNamesListFunction func() []string
type MatchPresence ¶
type MatchPresence struct { Node string UserID uuid.UUID SessionID uuid.UUID Username string Reason runtime.PresenceReason }
Represents routing and identify information for a single match participant.
func (*MatchPresence) GetHidden ¶
func (p *MatchPresence) GetHidden() bool
func (*MatchPresence) GetNodeId ¶
func (p *MatchPresence) GetNodeId() string
func (*MatchPresence) GetPersistence ¶
func (p *MatchPresence) GetPersistence() bool
func (*MatchPresence) GetReason ¶ added in v3.2.0
func (p *MatchPresence) GetReason() runtime.PresenceReason
func (*MatchPresence) GetSessionId ¶
func (p *MatchPresence) GetSessionId() string
func (*MatchPresence) GetStatus ¶
func (p *MatchPresence) GetStatus() string
func (*MatchPresence) GetUserId ¶
func (p *MatchPresence) GetUserId() string
func (*MatchPresence) GetUsername ¶
func (p *MatchPresence) GetUsername() string
type MatchPresenceList ¶
Maintains the match presences for routing and validation purposes.
func NewMatchPresenceList ¶
func NewMatchPresenceList() *MatchPresenceList
func (*MatchPresenceList) Contains ¶
func (m *MatchPresenceList) Contains(presence *PresenceID) bool
func (*MatchPresenceList) FilterPresenceIDs ¶ added in v3.1.0
func (m *MatchPresenceList) FilterPresenceIDs(ids []*PresenceID) []*PresenceID
func (*MatchPresenceList) Join ¶
func (m *MatchPresenceList) Join(joins []*MatchPresence) []*MatchPresence
func (*MatchPresenceList) Leave ¶
func (m *MatchPresenceList) Leave(leaves []*MatchPresence) []*MatchPresence
func (*MatchPresenceList) ListPresenceIDs ¶
func (m *MatchPresenceList) ListPresenceIDs() []*PresenceID
func (*MatchPresenceList) ListPresences ¶
func (m *MatchPresenceList) ListPresences() []*MatchPresence
func (*MatchPresenceList) Size ¶
func (m *MatchPresenceList) Size() int
type MatchPresenceListItem ¶
type MatchPresenceListItem struct { PresenceID *PresenceID Presence *MatchPresence }
type MatchProvider ¶
func NewMatchProvider ¶
func NewMatchProvider() *MatchProvider
func (*MatchProvider) CreateMatch ¶
func (*MatchProvider) RegisterCreateFn ¶
func (mp *MatchProvider) RegisterCreateFn(name string, fn RuntimeMatchCreateFunction)
type MatchRegistry ¶
type MatchRegistry interface { // Create and start a new match, given a Lua module name or registered Go match function. CreateMatch(ctx context.Context, logger *zap.Logger, createFn RuntimeMatchCreateFunction, module string, params map[string]interface{}) (string, error) // Register and initialise a match that's ready to run. NewMatch(logger *zap.Logger, id uuid.UUID, core RuntimeMatchCore, stopped *atomic.Bool, params map[string]interface{}) (*MatchHandler, error) // Return a match by ID. GetMatch(ctx context.Context, id string) (*api.Match, error) // Remove a tracked match and ensure all its presences are cleaned up. // Does not ensure the match process itself is no longer running, that must be handled separately. RemoveMatch(id uuid.UUID, stream PresenceStream) // Update the label entry for a given match. UpdateMatchLabel(id uuid.UUID, tickRate int, handlerName, label string, createTime int64) error // List (and optionally filter) currently running matches. // This can list across both authoritative and relayed matches. ListMatches(ctx context.Context, limit int, authoritative *wrapperspb.BoolValue, label *wrapperspb.StringValue, minSize *wrapperspb.Int32Value, maxSize *wrapperspb.Int32Value, query *wrapperspb.StringValue) ([]*api.Match, error) // Stop the match registry and close all matches it's tracking. Stop(graceSeconds int) chan struct{} // Returns the total number of currently active authoritative matches. Count() int // Pass a user join attempt to a match handler. Returns if the match was found, if the join was accepted, if it's a new user for this match, a reason for any rejection, the match label, and the list of existing match participants. JoinAttempt(ctx context.Context, id uuid.UUID, node string, userID, sessionID uuid.UUID, username string, sessionExpiry int64, vars map[string]string, clientIP, clientPort, fromNode string, metadata map[string]string) (bool, bool, bool, string, string, []*MatchPresence) // Notify a match handler that one or more users have successfully joined the match. // Expects that the caller has already determined the match is hosted on the current node. Join(id uuid.UUID, presences []*MatchPresence) // Notify a match handler that one or more users have left or disconnected. // Expects that the caller has already determined the match is hosted on the current node. Leave(id uuid.UUID, presences []*MatchPresence) // Called by match handlers to request the removal fo a match participant. Kick(stream PresenceStream, presences []*MatchPresence) // Pass a data payload (usually from a user) to the appropriate match handler. // Assumes that the data sender has already been validated as a match participant before this call. SendData(id uuid.UUID, node string, userID, sessionID uuid.UUID, username, fromNode string, opCode int64, data []byte, reliable bool, receiveTime int64) // Signal a match and wait for a response from its arbitrary signal handler function. Signal(ctx context.Context, id, data string) (string, error) // Get a snapshot of the match state in a string representation. GetState(ctx context.Context, id uuid.UUID, node string) ([]*rtapi.UserPresence, int64, string, error) }
func NewLocalMatchRegistry ¶
func NewLocalMatchRegistry(logger, startupLogger *zap.Logger, config Config, sessionRegistry SessionRegistry, tracker Tracker, router MessageRouter, metrics Metrics, node string) MatchRegistry
type MatchSignalResult ¶ added in v3.8.0
type Matchmaker ¶
type Matchmaker interface { Stop() Add(presences []*MatchmakerPresence, sessionID, partyId, query string, minCount, maxCount int, stringProperties map[string]string, numericProperties map[string]float64) (string, error) RemoveSession(sessionID, ticket string) error RemoveSessionAll(sessionID string) error RemoveParty(partyID, ticket string) error RemovePartyAll(partyID string) error }
func NewLocalMatchmaker ¶
func NewLocalMatchmaker(logger, startupLogger *zap.Logger, config Config, router MessageRouter, runtime *Runtime) Matchmaker
type MatchmakerConfig ¶
type MatchmakerConfig struct { MaxTickets int `` /* 135-byte string literal not displayed */ IntervalSec int `yaml:"interval_sec" json:"interval_sec" usage:"How quickly the matchmaker attempts to form matches, in seconds. Default 15."` MaxIntervals int `` /* 171-byte string literal not displayed */ BatchPoolSize int `yaml:"batch_pool_size" json:"batch_pool_size" usage:"Number of concurrent indexing batches that will be allocated."` }
func NewMatchmakerConfig ¶
func NewMatchmakerConfig() *MatchmakerConfig
type MatchmakerEntry ¶
type MatchmakerEntry struct { Ticket string `json:"ticket"` Presence *MatchmakerPresence `json:"presence"` Properties map[string]interface{} `json:"properties"` PartyId string `json:"party_id"` StringProperties map[string]string `json:"-"` NumericProperties map[string]float64 `json:"-"` }
func (*MatchmakerEntry) GetPartyId ¶
func (m *MatchmakerEntry) GetPartyId() string
func (*MatchmakerEntry) GetPresence ¶
func (m *MatchmakerEntry) GetPresence() runtime.Presence
func (*MatchmakerEntry) GetProperties ¶
func (m *MatchmakerEntry) GetProperties() map[string]interface{}
func (*MatchmakerEntry) GetTicket ¶
func (m *MatchmakerEntry) GetTicket() string
type MatchmakerIndex ¶
type MatchmakerIndex struct { Ticket string `json:"ticket"` Properties map[string]interface{} `json:"properties"` MinCount int `json:"min_count"` MaxCount int `json:"max_count"` PartyId string `json:"party_id"` CreatedAt int64 `json:"created_at"` // Parameters used for correctly processing various matchmaker operations, but not indexed for searching. Query string `json:"-"` Count int `json:"-"` SessionID string `json:"-"` Intervals int `json:"-"` SessionIDs map[string]struct{} `json:"-"` }
type MatchmakerPresence ¶
type MatchmakerPresence struct { UserId string `json:"user_id"` SessionId string `json:"session_id"` Username string `json:"username"` Node string `json:"node"` SessionID uuid.UUID `json:"-"` }
func (*MatchmakerPresence) GetHidden ¶
func (p *MatchmakerPresence) GetHidden() bool
func (*MatchmakerPresence) GetNodeId ¶
func (p *MatchmakerPresence) GetNodeId() string
func (*MatchmakerPresence) GetPersistence ¶
func (p *MatchmakerPresence) GetPersistence() bool
func (*MatchmakerPresence) GetReason ¶ added in v3.2.0
func (p *MatchmakerPresence) GetReason() runtime.PresenceReason
func (*MatchmakerPresence) GetSessionId ¶
func (p *MatchmakerPresence) GetSessionId() string
func (*MatchmakerPresence) GetStatus ¶
func (p *MatchmakerPresence) GetStatus() string
func (*MatchmakerPresence) GetUserId ¶
func (p *MatchmakerPresence) GetUserId() string
func (*MatchmakerPresence) GetUsername ¶
func (p *MatchmakerPresence) GetUsername() string
type MessageRouter ¶
type MessageRouter interface { SendToPresenceIDs(*zap.Logger, []*PresenceID, *rtapi.Envelope, bool) SendToStream(*zap.Logger, PresenceStream, *rtapi.Envelope, bool) SendDeferred(*zap.Logger, []*DeferredMessage) }
MessageRouter is responsible for sending a message to a list of presences or to an entire stream.
func NewLocalMessageRouter ¶
func NewLocalMessageRouter(sessionRegistry SessionRegistry, tracker Tracker, protojsonMarshaler *protojson.MarshalOptions) MessageRouter
type MethodName ¶
type MethodName string
type Metrics ¶
type Metrics interface { Stop(logger *zap.Logger) SnapshotLatencyMs() float64 SnapshotRateSec() float64 SnapshotRecvKbSec() float64 SnapshotSentKbSec() float64 Api(name string, elapsed time.Duration, recvBytes, sentBytes int64, isErr bool) ApiBefore(name string, elapsed time.Duration, isErr bool) ApiAfter(name string, elapsed time.Duration, isErr bool) Message(recvBytes int64, isErr bool) MessageBytesSent(sentBytes int64) GaugeRuntimes(value float64) GaugeLuaRuntimes(value float64) GaugeJsRuntimes(value float64) GaugeAuthoritativeMatches(value float64) CountDroppedEvents(delta int64) CountWebsocketOpened(delta int64) CountWebsocketClosed(delta int64) GaugeSessions(value float64) GaugePresences(value float64) PresenceEvent(dequeueElapsed, processElapsed time.Duration) CustomCounter(name string, tags map[string]string, delta int64) CustomGauge(name string, tags map[string]string, value float64) CustomTimer(name string, tags map[string]string, value time.Duration) }
type MetricsConfig ¶
type MetricsConfig struct { ReportingFreqSec int `yaml:"reporting_freq_sec" json:"reporting_freq_sec" usage:"Frequency of metrics exports. Default is 60 seconds."` Namespace string `yaml:"namespace" json:"namespace" usage:"Namespace for Prometheus metrics. It will always prepend node name."` PrometheusPort int `yaml:"prometheus_port" json:"prometheus_port" usage:"Port to expose Prometheus. If '0' Prometheus exports are disabled."` Prefix string `yaml:"prefix" json:"prefix" usage:"Prefix for metric names. Default is 'nakama', empty string '' disables the prefix."` CustomPrefix string `` /* 147-byte string literal not displayed */ }
MetricsConfig is configuration relevant to metrics capturing and output.
func NewMetricsConfig ¶
func NewMetricsConfig() *MetricsConfig
NewMetricsConfig creates a new MatricsConfig struct.
type MetricsGrpcHandler ¶
type MetricsGrpcHandler struct {
MetricsFn func(name string, elapsed time.Duration, recvBytes, sentBytes int64, isErr bool)
}
func (*MetricsGrpcHandler) HandleConn ¶
func (m *MetricsGrpcHandler) HandleConn(context.Context, stats.ConnStats)
HandleConn processes the Conn stats.
func (*MetricsGrpcHandler) HandleRPC ¶
func (m *MetricsGrpcHandler) HandleRPC(ctx context.Context, rs stats.RPCStats)
HandleRPC processes the RPC stats.
func (*MetricsGrpcHandler) TagConn ¶
func (m *MetricsGrpcHandler) TagConn(ctx context.Context, _ *stats.ConnTagInfo) context.Context
TagConn can attach some information to the given context. The returned context will be used for stats handling. For conn stats handling, the context used in HandleConn for this connection will be derived from the context returned. For RPC stats handling,
- On server side, the context used in HandleRPC for all RPCs on this
connection will be derived from the context returned.
- On client side, the context is not derived from the context returned.
func (*MetricsGrpcHandler) TagRPC ¶
func (m *MetricsGrpcHandler) TagRPC(ctx context.Context, info *stats.RPCTagInfo) context.Context
TagRPC can attach some information to the given context. The context used for the rest lifetime of the RPC will be derived from the returned context.
type OrderedTournaments ¶
type OrderedTournaments []*Leaderboard
Type alias for a list of tournaments that binds together sorting functions. Not intended to be used for sorting lists of non-tournament leaderboards.
func (OrderedTournaments) Len ¶
func (t OrderedTournaments) Len() int
func (OrderedTournaments) Less ¶
func (t OrderedTournaments) Less(i, j int) bool
func (OrderedTournaments) Swap ¶
func (t OrderedTournaments) Swap(i, j int)
type PartyHandler ¶
type PartyHandler struct { sync.RWMutex ID uuid.UUID Node string IDStr string Open bool MaxSize int Stream PresenceStream // contains filtered or unexported fields }
func NewPartyHandler ¶
func NewPartyHandler(logger *zap.Logger, partyRegistry PartyRegistry, matchmaker Matchmaker, tracker Tracker, streamManager StreamManager, router MessageRouter, id uuid.UUID, node string, open bool, maxSize int, presence *rtapi.UserPresence) *PartyHandler
func (*PartyHandler) Accept ¶
func (p *PartyHandler) Accept(sessionID, node string, presence *rtapi.UserPresence) error
func (*PartyHandler) Close ¶
func (p *PartyHandler) Close(sessionID, node string) error
func (*PartyHandler) DataSend ¶
func (p *PartyHandler) DataSend(sessionID, node string, opCode int64, data []byte) error
func (*PartyHandler) Join ¶
func (p *PartyHandler) Join(presences []*Presence)
func (*PartyHandler) JoinRequest ¶
func (p *PartyHandler) JoinRequest(presence *Presence) (bool, error)
func (*PartyHandler) JoinRequestList ¶
func (p *PartyHandler) JoinRequestList(sessionID, node string) ([]*rtapi.UserPresence, error)
func (*PartyHandler) Leave ¶
func (p *PartyHandler) Leave(presences []*Presence)
func (*PartyHandler) MatchmakerAdd ¶
func (p *PartyHandler) MatchmakerAdd(sessionID, node, query string, minCount, maxCount int, stringProperties map[string]string, numericProperties map[string]float64) (string, []*PresenceID, error)
func (*PartyHandler) MatchmakerRemove ¶
func (p *PartyHandler) MatchmakerRemove(sessionID, node, ticket string) error
func (*PartyHandler) Promote ¶
func (p *PartyHandler) Promote(sessionID, node string, presence *rtapi.UserPresence) error
func (*PartyHandler) Remove ¶
func (p *PartyHandler) Remove(sessionID, node string, presence *rtapi.UserPresence) error
type PartyRegistry ¶
type PartyRegistry interface { Create(open bool, maxSize int, leader *rtapi.UserPresence) *PartyHandler Delete(id uuid.UUID) Join(id uuid.UUID, presences []*Presence) Leave(id uuid.UUID, presences []*Presence) PartyJoinRequest(ctx context.Context, id uuid.UUID, node string, presence *Presence) (bool, error) PartyPromote(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string, presence *rtapi.UserPresence) error PartyAccept(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string, presence *rtapi.UserPresence) error PartyRemove(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string, presence *rtapi.UserPresence) error PartyClose(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string) error PartyJoinRequestList(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string) ([]*rtapi.UserPresence, error) PartyMatchmakerAdd(ctx context.Context, id uuid.UUID, node, sessionID, fromNode, query string, minCount, maxCount int, stringProperties map[string]string, numericProperties map[string]float64) (string, []*PresenceID, error) PartyMatchmakerRemove(ctx context.Context, id uuid.UUID, node, sessionID, fromNode, ticket string) error PartyDataSend(ctx context.Context, id uuid.UUID, node, sessionID, fromNode string, opCode int64, data []byte) error }
func NewLocalPartyRegistry ¶
func NewLocalPartyRegistry(logger *zap.Logger, matchmaker Matchmaker, tracker Tracker, streamManager StreamManager, router MessageRouter, node string) PartyRegistry
type Pipeline ¶
type Pipeline struct {
// contains filtered or unexported fields
}
func NewPipeline ¶
func NewPipeline(logger *zap.Logger, config Config, db *sql.DB, protojsonMarshaler *protojson.MarshalOptions, protojsonUnmarshaler *protojson.UnmarshalOptions, sessionRegistry SessionRegistry, statusRegistry *StatusRegistry, matchRegistry MatchRegistry, partyRegistry PartyRegistry, matchmaker Matchmaker, tracker Tracker, router MessageRouter, runtime *Runtime) *Pipeline
type Presence ¶
type Presence struct { ID PresenceID Stream PresenceStream UserID uuid.UUID Meta PresenceMeta }
func (*Presence) GetPersistence ¶
func (*Presence) GetReason ¶ added in v3.2.0
func (p *Presence) GetReason() runtime.PresenceReason
func (*Presence) GetSessionId ¶
func (*Presence) GetUsername ¶
type PresenceEvent ¶
type PresenceID ¶
type PresenceMeta ¶
type PresenceMeta struct { Format SessionFormat Hidden bool Persistence bool Username string Status string Reason uint32 }
func (*PresenceMeta) GetHidden ¶
func (pm *PresenceMeta) GetHidden() bool
func (*PresenceMeta) GetPersistence ¶
func (pm *PresenceMeta) GetPersistence() bool
func (*PresenceMeta) GetReason ¶ added in v3.2.0
func (pm *PresenceMeta) GetReason() runtime.PresenceReason
func (*PresenceMeta) GetStatus ¶
func (pm *PresenceMeta) GetStatus() string
func (*PresenceMeta) GetUsername ¶
func (pm *PresenceMeta) GetUsername() string
type PresenceStream ¶
type RedirectStdLogWriter ¶ added in v3.4.0
type RedirectStdLogWriter struct {
// contains filtered or unexported fields
}
type Runtime ¶
type Runtime struct {
// contains filtered or unexported fields
}
func (*Runtime) AfterAddFriends ¶
func (r *Runtime) AfterAddFriends() RuntimeAfterAddFriendsFunction
func (*Runtime) AfterAddGroupUsers ¶
func (r *Runtime) AfterAddGroupUsers() RuntimeAfterAddGroupUsersFunction
func (*Runtime) AfterAuthenticateApple ¶
func (r *Runtime) AfterAuthenticateApple() RuntimeAfterAuthenticateAppleFunction
func (*Runtime) AfterAuthenticateCustom ¶
func (r *Runtime) AfterAuthenticateCustom() RuntimeAfterAuthenticateCustomFunction
func (*Runtime) AfterAuthenticateDevice ¶
func (r *Runtime) AfterAuthenticateDevice() RuntimeAfterAuthenticateDeviceFunction
func (*Runtime) AfterAuthenticateEmail ¶
func (r *Runtime) AfterAuthenticateEmail() RuntimeAfterAuthenticateEmailFunction
func (*Runtime) AfterAuthenticateFacebook ¶
func (r *Runtime) AfterAuthenticateFacebook() RuntimeAfterAuthenticateFacebookFunction
func (*Runtime) AfterAuthenticateFacebookInstantGame ¶
func (r *Runtime) AfterAuthenticateFacebookInstantGame() RuntimeAfterAuthenticateFacebookInstantGameFunction
func (*Runtime) AfterAuthenticateGameCenter ¶
func (r *Runtime) AfterAuthenticateGameCenter() RuntimeAfterAuthenticateGameCenterFunction
func (*Runtime) AfterAuthenticateGoogle ¶
func (r *Runtime) AfterAuthenticateGoogle() RuntimeAfterAuthenticateGoogleFunction
func (*Runtime) AfterAuthenticateSteam ¶
func (r *Runtime) AfterAuthenticateSteam() RuntimeAfterAuthenticateSteamFunction
func (*Runtime) AfterBanGroupUsers ¶
func (r *Runtime) AfterBanGroupUsers() RuntimeAfterBanGroupUsersFunction
func (*Runtime) AfterBlockFriends ¶
func (r *Runtime) AfterBlockFriends() RuntimeAfterBlockFriendsFunction
func (*Runtime) AfterCreateGroup ¶
func (r *Runtime) AfterCreateGroup() RuntimeAfterCreateGroupFunction
func (*Runtime) AfterDeleteFriends ¶
func (r *Runtime) AfterDeleteFriends() RuntimeAfterDeleteFriendsFunction
func (*Runtime) AfterDeleteGroup ¶
func (r *Runtime) AfterDeleteGroup() RuntimeAfterDeleteGroupFunction
func (*Runtime) AfterDeleteLeaderboardRecord ¶
func (r *Runtime) AfterDeleteLeaderboardRecord() RuntimeAfterDeleteLeaderboardRecordFunction
func (*Runtime) AfterDeleteNotification ¶
func (r *Runtime) AfterDeleteNotification() RuntimeAfterDeleteNotificationFunction
func (*Runtime) AfterDeleteStorageObjects ¶
func (r *Runtime) AfterDeleteStorageObjects() RuntimeAfterDeleteStorageObjectsFunction
func (*Runtime) AfterDemoteGroupUsers ¶
func (r *Runtime) AfterDemoteGroupUsers() RuntimeAfterDemoteGroupUsersFunction
func (*Runtime) AfterEvent ¶
func (r *Runtime) AfterEvent() RuntimeAfterEventFunction
func (*Runtime) AfterGetAccount ¶
func (r *Runtime) AfterGetAccount() RuntimeAfterGetAccountFunction
func (*Runtime) AfterGetUsers ¶
func (r *Runtime) AfterGetUsers() RuntimeAfterGetUsersFunction
func (*Runtime) AfterImportFacebookFriends ¶
func (r *Runtime) AfterImportFacebookFriends() RuntimeAfterImportFacebookFriendsFunction
func (*Runtime) AfterImportSteamFriends ¶ added in v3.1.0
func (r *Runtime) AfterImportSteamFriends() RuntimeAfterImportSteamFriendsFunction
func (*Runtime) AfterJoinGroup ¶
func (r *Runtime) AfterJoinGroup() RuntimeAfterJoinGroupFunction
func (*Runtime) AfterJoinTournament ¶
func (r *Runtime) AfterJoinTournament() RuntimeAfterJoinTournamentFunction
func (*Runtime) AfterKickGroupUsers ¶
func (r *Runtime) AfterKickGroupUsers() RuntimeAfterKickGroupUsersFunction
func (*Runtime) AfterLeaveGroup ¶
func (r *Runtime) AfterLeaveGroup() RuntimeAfterLeaveGroupFunction
func (*Runtime) AfterLinkApple ¶
func (r *Runtime) AfterLinkApple() RuntimeAfterLinkAppleFunction
func (*Runtime) AfterLinkCustom ¶
func (r *Runtime) AfterLinkCustom() RuntimeAfterLinkCustomFunction
func (*Runtime) AfterLinkDevice ¶
func (r *Runtime) AfterLinkDevice() RuntimeAfterLinkDeviceFunction
func (*Runtime) AfterLinkEmail ¶
func (r *Runtime) AfterLinkEmail() RuntimeAfterLinkEmailFunction
func (*Runtime) AfterLinkFacebook ¶
func (r *Runtime) AfterLinkFacebook() RuntimeAfterLinkFacebookFunction
func (*Runtime) AfterLinkFacebookInstantGame ¶
func (r *Runtime) AfterLinkFacebookInstantGame() RuntimeAfterLinkFacebookInstantGameFunction
func (*Runtime) AfterLinkGameCenter ¶
func (r *Runtime) AfterLinkGameCenter() RuntimeAfterLinkGameCenterFunction
func (*Runtime) AfterLinkGoogle ¶
func (r *Runtime) AfterLinkGoogle() RuntimeAfterLinkGoogleFunction
func (*Runtime) AfterLinkSteam ¶
func (r *Runtime) AfterLinkSteam() RuntimeAfterLinkSteamFunction
func (*Runtime) AfterListChannelMessages ¶
func (r *Runtime) AfterListChannelMessages() RuntimeAfterListChannelMessagesFunction
func (*Runtime) AfterListFriends ¶
func (r *Runtime) AfterListFriends() RuntimeAfterListFriendsFunction
func (*Runtime) AfterListGroupUsers ¶
func (r *Runtime) AfterListGroupUsers() RuntimeAfterListGroupUsersFunction
func (*Runtime) AfterListGroups ¶
func (r *Runtime) AfterListGroups() RuntimeAfterListGroupsFunction
func (*Runtime) AfterListLeaderboardRecords ¶
func (r *Runtime) AfterListLeaderboardRecords() RuntimeAfterListLeaderboardRecordsFunction
func (*Runtime) AfterListLeaderboardRecordsAroundOwner ¶
func (r *Runtime) AfterListLeaderboardRecordsAroundOwner() RuntimeAfterListLeaderboardRecordsAroundOwnerFunction
func (*Runtime) AfterListMatches ¶
func (r *Runtime) AfterListMatches() RuntimeAfterListMatchesFunction
func (*Runtime) AfterListNotifications ¶
func (r *Runtime) AfterListNotifications() RuntimeAfterListNotificationsFunction
func (*Runtime) AfterListStorageObjects ¶
func (r *Runtime) AfterListStorageObjects() RuntimeAfterListStorageObjectsFunction
func (*Runtime) AfterListTournamentRecords ¶
func (r *Runtime) AfterListTournamentRecords() RuntimeAfterListTournamentRecordsFunction
func (*Runtime) AfterListTournamentRecordsAroundOwner ¶
func (r *Runtime) AfterListTournamentRecordsAroundOwner() RuntimeAfterListTournamentRecordsAroundOwnerFunction
func (*Runtime) AfterListTournaments ¶
func (r *Runtime) AfterListTournaments() RuntimeAfterListTournamentsFunction
func (*Runtime) AfterListUserGroups ¶
func (r *Runtime) AfterListUserGroups() RuntimeAfterListUserGroupsFunction
func (*Runtime) AfterPromoteGroupUsers ¶
func (r *Runtime) AfterPromoteGroupUsers() RuntimeAfterPromoteGroupUsersFunction
func (*Runtime) AfterReadStorageObjects ¶
func (r *Runtime) AfterReadStorageObjects() RuntimeAfterReadStorageObjectsFunction
func (*Runtime) AfterRt ¶
func (r *Runtime) AfterRt(id string) RuntimeAfterRtFunction
func (*Runtime) AfterSessionLogout ¶ added in v3.2.0
func (r *Runtime) AfterSessionLogout() RuntimeAfterSessionLogoutFunction
func (*Runtime) AfterSessionRefresh ¶
func (r *Runtime) AfterSessionRefresh() RuntimeAfterSessionRefreshFunction
func (*Runtime) AfterUnlinkApple ¶
func (r *Runtime) AfterUnlinkApple() RuntimeAfterUnlinkAppleFunction
func (*Runtime) AfterUnlinkCustom ¶
func (r *Runtime) AfterUnlinkCustom() RuntimeAfterUnlinkCustomFunction
func (*Runtime) AfterUnlinkDevice ¶
func (r *Runtime) AfterUnlinkDevice() RuntimeAfterUnlinkDeviceFunction
func (*Runtime) AfterUnlinkEmail ¶
func (r *Runtime) AfterUnlinkEmail() RuntimeAfterUnlinkEmailFunction
func (*Runtime) AfterUnlinkFacebook ¶
func (r *Runtime) AfterUnlinkFacebook() RuntimeAfterUnlinkFacebookFunction
func (*Runtime) AfterUnlinkFacebookInstantGame ¶
func (r *Runtime) AfterUnlinkFacebookInstantGame() RuntimeAfterUnlinkFacebookInstantGameFunction
func (*Runtime) AfterUnlinkGameCenter ¶
func (r *Runtime) AfterUnlinkGameCenter() RuntimeAfterUnlinkGameCenterFunction
func (*Runtime) AfterUnlinkGoogle ¶
func (r *Runtime) AfterUnlinkGoogle() RuntimeAfterUnlinkGoogleFunction
func (*Runtime) AfterUnlinkSteam ¶
func (r *Runtime) AfterUnlinkSteam() RuntimeAfterUnlinkSteamFunction
func (*Runtime) AfterUpdateAccount ¶
func (r *Runtime) AfterUpdateAccount() RuntimeAfterUpdateAccountFunction
func (*Runtime) AfterUpdateGroup ¶
func (r *Runtime) AfterUpdateGroup() RuntimeAfterUpdateGroupFunction
func (*Runtime) AfterValidatePurchaseApple ¶ added in v3.2.0
func (r *Runtime) AfterValidatePurchaseApple() RuntimeAfterValidatePurchaseAppleFunction
func (*Runtime) AfterValidatePurchaseGoogle ¶ added in v3.2.0
func (r *Runtime) AfterValidatePurchaseGoogle() RuntimeAfterValidatePurchaseGoogleFunction
func (*Runtime) AfterValidatePurchaseHuawei ¶ added in v3.2.0
func (r *Runtime) AfterValidatePurchaseHuawei() RuntimeAfterValidatePurchaseHuaweiFunction
func (*Runtime) AfterWriteLeaderboardRecord ¶
func (r *Runtime) AfterWriteLeaderboardRecord() RuntimeAfterWriteLeaderboardRecordFunction
func (*Runtime) AfterWriteStorageObjects ¶
func (r *Runtime) AfterWriteStorageObjects() RuntimeAfterWriteStorageObjectsFunction
func (*Runtime) AfterWriteTournamentRecord ¶
func (r *Runtime) AfterWriteTournamentRecord() RuntimeAfterWriteTournamentRecordFunction
func (*Runtime) BeforeAddFriends ¶
func (r *Runtime) BeforeAddFriends() RuntimeBeforeAddFriendsFunction
func (*Runtime) BeforeAddGroupUsers ¶
func (r *Runtime) BeforeAddGroupUsers() RuntimeBeforeAddGroupUsersFunction
func (*Runtime) BeforeAuthenticateApple ¶
func (r *Runtime) BeforeAuthenticateApple() RuntimeBeforeAuthenticateAppleFunction
func (*Runtime) BeforeAuthenticateCustom ¶
func (r *Runtime) BeforeAuthenticateCustom() RuntimeBeforeAuthenticateCustomFunction
func (*Runtime) BeforeAuthenticateDevice ¶
func (r *Runtime) BeforeAuthenticateDevice() RuntimeBeforeAuthenticateDeviceFunction
func (*Runtime) BeforeAuthenticateEmail ¶
func (r *Runtime) BeforeAuthenticateEmail() RuntimeBeforeAuthenticateEmailFunction
func (*Runtime) BeforeAuthenticateFacebook ¶
func (r *Runtime) BeforeAuthenticateFacebook() RuntimeBeforeAuthenticateFacebookFunction
func (*Runtime) BeforeAuthenticateFacebookInstantGame ¶
func (r *Runtime) BeforeAuthenticateFacebookInstantGame() RuntimeBeforeAuthenticateFacebookInstantGameFunction
func (*Runtime) BeforeAuthenticateGameCenter ¶
func (r *Runtime) BeforeAuthenticateGameCenter() RuntimeBeforeAuthenticateGameCenterFunction
func (*Runtime) BeforeAuthenticateGoogle ¶
func (r *Runtime) BeforeAuthenticateGoogle() RuntimeBeforeAuthenticateGoogleFunction
func (*Runtime) BeforeAuthenticateSteam ¶
func (r *Runtime) BeforeAuthenticateSteam() RuntimeBeforeAuthenticateSteamFunction
func (*Runtime) BeforeBanGroupUsers ¶
func (r *Runtime) BeforeBanGroupUsers() RuntimeBeforeBanGroupUsersFunction
func (*Runtime) BeforeBlockFriends ¶
func (r *Runtime) BeforeBlockFriends() RuntimeBeforeBlockFriendsFunction
func (*Runtime) BeforeCreateGroup ¶
func (r *Runtime) BeforeCreateGroup() RuntimeBeforeCreateGroupFunction
func (*Runtime) BeforeDeleteFriends ¶
func (r *Runtime) BeforeDeleteFriends() RuntimeBeforeDeleteFriendsFunction
func (*Runtime) BeforeDeleteGroup ¶
func (r *Runtime) BeforeDeleteGroup() RuntimeBeforeDeleteGroupFunction
func (*Runtime) BeforeDeleteLeaderboardRecord ¶
func (r *Runtime) BeforeDeleteLeaderboardRecord() RuntimeBeforeDeleteLeaderboardRecordFunction
func (*Runtime) BeforeDeleteNotification ¶
func (r *Runtime) BeforeDeleteNotification() RuntimeBeforeDeleteNotificationFunction
func (*Runtime) BeforeDeleteStorageObjects ¶
func (r *Runtime) BeforeDeleteStorageObjects() RuntimeBeforeDeleteStorageObjectsFunction
func (*Runtime) BeforeDemoteGroupUsers ¶
func (r *Runtime) BeforeDemoteGroupUsers() RuntimeBeforeDemoteGroupUsersFunction
func (*Runtime) BeforeEvent ¶
func (r *Runtime) BeforeEvent() RuntimeBeforeEventFunction
func (*Runtime) BeforeGetAccount ¶
func (r *Runtime) BeforeGetAccount() RuntimeBeforeGetAccountFunction
func (*Runtime) BeforeGetUsers ¶
func (r *Runtime) BeforeGetUsers() RuntimeBeforeGetUsersFunction
func (*Runtime) BeforeImportFacebookFriends ¶
func (r *Runtime) BeforeImportFacebookFriends() RuntimeBeforeImportFacebookFriendsFunction
func (*Runtime) BeforeImportSteamFriends ¶ added in v3.1.0
func (r *Runtime) BeforeImportSteamFriends() RuntimeBeforeImportSteamFriendsFunction
func (*Runtime) BeforeJoinGroup ¶
func (r *Runtime) BeforeJoinGroup() RuntimeBeforeJoinGroupFunction
func (*Runtime) BeforeJoinTournament ¶
func (r *Runtime) BeforeJoinTournament() RuntimeBeforeJoinTournamentFunction
func (*Runtime) BeforeKickGroupUsers ¶
func (r *Runtime) BeforeKickGroupUsers() RuntimeBeforeKickGroupUsersFunction
func (*Runtime) BeforeLeaveGroup ¶
func (r *Runtime) BeforeLeaveGroup() RuntimeBeforeLeaveGroupFunction
func (*Runtime) BeforeLinkApple ¶
func (r *Runtime) BeforeLinkApple() RuntimeBeforeLinkAppleFunction
func (*Runtime) BeforeLinkCustom ¶
func (r *Runtime) BeforeLinkCustom() RuntimeBeforeLinkCustomFunction
func (*Runtime) BeforeLinkDevice ¶
func (r *Runtime) BeforeLinkDevice() RuntimeBeforeLinkDeviceFunction
func (*Runtime) BeforeLinkEmail ¶
func (r *Runtime) BeforeLinkEmail() RuntimeBeforeLinkEmailFunction
func (*Runtime) BeforeLinkFacebook ¶
func (r *Runtime) BeforeLinkFacebook() RuntimeBeforeLinkFacebookFunction
func (*Runtime) BeforeLinkFacebookInstantGame ¶
func (r *Runtime) BeforeLinkFacebookInstantGame() RuntimeBeforeLinkFacebookInstantGameFunction
func (*Runtime) BeforeLinkGameCenter ¶
func (r *Runtime) BeforeLinkGameCenter() RuntimeBeforeLinkGameCenterFunction
func (*Runtime) BeforeLinkGoogle ¶
func (r *Runtime) BeforeLinkGoogle() RuntimeBeforeLinkGoogleFunction
func (*Runtime) BeforeLinkSteam ¶
func (r *Runtime) BeforeLinkSteam() RuntimeBeforeLinkSteamFunction
func (*Runtime) BeforeListChannelMessages ¶
func (r *Runtime) BeforeListChannelMessages() RuntimeBeforeListChannelMessagesFunction
func (*Runtime) BeforeListFriends ¶
func (r *Runtime) BeforeListFriends() RuntimeBeforeListFriendsFunction
func (*Runtime) BeforeListGroupUsers ¶
func (r *Runtime) BeforeListGroupUsers() RuntimeBeforeListGroupUsersFunction
func (*Runtime) BeforeListGroups ¶
func (r *Runtime) BeforeListGroups() RuntimeBeforeListGroupsFunction
func (*Runtime) BeforeListLeaderboardRecords ¶
func (r *Runtime) BeforeListLeaderboardRecords() RuntimeBeforeListLeaderboardRecordsFunction
func (*Runtime) BeforeListLeaderboardRecordsAroundOwner ¶
func (r *Runtime) BeforeListLeaderboardRecordsAroundOwner() RuntimeBeforeListLeaderboardRecordsAroundOwnerFunction
func (*Runtime) BeforeListMatches ¶
func (r *Runtime) BeforeListMatches() RuntimeBeforeListMatchesFunction
func (*Runtime) BeforeListNotifications ¶
func (r *Runtime) BeforeListNotifications() RuntimeBeforeListNotificationsFunction
func (*Runtime) BeforeListStorageObjects ¶
func (r *Runtime) BeforeListStorageObjects() RuntimeBeforeListStorageObjectsFunction
func (*Runtime) BeforeListTournamentRecords ¶
func (r *Runtime) BeforeListTournamentRecords() RuntimeBeforeListTournamentRecordsFunction
func (*Runtime) BeforeListTournamentRecordsAroundOwner ¶
func (r *Runtime) BeforeListTournamentRecordsAroundOwner() RuntimeBeforeListTournamentRecordsAroundOwnerFunction
func (*Runtime) BeforeListTournaments ¶
func (r *Runtime) BeforeListTournaments() RuntimeBeforeListTournamentsFunction
func (*Runtime) BeforeListUserGroups ¶
func (r *Runtime) BeforeListUserGroups() RuntimeBeforeListUserGroupsFunction
func (*Runtime) BeforePromoteGroupUsers ¶
func (r *Runtime) BeforePromoteGroupUsers() RuntimeBeforePromoteGroupUsersFunction
func (*Runtime) BeforeReadStorageObjects ¶
func (r *Runtime) BeforeReadStorageObjects() RuntimeBeforeReadStorageObjectsFunction
func (*Runtime) BeforeRt ¶
func (r *Runtime) BeforeRt(id string) RuntimeBeforeRtFunction
func (*Runtime) BeforeSessionLogout ¶ added in v3.2.0
func (r *Runtime) BeforeSessionLogout() RuntimeBeforeSessionLogoutFunction
func (*Runtime) BeforeSessionRefresh ¶
func (r *Runtime) BeforeSessionRefresh() RuntimeBeforeSessionRefreshFunction
func (*Runtime) BeforeUnlinkApple ¶
func (r *Runtime) BeforeUnlinkApple() RuntimeBeforeUnlinkAppleFunction
func (*Runtime) BeforeUnlinkCustom ¶
func (r *Runtime) BeforeUnlinkCustom() RuntimeBeforeUnlinkCustomFunction
func (*Runtime) BeforeUnlinkDevice ¶
func (r *Runtime) BeforeUnlinkDevice() RuntimeBeforeUnlinkDeviceFunction
func (*Runtime) BeforeUnlinkEmail ¶
func (r *Runtime) BeforeUnlinkEmail() RuntimeBeforeUnlinkEmailFunction
func (*Runtime) BeforeUnlinkFacebook ¶
func (r *Runtime) BeforeUnlinkFacebook() RuntimeBeforeUnlinkFacebookFunction
func (*Runtime) BeforeUnlinkFacebookInstantGame ¶
func (r *Runtime) BeforeUnlinkFacebookInstantGame() RuntimeBeforeUnlinkFacebookInstantGameFunction
func (*Runtime) BeforeUnlinkGameCenter ¶
func (r *Runtime) BeforeUnlinkGameCenter() RuntimeBeforeUnlinkGameCenterFunction
func (*Runtime) BeforeUnlinkGoogle ¶
func (r *Runtime) BeforeUnlinkGoogle() RuntimeBeforeUnlinkGoogleFunction
func (*Runtime) BeforeUnlinkSteam ¶
func (r *Runtime) BeforeUnlinkSteam() RuntimeBeforeUnlinkSteamFunction
func (*Runtime) BeforeUpdateAccount ¶
func (r *Runtime) BeforeUpdateAccount() RuntimeBeforeUpdateAccountFunction
func (*Runtime) BeforeUpdateGroup ¶
func (r *Runtime) BeforeUpdateGroup() RuntimeBeforeUpdateGroupFunction
func (*Runtime) BeforeValidatePurchaseApple ¶ added in v3.2.0
func (r *Runtime) BeforeValidatePurchaseApple() RuntimeBeforeValidatePurchaseAppleFunction
func (*Runtime) BeforeValidatePurchaseGoogle ¶ added in v3.2.0
func (r *Runtime) BeforeValidatePurchaseGoogle() RuntimeBeforeValidatePurchaseGoogleFunction
func (*Runtime) BeforeValidatePurchaseHuawei ¶ added in v3.2.0
func (r *Runtime) BeforeValidatePurchaseHuawei() RuntimeBeforeValidatePurchaseHuaweiFunction
func (*Runtime) BeforeWriteLeaderboardRecord ¶
func (r *Runtime) BeforeWriteLeaderboardRecord() RuntimeBeforeWriteLeaderboardRecordFunction
func (*Runtime) BeforeWriteStorageObjects ¶
func (r *Runtime) BeforeWriteStorageObjects() RuntimeBeforeWriteStorageObjectsFunction
func (*Runtime) BeforeWriteTournamentRecord ¶
func (r *Runtime) BeforeWriteTournamentRecord() RuntimeBeforeWriteTournamentRecordFunction
func (*Runtime) Event ¶
func (r *Runtime) Event() RuntimeEventCustomFunction
func (*Runtime) EventSessionEnd ¶
func (r *Runtime) EventSessionEnd() RuntimeEventSessionEndFunction
func (*Runtime) EventSessionStart ¶
func (r *Runtime) EventSessionStart() RuntimeEventSessionStartFunction
func (*Runtime) LeaderboardReset ¶
func (r *Runtime) LeaderboardReset() RuntimeLeaderboardResetFunction
func (*Runtime) MatchCreateFunction ¶
func (r *Runtime) MatchCreateFunction() RuntimeMatchCreateFunction
func (*Runtime) MatchmakerMatched ¶
func (r *Runtime) MatchmakerMatched() RuntimeMatchmakerMatchedFunction
func (*Runtime) Rpc ¶
func (r *Runtime) Rpc(id string) RuntimeRpcFunction
func (*Runtime) TournamentEnd ¶
func (r *Runtime) TournamentEnd() RuntimeTournamentEndFunction
func (*Runtime) TournamentReset ¶
func (r *Runtime) TournamentReset() RuntimeTournamentResetFunction
type RuntimeAfterImportSteamFriendsFunction ¶ added in v3.1.0
type RuntimeAfterReqFunctions ¶
type RuntimeAfterReqFunctions struct {
// contains filtered or unexported fields
}
type RuntimeAfterRtFunction ¶
type RuntimeAfterSessionLogoutFunction ¶ added in v3.2.0
type RuntimeAfterValidatePurchaseAppleFunction ¶ added in v3.2.0
type RuntimeAfterValidatePurchaseGoogleFunction ¶ added in v3.2.0
type RuntimeAfterValidatePurchaseHuaweiFunction ¶ added in v3.2.0
type RuntimeBeforeAuthenticateFacebookInstantGameFunction ¶
type RuntimeBeforeAuthenticateFacebookInstantGameFunction func(ctx context.Context, logger *zap.Logger, userID, username string, vars map[string]string, expiry int64, clientIP, clientPort string, in *api.AuthenticateFacebookInstantGameRequest) (*api.AuthenticateFacebookInstantGameRequest, error, codes.Code)
type RuntimeBeforeImportSteamFriendsFunction ¶ added in v3.1.0
type RuntimeBeforeListLeaderboardRecordsAroundOwnerFunction ¶
type RuntimeBeforeListLeaderboardRecordsAroundOwnerFunction func(ctx context.Context, logger *zap.Logger, userID, username string, vars map[string]string, expiry int64, clientIP, clientPort string, in *api.ListLeaderboardRecordsAroundOwnerRequest) (*api.ListLeaderboardRecordsAroundOwnerRequest, error, codes.Code)
type RuntimeBeforeListTournamentRecordsAroundOwnerFunction ¶
type RuntimeBeforeListTournamentRecordsAroundOwnerFunction func(ctx context.Context, logger *zap.Logger, userID, username string, vars map[string]string, expiry int64, clientIP, clientPort string, in *api.ListTournamentRecordsAroundOwnerRequest) (*api.ListTournamentRecordsAroundOwnerRequest, error, codes.Code)
type RuntimeBeforeReqFunctions ¶
type RuntimeBeforeReqFunctions struct {
// contains filtered or unexported fields
}
type RuntimeBeforeRtFunction ¶
type RuntimeBeforeSessionLogoutFunction ¶ added in v3.2.0
type RuntimeBeforeValidatePurchaseAppleFunction ¶ added in v3.2.0
type RuntimeBeforeValidatePurchaseGoogleFunction ¶ added in v3.2.0
type RuntimeBeforeValidatePurchaseHuaweiFunction ¶ added in v3.2.0
type RuntimeConfig ¶
type RuntimeConfig struct { Environment map[string]string `yaml:"-" json:"-"` Env []string `yaml:"env" json:"env" usage:"Values to pass into Runtime as environment variables."` Path string `yaml:"path" json:"path" usage:"Path for the server to scan for Lua and Go library files."` HTTPKey string `yaml:"http_key" json:"http_key" usage:"Runtime HTTP Invocation key."` MinCount int `yaml:"min_count" json:"min_count" usage:"Minimum number of Lua runtime instances to allocate. Default 0."` // Kept for backwards compatibility LuaMinCount int `yaml:"lua_min_count" json:"lua_min_count" usage:"Minimum number of Lua runtime instances to allocate. Default 16."` MaxCount int `yaml:"max_count" json:"max_count" usage:"Maximum number of Lua runtime instances to allocate. Default 0."` // Kept for backwards compatibility LuaMaxCount int `yaml:"lua_max_count" json:"lua_max_count" usage:"Maximum number of Lua runtime instances to allocate. Default 48."` JsMinCount int `yaml:"js_min_count" json:"js_min_count" usage:"Maximum number of Javascript runtime instances to allocate. Default 48."` JsMaxCount int `yaml:"js_max_count" json:"js_max_count" usage:"Maximum number of Javascript runtime instances to allocate. Default 48."` CallStackSize int `yaml:"call_stack_size" json:"call_stack_size" usage:"Size of each runtime instance's call stack. Default 0."` // Kept for backwards compatibility LuaCallStackSize int `yaml:"lua_call_stack_size" json:"lua_call_stack_size" usage:"Size of each runtime instance's call stack. Default 128."` RegistrySize int `yaml:"registry_size" json:"registry_size" usage:"Size of each Lua runtime instance's registry. Default 0."` // Kept for backwards compatibility LuaRegistrySize int `yaml:"lua_registry_size" json:"lua_registry_size" usage:"Size of each Lua runtime instance's registry. Default 512."` EventQueueSize int `yaml:"event_queue_size" json:"event_queue_size" usage:"Size of the event queue buffer. Default 65536."` EventQueueWorkers int `` /* 134-byte string literal not displayed */ ReadOnlyGlobals bool `` // Kept for backwards compatibility /* 161-byte string literal not displayed */ LuaReadOnlyGlobals bool `` /* 169-byte string literal not displayed */ LuaApiStacktrace bool `` /* 144-byte string literal not displayed */ JsEntrypoint string `yaml:"js_entrypoint" json:"js_entrypoint" usage:"Specifies the location of the bundled JavaScript runtime source code."` }
RuntimeConfig is configuration relevant to the Runtime Lua VM.
func NewRuntimeConfig ¶
func NewRuntimeConfig() *RuntimeConfig
NewRuntimeConfig creates a new RuntimeConfig struct.
func (*RuntimeConfig) GetLuaCallStackSize ¶
func (r *RuntimeConfig) GetLuaCallStackSize() int
Function to allow backwards compatibility for CallStackSize config
func (*RuntimeConfig) GetLuaMaxCount ¶
func (r *RuntimeConfig) GetLuaMaxCount() int
Function to allow backwards compatibility for MaxCount config
func (*RuntimeConfig) GetLuaMinCount ¶
func (r *RuntimeConfig) GetLuaMinCount() int
Function to allow backwards compatibility for MinCount config
func (*RuntimeConfig) GetLuaReadOnlyGlobals ¶
func (r *RuntimeConfig) GetLuaReadOnlyGlobals() bool
Function to allow backwards compatibility for LuaReadOnlyGlobals config
func (*RuntimeConfig) GetLuaRegistrySize ¶
func (r *RuntimeConfig) GetLuaRegistrySize() int
Function to allow backwards compatibility for RegistrySize config
type RuntimeEventFunction ¶
type RuntimeEventFunctions ¶
type RuntimeEventFunctions struct {
// contains filtered or unexported fields
}
type RuntimeEventQueue ¶
type RuntimeEventQueue struct {
// contains filtered or unexported fields
}
func NewRuntimeEventQueue ¶
func NewRuntimeEventQueue(logger *zap.Logger, config Config, metrics Metrics) *RuntimeEventQueue
func (*RuntimeEventQueue) Queue ¶
func (b *RuntimeEventQueue) Queue(fn func())
func (*RuntimeEventQueue) Stop ¶
func (b *RuntimeEventQueue) Stop()
type RuntimeExecutionMode ¶
type RuntimeExecutionMode int
const ( RuntimeExecutionModeEvent RuntimeExecutionMode = iota RuntimeExecutionModeRunOnce RuntimeExecutionModeRPC RuntimeExecutionModeBefore RuntimeExecutionModeAfter RuntimeExecutionModeMatch RuntimeExecutionModeMatchmaker RuntimeExecutionModeMatchCreate RuntimeExecutionModeTournamentEnd RuntimeExecutionModeTournamentReset RuntimeExecutionModeLeaderboardReset )
func (RuntimeExecutionMode) String ¶
func (e RuntimeExecutionMode) String() string
type RuntimeGoInitializer ¶
type RuntimeGoInitializer struct {
// contains filtered or unexported fields
}
func (*RuntimeGoInitializer) RegisterAfterAddFriends ¶
func (ri *RuntimeGoInitializer) RegisterAfterAddFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AddFriendsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterAddGroupUsers ¶
func (ri *RuntimeGoInitializer) RegisterAfterAddGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AddGroupUsersRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterAuthenticateApple ¶
func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateApple(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.Session, in *api.AuthenticateAppleRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterAuthenticateCustom ¶
func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateCustom(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.Session, in *api.AuthenticateCustomRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterAuthenticateDevice ¶
func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateDevice(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.Session, in *api.AuthenticateDeviceRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterAuthenticateEmail ¶
func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateEmail(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.Session, in *api.AuthenticateEmailRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterAuthenticateFacebook ¶
func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateFacebook(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.Session, in *api.AuthenticateFacebookRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterAuthenticateFacebookInstantGame ¶
func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateFacebookInstantGame(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.Session, in *api.AuthenticateFacebookInstantGameRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterAuthenticateGameCenter ¶
func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateGameCenter(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.Session, in *api.AuthenticateGameCenterRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterAuthenticateGoogle ¶
func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateGoogle(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.Session, in *api.AuthenticateGoogleRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterAuthenticateSteam ¶
func (ri *RuntimeGoInitializer) RegisterAfterAuthenticateSteam(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.Session, in *api.AuthenticateSteamRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterBanGroupUsers ¶
func (ri *RuntimeGoInitializer) RegisterAfterBanGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.BanGroupUsersRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterBlockFriends ¶
func (ri *RuntimeGoInitializer) RegisterAfterBlockFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.BlockFriendsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterCreateGroup ¶
func (ri *RuntimeGoInitializer) RegisterAfterCreateGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.Group, in *api.CreateGroupRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterDeleteFriends ¶
func (ri *RuntimeGoInitializer) RegisterAfterDeleteFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.DeleteFriendsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterDeleteGroup ¶
func (ri *RuntimeGoInitializer) RegisterAfterDeleteGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.DeleteGroupRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterDeleteLeaderboardRecord ¶
func (ri *RuntimeGoInitializer) RegisterAfterDeleteLeaderboardRecord(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.DeleteLeaderboardRecordRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterDeleteNotification ¶
func (ri *RuntimeGoInitializer) RegisterAfterDeleteNotification(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.DeleteNotificationsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterDeleteStorageObjects ¶
func (ri *RuntimeGoInitializer) RegisterAfterDeleteStorageObjects(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.DeleteStorageObjectsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterDemoteGroupUsers ¶
func (ri *RuntimeGoInitializer) RegisterAfterDemoteGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.DemoteGroupUsersRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterEvent ¶
func (*RuntimeGoInitializer) RegisterAfterGetAccount ¶
func (*RuntimeGoInitializer) RegisterAfterGetUsers ¶
func (ri *RuntimeGoInitializer) RegisterAfterGetUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.Users, in *api.GetUsersRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterImportFacebookFriends ¶
func (ri *RuntimeGoInitializer) RegisterAfterImportFacebookFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ImportFacebookFriendsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterImportSteamFriends ¶ added in v3.1.0
func (ri *RuntimeGoInitializer) RegisterAfterImportSteamFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ImportSteamFriendsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterJoinGroup ¶
func (ri *RuntimeGoInitializer) RegisterAfterJoinGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.JoinGroupRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterJoinTournament ¶
func (ri *RuntimeGoInitializer) RegisterAfterJoinTournament(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.JoinTournamentRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterKickGroupUsers ¶
func (ri *RuntimeGoInitializer) RegisterAfterKickGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.KickGroupUsersRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterLeaveGroup ¶
func (ri *RuntimeGoInitializer) RegisterAfterLeaveGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.LeaveGroupRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterLinkApple ¶
func (ri *RuntimeGoInitializer) RegisterAfterLinkApple(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountApple) error) error
func (*RuntimeGoInitializer) RegisterAfterLinkCustom ¶
func (ri *RuntimeGoInitializer) RegisterAfterLinkCustom(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountCustom) error) error
func (*RuntimeGoInitializer) RegisterAfterLinkDevice ¶
func (ri *RuntimeGoInitializer) RegisterAfterLinkDevice(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountDevice) error) error
func (*RuntimeGoInitializer) RegisterAfterLinkEmail ¶
func (ri *RuntimeGoInitializer) RegisterAfterLinkEmail(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountEmail) error) error
func (*RuntimeGoInitializer) RegisterAfterLinkFacebook ¶
func (ri *RuntimeGoInitializer) RegisterAfterLinkFacebook(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.LinkFacebookRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterLinkFacebookInstantGame ¶
func (ri *RuntimeGoInitializer) RegisterAfterLinkFacebookInstantGame(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountFacebookInstantGame) error) error
func (*RuntimeGoInitializer) RegisterAfterLinkGameCenter ¶
func (ri *RuntimeGoInitializer) RegisterAfterLinkGameCenter(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountGameCenter) error) error
func (*RuntimeGoInitializer) RegisterAfterLinkGoogle ¶
func (ri *RuntimeGoInitializer) RegisterAfterLinkGoogle(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountGoogle) error) error
func (*RuntimeGoInitializer) RegisterAfterLinkSteam ¶
func (ri *RuntimeGoInitializer) RegisterAfterLinkSteam(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.LinkSteamRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterListChannelMessages ¶
func (ri *RuntimeGoInitializer) RegisterAfterListChannelMessages(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.ChannelMessageList, in *api.ListChannelMessagesRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterListFriends ¶
func (ri *RuntimeGoInitializer) RegisterAfterListFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.FriendList) error) error
func (*RuntimeGoInitializer) RegisterAfterListGroupUsers ¶
func (ri *RuntimeGoInitializer) RegisterAfterListGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.GroupUserList, in *api.ListGroupUsersRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterListGroups ¶
func (ri *RuntimeGoInitializer) RegisterAfterListGroups(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.GroupList, in *api.ListGroupsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterListLeaderboardRecords ¶
func (ri *RuntimeGoInitializer) RegisterAfterListLeaderboardRecords(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.LeaderboardRecordList, in *api.ListLeaderboardRecordsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterListLeaderboardRecordsAroundOwner ¶
func (ri *RuntimeGoInitializer) RegisterAfterListLeaderboardRecordsAroundOwner(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.LeaderboardRecordList, in *api.ListLeaderboardRecordsAroundOwnerRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterListMatches ¶
func (ri *RuntimeGoInitializer) RegisterAfterListMatches(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.MatchList, in *api.ListMatchesRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterListNotifications ¶
func (ri *RuntimeGoInitializer) RegisterAfterListNotifications(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.NotificationList, in *api.ListNotificationsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterListStorageObjects ¶
func (ri *RuntimeGoInitializer) RegisterAfterListStorageObjects(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.StorageObjectList, in *api.ListStorageObjectsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterListTournamentRecords ¶
func (ri *RuntimeGoInitializer) RegisterAfterListTournamentRecords(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.TournamentRecordList, in *api.ListTournamentRecordsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterListTournamentRecordsAroundOwner ¶
func (ri *RuntimeGoInitializer) RegisterAfterListTournamentRecordsAroundOwner(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.TournamentRecordList, in *api.ListTournamentRecordsAroundOwnerRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterListTournaments ¶
func (ri *RuntimeGoInitializer) RegisterAfterListTournaments(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.TournamentList, in *api.ListTournamentsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterListUserGroups ¶
func (ri *RuntimeGoInitializer) RegisterAfterListUserGroups(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.UserGroupList, in *api.ListUserGroupsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterPromoteGroupUsers ¶
func (ri *RuntimeGoInitializer) RegisterAfterPromoteGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.PromoteGroupUsersRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterReadStorageObjects ¶
func (ri *RuntimeGoInitializer) RegisterAfterReadStorageObjects(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.StorageObjects, in *api.ReadStorageObjectsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterRt ¶
func (*RuntimeGoInitializer) RegisterAfterSessionLogout ¶ added in v3.2.0
func (ri *RuntimeGoInitializer) RegisterAfterSessionLogout(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.SessionLogoutRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterSessionRefresh ¶
func (ri *RuntimeGoInitializer) RegisterAfterSessionRefresh(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.Session, in *api.SessionRefreshRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterUnlinkApple ¶
func (ri *RuntimeGoInitializer) RegisterAfterUnlinkApple(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountApple) error) error
func (*RuntimeGoInitializer) RegisterAfterUnlinkCustom ¶
func (ri *RuntimeGoInitializer) RegisterAfterUnlinkCustom(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountCustom) error) error
func (*RuntimeGoInitializer) RegisterAfterUnlinkDevice ¶
func (ri *RuntimeGoInitializer) RegisterAfterUnlinkDevice(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountDevice) error) error
func (*RuntimeGoInitializer) RegisterAfterUnlinkEmail ¶
func (ri *RuntimeGoInitializer) RegisterAfterUnlinkEmail(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountEmail) error) error
func (*RuntimeGoInitializer) RegisterAfterUnlinkFacebook ¶
func (ri *RuntimeGoInitializer) RegisterAfterUnlinkFacebook(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountFacebook) error) error
func (*RuntimeGoInitializer) RegisterAfterUnlinkFacebookInstantGame ¶
func (ri *RuntimeGoInitializer) RegisterAfterUnlinkFacebookInstantGame(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountFacebookInstantGame) error) error
func (*RuntimeGoInitializer) RegisterAfterUnlinkGameCenter ¶
func (ri *RuntimeGoInitializer) RegisterAfterUnlinkGameCenter(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountGameCenter) error) error
func (*RuntimeGoInitializer) RegisterAfterUnlinkGoogle ¶
func (ri *RuntimeGoInitializer) RegisterAfterUnlinkGoogle(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountGoogle) error) error
func (*RuntimeGoInitializer) RegisterAfterUnlinkSteam ¶
func (ri *RuntimeGoInitializer) RegisterAfterUnlinkSteam(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountSteam) error) error
func (*RuntimeGoInitializer) RegisterAfterUpdateAccount ¶
func (ri *RuntimeGoInitializer) RegisterAfterUpdateAccount(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.UpdateAccountRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterUpdateGroup ¶
func (ri *RuntimeGoInitializer) RegisterAfterUpdateGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.UpdateGroupRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterValidatePurchaseApple ¶ added in v3.2.0
func (ri *RuntimeGoInitializer) RegisterAfterValidatePurchaseApple(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.ValidatePurchaseResponse, in *api.ValidatePurchaseAppleRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterValidatePurchaseGoogle ¶ added in v3.2.0
func (ri *RuntimeGoInitializer) RegisterAfterValidatePurchaseGoogle(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.ValidatePurchaseResponse, in *api.ValidatePurchaseGoogleRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterValidatePurchaseHuawei ¶ added in v3.2.0
func (ri *RuntimeGoInitializer) RegisterAfterValidatePurchaseHuawei(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.ValidatePurchaseResponse, in *api.ValidatePurchaseHuaweiRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterWriteLeaderboardRecord ¶
func (ri *RuntimeGoInitializer) RegisterAfterWriteLeaderboardRecord(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.LeaderboardRecord, in *api.WriteLeaderboardRecordRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterWriteStorageObjects ¶
func (ri *RuntimeGoInitializer) RegisterAfterWriteStorageObjects(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.StorageObjectAcks, in *api.WriteStorageObjectsRequest) error) error
func (*RuntimeGoInitializer) RegisterAfterWriteTournamentRecord ¶
func (ri *RuntimeGoInitializer) RegisterAfterWriteTournamentRecord(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, out *api.LeaderboardRecord, in *api.WriteTournamentRecordRequest) error) error
func (*RuntimeGoInitializer) RegisterBeforeAddFriends ¶
func (ri *RuntimeGoInitializer) RegisterBeforeAddFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AddFriendsRequest) (*api.AddFriendsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeAddGroupUsers ¶
func (ri *RuntimeGoInitializer) RegisterBeforeAddGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AddGroupUsersRequest) (*api.AddGroupUsersRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeAuthenticateApple ¶
func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateApple(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AuthenticateAppleRequest) (*api.AuthenticateAppleRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeAuthenticateCustom ¶
func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateCustom(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AuthenticateCustomRequest) (*api.AuthenticateCustomRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeAuthenticateDevice ¶
func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateDevice(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AuthenticateDeviceRequest) (*api.AuthenticateDeviceRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeAuthenticateEmail ¶
func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateEmail(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AuthenticateEmailRequest) (*api.AuthenticateEmailRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeAuthenticateFacebook ¶
func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateFacebook(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AuthenticateFacebookRequest) (*api.AuthenticateFacebookRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeAuthenticateFacebookInstantGame ¶
func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateFacebookInstantGame(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AuthenticateFacebookInstantGameRequest) (*api.AuthenticateFacebookInstantGameRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeAuthenticateGameCenter ¶
func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateGameCenter(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AuthenticateGameCenterRequest) (*api.AuthenticateGameCenterRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeAuthenticateGoogle ¶
func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateGoogle(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AuthenticateGoogleRequest) (*api.AuthenticateGoogleRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeAuthenticateSteam ¶
func (ri *RuntimeGoInitializer) RegisterBeforeAuthenticateSteam(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AuthenticateSteamRequest) (*api.AuthenticateSteamRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeBanGroupUsers ¶
func (ri *RuntimeGoInitializer) RegisterBeforeBanGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.BanGroupUsersRequest) (*api.BanGroupUsersRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeBlockFriends ¶
func (ri *RuntimeGoInitializer) RegisterBeforeBlockFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.BlockFriendsRequest) (*api.BlockFriendsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeCreateGroup ¶
func (ri *RuntimeGoInitializer) RegisterBeforeCreateGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.CreateGroupRequest) (*api.CreateGroupRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeDeleteFriends ¶
func (ri *RuntimeGoInitializer) RegisterBeforeDeleteFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.DeleteFriendsRequest) (*api.DeleteFriendsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeDeleteGroup ¶
func (ri *RuntimeGoInitializer) RegisterBeforeDeleteGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.DeleteGroupRequest) (*api.DeleteGroupRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeDeleteLeaderboardRecord ¶
func (ri *RuntimeGoInitializer) RegisterBeforeDeleteLeaderboardRecord(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.DeleteLeaderboardRecordRequest) (*api.DeleteLeaderboardRecordRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeDeleteNotification ¶
func (ri *RuntimeGoInitializer) RegisterBeforeDeleteNotification(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.DeleteNotificationsRequest) (*api.DeleteNotificationsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeDeleteStorageObjects ¶
func (ri *RuntimeGoInitializer) RegisterBeforeDeleteStorageObjects(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.DeleteStorageObjectsRequest) (*api.DeleteStorageObjectsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeDemoteGroupUsers ¶
func (ri *RuntimeGoInitializer) RegisterBeforeDemoteGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.DemoteGroupUsersRequest) (*api.DemoteGroupUsersRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeEvent ¶
func (*RuntimeGoInitializer) RegisterBeforeGetAccount ¶
func (*RuntimeGoInitializer) RegisterBeforeGetUsers ¶
func (ri *RuntimeGoInitializer) RegisterBeforeGetUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.GetUsersRequest) (*api.GetUsersRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeImportFacebookFriends ¶
func (ri *RuntimeGoInitializer) RegisterBeforeImportFacebookFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ImportFacebookFriendsRequest) (*api.ImportFacebookFriendsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeImportSteamFriends ¶ added in v3.1.0
func (ri *RuntimeGoInitializer) RegisterBeforeImportSteamFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ImportSteamFriendsRequest) (*api.ImportSteamFriendsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeJoinGroup ¶
func (ri *RuntimeGoInitializer) RegisterBeforeJoinGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.JoinGroupRequest) (*api.JoinGroupRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeJoinTournament ¶
func (ri *RuntimeGoInitializer) RegisterBeforeJoinTournament(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.JoinTournamentRequest) (*api.JoinTournamentRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeKickGroupUsers ¶
func (ri *RuntimeGoInitializer) RegisterBeforeKickGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.KickGroupUsersRequest) (*api.KickGroupUsersRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeLeaveGroup ¶
func (ri *RuntimeGoInitializer) RegisterBeforeLeaveGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.LeaveGroupRequest) (*api.LeaveGroupRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeLinkApple ¶
func (ri *RuntimeGoInitializer) RegisterBeforeLinkApple(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountApple) (*api.AccountApple, error)) error
func (*RuntimeGoInitializer) RegisterBeforeLinkCustom ¶
func (ri *RuntimeGoInitializer) RegisterBeforeLinkCustom(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountCustom) (*api.AccountCustom, error)) error
func (*RuntimeGoInitializer) RegisterBeforeLinkDevice ¶
func (ri *RuntimeGoInitializer) RegisterBeforeLinkDevice(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountDevice) (*api.AccountDevice, error)) error
func (*RuntimeGoInitializer) RegisterBeforeLinkEmail ¶
func (ri *RuntimeGoInitializer) RegisterBeforeLinkEmail(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountEmail) (*api.AccountEmail, error)) error
func (*RuntimeGoInitializer) RegisterBeforeLinkFacebook ¶
func (ri *RuntimeGoInitializer) RegisterBeforeLinkFacebook(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.LinkFacebookRequest) (*api.LinkFacebookRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeLinkFacebookInstantGame ¶
func (ri *RuntimeGoInitializer) RegisterBeforeLinkFacebookInstantGame(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountFacebookInstantGame) (*api.AccountFacebookInstantGame, error)) error
func (*RuntimeGoInitializer) RegisterBeforeLinkGameCenter ¶
func (ri *RuntimeGoInitializer) RegisterBeforeLinkGameCenter(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountGameCenter) (*api.AccountGameCenter, error)) error
func (*RuntimeGoInitializer) RegisterBeforeLinkGoogle ¶
func (ri *RuntimeGoInitializer) RegisterBeforeLinkGoogle(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountGoogle) (*api.AccountGoogle, error)) error
func (*RuntimeGoInitializer) RegisterBeforeLinkSteam ¶
func (ri *RuntimeGoInitializer) RegisterBeforeLinkSteam(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.LinkSteamRequest) (*api.LinkSteamRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListChannelMessages ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListChannelMessages(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListChannelMessagesRequest) (*api.ListChannelMessagesRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListFriends ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListFriends(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListFriendsRequest) (*api.ListFriendsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListGroupUsers ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListGroupUsersRequest) (*api.ListGroupUsersRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListGroups ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListGroups(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListGroupsRequest) (*api.ListGroupsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListLeaderboardRecords ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListLeaderboardRecords(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListLeaderboardRecordsRequest) (*api.ListLeaderboardRecordsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListLeaderboardRecordsAroundOwner ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListLeaderboardRecordsAroundOwner(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListLeaderboardRecordsAroundOwnerRequest) (*api.ListLeaderboardRecordsAroundOwnerRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListMatches ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListMatches(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListMatchesRequest) (*api.ListMatchesRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListNotifications ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListNotifications(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListNotificationsRequest) (*api.ListNotificationsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListStorageObjects ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListStorageObjects(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListStorageObjectsRequest) (*api.ListStorageObjectsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListTournamentRecords ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListTournamentRecords(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListTournamentRecordsRequest) (*api.ListTournamentRecordsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListTournamentRecordsAroundOwner ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListTournamentRecordsAroundOwner(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListTournamentRecordsAroundOwnerRequest) (*api.ListTournamentRecordsAroundOwnerRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListTournaments ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListTournaments(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListTournamentsRequest) (*api.ListTournamentsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeListUserGroups ¶
func (ri *RuntimeGoInitializer) RegisterBeforeListUserGroups(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ListUserGroupsRequest) (*api.ListUserGroupsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforePromoteGroupUsers ¶
func (ri *RuntimeGoInitializer) RegisterBeforePromoteGroupUsers(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.PromoteGroupUsersRequest) (*api.PromoteGroupUsersRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeReadStorageObjects ¶
func (ri *RuntimeGoInitializer) RegisterBeforeReadStorageObjects(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ReadStorageObjectsRequest) (*api.ReadStorageObjectsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeRt ¶
func (*RuntimeGoInitializer) RegisterBeforeSessionLogout ¶ added in v3.2.0
func (ri *RuntimeGoInitializer) RegisterBeforeSessionLogout(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.SessionLogoutRequest) (*api.SessionLogoutRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeSessionRefresh ¶
func (ri *RuntimeGoInitializer) RegisterBeforeSessionRefresh(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.SessionRefreshRequest) (*api.SessionRefreshRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeUnlinkApple ¶
func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkApple(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountApple) (*api.AccountApple, error)) error
func (*RuntimeGoInitializer) RegisterBeforeUnlinkCustom ¶
func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkCustom(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountCustom) (*api.AccountCustom, error)) error
func (*RuntimeGoInitializer) RegisterBeforeUnlinkDevice ¶
func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkDevice(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountDevice) (*api.AccountDevice, error)) error
func (*RuntimeGoInitializer) RegisterBeforeUnlinkEmail ¶
func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkEmail(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountEmail) (*api.AccountEmail, error)) error
func (*RuntimeGoInitializer) RegisterBeforeUnlinkFacebook ¶
func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkFacebook(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountFacebook) (*api.AccountFacebook, error)) error
func (*RuntimeGoInitializer) RegisterBeforeUnlinkFacebookInstantGame ¶
func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkFacebookInstantGame(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountFacebookInstantGame) (*api.AccountFacebookInstantGame, error)) error
func (*RuntimeGoInitializer) RegisterBeforeUnlinkGameCenter ¶
func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkGameCenter(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountGameCenter) (*api.AccountGameCenter, error)) error
func (*RuntimeGoInitializer) RegisterBeforeUnlinkGoogle ¶
func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkGoogle(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountGoogle) (*api.AccountGoogle, error)) error
func (*RuntimeGoInitializer) RegisterBeforeUnlinkSteam ¶
func (ri *RuntimeGoInitializer) RegisterBeforeUnlinkSteam(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.AccountSteam) (*api.AccountSteam, error)) error
func (*RuntimeGoInitializer) RegisterBeforeUpdateAccount ¶
func (ri *RuntimeGoInitializer) RegisterBeforeUpdateAccount(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.UpdateAccountRequest) (*api.UpdateAccountRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeUpdateGroup ¶
func (ri *RuntimeGoInitializer) RegisterBeforeUpdateGroup(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.UpdateGroupRequest) (*api.UpdateGroupRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeValidatePurchaseApple ¶ added in v3.2.0
func (ri *RuntimeGoInitializer) RegisterBeforeValidatePurchaseApple(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ValidatePurchaseAppleRequest) (*api.ValidatePurchaseAppleRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeValidatePurchaseGoogle ¶ added in v3.2.0
func (ri *RuntimeGoInitializer) RegisterBeforeValidatePurchaseGoogle(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ValidatePurchaseGoogleRequest) (*api.ValidatePurchaseGoogleRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeValidatePurchaseHuawei ¶ added in v3.2.0
func (ri *RuntimeGoInitializer) RegisterBeforeValidatePurchaseHuawei(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.ValidatePurchaseHuaweiRequest) (*api.ValidatePurchaseHuaweiRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeWriteLeaderboardRecord ¶
func (ri *RuntimeGoInitializer) RegisterBeforeWriteLeaderboardRecord(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.WriteLeaderboardRecordRequest) (*api.WriteLeaderboardRecordRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeWriteStorageObjects ¶
func (ri *RuntimeGoInitializer) RegisterBeforeWriteStorageObjects(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.WriteStorageObjectsRequest) (*api.WriteStorageObjectsRequest, error)) error
func (*RuntimeGoInitializer) RegisterBeforeWriteTournamentRecord ¶
func (ri *RuntimeGoInitializer) RegisterBeforeWriteTournamentRecord(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, in *api.WriteTournamentRecordRequest) (*api.WriteTournamentRecordRequest, error)) error
func (*RuntimeGoInitializer) RegisterEvent ¶
func (*RuntimeGoInitializer) RegisterEventSessionEnd ¶
func (*RuntimeGoInitializer) RegisterEventSessionStart ¶
func (*RuntimeGoInitializer) RegisterLeaderboardReset ¶
func (ri *RuntimeGoInitializer) RegisterLeaderboardReset(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, leaderboard *api.Leaderboard, reset int64) error) error
func (*RuntimeGoInitializer) RegisterMatch ¶
func (*RuntimeGoInitializer) RegisterMatchmakerMatched ¶
func (ri *RuntimeGoInitializer) RegisterMatchmakerMatched(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, entries []runtime.MatchmakerEntry) (string, error)) error
func (*RuntimeGoInitializer) RegisterRpc ¶
func (*RuntimeGoInitializer) RegisterTournamentEnd ¶
func (ri *RuntimeGoInitializer) RegisterTournamentEnd(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, tournament *api.Tournament, end, reset int64) error) error
func (*RuntimeGoInitializer) RegisterTournamentReset ¶
func (ri *RuntimeGoInitializer) RegisterTournamentReset(fn func(ctx context.Context, logger runtime.Logger, db *sql.DB, nk runtime.NakamaModule, tournament *api.Tournament, end, reset int64) error) error
type RuntimeGoLogger ¶
type RuntimeGoLogger struct {
// contains filtered or unexported fields
}
func (*RuntimeGoLogger) Debug ¶
func (l *RuntimeGoLogger) Debug(format string, v ...interface{})
func (*RuntimeGoLogger) Error ¶
func (l *RuntimeGoLogger) Error(format string, v ...interface{})
func (*RuntimeGoLogger) Fields ¶
func (l *RuntimeGoLogger) Fields() map[string]interface{}
func (*RuntimeGoLogger) Info ¶
func (l *RuntimeGoLogger) Info(format string, v ...interface{})
func (*RuntimeGoLogger) Warn ¶
func (l *RuntimeGoLogger) Warn(format string, v ...interface{})
func (*RuntimeGoLogger) WithField ¶
func (l *RuntimeGoLogger) WithField(key string, v interface{}) nkruntime.Logger
func (*RuntimeGoLogger) WithFields ¶
func (l *RuntimeGoLogger) WithFields(fields map[string]interface{}) nkruntime.Logger
type RuntimeGoMatchCore ¶
type RuntimeGoMatchCore struct {
// contains filtered or unexported fields
}
func (*RuntimeGoMatchCore) BroadcastMessage ¶
func (*RuntimeGoMatchCore) BroadcastMessageDeferred ¶
func (*RuntimeGoMatchCore) Cancel ¶
func (r *RuntimeGoMatchCore) Cancel()
func (*RuntimeGoMatchCore) Cleanup ¶ added in v3.10.0
func (r *RuntimeGoMatchCore) Cleanup()
func (*RuntimeGoMatchCore) CreateTime ¶ added in v3.1.2
func (r *RuntimeGoMatchCore) CreateTime() int64
func (*RuntimeGoMatchCore) GetState ¶
func (r *RuntimeGoMatchCore) GetState(state interface{}) (string, error)
func (*RuntimeGoMatchCore) HandlerName ¶
func (r *RuntimeGoMatchCore) HandlerName() string
func (*RuntimeGoMatchCore) Label ¶
func (r *RuntimeGoMatchCore) Label() string
func (*RuntimeGoMatchCore) MatchInit ¶
func (r *RuntimeGoMatchCore) MatchInit(presenceList *MatchPresenceList, deferMessageFn RuntimeMatchDeferMessageFunction, params map[string]interface{}) (interface{}, int, error)
func (*RuntimeGoMatchCore) MatchJoin ¶
func (r *RuntimeGoMatchCore) MatchJoin(tick int64, state interface{}, joins []*MatchPresence) (interface{}, error)
func (*RuntimeGoMatchCore) MatchJoinAttempt ¶
func (*RuntimeGoMatchCore) MatchKick ¶
func (r *RuntimeGoMatchCore) MatchKick(presences []runtime.Presence) error
func (*RuntimeGoMatchCore) MatchLabelUpdate ¶
func (r *RuntimeGoMatchCore) MatchLabelUpdate(label string) error
func (*RuntimeGoMatchCore) MatchLeave ¶
func (r *RuntimeGoMatchCore) MatchLeave(tick int64, state interface{}, leaves []*MatchPresence) (interface{}, error)
func (*RuntimeGoMatchCore) MatchLoop ¶
func (r *RuntimeGoMatchCore) MatchLoop(tick int64, state interface{}, inputCh <-chan *MatchDataMessage) (interface{}, error)
func (*RuntimeGoMatchCore) MatchSignal ¶ added in v3.8.0
func (r *RuntimeGoMatchCore) MatchSignal(tick int64, state interface{}, data string) (interface{}, string, error)
func (*RuntimeGoMatchCore) MatchTerminate ¶
func (r *RuntimeGoMatchCore) MatchTerminate(tick int64, state interface{}, graceSeconds int) (interface{}, error)
func (*RuntimeGoMatchCore) TickRate ¶ added in v3.1.2
func (r *RuntimeGoMatchCore) TickRate() int
type RuntimeGoNakamaModule ¶
func NewRuntimeGoNakamaModule ¶
func NewRuntimeGoNakamaModule(logger *zap.Logger, db *sql.DB, protojsonMarshaler *protojson.MarshalOptions, config Config, socialClient *social.Client, leaderboardCache LeaderboardCache, leaderboardRankCache LeaderboardRankCache, leaderboardScheduler LeaderboardScheduler, sessionRegistry SessionRegistry, sessionCache SessionCache, matchRegistry MatchRegistry, tracker Tracker, metrics Metrics, streamManager StreamManager, router MessageRouter) *RuntimeGoNakamaModule
func (*RuntimeGoNakamaModule) AccountDeleteId ¶
func (n *RuntimeGoNakamaModule) AccountDeleteId(ctx context.Context, userID string, recorded bool) error
@summary Delete an account by user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) User ID for the account to be deleted. Must be valid UUID. @param recorded(bool) Whether to record this deletion in the database. By default this is set to false. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AccountExportId ¶
@summary Export account information for a specified user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) User ID for the account to be exported. Must be valid UUID. @return export(string) Account information for the provided user ID, in JSON format. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AccountGetId ¶
func (n *RuntimeGoNakamaModule) AccountGetId(ctx context.Context, userID string) (*api.Account, error)
@summary Fetch account information by user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) User ID to fetch information for. Must be valid UUID. @return account(*api.Account) All account information including wallet, device IDs and more. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AccountUpdateId ¶
func (n *RuntimeGoNakamaModule) AccountUpdateId(ctx context.Context, userID, username string, metadata map[string]interface{}, displayName, timezone, location, langTag, avatarUrl string) error
@summary Update an account by user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) User ID for which the information is to be updated. Must be valid UUID. @param metadata(map[string]interface{}) The metadata to update for this account. @param username(string) Username to be set. Must be unique. Use "" if it is not being updated. @param displayName(string) Display name to be updated. Use "" if it is not being updated. @param timezone(string) Timezone to be updated. Use "" if it is not being updated. @param location(string) Location to be updated. Use "" if it is not being updated. @param language(string) Lang tag to be updated. Use "" if it is not being updated. @param avatarUrl(string) User's avatar URL. Use "" if it is not being updated. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AccountsGetId ¶
func (n *RuntimeGoNakamaModule) AccountsGetId(ctx context.Context, userIDs []string) ([]*api.Account, error)
@summary Fetch information for multiple accounts by user IDs. @param ctx(context.Context) The context object represents information about the server and requester. @param userIds([]string) Array of user IDs to fetch information for. Must be valid UUID. @return account(*api.Account) An array of accounts. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AuthenticateApple ¶
func (n *RuntimeGoNakamaModule) AuthenticateApple(ctx context.Context, token, username string, create bool) (string, string, bool, error)
@summary Authenticate user and create a session token using an Apple sign in token. @param ctx(context.Context) The context object represents information about the server and requester. @param token(string) Apple sign in token. @param username(string) The user's username. If left empty, one is generated. @param create(bool) Create user if one didn't exist previously. By default this is set to true. @return userID(string) The user ID of the authenticated user. @return username(string) The username of the authenticated user. @return create(bool) Value indicating if this account was just created or already existed. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AuthenticateCustom ¶
func (n *RuntimeGoNakamaModule) AuthenticateCustom(ctx context.Context, id, username string, create bool) (string, string, bool, error)
@summary Authenticate user and create a session token using a custom authentication managed by an external service or source not already supported by Nakama. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) Custom ID to use to authenticate the user. Must be between 6-128 characters. @param username(string) The user's username. If left empty, one is generated. @param create(bool) Create user if one didn't exist previously. By default this is set to true. @return userID(string) The user ID of the authenticated user. @return username(string) The username of the authenticated user. @return create(bool) Value indicating if this account was just created or already existed. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AuthenticateDevice ¶
func (n *RuntimeGoNakamaModule) AuthenticateDevice(ctx context.Context, id, username string, create bool) (string, string, bool, error)
@summary Authenticate user and create a session token using a device identifier. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) Device ID to use to authenticate the user. Must be between 1-128 characters. @param username(string) The user's username. If left empty, one is generated. @param create(bool) Create user if one didn't exist previously. By default this is set to true. @return userID(string) The user ID of the authenticated user. @return username(string) The username of the authenticated user. @return create(bool) Value indicating if this account was just created or already existed. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AuthenticateEmail ¶
func (n *RuntimeGoNakamaModule) AuthenticateEmail(ctx context.Context, email, password, username string, create bool) (string, string, bool, error)
@summary Authenticate user and create a session token using an email address and password. @param ctx(context.Context) The context object represents information about the server and requester. @param email(string) Email address to use to authenticate the user. Must be between 10-255 characters. @param password(string) Password to set. Must be longer than 8 characters. @param username(string) The user's username. If left empty, one is generated. @param create(bool) Create user if one didn't exist previously. By default this is set to true. @return userID(string) The user ID of the authenticated user. @return username(string) The username of the authenticated user. @return create(bool) Value indicating if this account was just created or already existed. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AuthenticateFacebook ¶
func (n *RuntimeGoNakamaModule) AuthenticateFacebook(ctx context.Context, token string, importFriends bool, username string, create bool) (string, string, bool, error)
@summary Authenticate user and create a session token using a Facebook account token. @param ctx(context.Context) The context object represents information about the server and requester. @param token(string) Facebook OAuth or Limited Login (JWT) access token. @param import(bool) Whether to automatically import Facebook friends after authentication. This is true by default. @param username(string) The user's username. If left empty, one is generated. @param create(bool) Create user if one didn't exist previously. By default this is set to true. @return userID(string) The user ID of the authenticated user. @return username(string) The username of the authenticated user. @return create(bool) Value indicating if this account was just created or already existed. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AuthenticateFacebookInstantGame ¶
func (n *RuntimeGoNakamaModule) AuthenticateFacebookInstantGame(ctx context.Context, signedPlayerInfo string, username string, create bool) (string, string, bool, error)
@summary Authenticate user and create a session token using a Facebook Instant Game. @param ctx(context.Context) The context object represents information about the server and requester. @param playerInfo(string) Facebook Player info. @param username(string) The user's username. If left empty, one is generated. @param create(bool) Create user if one didn't exist previously. By default this is set to true. @return userID(string) The user ID of the authenticated user. @return username(string) The username of the authenticated user. @return create(bool) Value indicating if this account was just created or already existed. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AuthenticateGameCenter ¶
func (n *RuntimeGoNakamaModule) AuthenticateGameCenter(ctx context.Context, playerID, bundleID string, timestamp int64, salt, signature, publicKeyUrl, username string, create bool) (string, string, bool, error)
@summary Authenticate user and create a session token using Apple Game Center credentials. @param ctx(context.Context) The context object represents information about the server and requester. @param playerId(string) PlayerId provided by GameCenter. @param bundleId(string) BundleId of your app on iTunesConnect. @param timestamp(int64) Timestamp at which Game Center authenticated the client and issued a signature. @param salt(string) A random string returned by Game Center authentication on client. @param signature(string) A signature returned by Game Center authentication on client. @param publicKeyUrl(string) A URL to the public key returned by Game Center authentication on client. @param username(string) The user's username. If left empty, one is generated. @param create(bool) Create user if one didn't exist previously. By default this is set to true. @return userID(string) The user ID of the authenticated user. @return username(string) The username of the authenticated user. @return create(bool) Value indicating if this account was just created or already existed. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AuthenticateGoogle ¶
func (n *RuntimeGoNakamaModule) AuthenticateGoogle(ctx context.Context, token, username string, create bool) (string, string, bool, error)
@summary Authenticate user and create a session token using a Google ID token. @param ctx(context.Context) The context object represents information about the server and requester. @param token(string) Google OAuth access token. @param username(string) The user's username. If left empty, one is generated. @param create(bool) Create user if one didn't exist previously. By default this is set to true. @return userID(string) The user ID of the authenticated user. @return username(string) The username of the authenticated user. @return create(bool) Value indicating if this account was just created or already existed. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AuthenticateSteam ¶
func (n *RuntimeGoNakamaModule) AuthenticateSteam(ctx context.Context, token, username string, create bool) (string, string, bool, error)
@summary Authenticate user and create a session token using a Steam account token. @param ctx(context.Context) The context object represents information about the server and requester. @param token(string) Steam token. @param username(string) The user's username. If left empty, one is generated. @param create(bool) Create user if one didn't exist previously. By default this is set to true. @return userID(string) The user ID of the authenticated user. @return username(string) The username of the authenticated user. @return create(bool) Value indicating if this account was just created or already existed. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) AuthenticateTokenGenerate ¶
func (n *RuntimeGoNakamaModule) AuthenticateTokenGenerate(userID, username string, exp int64, vars map[string]string) (string, int64, error)
@summary Generate a Nakama session token from a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) User ID to use to generate the token. @param username(string) The user's username. If left empty, one is generated. @param expiresAt(number) Optional. Number of seconds the token should be valid for. Defaults to server configured expiry time. @return token(string) The Nakama session token. @return validity(number) The period for which the token remains valid. @return create(bool) Value indicating if this account was just created or already existed. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) ChannelIdBuild ¶ added in v3.5.0
func (n *RuntimeGoNakamaModule) ChannelIdBuild(ctx context.Context, target string, chanType runtime.ChannelType) (string, error)
@summary Create a channel identifier to be used in other runtime calls. Does not create a channel. @param ctx(context.Context) The context object represents information about the server and requester. @param target(string) Can be the room name, group identifier, or another username. @param chanType(runtime.ChannelType) The type of channel, for example group or direct. @return channelId(string) The generated ID representing a channel. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) ChannelMessageSend ¶ added in v3.5.0
func (n *RuntimeGoNakamaModule) ChannelMessageSend(ctx context.Context, channelId string, content map[string]interface{}, senderId, senderUsername string, persist bool) (*rtapi.ChannelMessageAck, error)
@summary Register a function that processes events published to the server. @param ctx(context.Context) The context object represents information about the server and requester. @param channelId(string) The ID of the channel to send the message on. @param content(map[string]interface{}) Message content. Must be set. @param senderId(string) The UUID for the sender of this message. If left empty, it will be assumed that it is a system message. @param senderUsername(string) The username of the user to send this message as. If left empty, it will be assumed that it is a system message. @param persist(bool) Whether to record this message in the channel history. Defaults to true. @return channelMessageSend(*rtapi.ChannelMessageAck) Message sent ack. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) ChannelMessageUpdate ¶ added in v3.6.0
func (n *RuntimeGoNakamaModule) ChannelMessageUpdate(ctx context.Context, channelId, messageId string, content map[string]interface{}, senderId, senderUsername string, persist bool) (*rtapi.ChannelMessageAck, error)
@summary Update a message on a realtime chat channel. @param ctx(context.Context) The context object represents information about the server and requester. @param channelId(string) The ID of the channel to send the message on. @param messageId(string) The ID of the message to update. @param content(map[string]interface{}) Message content. Must be set. @param senderId(string) The UUID for the sender of this message. If left empty, it will be assumed that it is a system message. @param senderUsername(string) The username of the user to send this message as. If left empty, it will be assumed that it is a system message. @param persist(bool) Whether to record this message in the channel history. Defaults to true. @return channelMessageSend(*rtapi.ChannelMessageAck) Message updated ack. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) Event ¶
@summary Generate an event. @param ctx(context.Context) The context object represents information about the server and requester. @param evt(*api.Event) The event to be generated. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) FriendsList ¶
func (n *RuntimeGoNakamaModule) FriendsList(ctx context.Context, userID string, limit int, state *int, cursor string) ([]*api.Friend, string, error)
@summary List all friends, invites, invited, and blocked which belong to a user. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The ID of the user who's friends, invites, invited, and blocked you want to list. @param limit(int) The number of friends to retrieve in this page of results. No more than 100 limit allowed per result. @param state(int) The state of the friendship with the user. If unspecified this returns friends in all states for the user. @param cursor(string) The cursor returned from a previous listing request. Used to obtain the next page of results. @return friends([]*api.Friend) The user information for users that are friends of the current user. @return cursor(string) An optional next page cursor that can be used to retrieve the next page of records (if any). @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) GroupCreate ¶
func (n *RuntimeGoNakamaModule) GroupCreate(ctx context.Context, userID, name, creatorID, langTag, description, avatarUrl string, open bool, metadata map[string]interface{}, maxCount int) (*api.Group, error)
@summary Setup a group with various configuration settings. The group will be created if they don't exist or fail if the group name is taken. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) Mandatory. The user ID to be associated as the group superadmin. @param name(string) Mandatory. Group name, must be unique. @param creatorId(string) The user ID to be associated as creator. If not set or nil/null, system user will be set. @param langTag(string) Group language. If not set will default to 'en'. @param description(string) Group description, can be left empty as nil/null. @param avatarUrl(string) URL to the group avatar, can be left empty as nil/null. @param open(bool) Whether the group is for anyone to join, or members will need to send invitations to join. Defaults to false. @param metadata(map[string]interface{}) Custom information to store for this group. Can be left empty as nil/null. @param maxCount(int) Maximum number of members to have in the group. Defaults to 100. @return createGroup(*api.Group) The groupId of the newly created group. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) GroupDelete ¶
func (n *RuntimeGoNakamaModule) GroupDelete(ctx context.Context, id string) error
@summary Delete a group. @param ctx(context.Context) The context object represents information about the server and requester. @param groupId(string) The ID of the group to delete. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) GroupUpdate ¶
func (n *RuntimeGoNakamaModule) GroupUpdate(ctx context.Context, id, name, creatorID, langTag, description, avatarUrl string, open bool, metadata map[string]interface{}, maxCount int) error
@summary Update a group with various configuration settings. The group which is updated can change some or all of its fields. @param ctx(context.Context) The context object represents information about the server and requester. @param groupId(string) The ID of the group to update. @param userId(string) User ID calling the update operation for permission checking. Set as nil to enact the changes as the system user. @param name(string) Group name, can be empty if not changed. @param creatorId(string) The user ID to be associated as creator. Can be empty if not changed. @param langTag(string) Group language. Empty if not updated. @param description(string) Group description, can be left empty if not updated. @param avatarUrl(string) URL to the group avatar, can be left empty if not updated. @param open(bool) Whether the group is for anyone to join or not. @param metadata(map[string]interface{}) Custom information to store for this group. Use nil if field is not being updated. @param maxCount(int) Maximum number of members to have in the group. Use 0, nil/null if field is not being updated. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) GroupUserJoin ¶
func (n *RuntimeGoNakamaModule) GroupUserJoin(ctx context.Context, groupID, userID, username string) error
@summary Join a group for a particular user. @param ctx(context.Context) The context object represents information about the server and requester. @param groupId(string) The ID of the group to join. @param userId(string) The user ID to add to this group. @param username(string) The username of the user to add to this group. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) GroupUserLeave ¶
func (n *RuntimeGoNakamaModule) GroupUserLeave(ctx context.Context, groupID, userID, username string) error
@summary Leave a group for a particular user. @param ctx(context.Context) The context object represents information about the server and requester. @param groupId(string) The ID of the group to leave. @param userId(string) The user ID to remove from this group. @param username(string) The username of the user to remove from this group. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) GroupUsersAdd ¶
func (n *RuntimeGoNakamaModule) GroupUsersAdd(ctx context.Context, callerID, groupID string, userIDs []string) error
@summary Add users to a group. @param ctx(context.Context) The context object represents information about the server and requester. @param groupId(string) The ID of the group to add users to. @param userIds([]string) Table array of user IDs to add to this group. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) GroupUsersDemote ¶
func (n *RuntimeGoNakamaModule) GroupUsersDemote(ctx context.Context, callerID, groupID string, userIDs []string) error
@summary Demote users in a group. @param ctx(context.Context) The context object represents information about the server and requester. @param groupId(string) The ID of the group whose members are being demoted. @param userIds([]string) Table array of user IDs to demote. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) GroupUsersKick ¶
func (n *RuntimeGoNakamaModule) GroupUsersKick(ctx context.Context, callerID, groupID string, userIDs []string) error
@summary Kick users from a group. @param ctx(context.Context) The context object represents information about the server and requester. @param groupId(string) The ID of the group to kick users from. @param userIds([]string) Table array of user IDs to kick. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) GroupUsersList ¶
func (n *RuntimeGoNakamaModule) GroupUsersList(ctx context.Context, id string, limit int, state *int, cursor string) ([]*api.GroupUserList_GroupUser, string, error)
@summary List all members, admins and superadmins which belong to a group. This also list incoming join requests. ctx @param ctx(context.Context) The context object represents information about the server and requester. @param groupId(string) The ID of the group to list members for. @return groupUsers([]*api.GroupUserList_GroupUser) The user information for members, admins and superadmins for the group. Also users who sent a join request. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) GroupUsersPromote ¶
func (n *RuntimeGoNakamaModule) GroupUsersPromote(ctx context.Context, callerID, groupID string, userIDs []string) error
@summary Promote users in a group. @param ctx(context.Context) The context object represents information about the server and requester. @param groupId(string) The ID of the group whose members are being promoted. @param userIds([]string) Table array of user IDs to promote. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) GroupsGetId ¶
func (n *RuntimeGoNakamaModule) GroupsGetId(ctx context.Context, groupIDs []string) ([]*api.Group, error)
@summary Fetch one or more groups by their ID. @param ctx(context.Context) The context object represents information about the server and requester. @param groupIds([]string) An array of strings of the IDs for the groups to get. @return getGroups([]*api.Group) An array of groups with their fields. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) GroupsList ¶ added in v3.4.0
func (n *RuntimeGoNakamaModule) GroupsList(ctx context.Context, name, langTag string, members *int, open *bool, limit int, cursor string) ([]*api.Group, string, error)
@summary Find groups based on the entered criteria. @param ctx(context.Context) The context object represents information about the server and requester. @param name(string) Search for groups that contain this value in their name. @param langTag(string) Filter based upon the entered language tag. @param members(int) Search by number of group members. @param open(bool) Filter based on whether groups are Open or Closed. @param limit(int) Return only the required number of groups denoted by this limit value. @param cursor(string) Cursor to paginate to the next result set. If this is empty/null there is no further results. @return groups([]*api.Group) A list of groups. @return cursor(string) An optional next page cursor that can be used to retrieve the next page of records (if any). @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LeaderboardCreate ¶
func (n *RuntimeGoNakamaModule) LeaderboardCreate(ctx context.Context, id string, authoritative bool, sortOrder, operator, resetSchedule string, metadata map[string]interface{}) error
@summary Setup a new dynamic leaderboard with the specified ID and various configuration settings. The leaderboard will be created if it doesn't already exist, otherwise its configuration will not be updated. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) The unique identifier for the new leaderboard. This is used by clients to submit scores. @param authoritative(bool) Mark the leaderboard as authoritative which ensures updates can only be made via the Go runtime. No client can submit a score directly. Default false. @param sortOrder(string) The sort order for records in the leaderboard; possible values are "asc" or "desc". Default "desc". @param operator(string) The operator that determines how scores behave when submitted; possible values are "best", "set", or "incr". Default "best". @param resetSchedule(string) The cron format used to define the reset schedule for the leaderboard. This controls when a leaderboard is reset and can be used to power daily/weekly/monthly leaderboards. @param metadata(map[string]interface{}) The metadata you want associated to the leaderboard. Some good examples are weather conditions for a racing game. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LeaderboardDelete ¶
func (n *RuntimeGoNakamaModule) LeaderboardDelete(ctx context.Context, id string) error
@summary Delete a leaderboard and all scores that belong to it. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) The unique identifier for the leaderboard to delete. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LeaderboardList ¶ added in v3.4.0
func (n *RuntimeGoNakamaModule) LeaderboardList(categoryStart, categoryEnd, limit int, cursor string) (*api.LeaderboardList, error)
@summary Find leaderboards which have been created on the server. Leaderboards can be filtered with categories. @param categoryStart(int) Filter leaderboards with categories greater or equal than this value. @param categoryEnd(int) Filter leaderboards with categories equal or less than this value. @param limit(int) Return only the required number of leaderboards denoted by this limit value. @param cursor(string) Cursor to paginate to the next result set. If this is empty/null there are no further results. @return leaderboardList(*api.LeaderboardList) A list of leaderboard results and possibly a cursor. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LeaderboardRecordDelete ¶
func (n *RuntimeGoNakamaModule) LeaderboardRecordDelete(ctx context.Context, id, ownerID string) error
@summary Remove an owner's record from a leaderboard, if one exists. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) The unique identifier for the leaderboard to delete from. @param owner(string) The owner of the score to delete. Mandatory field. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LeaderboardRecordWrite ¶
func (n *RuntimeGoNakamaModule) LeaderboardRecordWrite(ctx context.Context, id, ownerID, username string, score, subscore int64, metadata map[string]interface{}, overrideOperator *int) (*api.LeaderboardRecord, error)
@summary Use the preconfigured operator for the given leaderboard to submit a score for a particular user. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) The unique identifier for the leaderboard to submit to. @param owner(string) The owner of this score submission. Mandatory field. @param username(string) The owner username of this score submission, if it's a user. @param score(int64) The score to submit. Default 0. @param subscore(int64) A secondary subscore parameter for the submission. Default 0. @param metadata(map[string]interface{}) The metadata you want associated to this submission. Some good examples are weather conditions for a racing game. @return record(*api.LeaderboardRecord) The newly created leaderboard record. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LeaderboardRecordsList ¶
func (n *RuntimeGoNakamaModule) LeaderboardRecordsList(ctx context.Context, id string, ownerIDs []string, limit int, cursor string, expiry int64) ([]*api.LeaderboardRecord, []*api.LeaderboardRecord, string, string, error)
@summary List records on the specified leaderboard, optionally filtering to only a subset of records by their owners. Records will be listed in the preconfigured leaderboard sort order. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) The unique identifier for the leaderboard to list. Mandatory field. @param owners([]string) Array of owners to filter to. @param limit(int) The maximum number of records to return (Max 10,000). @param cursor(string) Cursor to paginate to the next result set. If this is empty/null there are no further results. @return records(*api.LeaderboardRecord) A page of leaderboard records. @return ownerRecords(*api.LeaderboardRecord) A list of owner leaderboard records (empty if the owners input parameter is not set). @return nextCursor(string) An optional next page cursor that can be used to retrieve the next page of records (if any). @return prevCursor(string) An optional previous page cursor that can be used to retrieve the previous page of records (if any). @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LeaderboardsGetId ¶ added in v3.4.0
func (n *RuntimeGoNakamaModule) LeaderboardsGetId(ctx context.Context, IDs []string) ([]*api.Leaderboard, error)
@summary Fetch one or more leaderboards by ID. @param ids([]string) The table array of leaderboard ids. @return leaderboardsGet(*api.Leaderboard) The leaderboard records according to ID. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LinkApple ¶
func (n *RuntimeGoNakamaModule) LinkApple(ctx context.Context, userID, token string) error
@summary Link Apple authentication to a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be linked. @param token(string) Apple sign in token. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LinkCustom ¶
func (n *RuntimeGoNakamaModule) LinkCustom(ctx context.Context, userID, customID string) error
@summary Link custom authentication to a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be linked. @param customId(string) Custom ID to be linked to the user. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LinkDevice ¶
func (n *RuntimeGoNakamaModule) LinkDevice(ctx context.Context, userID, deviceID string) error
@summary Link device authentication to a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be linked. @param deviceId(string) Device ID to be linked to the user. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LinkEmail ¶
func (n *RuntimeGoNakamaModule) LinkEmail(ctx context.Context, userID, email, password string) error
@summary Link email authentication to a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be linked. @param email(string) Authentication email to be linked to the user. @param password(string) Password to set. Must be longer than 8 characters. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LinkFacebook ¶
func (n *RuntimeGoNakamaModule) LinkFacebook(ctx context.Context, userID, username, token string, importFriends bool) error
@summary Link Facebook authentication to a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be linked. @param username(string) If left empty, one is generated. @param token(string) Facebook OAuth or Limited Login (JWT) access token. @param importFriends(bool) Whether to automatically import Facebook friends after authentication. This is true by default. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LinkFacebookInstantGame ¶
func (n *RuntimeGoNakamaModule) LinkFacebookInstantGame(ctx context.Context, userID, signedPlayerInfo string) error
@summary Link Facebook Instant Game authentication to a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be linked. @param playerInfo(string) Facebook player info. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LinkGameCenter ¶
func (n *RuntimeGoNakamaModule) LinkGameCenter(ctx context.Context, userID, playerID, bundleID string, timestamp int64, salt, signature, publicKeyUrl string) error
@summary Link Apple Game Center authentication to a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be linked. @param playerId(string) Player ID provided by Game Center. @param bundleId(string) Bundle ID of your app on iTunesConnect. @param timestamp(int64) Timestamp at which Game Center authenticated the client and issued a signature. @param salt(string) A random string returned by Game Center authentication on client. @param signature(string) A signature returned by Game Center authentication on client. @param publicKeyUrl(string) A URL to the public key returned by Game Center authentication on client. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LinkGoogle ¶
func (n *RuntimeGoNakamaModule) LinkGoogle(ctx context.Context, userID, token string) error
@summary Link Google authentication to a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be linked. @param token(string) Google OAuth access token. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) LinkSteam ¶
func (n *RuntimeGoNakamaModule) LinkSteam(ctx context.Context, userID, username, token string, importFriends bool) error
@summary Link Steam authentication to a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be linked. @param username(string) If left empty, one is generated. @param token(string) Steam access token. @param importFriends(bool) Whether to automatically import Steam friends after authentication. This is true by default. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) MatchCreate ¶
func (n *RuntimeGoNakamaModule) MatchCreate(ctx context.Context, module string, params map[string]interface{}) (string, error)
@summary Create a new authoritative realtime multiplayer match running on the given runtime module name. The given params are passed to the match's init hook. @param ctx(context.Context) The context object represents information about the server and requester. @param module(string) The name of an available runtime module that will be responsible for the match. This was registered in InitModule. @param params(map[string]interface{}) Any value to pass to the match init hook. @return matchId(string) The match ID of the newly created match. Clients can immediately use this ID to join the match. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) MatchGet ¶
@summary Get information on a running match. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) The ID of the match to fetch. @return match(*api.Match) Information for the running match. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) MatchList ¶
func (n *RuntimeGoNakamaModule) MatchList(ctx context.Context, limit int, authoritative bool, label string, minSize, maxSize *int, query string) ([]*api.Match, error)
@summary List currently running realtime multiplayer matches and optionally filter them by authoritative mode, label, and current participant count. @param ctx(context.Context) The context object represents information about the server and requester. @param limit(int) The maximum number of matches to list. Default 1. @param authoritative(bool) Set true to only return authoritative matches, false to only return relayed matches. Default false. @param label(string) A label to filter authoritative matches by. Default "" meaning any label matches. @param minSize(int) Inclusive lower limit of current match participants. @param maxSize(int) Inclusive upper limit of current match participants. @param query(String) Additional query parameters to shortlist matches. @return match(*api.Match) A list of matches matching the parameters criteria. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) MatchSignal ¶ added in v3.8.0
func (n *RuntimeGoNakamaModule) MatchSignal(ctx context.Context, id string, data string) (string, error)
@summary Allow the match handler to be sent a reservation signal to mark a user ID or session ID into the match state ahead of their join attempt and eventual join flow. Called when the match handler receives a runtime signal. @param ctx(context.Context) Context object represents information about the match and server for information purposes. @param id(string) The user ID or session ID to send a reservation signal for. @param data(string) An arbitrary input supplied by the runtime caller of the signal. @return state(interface{}) An (optionally) updated state. May be any non-nil value, or nil to end the match. @return data(string) Arbitrary data to return to the runtime caller of the signal. May be a string or nil. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) MetricsCounterAdd ¶ added in v3.4.0
func (n *RuntimeGoNakamaModule) MetricsCounterAdd(name string, tags map[string]string, delta int64)
@summary Add a custom metrics counter. @param name(string) The name of the custom metrics counter. @param tags(map[string]string) The metrics tags associated with this counter. @param delta(int64) Value to update this metric with.
func (*RuntimeGoNakamaModule) MetricsGaugeSet ¶ added in v3.4.0
func (n *RuntimeGoNakamaModule) MetricsGaugeSet(name string, tags map[string]string, value float64)
@summary Add a custom metrics gauge. @param name(string) The name of the custom metrics gauge. @param tags(map[string]string) The metrics tags associated with this gauge. @param value(float64) Value to update this metric with.
func (*RuntimeGoNakamaModule) MetricsTimerRecord ¶ added in v3.4.0
func (n *RuntimeGoNakamaModule) MetricsTimerRecord(name string, tags map[string]string, value time.Duration)
@summary Add a custom metrics timer. @param name(string) The name of the custom metrics timer. @param tags(map[string]string) The metrics tags associated with this timer. @param value(time.Duration) Value to update this metric with.
func (*RuntimeGoNakamaModule) MultiUpdate ¶
func (n *RuntimeGoNakamaModule) MultiUpdate(ctx context.Context, accountUpdates []*runtime.AccountUpdate, storageWrites []*runtime.StorageWrite, walletUpdates []*runtime.WalletUpdate, updateLedger bool) ([]*api.StorageObjectAck, []*runtime.WalletUpdateResult, error)
@summary Update account, storage, and wallet information simultaneously. @param ctx(context.Context) The context object represents information about the server and requester. @param accountUpdates([]*runtime.AccountUpdate) Array of account information to be updated. @param storageWrites([]*runtime.StorageWrite) Array of storage objects to be updated. @param walletUpdates([]*runtime.WalletUpdate) Array of wallet updates to be made. @param updateLedger(bool) Whether to record this wallet update in the ledger. Defaults to false. @return storageWriteOps([]*api.StorageObjectAck) A list of acks with the version of the written objects. @return walletUpdateOps(*runtime.WalletUpdateResult) A list of wallet updates results. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) NotificationSend ¶
func (n *RuntimeGoNakamaModule) NotificationSend(ctx context.Context, userID, subject string, content map[string]interface{}, code int, sender string, persistent bool) error
@summary Send one in-app notification to a user. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID of the user to be sent the notification. @param subject(string) Notification subject. Must be set. @param content(map[string]interface{}) Notification content. Must be set but can be an struct. @param code(int) Notification code to use. Must be equal or greater than 0. @param sender(string) The sender of this notification. If left empty, it will be assumed that it is a system notification. @param persistent(bool) Whether to record this in the database for later listing. Defaults to false. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) NotificationsSend ¶
func (n *RuntimeGoNakamaModule) NotificationsSend(ctx context.Context, notifications []*runtime.NotificationSend) error
@summary Send one or more in-app notifications to a user. @param ctx(context.Context) The context object represents information about the server and requester. @param notifications([]*runtime.NotificationsSend) A list of notifications to be sent together. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) PurchaseGetByTransactionId ¶ added in v3.2.0
func (n *RuntimeGoNakamaModule) PurchaseGetByTransactionId(ctx context.Context, transactionID string) (string, *api.ValidatedPurchase, error)
@summary Look up a purchase receipt by transaction ID. @param ctx(context.Context) The context object represents information about the server and requester. @param transactionId(string) Transaction ID of the purchase to look up. @return owner(string) The owner of the purchase. @return purchase(*api.ValidatedPurchase) A validated purchase. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) PurchaseValidateApple ¶ added in v3.2.0
func (n *RuntimeGoNakamaModule) PurchaseValidateApple(ctx context.Context, userID, receipt string, passwordOverride ...string) (*api.ValidatePurchaseResponse, error)
@summary Validates and stores the purchases present in an Apple App Store Receipt. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID of the owner of the receipt. @param receipt(string) Base-64 encoded receipt data returned by the purchase operation itself. @param passwordOverride(string) Optional. Override the iap.apple.shared_password provided in your configuration. @return validation(*api.ValidatePurchaseResponse) The resulting successfully validated purchases. Any previously validated purchases are returned with a seenBefore flag. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) PurchaseValidateGoogle ¶ added in v3.2.0
func (n *RuntimeGoNakamaModule) PurchaseValidateGoogle(ctx context.Context, userID, receipt string) (*api.ValidatePurchaseResponse, error)
@summary Validates and stores a purchase receipt from the Google Play Store. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID of the owner of the receipt. @param receipt(string) JSON encoded Google receipt. @return validation(*api.ValidatePurchaseResponse) The resulting successfully validated purchases. Any previously validated purchases are returned with a seenBefore flag. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) PurchaseValidateHuawei ¶ added in v3.2.0
func (n *RuntimeGoNakamaModule) PurchaseValidateHuawei(ctx context.Context, userID, signature, inAppPurchaseData string) (*api.ValidatePurchaseResponse, error)
@summary Validates and stores a purchase receipt from the Huawei App Gallery. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID of the owner of the receipt. @param receipt(string) The Huawei receipt data. @param signature(string) The receipt signature. @return validation(*api.ValidatePurchaseResponse) The resulting successfully validated purchases. Any previously validated purchases are returned with a seenBefore flag. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) PurchasesList ¶ added in v3.2.0
func (n *RuntimeGoNakamaModule) PurchasesList(ctx context.Context, userID string, limit int, cursor string) (*api.PurchaseList, error)
@summary List stored validated purchase receipts. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) Filter by user ID. Can be an empty string to list purchases for all users. @param limit(int) Limit number of records retrieved. Defaults to 100. @param cursor(string) Pagination cursor from previous result. If none available set to nil or "" (empty string). @return listPurchases(*api.PurchaseList) A page of stored validated purchases. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) ReadFile ¶
func (n *RuntimeGoNakamaModule) ReadFile(relPath string) (*os.File, error)
@summary Read file from user device. @param relPath(string) Relative path to the file to be read. @return fileRead(*os.File) The read file. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) SessionDisconnect ¶
func (n *RuntimeGoNakamaModule) SessionDisconnect(ctx context.Context, sessionID string, reason ...runtime.PresenceReason) error
@summary Disconnect a session. @param ctx(context.Context) The context object represents information about the server and requester. @param sessionId(string) The ID of the session to be disconnected. @param reason(runtime.PresenceReason) The reason for the session disconnect. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) SessionLogout ¶ added in v3.2.0
func (n *RuntimeGoNakamaModule) SessionLogout(userID, token, refreshToken string) error
@summary Log out a user from their current session. @param userId(string) The ID of the user to be logged out. @param token(string) The current session authentication token. @param refreshToken(string) The current session refresh token. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) SetEventFn ¶
func (n *RuntimeGoNakamaModule) SetEventFn(fn RuntimeEventCustomFunction)
func (*RuntimeGoNakamaModule) StorageDelete ¶
func (n *RuntimeGoNakamaModule) StorageDelete(ctx context.Context, deletes []*runtime.StorageDelete) error
@summary Remove one or more objects by their collection/keyname and optional user. @param ctx(context.Context) The context object represents information about the server and requester. @param objectIds([]*runtime.StorageDelete) An array of object identifiers to be deleted. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StorageList ¶
func (n *RuntimeGoNakamaModule) StorageList(ctx context.Context, userID, collection string, limit int, cursor string) ([]*api.StorageObject, string, error)
@summary List records in a collection and page through results. The records returned can be filtered to those owned by the user or "" for public records. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) User ID to list records for or "" (empty string) for public records. @param collection(string) Collection to list data from. @param limit(int) Limit number of records retrieved. Defaults to 100. @param cursor(string) Pagination cursor from previous result. If none available set to nil or "" (empty string). @return objects([]*api.StorageObject) A list of storage objects. @return cursor(string) Pagination cursor. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StorageRead ¶
func (n *RuntimeGoNakamaModule) StorageRead(ctx context.Context, reads []*runtime.StorageRead) ([]*api.StorageObject, error)
@summary Fetch one or more records by their bucket/collection/keyname and optional user. @param ctx(context.Context) The context object represents information about the server and requester. @param objectIds([]*runtime.StorageReads) An array of object identifiers to be fetched. @return objects([]*api.StorageObject) A list of matches matching the parameters criteria. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StorageWrite ¶
func (n *RuntimeGoNakamaModule) StorageWrite(ctx context.Context, writes []*runtime.StorageWrite) ([]*api.StorageObjectAck, error)
@summary Write one or more objects by their collection/keyname and optional user. @param ctx(context.Context) The context object represents information about the server and requester. @param objectIds([]*runtime.StorageWrite) An array of object identifiers to be written. @return acks([]*api.StorageObjectAcks) A list of acks with the version of the written objects. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StreamClose ¶
func (n *RuntimeGoNakamaModule) StreamClose(mode uint8, subject, subcontext, label string) error
@summary Close a stream and remove all presences on it. @param mode(uint8) The type of stream, 'chat' for example. @param subject(string) The primary stream subject, typically a user ID. @param subcontext(string) A secondary subject, for example for direct chat between two users. @param label(string) Meta-information about the stream, for example a chat room name. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StreamCount ¶
func (n *RuntimeGoNakamaModule) StreamCount(mode uint8, subject, subcontext, label string) (int, error)
@summary Get a count of stream presences. @param mode(uint8) The type of stream, 'chat' for example. @param subject(string) The primary stream subject, typically a user ID. @param subcontext(string) A secondary subject, for example for direct chat between two users. @param label(string) Meta-information about the stream, for example a chat room name. @return countByStream(int) Number of current stream presences. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StreamSend ¶
func (n *RuntimeGoNakamaModule) StreamSend(mode uint8, subject, subcontext, label, data string, presences []runtime.Presence, reliable bool) error
@summary Send data to presences on a stream. @param mode(uint8) The type of stream, 'chat' for example. @param subject(string) The primary stream subject, typically a user ID. @param subcontext(string) A secondary subject, for example for direct chat between two users. @param label(string) Meta-information about the stream, for example a chat room name. @param data(string) The data to send. @param presences([]runtime.Presence) Array of presences to receive the sent data. If not set, will be sent to all presences. @param reliable(bool) Whether the sender has been validated prior. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StreamSendRaw ¶
func (n *RuntimeGoNakamaModule) StreamSendRaw(mode uint8, subject, subcontext, label string, msg *rtapi.Envelope, presences []runtime.Presence, reliable bool) error
@summary Send a message to presences on a stream. @param mode(uint8) The type of stream, 'chat' for example. @param subject(string) The primary stream subject, typically a user ID. @param subcontext(string) A secondary subject, for example for direct chat between two users. @param label(string) Meta-information about the stream, for example a chat room name. @param msg(*rtapi.Envelope) The message to send. @param presences([]runtime.Presence) Array of presences to receive the sent data. If not set, will be sent to all presences. @param reliable(bool) Whether the sender has been validated prior. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StreamUserGet ¶
func (n *RuntimeGoNakamaModule) StreamUserGet(mode uint8, subject, subcontext, label, userID, sessionID string) (runtime.PresenceMeta, error)
@summary Retreive a stream presence and metadata by user ID. @param mode(uint8) The type of stream, 'chat' for example. @param subject(string) The primary stream subject, typically a user ID. @param subcontext(string) A secondary subject, for example for direct chat between two users. @param label(string) Meta-information about the stream, for example a chat room name. @param userId(string) The user ID to fetch information for. @param sessionId(string) The current session ID for the user. @return meta(runtime.PresenceMeta) Presence and metadata for the user. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StreamUserJoin ¶
func (n *RuntimeGoNakamaModule) StreamUserJoin(mode uint8, subject, subcontext, label, userID, sessionID string, hidden, persistence bool, status string) (bool, error)
@summary Add a user to a stream. @param mode(uint8) The type of stream, 'chat' for example. @param subject(string) The primary stream subject, typically a user ID. @param subcontext(string) A secondary subject, for example for direct chat between two users. @param label(string) Meta-information about the stream, for example a chat room name. @param userId(string) The user ID to be added. @param sessionId(string) The current session ID for the user. @param hidden(bool) Whether the user will be marked as hidden. @param persistence(bool) Whether message data should be stored in the database. @param status(string) User status message. @return success(bool) Whether the user was successfully added. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StreamUserKick ¶
func (n *RuntimeGoNakamaModule) StreamUserKick(mode uint8, subject, subcontext, label string, presence runtime.Presence) error
@summary Kick a user from a stream. @param mode(uint8) The type of stream, 'chat' for example. @param subject(string) The primary stream subject, typically a user ID. @param subcontext(string) A secondary subject, for example for direct chat between two users. @param label(string) Meta-information about the stream, for example a chat room name. @param presence(runtime.Presence) The presence to be kicked. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StreamUserLeave ¶
func (n *RuntimeGoNakamaModule) StreamUserLeave(mode uint8, subject, subcontext, label, userID, sessionID string) error
@summary Remove a user from a stream. @param mode(uint8) The type of stream, 'chat' for example. @param subject(string) The primary stream subject, typically a user ID. @param subcontext(string) A secondary subject, for example for direct chat between two users. @param label(string) Meta-information about the stream, for example a chat room name. @param userId(string) The user ID to be removed. @param sessionId(string) The current session ID for the user. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StreamUserList ¶
func (n *RuntimeGoNakamaModule) StreamUserList(mode uint8, subject, subcontext, label string, includeHidden, includeNotHidden bool) ([]runtime.Presence, error)
@summary List all users currently online and connected to a stream. @param mode(uint8) The type of stream, 'chat' for example. @param subject(string) The primary stream subject, typically a user ID. @param subcontext(string) A secondary subject, for example for direct chat between two users. @param label(string) Meta-information about the stream, for example a chat room name. @param includeHidden(bool) Include stream presences marked as hidden in the results. @param includeNotHidden(bool) Include stream presences not marked as hidden in the results. @return presences([]runtime.Presences) Array of stream presences and their information. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) StreamUserUpdate ¶
func (n *RuntimeGoNakamaModule) StreamUserUpdate(mode uint8, subject, subcontext, label, userID, sessionID string, hidden, persistence bool, status string) error
@summary Update a stream user by ID. @param mode(uint8) The type of stream, 'chat' for example. @param subject(string) The primary stream subject, typically a user ID. @param subcontext(string) A secondary subject, for example for direct chat between two users. @param label(string) Meta-information about the stream, for example a chat room name. @param userId(string) The user ID to be updated. @param sessionId(string) The current session ID for the user. @param hidden(bool) Whether the user will be marked as hidden. @param persistence(bool) Whether message data should be stored in the database. @param status(string) User status message. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) TournamentAddAttempt ¶
func (n *RuntimeGoNakamaModule) TournamentAddAttempt(ctx context.Context, id, ownerID string, count int) error
@summary Add additional score attempts to the owner's tournament record. This overrides the max number of score attempts allowed in the tournament for this specific owner. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) The unique identifier for the tournament to update. @param owner(string) The owner of the records to increment the count for. @param count(int) The number of attempt counts to increment. Can be negative to decrease count. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) TournamentCreate ¶
func (n *RuntimeGoNakamaModule) TournamentCreate(ctx context.Context, id string, authoritative bool, sortOrder, operator, resetSchedule string, metadata map[string]interface{}, title, description string, category, startTime, endTime, duration, maxSize, maxNumScore int, joinRequired bool) error
@summary Setup a new dynamic tournament with the specified ID and various configuration settings. The underlying leaderboard will be created if it doesn't already exist, otherwise its configuration will not be updated. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) The unique identifier for the new tournament. This is used by clients to submit scores. @param authoritative(bool) Whether the tournament created is server authoritative. Default true. @param sortOrder(string) The sort order for records in the tournament. Possible values are "asc" or "desc" (Default). @param operator(string) The operator that determines how scores behave when submitted. The possible values are "best" (Default), "set", or "incr". @param resetSchedule(string) The cron format used to define the reset schedule for the tournament. This controls when the underlying leaderboard resets and the tournament is considered active again. Optional. @param metadata(map[string]interface{}) The metadata you want associated to the tournament. Some good examples are weather conditions for a racing game. Optional. @param title(string) The title of the tournament. Optional. @param description(string) The description of the tournament. Optional. @param category(int) A category associated with the tournament. This can be used to filter different types of tournaments. Between 0 and 127. Optional. @param startTime(int) The start time of the tournament. Leave empty for immediately or a future time. @param endTime(int) The end time of the tournament. When the end time is elapsed, the tournament will not reset and will cease to exist. Must be greater than startTime if set. Default value is never. @param duration(int) The active duration for a tournament. This is the duration when clients are able to submit new records. The duration starts from either the reset period or tournament start time whichever is sooner. A game client can query the tournament for results between end of duration and next reset period. @param maxSize(int) Maximum size of participants in a tournament. Optional. @param maxNumScore(int) Maximum submission attempts for a tournament record. @param joinRequired(bool) Whether the tournament needs to be joined before a record write is allowed. Defaults to false. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) TournamentDelete ¶
func (n *RuntimeGoNakamaModule) TournamentDelete(ctx context.Context, id string) error
@summary Delete a tournament and all records that belong to it. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) The unique identifier for the tournament to delete. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) TournamentJoin ¶
func (n *RuntimeGoNakamaModule) TournamentJoin(ctx context.Context, id, ownerID, username string) error
@summary A tournament may need to be joined before the owner can submit scores. This operation is idempotent and will always succeed for the owner even if they have already joined the tournament. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) The unique identifier for the tournament to join. @param ownerId(string) The owner of the record. @param username(string) The username of the record owner. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) TournamentList ¶
func (n *RuntimeGoNakamaModule) TournamentList(ctx context.Context, categoryStart, categoryEnd, startTime, endTime, limit int, cursor string) (*api.TournamentList, error)
@summary Find tournaments which have been created on the server. Tournaments can be filtered with categories and via start and end times. @param ctx(context.Context) The context object represents information about the server and requester. @param categoryStart(int) Filter tournament with categories greater or equal than this value. @param categoryEnd(int) Filter tournament with categories equal or less than this value. @param startTime(int) Filter tournament with that start after this time. @param endTime(int) Filter tournament with that end before this time. @param limit(int) Return only the required number of tournament denoted by this limit value. Defaults to 10. @param cursor(string) Cursor to paginate to the next result set. If this is empty/null there is no further results. @return tournamentList([]*api.TournamentList) A list of tournament results and possibly a cursor. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) TournamentRecordWrite ¶
func (n *RuntimeGoNakamaModule) TournamentRecordWrite(ctx context.Context, id, ownerID, username string, score, subscore int64, metadata map[string]interface{}, overrideOperator *int) (*api.LeaderboardRecord, error)
@summary Submit a score and optional subscore to a tournament leaderboard. If the tournament has been configured with join required this will fail unless the owner has already joined the tournament. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) The unique identifier for the tournament leaderboard to submit to. @param owner(string) The owner of this score submission. Mandatory field. @param username(string) The owner username of this score submission, if it's a user. @param score(int64) The score to submit. Default 0. @return subscore(int64) A secondary subscore parameter for the submission. Default 0. @return metadata(map[string]interface{}) The metadata you want associated to this submission. Some good examples are weather conditions for a racing game. @return result(*api.LeaderboardRecord) The newly created leaderboard record. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) TournamentRecordsHaystack ¶
func (n *RuntimeGoNakamaModule) TournamentRecordsHaystack(ctx context.Context, id, ownerID string, limit int, expiry int64) ([]*api.LeaderboardRecord, error)
@summary Fetch the list of tournament records around the owner. @param ctx(context.Context) The context object represents information about the server and requester. @param id(string) The ID of the tournament to list records for. @param ownerId(string) The owner ID around which to show records. @param limit(int) Return only the required number of tournament records denoted by this limit value. Between 1-100. @param expiry(int64) Time since epoch in seconds. Must be greater than 0. @return tournamentRecordsHaystack(*api.Tournament) A list of tournament records. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) TournamentRecordsList ¶
func (n *RuntimeGoNakamaModule) TournamentRecordsList(ctx context.Context, tournamentId string, ownerIDs []string, limit int, cursor string, overrideExpiry int64) ([]*api.LeaderboardRecord, []*api.LeaderboardRecord, string, string, error)
@summary List records on the specified tournament, optionally filtering to only a subset of records by their owners. Records will be listed in the preconfigured tournament sort order. @param ctx(context.Context) The context object represents information about the server and requester. @param tournamentId(string) The ID of the tournament to list records for. @param ownerIds([]string) Array of owner IDs to filter results by. Optional. @param limit(int) Return only the required number of tournament records denoted by this limit value. Max is 10000. @param cursor(string) Cursor to paginate to the next result set. If this is empty/null there are no further results. @param overrideExpiry(int64) Records with expiry in the part are not returned unless within this defined limit. Must be equal or greater than 0. @return records(*api.LeaderboardRecord) A page of tournament records. @return ownerRecords(*api.LeaderboardRecord) A list of owner tournament records (empty if the owners input parameter is not set). @return prevCursor(string) An optional previous page cursor that can be used to retrieve the previous page of records (if any). @return nextCursor(string) An optional next page cursor that can be used to retrieve the next page of records (if any). @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) TournamentsGetId ¶
func (n *RuntimeGoNakamaModule) TournamentsGetId(ctx context.Context, tournamentIDs []string) ([]*api.Tournament, error)
@summary Fetch one or more tournaments by ID. @param ctx(context.Context) The context object represents information about the server and requester. @param ids([]string) The table array of tournament ids. @return result([]*api.Tournament) Array of tournament records. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UnlinkApple ¶
func (n *RuntimeGoNakamaModule) UnlinkApple(ctx context.Context, userID, token string) error
@summary Unlink Apple authentication from a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be unlinked. @param token(string) Apple sign in token. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UnlinkCustom ¶
func (n *RuntimeGoNakamaModule) UnlinkCustom(ctx context.Context, userID, customID string) error
@summary Unlink custom authentication from a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be unlinked. @param customId(string) Custom ID to be unlinked from the user. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UnlinkDevice ¶
func (n *RuntimeGoNakamaModule) UnlinkDevice(ctx context.Context, userID, deviceID string) error
@summary Unlink device authentication from a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be unlinked. @param deviceId(string) Device ID to be unlinked to the user. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UnlinkEmail ¶
func (n *RuntimeGoNakamaModule) UnlinkEmail(ctx context.Context, userID, email string) error
@summary Unlink email authentication from a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be unlinked. @param email(string) Email to be unlinked from the user. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UnlinkFacebook ¶
func (n *RuntimeGoNakamaModule) UnlinkFacebook(ctx context.Context, userID, token string) error
@summary Unlink Facebook authentication from a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be unlinked. @param token(string) Facebook OAuth or Limited Login (JWT) access token. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UnlinkFacebookInstantGame ¶
func (n *RuntimeGoNakamaModule) UnlinkFacebookInstantGame(ctx context.Context, userID, signedPlayerInfo string) error
@summary Unlink Facebook Instant Game authentication from a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be unlinked. @param playerInfo(string) Facebook player info. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UnlinkGameCenter ¶
func (n *RuntimeGoNakamaModule) UnlinkGameCenter(ctx context.Context, userID, playerID, bundleID string, timestamp int64, salt, signature, publicKeyUrl string) error
@summary Unlink Apple Game Center authentication from a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be unlinked. @param playerId(string) Player ID provided by Game Center. @param bundleId(string) Bundle ID of your app on iTunesConnect. @param timestamp(int64) Timestamp at which Game Center authenticated the client and issued a signature. @param salt(string) A random string returned by Game Center authentication on client. @param signature(string) A signature returned by Game Center authentication on client. @param publicKeyUrl(string) A URL to the public key returned by Game Center authentication on client. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UnlinkGoogle ¶
func (n *RuntimeGoNakamaModule) UnlinkGoogle(ctx context.Context, userID, token string) error
@summary Unlink Google authentication from a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be unlinked. @param token(string) Google OAuth access token. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UnlinkSteam ¶
func (n *RuntimeGoNakamaModule) UnlinkSteam(ctx context.Context, userID, token string) error
@summary Unlink Steam authentication from a user ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The user ID to be unlinked. @param token(string) Steam access token. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UserGroupsList ¶
func (n *RuntimeGoNakamaModule) UserGroupsList(ctx context.Context, userID string, limit int, state *int, cursor string) ([]*api.UserGroupList_UserGroup, string, error)
@summary List all groups which a user belongs to and whether they've been accepted or if it's an invite. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The ID of the user to list groups for. @return userGroups([]*api.UserGroupList_UserGroup) A table of groups with their fields. @return cursor(string) An optional next page cursor that can be used to retrieve the next page of records (if any). @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UsersBanId ¶
func (n *RuntimeGoNakamaModule) UsersBanId(ctx context.Context, userIDs []string) error
@summary Ban one or more users by ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userIds([]string) An array of user IDs to ban. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UsersGetId ¶
func (n *RuntimeGoNakamaModule) UsersGetId(ctx context.Context, userIDs []string, facebookIDs []string) ([]*api.User, error)
@summary Fetch one or more users by ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userIds([]string) An array of user IDs to fetch. @return users([]*api.Users) A list of user record objects. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UsersGetRandom ¶ added in v3.5.0
@summary Fetch one or more users randomly. @param ctx(context.Context) The context object represents information about the server and requester. @param count(int) The number of users to fetch. @return users([]*api.Users) A list of user record objects. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UsersGetUsername ¶
func (n *RuntimeGoNakamaModule) UsersGetUsername(ctx context.Context, usernames []string) ([]*api.User, error)
@summary Fetch one or more users by username. @param ctx(context.Context) The context object represents information about the server and requester. @param usernames([]string) An array of usernames to fetch. @return users([]*api.Users) A list of user record objects. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) UsersUnbanId ¶
func (n *RuntimeGoNakamaModule) UsersUnbanId(ctx context.Context, userIDs []string) error
@summary Unban one or more users by ID. @param ctx(context.Context) The context object represents information about the server and requester. @param userIds([]string) An array of user IDs to unban. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) WalletLedgerList ¶
func (n *RuntimeGoNakamaModule) WalletLedgerList(ctx context.Context, userID string, limit int, cursor string) ([]runtime.WalletLedgerItem, string, error)
@summary List all wallet updates for a particular user from oldest to newest. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The ID of the user to list wallet updates for. @param limit(int) Limit number of results. Defaults to 100. @param cursor(string) Pagination cursor from previous result. If none available set to nil or "" (empty string). @return runtimeItems([]runtime.WalletLedgerItem) A Go slice containing wallet entries with Id, UserId, CreateTime, UpdateTime, Changeset, Metadata parameters. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) WalletLedgerUpdate ¶
func (n *RuntimeGoNakamaModule) WalletLedgerUpdate(ctx context.Context, itemID string, metadata map[string]interface{}) (runtime.WalletLedgerItem, error)
@summary Update the metadata for a particular wallet update in a user's wallet ledger history. Useful when adding a note to a transaction for example. @param ctx(context.Context) The context object represents information about the server and requester. @param itemId(string) The ID of the wallet ledger item to update. @param metadata(map[string]interface{}) The new metadata to set on the wallet ledger item. @return updateWalletLedger(runtime.WalletLedgerItem) The updated wallet ledger item. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) WalletUpdate ¶
func (n *RuntimeGoNakamaModule) WalletUpdate(ctx context.Context, userID string, changeset map[string]int64, metadata map[string]interface{}, updateLedger bool) (map[string]int64, map[string]int64, error)
@summary Update a user's wallet with the given changeset. @param ctx(context.Context) The context object represents information about the server and requester. @param userId(string) The ID of the user whose wallet to update. @param changeset(map[string]int64) The set of wallet operations to apply. @param metadata(map[string]interface{}) Additional metadata to tag the wallet update with. @param updateLedger(bool) Whether to record this update in the ledger. Defaults to false. @return error(error) An optional error value if an error occurred.
func (*RuntimeGoNakamaModule) WalletsUpdate ¶
func (n *RuntimeGoNakamaModule) WalletsUpdate(ctx context.Context, updates []*runtime.WalletUpdate, updateLedger bool) ([]*runtime.WalletUpdateResult, error)
@summary Update one or more user wallets with individual changesets. This function will also insert a new wallet ledger item into each user's wallet history that tracks their update. @param ctx(context.Context) The context object represents information about the server and requester. @param updates([]*runtime.WalletUpdate) The set of user wallet update operations to apply. @param updateLedger(bool) Whether to record this update in the ledger. Defaults to false. @return updateWallets(runtime.WallateUpdateResult) A list of wallet update results. @return error(error) An optional error value if an error occurred.
type RuntimeInfo ¶
type RuntimeJS ¶
type RuntimeJS struct {
// contains filtered or unexported fields
}
func (*RuntimeJS) GetCallback ¶
func (r *RuntimeJS) GetCallback(e RuntimeExecutionMode, key string) string
func (*RuntimeJS) InvokeFunction ¶
func (r *RuntimeJS) InvokeFunction(execMode RuntimeExecutionMode, id string, fn goja.Callable, logger goja.Value, httpHeaders, queryParams map[string][]string, uid, username string, vars map[string]string, sessionExpiry int64, sid, clientIP, clientPort, lang string, payloads ...interface{}) (interface{}, error, codes.Code)
type RuntimeJSModule ¶
type RuntimeJSModuleCache ¶
type RuntimeJSModuleCache struct { Names []string Modules map[string]*RuntimeJSModule }
func (*RuntimeJSModuleCache) Add ¶
func (mc *RuntimeJSModuleCache) Add(m *RuntimeJSModule)
type RuntimeJavaScriptMatchCore ¶
type RuntimeJavaScriptMatchCore struct {
// contains filtered or unexported fields
}
func (*RuntimeJavaScriptMatchCore) Cancel ¶
func (rm *RuntimeJavaScriptMatchCore) Cancel()
func (*RuntimeJavaScriptMatchCore) Cleanup ¶ added in v3.10.0
func (rm *RuntimeJavaScriptMatchCore) Cleanup()
func (*RuntimeJavaScriptMatchCore) CreateTime ¶ added in v3.1.2
func (rm *RuntimeJavaScriptMatchCore) CreateTime() int64
func (*RuntimeJavaScriptMatchCore) GetState ¶
func (rm *RuntimeJavaScriptMatchCore) GetState(state interface{}) (string, error)
func (*RuntimeJavaScriptMatchCore) HandlerName ¶
func (rm *RuntimeJavaScriptMatchCore) HandlerName() string
func (*RuntimeJavaScriptMatchCore) Label ¶
func (rm *RuntimeJavaScriptMatchCore) Label() string
func (*RuntimeJavaScriptMatchCore) MatchInit ¶
func (rm *RuntimeJavaScriptMatchCore) MatchInit(presenceList *MatchPresenceList, deferMessageFn RuntimeMatchDeferMessageFunction, params map[string]interface{}) (interface{}, int, error)
func (*RuntimeJavaScriptMatchCore) MatchJoin ¶
func (rm *RuntimeJavaScriptMatchCore) MatchJoin(tick int64, state interface{}, joins []*MatchPresence) (interface{}, error)
func (*RuntimeJavaScriptMatchCore) MatchJoinAttempt ¶
func (*RuntimeJavaScriptMatchCore) MatchLeave ¶
func (rm *RuntimeJavaScriptMatchCore) MatchLeave(tick int64, state interface{}, leaves []*MatchPresence) (interface{}, error)
func (*RuntimeJavaScriptMatchCore) MatchLoop ¶
func (rm *RuntimeJavaScriptMatchCore) MatchLoop(tick int64, state interface{}, inputCh <-chan *MatchDataMessage) (interface{}, error)
func (*RuntimeJavaScriptMatchCore) MatchSignal ¶ added in v3.8.0
func (rm *RuntimeJavaScriptMatchCore) MatchSignal(tick int64, state interface{}, data string) (interface{}, string, error)
func (*RuntimeJavaScriptMatchCore) MatchTerminate ¶
func (rm *RuntimeJavaScriptMatchCore) MatchTerminate(tick int64, state interface{}, graceSeconds int) (interface{}, error)
func (*RuntimeJavaScriptMatchCore) TickRate ¶ added in v3.1.2
func (rm *RuntimeJavaScriptMatchCore) TickRate() int
type RuntimeJavascriptInitModule ¶
type RuntimeJavascriptInitModule struct { Logger *zap.Logger Callbacks *RuntimeJavascriptCallbacks MatchCallbacks *RuntimeJavascriptMatchHandlers // contains filtered or unexported fields }
func NewRuntimeJavascriptInitModule ¶
func NewRuntimeJavascriptInitModule(logger *zap.Logger, ast *ast.Program, callbacks *RuntimeJavascriptCallbacks, matchCallbacks *RuntimeJavascriptMatchHandlers, announceCallbackFn func(RuntimeExecutionMode, string)) *RuntimeJavascriptInitModule
func (*RuntimeJavascriptInitModule) Constructor ¶
func (im *RuntimeJavascriptInitModule) Constructor(r *goja.Runtime) func(goja.ConstructorCall) *goja.Object
type RuntimeJavascriptLocalCache ¶ added in v3.1.0
func NewRuntimeJavascriptLocalCache ¶ added in v3.1.0
func NewRuntimeJavascriptLocalCache() *RuntimeJavascriptLocalCache
func (*RuntimeJavascriptLocalCache) Delete ¶ added in v3.1.0
func (lc *RuntimeJavascriptLocalCache) Delete(key string)
type RuntimeJavascriptMatchHandlers ¶
type RuntimeJavascriptMatchHandlers struct { sync.RWMutex // contains filtered or unexported fields }
func (*RuntimeJavascriptMatchHandlers) Add ¶
func (rmh *RuntimeJavascriptMatchHandlers) Add(name string, handlers *jsMatchHandlers)
func (*RuntimeJavascriptMatchHandlers) Get ¶
func (rmh *RuntimeJavascriptMatchHandlers) Get(name string) *jsMatchHandlers
type RuntimeLua ¶
type RuntimeLua struct {
// contains filtered or unexported fields
}
func (*RuntimeLua) GetCallback ¶
func (r *RuntimeLua) GetCallback(e RuntimeExecutionMode, key string) *lua.LFunction
func (*RuntimeLua) InvokeFunction ¶
func (r *RuntimeLua) InvokeFunction(execMode RuntimeExecutionMode, fn *lua.LFunction, headers, queryParams map[string][]string, uid string, username string, vars map[string]string, sessionExpiry int64, sid string, clientIP, clientPort, lang string, payloads ...interface{}) (interface{}, error, codes.Code, bool)
func (*RuntimeLua) Stop ¶
func (r *RuntimeLua) Stop()
type RuntimeLuaCallbacks ¶
type RuntimeLuaLocalCache ¶
func NewRuntimeLuaLocalCache ¶
func NewRuntimeLuaLocalCache() *RuntimeLuaLocalCache
func (*RuntimeLuaLocalCache) Delete ¶
func (lc *RuntimeLuaLocalCache) Delete(key string)
type RuntimeLuaMatchCore ¶
type RuntimeLuaMatchCore struct {
// contains filtered or unexported fields
}
func (*RuntimeLuaMatchCore) Cancel ¶
func (r *RuntimeLuaMatchCore) Cancel()
func (*RuntimeLuaMatchCore) Cleanup ¶ added in v3.10.0
func (r *RuntimeLuaMatchCore) Cleanup()
func (*RuntimeLuaMatchCore) CreateTime ¶ added in v3.1.2
func (r *RuntimeLuaMatchCore) CreateTime() int64
func (*RuntimeLuaMatchCore) GetState ¶
func (r *RuntimeLuaMatchCore) GetState(state interface{}) (string, error)
func (*RuntimeLuaMatchCore) HandlerName ¶
func (r *RuntimeLuaMatchCore) HandlerName() string
func (*RuntimeLuaMatchCore) Label ¶
func (r *RuntimeLuaMatchCore) Label() string
func (*RuntimeLuaMatchCore) MatchInit ¶
func (r *RuntimeLuaMatchCore) MatchInit(presenceList *MatchPresenceList, deferMessageFn RuntimeMatchDeferMessageFunction, params map[string]interface{}) (interface{}, int, error)
func (*RuntimeLuaMatchCore) MatchJoin ¶
func (r *RuntimeLuaMatchCore) MatchJoin(tick int64, state interface{}, joins []*MatchPresence) (interface{}, error)
func (*RuntimeLuaMatchCore) MatchJoinAttempt ¶
func (*RuntimeLuaMatchCore) MatchLeave ¶
func (r *RuntimeLuaMatchCore) MatchLeave(tick int64, state interface{}, leaves []*MatchPresence) (interface{}, error)
func (*RuntimeLuaMatchCore) MatchLoop ¶
func (r *RuntimeLuaMatchCore) MatchLoop(tick int64, state interface{}, inputCh <-chan *MatchDataMessage) (interface{}, error)
func (*RuntimeLuaMatchCore) MatchSignal ¶ added in v3.8.0
func (r *RuntimeLuaMatchCore) MatchSignal(tick int64, state interface{}, data string) (interface{}, string, error)
func (*RuntimeLuaMatchCore) MatchTerminate ¶
func (r *RuntimeLuaMatchCore) MatchTerminate(tick int64, state interface{}, graceSeconds int) (interface{}, error)
func (*RuntimeLuaMatchCore) TickRate ¶ added in v3.1.2
func (r *RuntimeLuaMatchCore) TickRate() int
type RuntimeLuaModule ¶
type RuntimeLuaModuleCache ¶
type RuntimeLuaModuleCache struct { Names []string Modules map[string]*RuntimeLuaModule }
func (*RuntimeLuaModuleCache) Add ¶
func (mc *RuntimeLuaModuleCache) Add(m *RuntimeLuaModule)
type RuntimeLuaNakamaModule ¶
type RuntimeLuaNakamaModule struct {
// contains filtered or unexported fields
}
func NewRuntimeLuaNakamaModule ¶
func NewRuntimeLuaNakamaModule(logger *zap.Logger, db *sql.DB, protojsonMarshaler *protojson.MarshalOptions, protojsonUnmarshaler *protojson.UnmarshalOptions, config Config, socialClient *social.Client, leaderboardCache LeaderboardCache, rankCache LeaderboardRankCache, leaderboardScheduler LeaderboardScheduler, sessionRegistry SessionRegistry, sessionCache SessionCache, matchRegistry MatchRegistry, tracker Tracker, streamManager StreamManager, router MessageRouter, once *sync.Once, localCache *RuntimeLuaLocalCache, matchCreateFn RuntimeMatchCreateFunction, eventFn RuntimeEventCustomFunction, registerCallbackFn func(RuntimeExecutionMode, string, *lua.LFunction), announceCallbackFn func(RuntimeExecutionMode, string)) *RuntimeLuaNakamaModule
type RuntimeMatchCore ¶
type RuntimeMatchCore interface { MatchInit(presenceList *MatchPresenceList, deferMessageFn RuntimeMatchDeferMessageFunction, params map[string]interface{}) (interface{}, int, error) MatchJoinAttempt(tick int64, state interface{}, userID, sessionID uuid.UUID, username string, sessionExpiry int64, vars map[string]string, clientIP, clientPort, node string, metadata map[string]string) (interface{}, bool, string, error) MatchJoin(tick int64, state interface{}, joins []*MatchPresence) (interface{}, error) MatchLeave(tick int64, state interface{}, leaves []*MatchPresence) (interface{}, error) MatchLoop(tick int64, state interface{}, inputCh <-chan *MatchDataMessage) (interface{}, error) MatchTerminate(tick int64, state interface{}, graceSeconds int) (interface{}, error) MatchSignal(tick int64, state interface{}, data string) (interface{}, string, error) GetState(state interface{}) (string, error) Label() string TickRate() int HandlerName() string CreateTime() int64 Cancel() Cleanup() }
func NewRuntimeGoMatchCore ¶
func NewRuntimeGoMatchCore(logger *zap.Logger, module string, matchRegistry MatchRegistry, router MessageRouter, id uuid.UUID, node string, stopped *atomic.Bool, db *sql.DB, env map[string]string, nk runtime.NakamaModule, match runtime.Match) (RuntimeMatchCore, error)
func NewRuntimeJavascriptMatchCore ¶
func NewRuntimeJavascriptMatchCore(logger *zap.Logger, module string, db *sql.DB, protojsonMarshaler *protojson.MarshalOptions, protojsonUnmarshaler *protojson.UnmarshalOptions, config Config, socialClient *social.Client, leaderboardCache LeaderboardCache, rankCache LeaderboardRankCache, localCache *RuntimeJavascriptLocalCache, leaderboardScheduler LeaderboardScheduler, sessionRegistry SessionRegistry, sessionCache SessionCache, matchRegistry MatchRegistry, tracker Tracker, streamManager StreamManager, router MessageRouter, matchCreateFn RuntimeMatchCreateFunction, eventFn RuntimeEventCustomFunction, id uuid.UUID, node string, stopped *atomic.Bool, matchHandlers *jsMatchHandlers, modCache *RuntimeJSModuleCache) (RuntimeMatchCore, error)
func NewRuntimeLuaMatchCore ¶
func NewRuntimeLuaMatchCore(logger *zap.Logger, module string, db *sql.DB, protojsonMarshaler *protojson.MarshalOptions, protojsonUnmarshaler *protojson.UnmarshalOptions, config Config, socialClient *social.Client, leaderboardCache LeaderboardCache, rankCache LeaderboardRankCache, leaderboardScheduler LeaderboardScheduler, sessionRegistry SessionRegistry, sessionCache SessionCache, matchRegistry MatchRegistry, tracker Tracker, streamManager StreamManager, router MessageRouter, stdLibs map[string]lua.LGFunction, once *sync.Once, localCache *RuntimeLuaLocalCache, eventFn RuntimeEventCustomFunction, sharedReg, sharedGlobals *lua.LTable, id uuid.UUID, node string, stopped *atomic.Bool, name string, matchProvider *MatchProvider) (RuntimeMatchCore, error)
type RuntimeMatchDeferMessageFunction ¶
type RuntimeMatchDeferMessageFunction func(msg *DeferredMessage) error
type RuntimeProviderJS ¶
type RuntimeProviderJS struct {
// contains filtered or unexported fields
}
func (*RuntimeProviderJS) Get ¶
func (rp *RuntimeProviderJS) Get(ctx context.Context) (*RuntimeJS, error)
func (*RuntimeProviderJS) LeaderboardReset ¶
func (rp *RuntimeProviderJS) LeaderboardReset(ctx context.Context, leaderboard *api.Leaderboard, reset int64) error
func (*RuntimeProviderJS) MatchmakerMatched ¶
func (rp *RuntimeProviderJS) MatchmakerMatched(ctx context.Context, entries []*MatchmakerEntry) (string, bool, error)
func (*RuntimeProviderJS) Put ¶
func (rp *RuntimeProviderJS) Put(r *RuntimeJS)
func (*RuntimeProviderJS) TournamentEnd ¶
func (rp *RuntimeProviderJS) TournamentEnd(ctx context.Context, tournament *api.Tournament, end, reset int64) error
func (*RuntimeProviderJS) TournamentReset ¶
func (rp *RuntimeProviderJS) TournamentReset(ctx context.Context, tournament *api.Tournament, end, reset int64) error
type RuntimeProviderLua ¶
type RuntimeProviderLua struct {
// contains filtered or unexported fields
}
func (*RuntimeProviderLua) Get ¶
func (rp *RuntimeProviderLua) Get(ctx context.Context) (*RuntimeLua, error)
func (*RuntimeProviderLua) LeaderboardReset ¶
func (rp *RuntimeProviderLua) LeaderboardReset(ctx context.Context, leaderboard *api.Leaderboard, reset int64) error
func (*RuntimeProviderLua) MatchmakerMatched ¶
func (rp *RuntimeProviderLua) MatchmakerMatched(ctx context.Context, entries []*MatchmakerEntry) (string, bool, error)
func (*RuntimeProviderLua) Put ¶
func (rp *RuntimeProviderLua) Put(r *RuntimeLua)
func (*RuntimeProviderLua) TournamentEnd ¶
func (rp *RuntimeProviderLua) TournamentEnd(ctx context.Context, tournament *api.Tournament, end, reset int64) error
func (*RuntimeProviderLua) TournamentReset ¶
func (rp *RuntimeProviderLua) TournamentReset(ctx context.Context, tournament *api.Tournament, end, reset int64) error
type RuntimeRpcFunction ¶
type Scannable ¶
type Scannable interface {
Scan(dest ...interface{}) error
}
Scannable Interface to help utility functions accept either *sql.Row or *sql.Rows for scanning one row at a time.
type Session ¶
type Session interface { Logger() *zap.Logger ID() uuid.UUID UserID() uuid.UUID Vars() map[string]string ClientIP() string ClientPort() string Lang() string Context() context.Context Username() string SetUsername(string) Expiry() int64 Consume() Format() SessionFormat Send(envelope *rtapi.Envelope, reliable bool) error SendBytes(payload []byte, reliable bool) error Close(msg string, reason runtime.PresenceReason, envelopes ...*rtapi.Envelope) }
func NewSessionWS ¶
func NewSessionWS(logger *zap.Logger, config Config, format SessionFormat, sessionID, userID uuid.UUID, username string, vars map[string]string, expiry int64, clientIP, clientPort, lang string, protojsonMarshaler *protojson.MarshalOptions, protojsonUnmarshaler *protojson.UnmarshalOptions, conn *websocket.Conn, sessionRegistry SessionRegistry, statusRegistry *StatusRegistry, matchmaker Matchmaker, tracker Tracker, metrics Metrics, pipeline *Pipeline, runtime *Runtime) Session
type SessionCache ¶ added in v3.2.0
type SessionCache interface { Stop() // Check if a given user, expiry, and session token combination is valid. IsValidSession(userID uuid.UUID, exp int64, token string) bool // Check if a given user, expiry, and refresh token combination is valid. IsValidRefresh(userID uuid.UUID, exp int64, token string) bool // Add a valid session and/or refresh token for a given user. Add(userID uuid.UUID, sessionExp int64, sessionToken string, refreshExp int64, refreshToken string) // Remove a session and/or refresh token for a given user. Remove(userID uuid.UUID, sessionExp int64, sessionToken string, refreshExp int64, refreshToken string) // Remove all of a user's session and refresh tokens. RemoveAll(userID uuid.UUID) // Mark a set of users as banned. Ban(userIDs []uuid.UUID) // Unban a set of users. Unban(userIDs []uuid.UUID) }
func NewLocalSessionCache ¶ added in v3.2.0
func NewLocalSessionCache(config Config) SessionCache
type SessionConfig ¶
type SessionConfig struct { EncryptionKey string `yaml:"encryption_key" json:"encryption_key" usage:"The encryption key used to produce the client token."` TokenExpirySec int64 `yaml:"token_expiry_sec" json:"token_expiry_sec" usage:"Token expiry in seconds."` RefreshEncryptionKey string `` /* 128-byte string literal not displayed */ RefreshTokenExpirySec int64 `yaml:"refresh_token_expiry_sec" json:"refresh_token_expiry_sec" usage:"Refresh token expiry in seconds."` SingleSocket bool `` /* 129-byte string literal not displayed */ SingleMatch bool `` /* 158-byte string literal not displayed */ }
SessionConfig is configuration relevant to the session.
func NewSessionConfig ¶
func NewSessionConfig() *SessionConfig
NewSessionConfig creates a new SessionConfig struct.
type SessionFormat ¶
type SessionFormat uint8
const ( SessionFormatJson SessionFormat = iota SessionFormatProtobuf )
type SessionRegistry ¶
type SessionRegistry interface { Stop() Count() int Get(sessionID uuid.UUID) Session Add(session Session) Remove(sessionID uuid.UUID) Disconnect(ctx context.Context, sessionID uuid.UUID, reason ...runtime.PresenceReason) error SingleSession(ctx context.Context, tracker Tracker, userID, sessionID uuid.UUID) }
func NewLocalSessionRegistry ¶
func NewLocalSessionRegistry(metrics Metrics) SessionRegistry
type SessionTokenClaims ¶
type SessionTokenClaims struct { UserId string `json:"uid,omitempty"` Username string `json:"usn,omitempty"` Vars map[string]string `json:"vrs,omitempty"` ExpiresAt int64 `json:"exp,omitempty"` }
func (*SessionTokenClaims) Valid ¶
func (stc *SessionTokenClaims) Valid() error
type SocialConfig ¶
type SocialConfig struct { Steam *SocialConfigSteam `yaml:"steam" json:"steam" usage:"Steam configuration."` FacebookInstantGame *SocialConfigFacebookInstantGame `yaml:"facebook_instant_game" json:"facebook_instant_game" usage:"Facebook Instant Game configuration."` FacebookLimitedLogin *SocialConfigFacebookLimitedLogin `yaml:"facebook_limited_login" json:"facebook_limited_login" usage:"Facebook Limited Login configuration."` Apple *SocialConfigApple `yaml:"apple" json:"apple" usage:"Apple Sign In configuration."` }
SocialConfig is configuration relevant to the social authentication providers.
func NewSocialConfig ¶
func NewSocialConfig() *SocialConfig
NewSocialConfig creates a new SocialConfig struct.
type SocialConfigApple ¶
type SocialConfigApple struct {
BundleId string `yaml:"bundle_id" json:"bundle_id" usage:"Apple Sign In bundle ID."`
}
SocialConfigApple is configuration relevant to Apple Sign In.
type SocialConfigFacebookInstantGame ¶
type SocialConfigFacebookInstantGame struct {
AppSecret string `yaml:"app_secret" json:"app_secret" usage:"Facebook Instant App secret."`
}
SocialConfigFacebookInstantGame is configuration relevant to Facebook Instant Games.
type SocialConfigFacebookLimitedLogin ¶ added in v3.2.0
type SocialConfigFacebookLimitedLogin struct {
AppId string `yaml:"app_id" json:"app_id" usage:"Facebook Limited Login App ID."`
}
SocialConfigFacebookLimitedLogin is configuration relevant to Facebook Limited Login.
type SocialConfigSteam ¶
type SocialConfigSteam struct { PublisherKey string `yaml:"publisher_key" json:"publisher_key" usage:"Steam Publisher Key value."` AppID int `yaml:"app_id" json:"app_id" usage:"Steam App ID."` }
SocialConfigSteam is configuration relevant to Steam.
type SocketConfig ¶
type SocketConfig struct { ServerKey string `yaml:"server_key" json:"server_key" usage:"Server key to use to establish a connection to the server."` Port int `` /* 154-byte string literal not displayed */ Address string `` /* 156-byte string literal not displayed */ Protocol string `` /* 198-byte string literal not displayed */ MaxMessageSizeBytes int64 `` /* 186-byte string literal not displayed */ MaxRequestSizeBytes int64 `` /* 180-byte string literal not displayed */ ReadBufferSizeBytes int `` /* 136-byte string literal not displayed */ WriteBufferSizeBytes int `` /* 139-byte string literal not displayed */ ReadTimeoutMs int `` /* 145-byte string literal not displayed */ WriteTimeoutMs int `` /* 157-byte string literal not displayed */ IdleTimeoutMs int `` /* 178-byte string literal not displayed */ WriteWaitMs int `` /* 156-byte string literal not displayed */ PongWaitMs int `` /* 156-byte string literal not displayed */ PingPeriodMs int `` /* 204-byte string literal not displayed */ PingBackoffThreshold int `` /* 293-byte string literal not displayed */ OutgoingQueueSize int `` /* 245-byte string literal not displayed */ SSLCertificate string `` /* 192-byte string literal not displayed */ SSLPrivateKey string `` /* 192-byte string literal not displayed */ CertPEMBlock []byte `yaml:"-" json:"-"` // Created by fully reading the file contents of SSLCertificate, not set from input args directly. KeyPEMBlock []byte `yaml:"-" json:"-"` // Created by fully reading the file contents of SSLPrivateKey, not set from input args directly. TLSCert []tls.Certificate `yaml:"-" json:"-"` // Created by processing CertPEMBlock and KeyPEMBlock, not set from input args directly. }
SocketConfig is configuration relevant to the transport socket and protocol.
func NewSocketConfig ¶
func NewSocketConfig() *SocketConfig
NewTransportConfig creates a new TransportConfig struct.
type StatusHandler ¶
type StatusHandler interface {
GetStatus(ctx context.Context) ([]*console.StatusList_Status, error)
}
func NewLocalStatusHandler ¶
func NewLocalStatusHandler(logger *zap.Logger, sessionRegistry SessionRegistry, matchRegistry MatchRegistry, tracker Tracker, metrics Metrics, node string) StatusHandler
type StatusRegistry ¶ added in v3.1.1
func NewStatusRegistry ¶ added in v3.1.1
func NewStatusRegistry(logger *zap.Logger, config Config, sessionRegistry SessionRegistry, protojsonMarshaler *protojson.MarshalOptions) *StatusRegistry
func (*StatusRegistry) Follow ¶ added in v3.1.1
func (s *StatusRegistry) Follow(sessionID uuid.UUID, userIDs map[uuid.UUID]struct{})
func (*StatusRegistry) Queue ¶ added in v3.1.1
func (s *StatusRegistry) Queue(userID uuid.UUID, joins, leaves []*rtapi.UserPresence)
func (*StatusRegistry) Stop ¶ added in v3.1.1
func (s *StatusRegistry) Stop()
func (*StatusRegistry) Unfollow ¶ added in v3.1.1
func (s *StatusRegistry) Unfollow(sessionID uuid.UUID, userIDs []uuid.UUID)
func (*StatusRegistry) UnfollowAll ¶ added in v3.1.1
func (s *StatusRegistry) UnfollowAll(sessionID uuid.UUID)
type StorageOpDelete ¶
type StorageOpDelete struct { OwnerID string ObjectID *api.DeleteStorageObjectId }
type StorageOpDeletes ¶
type StorageOpDeletes []*StorageOpDelete
Internal representation for a batch of storage delete operations.
func (StorageOpDeletes) Len ¶
func (s StorageOpDeletes) Len() int
func (StorageOpDeletes) Less ¶
func (s StorageOpDeletes) Less(i, j int) bool
func (StorageOpDeletes) Swap ¶
func (s StorageOpDeletes) Swap(i, j int)
type StorageOpWrite ¶
type StorageOpWrite struct { OwnerID string Object *api.WriteStorageObject }
type StorageOpWrites ¶
type StorageOpWrites []*StorageOpWrite
Internal representation for a batch of storage write operations.
func (StorageOpWrites) Len ¶
func (s StorageOpWrites) Len() int
func (StorageOpWrites) Less ¶
func (s StorageOpWrites) Less(i, j int) bool
func (StorageOpWrites) Swap ¶
func (s StorageOpWrites) Swap(i, j int)
type StreamManager ¶
type StreamManager interface { UserJoin(stream PresenceStream, userID, sessionID uuid.UUID, hidden, persistence bool, status string) (bool, bool, error) UserUpdate(stream PresenceStream, userID, sessionID uuid.UUID, hidden, persistence bool, status string) (bool, error) UserLeave(stream PresenceStream, userID, sessionID uuid.UUID) error }
func NewLocalStreamManager ¶
func NewLocalStreamManager(config Config, sessionRegistry SessionRegistry, tracker Tracker) StreamManager
type TournamentListCursor ¶
type TournamentListCursor struct {
Id string
}
type Tracker ¶
type Tracker interface { SetMatchJoinListener(func(id uuid.UUID, joins []*MatchPresence)) SetMatchLeaveListener(func(id uuid.UUID, leaves []*MatchPresence)) SetPartyJoinListener(func(id uuid.UUID, joins []*Presence)) SetPartyLeaveListener(func(id uuid.UUID, leaves []*Presence)) Stop() // Track returns success true/false, and new presence true/false. Track(ctx context.Context, sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID, meta PresenceMeta, allowIfFirstForSession bool) (bool, bool) TrackMulti(ctx context.Context, sessionID uuid.UUID, ops []*TrackerOp, userID uuid.UUID, allowIfFirstForSession bool) bool Untrack(sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID) UntrackMulti(sessionID uuid.UUID, streams []*PresenceStream, userID uuid.UUID) UntrackAll(sessionID uuid.UUID, reason runtime.PresenceReason) // Update returns success true/false - will only fail if the user has no presence and allowIfFirstForSession is false, otherwise is an upsert. Update(ctx context.Context, sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID, meta PresenceMeta, allowIfFirstForSession bool) bool // Remove all presences on a stream, effectively closing it. UntrackByStream(stream PresenceStream) // Remove all presences on a stream from the local node. UntrackLocalByStream(stream PresenceStream) // Remove the given session from any streams matching the given mode, except the specified stream. UntrackLocalByModes(sessionID uuid.UUID, modes map[uint8]struct{}, skipStream PresenceStream) // List the nodes that have at least one presence for the given stream. ListNodesForStream(stream PresenceStream) map[string]struct{} // Check if a stream exists (has any presences) or not. StreamExists(stream PresenceStream) bool // Get current total number of presences. Count() int // Get the number of presences in the given stream. CountByStream(stream PresenceStream) int // Get a snapshot of current presence counts for streams with one of the given stream modes. CountByStreamModeFilter(modes map[uint8]*uint8) map[*PresenceStream]int32 // Check if a single presence on the current node exists. GetLocalBySessionIDStreamUserID(sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID) *PresenceMeta // Check if a single presence on any node exists. GetBySessionIDStreamUserID(node string, sessionID uuid.UUID, stream PresenceStream, userID uuid.UUID) *PresenceMeta // List presences by stream, optionally include hidden ones and not hidden ones. ListByStream(stream PresenceStream, includeHidden bool, includeNotHidden bool) []*Presence // Fast lookup of local session IDs to use for message delivery. ListLocalSessionIDByStream(stream PresenceStream) []uuid.UUID // Fast lookup of node + session IDs to use for message delivery. ListPresenceIDByStream(stream PresenceStream) []*PresenceID }
func StartLocalTracker ¶
func StartLocalTracker(logger *zap.Logger, config Config, sessionRegistry SessionRegistry, statusRegistry *StatusRegistry, metrics Metrics, protojsonMarshaler *protojson.MarshalOptions) Tracker
type TrackerConfig ¶
type TrackerConfig struct {
EventQueueSize int `` /* 210-byte string literal not displayed */
}
TrackerConfig is configuration relevant to the presence tracker.
func NewTrackerConfig ¶
func NewTrackerConfig() *TrackerConfig
NewTrackerConfig creates a new TrackerConfig struct.
type TrackerOp ¶ added in v3.1.0
type TrackerOp struct { Stream PresenceStream Meta PresenceMeta }
type Tx ¶
type Tx interface { ExecContext(context.Context, string, ...interface{}) (sql.Result, error) Commit() error Rollback() error }
Tx is used to permit clients to implement custom transaction logic.
type TxnRestartError ¶
type TxnRestartError struct {
// contains filtered or unexported fields
}
TxnRestartError represents an error when restarting a transaction. `cause` is the error from restarting the txn and `retryCause` is the original error which triggered the restart.
func (*TxnRestartError) Cause ¶
func (e *TxnRestartError) Cause() error
Cause implements the ErrorCauser interface.
func (*TxnRestartError) Error ¶
func (e *TxnRestartError) Error() string
Error implements the error interface.
func (*TxnRestartError) RetryCause ¶
func (e *TxnRestartError) RetryCause() error
RetryCause returns the error that caused the transaction to be restarted.
type ValidatableQuery ¶ added in v3.9.0
type ValidatableQuery interface {
Validate() error
}
Source Files ¶
- api.go
- api_account.go
- api_authenticate.go
- api_channel.go
- api_event.go
- api_friend.go
- api_group.go
- api_leaderboard.go
- api_link.go
- api_match.go
- api_notification.go
- api_purchase.go
- api_rpc.go
- api_session.go
- api_storage.go
- api_tournament.go
- api_unlink.go
- api_user.go
- config.go
- console.go
- console_account.go
- console_api_explorer.go
- console_authenticate.go
- console_config.go
- console_leaderboard.go
- console_match.go
- console_purchase.go
- console_runtime.go
- console_status.go
- console_storage.go
- console_storage_import.go
- console_unlink.go
- console_user.go
- core_account.go
- core_authenticate.go
- core_channel.go
- core_file.go
- core_friend.go
- core_group.go
- core_leaderboard.go
- core_link.go
- core_message.go
- core_multi.go
- core_notification.go
- core_purchase.go
- core_session.go
- core_storage.go
- core_tournament.go
- core_unlink.go
- core_user.go
- core_wallet.go
- db.go
- db_error.go
- leaderboard_cache.go
- leaderboard_rank_cache.go
- leaderboard_scheduler.go
- logger.go
- match_common.go
- match_handler.go
- match_presence.go
- match_registry.go
- matchmaker.go
- message_router.go
- metrics.go
- metrics_grpc_handler.go
- party_handler.go
- party_registry.go
- pipeline.go
- pipeline_channel.go
- pipeline_match.go
- pipeline_matchmaker.go
- pipeline_party.go
- pipeline_ping.go
- pipeline_rpc.go
- pipeline_status.go
- runtime.go
- runtime_event.go
- runtime_go.go
- runtime_go_context.go
- runtime_go_logger.go
- runtime_go_match_core.go
- runtime_go_nakama.go
- runtime_javascript.go
- runtime_javascript_context.go
- runtime_javascript_init.go
- runtime_javascript_localcache.go
- runtime_javascript_logger.go
- runtime_javascript_match_core.go
- runtime_javascript_nakama.go
- runtime_lua.go
- runtime_lua_bit32.go
- runtime_lua_context.go
- runtime_lua_loadlib.go
- runtime_lua_localcache.go
- runtime_lua_match_core.go
- runtime_lua_nakama.go
- runtime_lua_oslib.go
- runtime_lua_utils.go
- session_cache.go
- session_registry.go
- session_ws.go
- socket_ws.go
- status_handler.go
- status_registry.go
- stream_manager.go
- tracker.go