This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { usedRedisStore } from "./../../../main"; | |
import {ExecutionContext, Injectable, CanActivate, Logger} from "@nestjs/common"; | |
import {Reflector} from "@nestjs/core"; | |
import {AuthGuard} from "@nestjs/passport"; | |
import * as passport from "passport"; | |
import { Request, Express } from "express"; | |
import { AuthService } from "./auth.service"; | |
import { Classes } from "@player-search/api-interfaces"; | |
@Injectable() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { SubscribeMessage, WebSocketGateway, MessageBody, WebSocketServer, OnGatewayConnection, OnGatewayDisconnect, OnGatewayInit, ConnectedSocket } from "@nestjs/websockets"; | |
import { Logger, Req, UseGuards, UsePipes } from "@nestjs/common"; | |
import { Server, Socket } from "socket.io"; | |
import { Enums } from "@player-search/api-interfaces"; | |
import { LocalGuard } from "../../rest/auth/local.guard"; | |
import { LocalWebsocketGuard } from "../../rest/auth/local.websocket.guard"; | |
import { EnhanceWebsocketRequestPipe } from "../../pipes/enhance-websocket-request.pipe"; | |
@WebSocketGateway({ | |
namespace: Enums.WsNamespaces.CHAT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { ArgumentMetadata, Injectable, PipeTransform, Logger } from '@nestjs/common'; | |
@Injectable() | |
export class EnhanceWebsocketRequestPipe implements PipeTransform { | |
private logger: Logger = new Logger(EnhanceWebsocketRequestPipe.name); | |
transform(value: any, metadata: ArgumentMetadata) { | |
this.logger.debug("transform | value start: " + JSON.stringify(value)); | |
if(typeof value !== "object" || !Array.isArray(value)) { | |
value = { | |
originalValue: value |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { ArgumentMetadata, Injectable, PipeTransform, Logger } from '@nestjs/common'; | |
@Injectable() | |
export class EnhanceWebsocketRequestPipe implements PipeTransform { | |
private logger: Logger = new Logger(EnhanceWebsocketRequestPipe.name); | |
transform(value: any, metadata: ArgumentMetadata) { | |
this.logger.debug("transform | value start: " + JSON.stringify(value)); | |
if(typeof value !== "object" || !Array.isArray(value)) { | |
value = { | |
originalValue: value |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"size": 0, | |
"aggregations": { | |
"group_by_sessionid": { | |
"terms": { | |
"field": "sessionid", | |
"size": 10, | |
"order": { | |
"earliest_hit": "desc" | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"took": 7, | |
"timed_out": false, | |
"_shards": { | |
"total": 2, | |
"successful": 2, | |
"failed": 0 | |
}, | |
"hits": { | |
"total": 17944, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"took": 2, | |
"timed_out": false, | |
"_shards": { | |
"total": 2, | |
"successful": 2, | |
"failed": 0 | |
}, | |
"hits": { | |
"total": 17944, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"size": 0, | |
"aggregations": { | |
"group_by_sessionid": { | |
"terms": { | |
"field": "sessionid", | |
"size": 10, | |
"order": { | |
"earliest_hit": "desc" | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
unbindall | |
bind "0" "slot10" | |
bind "1" "slot1" | |
bind "2" "slot2" | |
bind "3" "slot3" | |
bind "4" "slot4" | |
bind "5" "slot5" | |
bind "6" "slot6" | |
bind "7" "slot7" | |
bind "8" "slot8" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Autoexec file generated by bzl.no | |
//Rates | |
rate "128000" | |
cl_cmdrate "128" | |
cl_updaterate "128" | |
cl_interp "0" | |
cl_interp_ratio "1" | |
cl_lagcompensation "1" |
NewerOlder