moleculer-api
Version:
A dynamic API Gateway for MoleculerJS which updates REST endpoints and aggregated GraphQL schema, access control policy for each action calls from metadata of remote services schema without restart or deployment.
28 lines (27 loc) • 841 B
TypeScript
import { ServerOptions as SubscriptionServerOptions } from "subscriptions-transport-ws";
import * as WebSocket from "ws";
import { WebSocketRouteHandler } from "../../../../../server";
export declare class GraphQLSubscriptionHandler {
readonly handler: WebSocketRouteHandler;
private onOperation?;
private onOperationComplete?;
private onConnect?;
private onDisconnect?;
private keepAlive?;
private execute?;
private subscribe?;
private schema?;
private rootValue?;
private closeHandler?;
private specifiedRules;
constructor(options: SubscriptionServerOptions);
close(): void;
get server(): WebSocket.Server;
private loadExecutor;
private unsubscribe;
private onClose;
private onMessage;
private sendKeepAlive;
private sendMessage;
private sendError;
}