<Self>(): {
(clientId: string): ApiMetricsTag<Self>
<HSelf>(
clientId: string,
options: {
readonly node: NodeKey<HSelf>
readonly description?: string
}
): ApiMetricsNodeTag<Self, HSelf>
}Class factory for an ApiMetrics instance tag — its own per-instance RPC group, so it
serves on a node alongside queues/processes via ApiMetrics.serve and is reached with
Hyperlink.client. Bind it to a node with { node }.
const const tag: <Self>() => {
(clientId: string): ApiMetricsTag<Self>
<HSelf>(
clientId: string,
options: {
readonly node: NodeKey<HSelf>
readonly description?: string
}
): ApiMetricsNodeTag<Self, HSelf>
}
Class factory for an
ApiMetrics
instance tag — its own per-instance RPC group, so it
serves on a node alongside queues/processes via
ApiMetrics.serve
and is reached with
Hyperlink.client. Bind it to a node with { node }.
tag = <function (type parameter) Self in <Self>(): {
(clientId: string): ApiMetricsTag<Self>;
<HSelf>(clientId: string, options: {
readonly node: NodeKey<HSelf>;
readonly description?: string;
}): ApiMetricsNodeTag<Self, HSelf>;
}
Self>() => {
function function (local function) build(clientId: string): ApiMetricsTag<Self> (+1 overload)build(clientId: stringclientId: string): type ApiMetricsTag<Self> = anyAn
ApiMetrics
instance tag — a
HyperlinkTag
plus the linked client id.
ApiMetricsTag<function (type parameter) Self in <Self>(): {
(clientId: string): ApiMetricsTag<Self>;
<HSelf>(clientId: string, options: {
readonly node: NodeKey<HSelf>;
readonly description?: string;
}): ApiMetricsNodeTag<Self, HSelf>;
}
Self>;
function function (local function) build<HSelf>(clientId: string, options: {
readonly node: NodeKey<HSelf>;
readonly description?: string;
}): ApiMetricsNodeTag<Self, HSelf> (+1 overload)
build<function (type parameter) HSelf in build<HSelf>(clientId: string, options: {
readonly node: NodeKey<HSelf>;
readonly description?: string;
}): ApiMetricsNodeTag<Self, HSelf>
HSelf>(
clientId: stringclientId: string,
options: {
readonly node: NodeKey<HSelf>
readonly description?: string
}
options: { readonly node: NodeKey<HSelf>node: import NodeKeyNodeKey<function (type parameter) HSelf in build<HSelf>(clientId: string, options: {
readonly node: NodeKey<HSelf>;
readonly description?: string;
}): ApiMetricsNodeTag<Self, HSelf>
HSelf>; readonly description?: string | undefineddescription?: string },
): type ApiMetricsNodeTag<Self, HSelf> = anyA node-bound
ApiMetricsTag
— its [nodeSym] narrowed to the node (so Hyperlink.client
resolves the transport). A named type so a consumer can export a node-bound metrics tag
without leaking the internal clientIdSym (TS4020). Returned by ApiMetrics.Tag()(id, { node }).
ApiMetricsNodeTag<function (type parameter) Self in <Self>(): {
(clientId: string): ApiMetricsTag<Self>;
<HSelf>(clientId: string, options: {
readonly node: NodeKey<HSelf>;
readonly description?: string;
}): ApiMetricsNodeTag<Self, HSelf>;
}
Self, function (type parameter) HSelf in build<HSelf>(clientId: string, options: {
readonly node: NodeKey<HSelf>;
readonly description?: string;
}): ApiMetricsNodeTag<Self, HSelf>
HSelf>;
function function (local function) build(clientId: string): ApiMetricsTag<Self> (+1 overload)build(
clientId: stringclientId: string,
options: ApiMetricsConstructOptions<unknown>options?: interface ApiMetricsConstructOptions<HSelf = never>Tag-construction options for
ApiMetrics.Tag
: bind the metrics resource to a
Node.Tag
(so it's served + reached on that node) and/or set its dashboard panel title.
ApiMetricsConstructOptions<unknown>,
): type ApiMetricsTag<Self> = anyAn
ApiMetrics
instance tag — a
HyperlinkTag
plus the linked client id.
ApiMetricsTag<function (type parameter) Self in <Self>(): {
(clientId: string): ApiMetricsTag<Self>;
<HSelf>(clientId: string, options: {
readonly node: NodeKey<HSelf>;
readonly description?: string;
}): ApiMetricsNodeTag<Self, HSelf>;
}
Self> {
const const node: anynode = options: ApiMetricsConstructOptions<unknown>options?.ApiMetricsConstructOptions<unknown>.node?: anynode;
const const key: stringkey = const keyFor: (
clientId: string,
node: NodeKey<unknown> | undefined
) => string
The per-instance Hyperlink key (wire group prefix) for a metrics tag. A node-bound tag prefixes by
its node's key, so two nodes serving the same clientId (e.g. the same SDP client behind two
league nodes) get distinct groups and never collide.
keyFor(clientId: stringclientId, const node: anynode);
const const base: anybase =
const node: anynode === var undefinedundefined
? import resourceTagresourceTag<function (type parameter) Self in <Self>(): {
(clientId: string): ApiMetricsTag<Self>;
<HSelf>(clientId: string, options: {
readonly node: NodeKey<HSelf>;
readonly description?: string;
}): ApiMetricsNodeTag<Self, HSelf>;
}
Self>()(const key: stringkey, const apiMetricsSpec: {
metrics: any
usage: any
}
apiMetricsSpec, { kind: stringkind, description: string | undefineddescription: options: ApiMetricsConstructOptions<unknown>options?.ApiMetricsConstructOptions<unknown>.description?: string | undefineddescription })
: import resourceTagresourceTag<function (type parameter) Self in <Self>(): {
(clientId: string): ApiMetricsTag<Self>;
<HSelf>(clientId: string, options: {
readonly node: NodeKey<HSelf>;
readonly description?: string;
}): ApiMetricsNodeTag<Self, HSelf>;
}
Self>()(const key: stringkey, const apiMetricsSpec: {
metrics: any
usage: any
}
apiMetricsSpec, { kind: stringkind, description: string | undefineddescription: options: ApiMetricsConstructOptions<unknown>options?.ApiMetricsConstructOptions<unknown>.description?: string | undefineddescription, node: anynode });
return var Object: ObjectConstructorProvides functionality common to all JavaScript objects.
Object.ObjectConstructor.assign<any, {
[clientIdSym]: string;
}>(target: any, source: {
[clientIdSym]: string;
}): any (+3 overloads)
Copy the values of all of the enumerable own properties from one or more source objects to a
target object. Returns the target object.
assign(const base: anybase, { [const clientIdSym: typeof clientIdSymWhere the linked outbound client id is stored on an
ApiMetrics
tag.
clientIdSym]: clientId: stringclientId });
}
return function (local function) build(clientId: string): ApiMetricsTag<Self> (+1 overload)build;
};