@cloudflare/workers-types 4.20250705.0 → 4.20250708.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/2021-11-03/index.d.ts +30 -28
- package/2021-11-03/index.ts +30 -28
- package/2022-01-31/index.d.ts +30 -28
- package/2022-01-31/index.ts +30 -28
- package/2022-03-21/index.d.ts +30 -28
- package/2022-03-21/index.ts +30 -28
- package/2022-08-04/index.d.ts +30 -28
- package/2022-08-04/index.ts +30 -28
- package/2022-10-31/index.d.ts +30 -28
- package/2022-10-31/index.ts +30 -28
- package/2022-11-30/index.d.ts +30 -28
- package/2022-11-30/index.ts +30 -28
- package/2023-03-01/index.d.ts +30 -28
- package/2023-03-01/index.ts +30 -28
- package/2023-07-01/index.d.ts +30 -28
- package/2023-07-01/index.ts +30 -28
- package/experimental/index.d.ts +30 -28
- package/experimental/index.ts +30 -28
- package/index.d.ts +30 -28
- package/index.ts +30 -28
- package/latest/index.d.ts +30 -28
- package/latest/index.ts +30 -28
- package/oldest/index.d.ts +30 -28
- package/oldest/index.ts +30 -28
- package/package.json +1 -1
package/2021-11-03/index.d.ts
CHANGED
|
@@ -400,7 +400,7 @@ type ExportedHandlerTraceHandler<Env = unknown> = (
|
|
|
400
400
|
ctx: ExecutionContext,
|
|
401
401
|
) => void | Promise<void>;
|
|
402
402
|
type ExportedHandlerTailStreamHandler<Env = unknown> = (
|
|
403
|
-
event: TailStream.TailEvent
|
|
403
|
+
event: TailStream.TailEvent<TailStream.Onset>,
|
|
404
404
|
env: Env,
|
|
405
405
|
ctx: ExecutionContext,
|
|
406
406
|
) => TailStream.TailEventHandlerType | Promise<TailStream.TailEventHandlerType>;
|
|
@@ -8032,38 +8032,40 @@ declare namespace TailStream {
|
|
|
8032
8032
|
readonly type: "attributes";
|
|
8033
8033
|
readonly info: Attribute[];
|
|
8034
8034
|
}
|
|
8035
|
-
|
|
8036
|
-
|
|
8035
|
+
type EventType =
|
|
8036
|
+
| Onset
|
|
8037
|
+
| Outcome
|
|
8038
|
+
| Hibernate
|
|
8039
|
+
| SpanOpen
|
|
8040
|
+
| SpanClose
|
|
8041
|
+
| DiagnosticChannelEvent
|
|
8042
|
+
| Exception
|
|
8043
|
+
| Log
|
|
8044
|
+
| Return
|
|
8045
|
+
| Link
|
|
8046
|
+
| Attributes;
|
|
8047
|
+
interface TailEvent<Event extends EventType> {
|
|
8037
8048
|
readonly invocationId: string;
|
|
8038
8049
|
readonly spanId: string;
|
|
8039
8050
|
readonly timestamp: Date;
|
|
8040
8051
|
readonly sequence: number;
|
|
8041
|
-
readonly event:
|
|
8042
|
-
| Onset
|
|
8043
|
-
| Outcome
|
|
8044
|
-
| Hibernate
|
|
8045
|
-
| SpanOpen
|
|
8046
|
-
| SpanClose
|
|
8047
|
-
| DiagnosticChannelEvent
|
|
8048
|
-
| Exception
|
|
8049
|
-
| Log
|
|
8050
|
-
| Return
|
|
8051
|
-
| Link
|
|
8052
|
-
| Attributes;
|
|
8052
|
+
readonly event: Event;
|
|
8053
8053
|
}
|
|
8054
|
-
type TailEventHandler
|
|
8055
|
-
|
|
8056
|
-
|
|
8057
|
-
|
|
8058
|
-
|
|
8059
|
-
|
|
8060
|
-
|
|
8061
|
-
|
|
8062
|
-
|
|
8063
|
-
|
|
8064
|
-
|
|
8065
|
-
|
|
8066
|
-
|
|
8054
|
+
type TailEventHandler<Event extends EventType = EventType> = (
|
|
8055
|
+
event: TailEvent<Event>,
|
|
8056
|
+
) => void | Promise<void>;
|
|
8057
|
+
type TailEventHandlerObject = {
|
|
8058
|
+
outcome?: TailEventHandler<Outcome>;
|
|
8059
|
+
hibernate?: TailEventHandler<Hibernate>;
|
|
8060
|
+
spanOpen?: TailEventHandler<SpanOpen>;
|
|
8061
|
+
spanClose?: TailEventHandler<SpanClose>;
|
|
8062
|
+
diagnosticChannel?: TailEventHandler<DiagnosticChannelEvent>;
|
|
8063
|
+
exception?: TailEventHandler<Exception>;
|
|
8064
|
+
log?: TailEventHandler<Log>;
|
|
8065
|
+
return?: TailEventHandler<Return>;
|
|
8066
|
+
link?: TailEventHandler<Link>;
|
|
8067
|
+
attributes?: TailEventHandler<Attributes>;
|
|
8068
|
+
};
|
|
8067
8069
|
type TailEventHandlerType = TailEventHandler | TailEventHandlerObject;
|
|
8068
8070
|
}
|
|
8069
8071
|
// Copyright (c) 2022-2023 Cloudflare, Inc.
|
package/2021-11-03/index.ts
CHANGED
|
@@ -405,7 +405,7 @@ export type ExportedHandlerTraceHandler<Env = unknown> = (
|
|
|
405
405
|
ctx: ExecutionContext,
|
|
406
406
|
) => void | Promise<void>;
|
|
407
407
|
export type ExportedHandlerTailStreamHandler<Env = unknown> = (
|
|
408
|
-
event: TailStream.TailEvent
|
|
408
|
+
event: TailStream.TailEvent<TailStream.Onset>,
|
|
409
409
|
env: Env,
|
|
410
410
|
ctx: ExecutionContext,
|
|
411
411
|
) => TailStream.TailEventHandlerType | Promise<TailStream.TailEventHandlerType>;
|
|
@@ -7895,38 +7895,40 @@ export declare namespace TailStream {
|
|
|
7895
7895
|
readonly type: "attributes";
|
|
7896
7896
|
readonly info: Attribute[];
|
|
7897
7897
|
}
|
|
7898
|
-
|
|
7899
|
-
|
|
7898
|
+
type EventType =
|
|
7899
|
+
| Onset
|
|
7900
|
+
| Outcome
|
|
7901
|
+
| Hibernate
|
|
7902
|
+
| SpanOpen
|
|
7903
|
+
| SpanClose
|
|
7904
|
+
| DiagnosticChannelEvent
|
|
7905
|
+
| Exception
|
|
7906
|
+
| Log
|
|
7907
|
+
| Return
|
|
7908
|
+
| Link
|
|
7909
|
+
| Attributes;
|
|
7910
|
+
interface TailEvent<Event extends EventType> {
|
|
7900
7911
|
readonly invocationId: string;
|
|
7901
7912
|
readonly spanId: string;
|
|
7902
7913
|
readonly timestamp: Date;
|
|
7903
7914
|
readonly sequence: number;
|
|
7904
|
-
readonly event:
|
|
7905
|
-
| Onset
|
|
7906
|
-
| Outcome
|
|
7907
|
-
| Hibernate
|
|
7908
|
-
| SpanOpen
|
|
7909
|
-
| SpanClose
|
|
7910
|
-
| DiagnosticChannelEvent
|
|
7911
|
-
| Exception
|
|
7912
|
-
| Log
|
|
7913
|
-
| Return
|
|
7914
|
-
| Link
|
|
7915
|
-
| Attributes;
|
|
7915
|
+
readonly event: Event;
|
|
7916
7916
|
}
|
|
7917
|
-
type TailEventHandler
|
|
7918
|
-
|
|
7919
|
-
|
|
7920
|
-
|
|
7921
|
-
|
|
7922
|
-
|
|
7923
|
-
|
|
7924
|
-
|
|
7925
|
-
|
|
7926
|
-
|
|
7927
|
-
|
|
7928
|
-
|
|
7929
|
-
|
|
7917
|
+
type TailEventHandler<Event extends EventType = EventType> = (
|
|
7918
|
+
event: TailEvent<Event>,
|
|
7919
|
+
) => void | Promise<void>;
|
|
7920
|
+
type TailEventHandlerObject = {
|
|
7921
|
+
outcome?: TailEventHandler<Outcome>;
|
|
7922
|
+
hibernate?: TailEventHandler<Hibernate>;
|
|
7923
|
+
spanOpen?: TailEventHandler<SpanOpen>;
|
|
7924
|
+
spanClose?: TailEventHandler<SpanClose>;
|
|
7925
|
+
diagnosticChannel?: TailEventHandler<DiagnosticChannelEvent>;
|
|
7926
|
+
exception?: TailEventHandler<Exception>;
|
|
7927
|
+
log?: TailEventHandler<Log>;
|
|
7928
|
+
return?: TailEventHandler<Return>;
|
|
7929
|
+
link?: TailEventHandler<Link>;
|
|
7930
|
+
attributes?: TailEventHandler<Attributes>;
|
|
7931
|
+
};
|
|
7930
7932
|
type TailEventHandlerType = TailEventHandler | TailEventHandlerObject;
|
|
7931
7933
|
}
|
|
7932
7934
|
// Copyright (c) 2022-2023 Cloudflare, Inc.
|
package/2022-01-31/index.d.ts
CHANGED
|
@@ -400,7 +400,7 @@ type ExportedHandlerTraceHandler<Env = unknown> = (
|
|
|
400
400
|
ctx: ExecutionContext,
|
|
401
401
|
) => void | Promise<void>;
|
|
402
402
|
type ExportedHandlerTailStreamHandler<Env = unknown> = (
|
|
403
|
-
event: TailStream.TailEvent
|
|
403
|
+
event: TailStream.TailEvent<TailStream.Onset>,
|
|
404
404
|
env: Env,
|
|
405
405
|
ctx: ExecutionContext,
|
|
406
406
|
) => TailStream.TailEventHandlerType | Promise<TailStream.TailEventHandlerType>;
|
|
@@ -8058,38 +8058,40 @@ declare namespace TailStream {
|
|
|
8058
8058
|
readonly type: "attributes";
|
|
8059
8059
|
readonly info: Attribute[];
|
|
8060
8060
|
}
|
|
8061
|
-
|
|
8062
|
-
|
|
8061
|
+
type EventType =
|
|
8062
|
+
| Onset
|
|
8063
|
+
| Outcome
|
|
8064
|
+
| Hibernate
|
|
8065
|
+
| SpanOpen
|
|
8066
|
+
| SpanClose
|
|
8067
|
+
| DiagnosticChannelEvent
|
|
8068
|
+
| Exception
|
|
8069
|
+
| Log
|
|
8070
|
+
| Return
|
|
8071
|
+
| Link
|
|
8072
|
+
| Attributes;
|
|
8073
|
+
interface TailEvent<Event extends EventType> {
|
|
8063
8074
|
readonly invocationId: string;
|
|
8064
8075
|
readonly spanId: string;
|
|
8065
8076
|
readonly timestamp: Date;
|
|
8066
8077
|
readonly sequence: number;
|
|
8067
|
-
readonly event:
|
|
8068
|
-
| Onset
|
|
8069
|
-
| Outcome
|
|
8070
|
-
| Hibernate
|
|
8071
|
-
| SpanOpen
|
|
8072
|
-
| SpanClose
|
|
8073
|
-
| DiagnosticChannelEvent
|
|
8074
|
-
| Exception
|
|
8075
|
-
| Log
|
|
8076
|
-
| Return
|
|
8077
|
-
| Link
|
|
8078
|
-
| Attributes;
|
|
8078
|
+
readonly event: Event;
|
|
8079
8079
|
}
|
|
8080
|
-
type TailEventHandler
|
|
8081
|
-
|
|
8082
|
-
|
|
8083
|
-
|
|
8084
|
-
|
|
8085
|
-
|
|
8086
|
-
|
|
8087
|
-
|
|
8088
|
-
|
|
8089
|
-
|
|
8090
|
-
|
|
8091
|
-
|
|
8092
|
-
|
|
8080
|
+
type TailEventHandler<Event extends EventType = EventType> = (
|
|
8081
|
+
event: TailEvent<Event>,
|
|
8082
|
+
) => void | Promise<void>;
|
|
8083
|
+
type TailEventHandlerObject = {
|
|
8084
|
+
outcome?: TailEventHandler<Outcome>;
|
|
8085
|
+
hibernate?: TailEventHandler<Hibernate>;
|
|
8086
|
+
spanOpen?: TailEventHandler<SpanOpen>;
|
|
8087
|
+
spanClose?: TailEventHandler<SpanClose>;
|
|
8088
|
+
diagnosticChannel?: TailEventHandler<DiagnosticChannelEvent>;
|
|
8089
|
+
exception?: TailEventHandler<Exception>;
|
|
8090
|
+
log?: TailEventHandler<Log>;
|
|
8091
|
+
return?: TailEventHandler<Return>;
|
|
8092
|
+
link?: TailEventHandler<Link>;
|
|
8093
|
+
attributes?: TailEventHandler<Attributes>;
|
|
8094
|
+
};
|
|
8093
8095
|
type TailEventHandlerType = TailEventHandler | TailEventHandlerObject;
|
|
8094
8096
|
}
|
|
8095
8097
|
// Copyright (c) 2022-2023 Cloudflare, Inc.
|
package/2022-01-31/index.ts
CHANGED
|
@@ -405,7 +405,7 @@ export type ExportedHandlerTraceHandler<Env = unknown> = (
|
|
|
405
405
|
ctx: ExecutionContext,
|
|
406
406
|
) => void | Promise<void>;
|
|
407
407
|
export type ExportedHandlerTailStreamHandler<Env = unknown> = (
|
|
408
|
-
event: TailStream.TailEvent
|
|
408
|
+
event: TailStream.TailEvent<TailStream.Onset>,
|
|
409
409
|
env: Env,
|
|
410
410
|
ctx: ExecutionContext,
|
|
411
411
|
) => TailStream.TailEventHandlerType | Promise<TailStream.TailEventHandlerType>;
|
|
@@ -7921,38 +7921,40 @@ export declare namespace TailStream {
|
|
|
7921
7921
|
readonly type: "attributes";
|
|
7922
7922
|
readonly info: Attribute[];
|
|
7923
7923
|
}
|
|
7924
|
-
|
|
7925
|
-
|
|
7924
|
+
type EventType =
|
|
7925
|
+
| Onset
|
|
7926
|
+
| Outcome
|
|
7927
|
+
| Hibernate
|
|
7928
|
+
| SpanOpen
|
|
7929
|
+
| SpanClose
|
|
7930
|
+
| DiagnosticChannelEvent
|
|
7931
|
+
| Exception
|
|
7932
|
+
| Log
|
|
7933
|
+
| Return
|
|
7934
|
+
| Link
|
|
7935
|
+
| Attributes;
|
|
7936
|
+
interface TailEvent<Event extends EventType> {
|
|
7926
7937
|
readonly invocationId: string;
|
|
7927
7938
|
readonly spanId: string;
|
|
7928
7939
|
readonly timestamp: Date;
|
|
7929
7940
|
readonly sequence: number;
|
|
7930
|
-
readonly event:
|
|
7931
|
-
| Onset
|
|
7932
|
-
| Outcome
|
|
7933
|
-
| Hibernate
|
|
7934
|
-
| SpanOpen
|
|
7935
|
-
| SpanClose
|
|
7936
|
-
| DiagnosticChannelEvent
|
|
7937
|
-
| Exception
|
|
7938
|
-
| Log
|
|
7939
|
-
| Return
|
|
7940
|
-
| Link
|
|
7941
|
-
| Attributes;
|
|
7941
|
+
readonly event: Event;
|
|
7942
7942
|
}
|
|
7943
|
-
type TailEventHandler
|
|
7944
|
-
|
|
7945
|
-
|
|
7946
|
-
|
|
7947
|
-
|
|
7948
|
-
|
|
7949
|
-
|
|
7950
|
-
|
|
7951
|
-
|
|
7952
|
-
|
|
7953
|
-
|
|
7954
|
-
|
|
7955
|
-
|
|
7943
|
+
type TailEventHandler<Event extends EventType = EventType> = (
|
|
7944
|
+
event: TailEvent<Event>,
|
|
7945
|
+
) => void | Promise<void>;
|
|
7946
|
+
type TailEventHandlerObject = {
|
|
7947
|
+
outcome?: TailEventHandler<Outcome>;
|
|
7948
|
+
hibernate?: TailEventHandler<Hibernate>;
|
|
7949
|
+
spanOpen?: TailEventHandler<SpanOpen>;
|
|
7950
|
+
spanClose?: TailEventHandler<SpanClose>;
|
|
7951
|
+
diagnosticChannel?: TailEventHandler<DiagnosticChannelEvent>;
|
|
7952
|
+
exception?: TailEventHandler<Exception>;
|
|
7953
|
+
log?: TailEventHandler<Log>;
|
|
7954
|
+
return?: TailEventHandler<Return>;
|
|
7955
|
+
link?: TailEventHandler<Link>;
|
|
7956
|
+
attributes?: TailEventHandler<Attributes>;
|
|
7957
|
+
};
|
|
7956
7958
|
type TailEventHandlerType = TailEventHandler | TailEventHandlerObject;
|
|
7957
7959
|
}
|
|
7958
7960
|
// Copyright (c) 2022-2023 Cloudflare, Inc.
|
package/2022-03-21/index.d.ts
CHANGED
|
@@ -403,7 +403,7 @@ type ExportedHandlerTraceHandler<Env = unknown> = (
|
|
|
403
403
|
ctx: ExecutionContext,
|
|
404
404
|
) => void | Promise<void>;
|
|
405
405
|
type ExportedHandlerTailStreamHandler<Env = unknown> = (
|
|
406
|
-
event: TailStream.TailEvent
|
|
406
|
+
event: TailStream.TailEvent<TailStream.Onset>,
|
|
407
407
|
env: Env,
|
|
408
408
|
ctx: ExecutionContext,
|
|
409
409
|
) => TailStream.TailEventHandlerType | Promise<TailStream.TailEventHandlerType>;
|
|
@@ -8076,38 +8076,40 @@ declare namespace TailStream {
|
|
|
8076
8076
|
readonly type: "attributes";
|
|
8077
8077
|
readonly info: Attribute[];
|
|
8078
8078
|
}
|
|
8079
|
-
|
|
8080
|
-
|
|
8079
|
+
type EventType =
|
|
8080
|
+
| Onset
|
|
8081
|
+
| Outcome
|
|
8082
|
+
| Hibernate
|
|
8083
|
+
| SpanOpen
|
|
8084
|
+
| SpanClose
|
|
8085
|
+
| DiagnosticChannelEvent
|
|
8086
|
+
| Exception
|
|
8087
|
+
| Log
|
|
8088
|
+
| Return
|
|
8089
|
+
| Link
|
|
8090
|
+
| Attributes;
|
|
8091
|
+
interface TailEvent<Event extends EventType> {
|
|
8081
8092
|
readonly invocationId: string;
|
|
8082
8093
|
readonly spanId: string;
|
|
8083
8094
|
readonly timestamp: Date;
|
|
8084
8095
|
readonly sequence: number;
|
|
8085
|
-
readonly event:
|
|
8086
|
-
| Onset
|
|
8087
|
-
| Outcome
|
|
8088
|
-
| Hibernate
|
|
8089
|
-
| SpanOpen
|
|
8090
|
-
| SpanClose
|
|
8091
|
-
| DiagnosticChannelEvent
|
|
8092
|
-
| Exception
|
|
8093
|
-
| Log
|
|
8094
|
-
| Return
|
|
8095
|
-
| Link
|
|
8096
|
-
| Attributes;
|
|
8096
|
+
readonly event: Event;
|
|
8097
8097
|
}
|
|
8098
|
-
type TailEventHandler
|
|
8099
|
-
|
|
8100
|
-
|
|
8101
|
-
|
|
8102
|
-
|
|
8103
|
-
|
|
8104
|
-
|
|
8105
|
-
|
|
8106
|
-
|
|
8107
|
-
|
|
8108
|
-
|
|
8109
|
-
|
|
8110
|
-
|
|
8098
|
+
type TailEventHandler<Event extends EventType = EventType> = (
|
|
8099
|
+
event: TailEvent<Event>,
|
|
8100
|
+
) => void | Promise<void>;
|
|
8101
|
+
type TailEventHandlerObject = {
|
|
8102
|
+
outcome?: TailEventHandler<Outcome>;
|
|
8103
|
+
hibernate?: TailEventHandler<Hibernate>;
|
|
8104
|
+
spanOpen?: TailEventHandler<SpanOpen>;
|
|
8105
|
+
spanClose?: TailEventHandler<SpanClose>;
|
|
8106
|
+
diagnosticChannel?: TailEventHandler<DiagnosticChannelEvent>;
|
|
8107
|
+
exception?: TailEventHandler<Exception>;
|
|
8108
|
+
log?: TailEventHandler<Log>;
|
|
8109
|
+
return?: TailEventHandler<Return>;
|
|
8110
|
+
link?: TailEventHandler<Link>;
|
|
8111
|
+
attributes?: TailEventHandler<Attributes>;
|
|
8112
|
+
};
|
|
8111
8113
|
type TailEventHandlerType = TailEventHandler | TailEventHandlerObject;
|
|
8112
8114
|
}
|
|
8113
8115
|
// Copyright (c) 2022-2023 Cloudflare, Inc.
|
package/2022-03-21/index.ts
CHANGED
|
@@ -408,7 +408,7 @@ export type ExportedHandlerTraceHandler<Env = unknown> = (
|
|
|
408
408
|
ctx: ExecutionContext,
|
|
409
409
|
) => void | Promise<void>;
|
|
410
410
|
export type ExportedHandlerTailStreamHandler<Env = unknown> = (
|
|
411
|
-
event: TailStream.TailEvent
|
|
411
|
+
event: TailStream.TailEvent<TailStream.Onset>,
|
|
412
412
|
env: Env,
|
|
413
413
|
ctx: ExecutionContext,
|
|
414
414
|
) => TailStream.TailEventHandlerType | Promise<TailStream.TailEventHandlerType>;
|
|
@@ -7939,38 +7939,40 @@ export declare namespace TailStream {
|
|
|
7939
7939
|
readonly type: "attributes";
|
|
7940
7940
|
readonly info: Attribute[];
|
|
7941
7941
|
}
|
|
7942
|
-
|
|
7943
|
-
|
|
7942
|
+
type EventType =
|
|
7943
|
+
| Onset
|
|
7944
|
+
| Outcome
|
|
7945
|
+
| Hibernate
|
|
7946
|
+
| SpanOpen
|
|
7947
|
+
| SpanClose
|
|
7948
|
+
| DiagnosticChannelEvent
|
|
7949
|
+
| Exception
|
|
7950
|
+
| Log
|
|
7951
|
+
| Return
|
|
7952
|
+
| Link
|
|
7953
|
+
| Attributes;
|
|
7954
|
+
interface TailEvent<Event extends EventType> {
|
|
7944
7955
|
readonly invocationId: string;
|
|
7945
7956
|
readonly spanId: string;
|
|
7946
7957
|
readonly timestamp: Date;
|
|
7947
7958
|
readonly sequence: number;
|
|
7948
|
-
readonly event:
|
|
7949
|
-
| Onset
|
|
7950
|
-
| Outcome
|
|
7951
|
-
| Hibernate
|
|
7952
|
-
| SpanOpen
|
|
7953
|
-
| SpanClose
|
|
7954
|
-
| DiagnosticChannelEvent
|
|
7955
|
-
| Exception
|
|
7956
|
-
| Log
|
|
7957
|
-
| Return
|
|
7958
|
-
| Link
|
|
7959
|
-
| Attributes;
|
|
7959
|
+
readonly event: Event;
|
|
7960
7960
|
}
|
|
7961
|
-
type TailEventHandler
|
|
7962
|
-
|
|
7963
|
-
|
|
7964
|
-
|
|
7965
|
-
|
|
7966
|
-
|
|
7967
|
-
|
|
7968
|
-
|
|
7969
|
-
|
|
7970
|
-
|
|
7971
|
-
|
|
7972
|
-
|
|
7973
|
-
|
|
7961
|
+
type TailEventHandler<Event extends EventType = EventType> = (
|
|
7962
|
+
event: TailEvent<Event>,
|
|
7963
|
+
) => void | Promise<void>;
|
|
7964
|
+
type TailEventHandlerObject = {
|
|
7965
|
+
outcome?: TailEventHandler<Outcome>;
|
|
7966
|
+
hibernate?: TailEventHandler<Hibernate>;
|
|
7967
|
+
spanOpen?: TailEventHandler<SpanOpen>;
|
|
7968
|
+
spanClose?: TailEventHandler<SpanClose>;
|
|
7969
|
+
diagnosticChannel?: TailEventHandler<DiagnosticChannelEvent>;
|
|
7970
|
+
exception?: TailEventHandler<Exception>;
|
|
7971
|
+
log?: TailEventHandler<Log>;
|
|
7972
|
+
return?: TailEventHandler<Return>;
|
|
7973
|
+
link?: TailEventHandler<Link>;
|
|
7974
|
+
attributes?: TailEventHandler<Attributes>;
|
|
7975
|
+
};
|
|
7974
7976
|
type TailEventHandlerType = TailEventHandler | TailEventHandlerObject;
|
|
7975
7977
|
}
|
|
7976
7978
|
// Copyright (c) 2022-2023 Cloudflare, Inc.
|
package/2022-08-04/index.d.ts
CHANGED
|
@@ -403,7 +403,7 @@ type ExportedHandlerTraceHandler<Env = unknown> = (
|
|
|
403
403
|
ctx: ExecutionContext,
|
|
404
404
|
) => void | Promise<void>;
|
|
405
405
|
type ExportedHandlerTailStreamHandler<Env = unknown> = (
|
|
406
|
-
event: TailStream.TailEvent
|
|
406
|
+
event: TailStream.TailEvent<TailStream.Onset>,
|
|
407
407
|
env: Env,
|
|
408
408
|
ctx: ExecutionContext,
|
|
409
409
|
) => TailStream.TailEventHandlerType | Promise<TailStream.TailEventHandlerType>;
|
|
@@ -8077,38 +8077,40 @@ declare namespace TailStream {
|
|
|
8077
8077
|
readonly type: "attributes";
|
|
8078
8078
|
readonly info: Attribute[];
|
|
8079
8079
|
}
|
|
8080
|
-
|
|
8081
|
-
|
|
8080
|
+
type EventType =
|
|
8081
|
+
| Onset
|
|
8082
|
+
| Outcome
|
|
8083
|
+
| Hibernate
|
|
8084
|
+
| SpanOpen
|
|
8085
|
+
| SpanClose
|
|
8086
|
+
| DiagnosticChannelEvent
|
|
8087
|
+
| Exception
|
|
8088
|
+
| Log
|
|
8089
|
+
| Return
|
|
8090
|
+
| Link
|
|
8091
|
+
| Attributes;
|
|
8092
|
+
interface TailEvent<Event extends EventType> {
|
|
8082
8093
|
readonly invocationId: string;
|
|
8083
8094
|
readonly spanId: string;
|
|
8084
8095
|
readonly timestamp: Date;
|
|
8085
8096
|
readonly sequence: number;
|
|
8086
|
-
readonly event:
|
|
8087
|
-
| Onset
|
|
8088
|
-
| Outcome
|
|
8089
|
-
| Hibernate
|
|
8090
|
-
| SpanOpen
|
|
8091
|
-
| SpanClose
|
|
8092
|
-
| DiagnosticChannelEvent
|
|
8093
|
-
| Exception
|
|
8094
|
-
| Log
|
|
8095
|
-
| Return
|
|
8096
|
-
| Link
|
|
8097
|
-
| Attributes;
|
|
8097
|
+
readonly event: Event;
|
|
8098
8098
|
}
|
|
8099
|
-
type TailEventHandler
|
|
8100
|
-
|
|
8101
|
-
|
|
8102
|
-
|
|
8103
|
-
|
|
8104
|
-
|
|
8105
|
-
|
|
8106
|
-
|
|
8107
|
-
|
|
8108
|
-
|
|
8109
|
-
|
|
8110
|
-
|
|
8111
|
-
|
|
8099
|
+
type TailEventHandler<Event extends EventType = EventType> = (
|
|
8100
|
+
event: TailEvent<Event>,
|
|
8101
|
+
) => void | Promise<void>;
|
|
8102
|
+
type TailEventHandlerObject = {
|
|
8103
|
+
outcome?: TailEventHandler<Outcome>;
|
|
8104
|
+
hibernate?: TailEventHandler<Hibernate>;
|
|
8105
|
+
spanOpen?: TailEventHandler<SpanOpen>;
|
|
8106
|
+
spanClose?: TailEventHandler<SpanClose>;
|
|
8107
|
+
diagnosticChannel?: TailEventHandler<DiagnosticChannelEvent>;
|
|
8108
|
+
exception?: TailEventHandler<Exception>;
|
|
8109
|
+
log?: TailEventHandler<Log>;
|
|
8110
|
+
return?: TailEventHandler<Return>;
|
|
8111
|
+
link?: TailEventHandler<Link>;
|
|
8112
|
+
attributes?: TailEventHandler<Attributes>;
|
|
8113
|
+
};
|
|
8112
8114
|
type TailEventHandlerType = TailEventHandler | TailEventHandlerObject;
|
|
8113
8115
|
}
|
|
8114
8116
|
// Copyright (c) 2022-2023 Cloudflare, Inc.
|
package/2022-08-04/index.ts
CHANGED
|
@@ -408,7 +408,7 @@ export type ExportedHandlerTraceHandler<Env = unknown> = (
|
|
|
408
408
|
ctx: ExecutionContext,
|
|
409
409
|
) => void | Promise<void>;
|
|
410
410
|
export type ExportedHandlerTailStreamHandler<Env = unknown> = (
|
|
411
|
-
event: TailStream.TailEvent
|
|
411
|
+
event: TailStream.TailEvent<TailStream.Onset>,
|
|
412
412
|
env: Env,
|
|
413
413
|
ctx: ExecutionContext,
|
|
414
414
|
) => TailStream.TailEventHandlerType | Promise<TailStream.TailEventHandlerType>;
|
|
@@ -7940,38 +7940,40 @@ export declare namespace TailStream {
|
|
|
7940
7940
|
readonly type: "attributes";
|
|
7941
7941
|
readonly info: Attribute[];
|
|
7942
7942
|
}
|
|
7943
|
-
|
|
7944
|
-
|
|
7943
|
+
type EventType =
|
|
7944
|
+
| Onset
|
|
7945
|
+
| Outcome
|
|
7946
|
+
| Hibernate
|
|
7947
|
+
| SpanOpen
|
|
7948
|
+
| SpanClose
|
|
7949
|
+
| DiagnosticChannelEvent
|
|
7950
|
+
| Exception
|
|
7951
|
+
| Log
|
|
7952
|
+
| Return
|
|
7953
|
+
| Link
|
|
7954
|
+
| Attributes;
|
|
7955
|
+
interface TailEvent<Event extends EventType> {
|
|
7945
7956
|
readonly invocationId: string;
|
|
7946
7957
|
readonly spanId: string;
|
|
7947
7958
|
readonly timestamp: Date;
|
|
7948
7959
|
readonly sequence: number;
|
|
7949
|
-
readonly event:
|
|
7950
|
-
| Onset
|
|
7951
|
-
| Outcome
|
|
7952
|
-
| Hibernate
|
|
7953
|
-
| SpanOpen
|
|
7954
|
-
| SpanClose
|
|
7955
|
-
| DiagnosticChannelEvent
|
|
7956
|
-
| Exception
|
|
7957
|
-
| Log
|
|
7958
|
-
| Return
|
|
7959
|
-
| Link
|
|
7960
|
-
| Attributes;
|
|
7960
|
+
readonly event: Event;
|
|
7961
7961
|
}
|
|
7962
|
-
type TailEventHandler
|
|
7963
|
-
|
|
7964
|
-
|
|
7965
|
-
|
|
7966
|
-
|
|
7967
|
-
|
|
7968
|
-
|
|
7969
|
-
|
|
7970
|
-
|
|
7971
|
-
|
|
7972
|
-
|
|
7973
|
-
|
|
7974
|
-
|
|
7962
|
+
type TailEventHandler<Event extends EventType = EventType> = (
|
|
7963
|
+
event: TailEvent<Event>,
|
|
7964
|
+
) => void | Promise<void>;
|
|
7965
|
+
type TailEventHandlerObject = {
|
|
7966
|
+
outcome?: TailEventHandler<Outcome>;
|
|
7967
|
+
hibernate?: TailEventHandler<Hibernate>;
|
|
7968
|
+
spanOpen?: TailEventHandler<SpanOpen>;
|
|
7969
|
+
spanClose?: TailEventHandler<SpanClose>;
|
|
7970
|
+
diagnosticChannel?: TailEventHandler<DiagnosticChannelEvent>;
|
|
7971
|
+
exception?: TailEventHandler<Exception>;
|
|
7972
|
+
log?: TailEventHandler<Log>;
|
|
7973
|
+
return?: TailEventHandler<Return>;
|
|
7974
|
+
link?: TailEventHandler<Link>;
|
|
7975
|
+
attributes?: TailEventHandler<Attributes>;
|
|
7976
|
+
};
|
|
7975
7977
|
type TailEventHandlerType = TailEventHandler | TailEventHandlerObject;
|
|
7976
7978
|
}
|
|
7977
7979
|
// Copyright (c) 2022-2023 Cloudflare, Inc.
|