Interface Option

interface Option {
    aliasName?: string;
    env?: string;
    metaData?: Record<string, string | ArrayBuffer>;
    namespace?: string;
    network?: string;
    protocol?: string;
    sendOnly?: boolean;
    serializationType?: 0 | 2;
    serviceName?: string;
    setName?: string;
    target?: string;
    timeoutMs?: number;
}

Hierarchy (view full)

Properties

aliasName?: string

trpc 特有插件别名

env?: string

123 环境名,例如 formal、pre、test

metaData?: Record<string, string | ArrayBuffer>

请求头信息

namespace?: string

北极星环境类型(命名空间),例如 Production、Development

network?: string

网络类型 tcp or udp

protocol?: string

protocol 协议类型。

sendOnly?: boolean

trpc 只发不收选项

serializationType?: 0 | 2

序列化类型。0-pb,2-json

serviceName?: string

被调服务名,用于北极星寻址

setName?: string

被调 set 名

target?: string

目标

timeoutMs?: number

请求超时,单位毫秒