UNPKG

727 BTypeScriptView Raw
1/// <reference types="node" />
2/// <reference types="node" />
3import { Socket } from 'net';
4import * as tls from 'tls';
5import { SubchannelAddress } from './subchannel-address';
6import { ChannelOptions } from './channel-options';
7import { GrpcUri } from './uri-parser';
8export interface ProxyMapResult {
9 target: GrpcUri;
10 extraOptions: ChannelOptions;
11}
12export declare function mapProxyName(target: GrpcUri, options: ChannelOptions): ProxyMapResult;
13export interface ProxyConnectionResult {
14 socket?: Socket;
15 realTarget?: GrpcUri;
16}
17export declare function getProxiedConnection(address: SubchannelAddress, channelOptions: ChannelOptions, connectionOptions: tls.ConnectionOptions): Promise<ProxyConnectionResult>;