@genesislcap/foundation-comms 14.184.0 → 14.186.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (81) hide show
  1. package/dist/dts/auth/auth.types.d.ts +1 -1
  2. package/dist/dts/auth/auth.types.d.ts.map +1 -1
  3. package/dist/dts/connect/connect.d.ts +14 -6
  4. package/dist/dts/connect/connect.d.ts.map +1 -1
  5. package/dist/dts/connect/connect.events.d.ts +28 -2
  6. package/dist/dts/connect/connect.events.d.ts.map +1 -1
  7. package/dist/dts/connect/connect.types.d.ts +5 -52
  8. package/dist/dts/connect/connect.types.d.ts.map +1 -1
  9. package/dist/dts/connect/http.connect.d.ts +4 -8
  10. package/dist/dts/connect/http.connect.d.ts.map +1 -1
  11. package/dist/dts/connect/http.connect.types.d.ts +62 -0
  12. package/dist/dts/connect/http.connect.types.d.ts.map +1 -0
  13. package/dist/dts/connect/index.d.ts +1 -0
  14. package/dist/dts/connect/index.d.ts.map +1 -1
  15. package/dist/dts/connect/message.d.ts +6 -2
  16. package/dist/dts/connect/message.d.ts.map +1 -1
  17. package/dist/dts/connect/socket.d.ts +3 -56
  18. package/dist/dts/connect/socket.d.ts.map +1 -1
  19. package/dist/dts/connect/socket.types.d.ts +57 -0
  20. package/dist/dts/connect/socket.types.d.ts.map +1 -0
  21. package/dist/dts/connect/updateState.d.ts +3 -0
  22. package/dist/dts/connect/updateState.d.ts.map +1 -0
  23. package/dist/dts/networkMonitor/service.d.ts.map +1 -1
  24. package/dist/dts/testing/mocks/auth/auth.d.ts +1 -1
  25. package/dist/dts/testing/mocks/auth/auth.d.ts.map +1 -1
  26. package/dist/dts/testing/mocks/connect/connect.d.ts +3 -1
  27. package/dist/dts/testing/mocks/connect/connect.d.ts.map +1 -1
  28. package/dist/dts/testing/mocks/connect/socket.d.ts +1 -1
  29. package/dist/dts/testing/mocks/connect/socket.d.ts.map +1 -1
  30. package/dist/dts/testing/mocks/datasource/datasource.d.ts +1 -1
  31. package/dist/dts/testing/mocks/datasource/datasource.d.ts.map +1 -1
  32. package/dist/esm/connect/connect.events.js +21 -2
  33. package/dist/esm/connect/connect.js +26 -28
  34. package/dist/esm/connect/connect.types.js +21 -5
  35. package/dist/esm/connect/http.connect.js +11 -23
  36. package/dist/esm/connect/http.connect.types.js +24 -0
  37. package/dist/esm/connect/index.js +1 -0
  38. package/dist/esm/connect/message.js +3 -2
  39. package/dist/esm/connect/socket.js +10 -5
  40. package/dist/esm/connect/socket.types.js +1 -0
  41. package/dist/esm/connect/updateState.js +26 -0
  42. package/dist/esm/networkMonitor/service.js +18 -8
  43. package/dist/esm/testing/mocks/connect/connect.js +3 -0
  44. package/dist/esm/testing/mocks/connect/socket.js +1 -1
  45. package/dist/foundation-comms.api.json +823 -384
  46. package/dist/foundation-comms.d.ts +63 -16
  47. package/docs/api/foundation-comms.connect.md +1 -0
  48. package/docs/api/foundation-comms.connect.streamstate.md +30 -0
  49. package/docs/api/foundation-comms.connectconfig.iswebsocketexpression.md +13 -0
  50. package/docs/api/foundation-comms.connectconfig.md +1 -0
  51. package/docs/api/foundation-comms.connectevents.addstreamlistener.md +2 -1
  52. package/docs/api/foundation-comms.connectevents.md +1 -1
  53. package/docs/api/foundation-comms.connecteventsemitter.md +1 -0
  54. package/docs/api/foundation-comms.connecteventsemitter.onstreamerrorevent.md +26 -0
  55. package/docs/api/foundation-comms.defaultconnect._constructor_.md +2 -2
  56. package/docs/api/foundation-comms.defaultconnect.md +1 -0
  57. package/docs/api/foundation-comms.defaultconnect.streamstate.md +26 -0
  58. package/docs/api/foundation-comms.defaultconnectevents.addstreamlistener.md +2 -1
  59. package/docs/api/foundation-comms.defaultconnectevents.md +2 -1
  60. package/docs/api/foundation-comms.defaultconnectevents.onstreamerrorevent.md +26 -0
  61. package/docs/api/foundation-comms.defaulthttpconnect._constructor_.md +2 -2
  62. package/docs/api/foundation-comms.defaulthttpconnect.md +1 -0
  63. package/docs/api/foundation-comms.defaulthttpconnect.streamstate.md +26 -0
  64. package/docs/api/foundation-comms.md +3 -4
  65. package/docs/api/foundation-comms.pingmessage.md +1 -1
  66. package/docs/api/foundation-comms.streamerrorevent.md +14 -0
  67. package/docs/api/foundation-comms.streamerroreventdetail.md +16 -0
  68. package/docs/api/foundation-comms.streamerroreventtype.md +12 -0
  69. package/docs/api-report.md +36 -38
  70. package/package.json +21 -13
  71. package/docs/api/foundation-comms.defaulthttpconnectconfig.md +0 -13
  72. package/docs/api/foundation-comms.httpconnectconfig.md +0 -20
  73. package/docs/api/foundation-comms.httpconnectconfig.polling.md +0 -13
  74. package/docs/api/foundation-comms.httppollingconfig.md +0 -22
  75. package/docs/api/foundation-comms.httppollingconfig.polling_frequency.md +0 -13
  76. package/docs/api/foundation-comms.httppollingconfig.polling_interval_map.md +0 -15
  77. package/docs/api/foundation-comms.httppollingconfig.polling_map.md +0 -15
  78. package/docs/api/foundation-comms.pollingconfiguration.amount_of_polls.md +0 -18
  79. package/docs/api/foundation-comms.pollingconfiguration.md +0 -22
  80. package/docs/api/foundation-comms.pollingconfiguration.queries.md +0 -13
  81. package/docs/api/foundation-comms.pollingconfiguration.temp_frequency.md +0 -13
@@ -1,4 +1,4 @@
1
- import { Message } from '../connect';
1
+ import type { Message } from '../connect/message';
2
2
  /**
3
3
  * The available ypes of authentication.
4
4
  * @public
@@ -1 +1 @@
1
- {"version":3,"file":"auth.types.d.ts","sourceRoot":"","sources":["../../../src/auth/auth.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAErC;;;GAGG;AACH,oBAAY,QAAQ;IAClB,KAAK,UAAU;IACf,GAAG,QAAQ;IACX,GAAG,QAAQ;IACX,OAAO,YAAY;CACpB;AAED;;;GAGG;AACH,MAAM,MAAM,aAAa,GAAG;IAC1B,IAAI,EAAE,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAChC,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AA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Ae,CAAC;AAEnF;;;GAGG;AACH,MAAM,MAAM,WAAW,GAAG;IACxB,SAAS,EAAE,MAAM,CAAC;IAClB,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,WAAW,EAAE,MAAM,EAAE,CAAC;IACtB,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC3B;;;OAGG;IACH,OAAO,EAAE,OAAO,CAAC;IAEjB;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED;;;GAGG;AACH,qBAAa,SAAU,SAAQ,KAAK;IAEzB,IAAI,EAAE,OAAO;IACb,QAAQ,CAAC,EAAE,OAAO;gBADlB,IAAI,EAAE,OAAO,EACb,QAAQ,CAAC,EAAE,OAAO,EACzB,OAAO,GAAE,MAAyB;IAMpC,gBAAgB,IAAI,OAAO;IAc3B,eAAe,IAAI,MAAM;IAMzB,eAAe,IAAI,MAAM;IAMzB,uBAAuB,IAAI,OAAO;IAIlC,WAAW,IAAI,OAAO;IAItB,YAAY,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO;IAMnC,OAAO,CAAC,oBAAoB;CAG7B"}
@@ -6,11 +6,6 @@ import { ConnectConfig } from './connect.types';
6
6
  import { CommitParams, Message, MessageBuilder, RequestParams } from './message';
7
7
  import type { SocketObservable } from './socket';
8
8
  import { Socket } from './socket';
9
- /**
10
- * The default configuration for connecting to a WS service.
11
- * @public
12
- */
13
- export declare const defaultConnectConfig: ConnectConfig;
14
9
  /**
15
10
  * Represents a connection and its capabilities on a remote server
16
11
  * Provides methods to send and receive messages, as well as metadata and schema information.
@@ -90,8 +85,20 @@ export interface Connect {
90
85
  * @returns An observable that emits messages received from the server.
91
86
  */
92
87
  stream(resourceName: string, onMessage: Function, onError: Function, params?: any): SocketObservable<Message>;
88
+ /**
89
+ * Starts listening for updates on the specified resource.
90
+ * @public
91
+ * @param resourceName - The name of the resource to listen for updates on.
92
+ * @param onMessage - A callback function to handle received messages.
93
+ * @param onError - A callback function to handle errors.
94
+ * @param params - Additional parameters to pass to the server.
95
+ * @param initialState - State of the list to start with, defaults to empty array.
96
+ * @returns An observable that emits latest state of the list it subscribes to.
97
+ */
98
+ streamState(resourceName: string, onMessage: Function, onError: Function, params?: any, initialState?: any[]): Observable<any[]>;
93
99
  /**
94
100
  * Starts listening for updates on the specified resource without auto-teardown.
101
+ * @deprecated - Use `stream` instead. Will be removed in v15.
95
102
  * @alpha
96
103
  * @param resourceName - The name of the resource to listen for updates on.
97
104
  * @param onMessage - A callback function to handle received messages.
@@ -173,7 +180,7 @@ export declare class DefaultConnect implements Connect {
173
180
  get isConnected(): boolean;
174
181
  get isConnectedSubject(): BehaviorSubject<boolean>;
175
182
  get isConnected$(): Observable<boolean>;
176
- constructor(socket: Socket, messageBuilder: MessageBuilder, metaCache: MetaCache, events: ConnectEventsEmitter, config?: ConnectConfig);
183
+ constructor(socket: Socket, messageBuilder: MessageBuilder, metaCache: MetaCache, events: ConnectEventsEmitter, config: ConnectConfig);
177
184
  httpMode(): boolean;
178
185
  /**
179
186
  * @deprecated - Please reference {@link @genesislcap/foundation-user#User} instead.',
@@ -184,6 +191,7 @@ export declare class DefaultConnect implements Connect {
184
191
  disconnect(): void;
185
192
  snapshot(resourceName: string, params?: any): Promise<Message>;
186
193
  stream(resourceName: string, onMessage: Function, onError: Function, params?: any): SocketObservable<Message>;
194
+ streamState(resourceName: string, onMessage?: Function, onError?: Function, params?: any, initialState?: any[]): Observable<any[]>;
187
195
  streamWithoutAutoTeardown(resourceName: string, onMessage: Function, onError: Function, params?: any): SocketObservable<Message>;
188
196
  getMoreRows(sourceRef: string): Promise<Message>;
189
197
  getMoreColumns(sourceRef: string): Promise<Message>;
@@ -1 +1 @@
1
- {"version":3,"file":"connect.d.ts","sourceRoot":"","sources":["../../../src/connect/connect.ts"],"names":[],"mappings":"AAGA,OA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B,CAAC,OAAO,CAAC;IAef,WAAW,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;IAMhD,cAAc,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;IAKnD,UAAU,CAAC,eAAe,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;IAMrD,WAAW,CAAC,YAAY,EAAE,MAAM,EAAE,QAAQ,GAAE,OAAc,GAAG,OAAO,CAAC,QAAQ,CAAC;IAmC9E,aAAa,CACxB,YAAY,EAAE,MAAM,EACpB,QAAQ,GAAE,OAAc,GACvB,OAAO,CAAC,cAAc,CAAC;IAiCnB,OAAO,CAAC,YAAY,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,aAAa,GAAG,OAAO,CAAC,OAAO,CAAC;IASvE,qBAAqB,CAAC,MAAM,CAAC,EAAE,GAAG,GAAG,OAAO,CAAC,OAAO,CAAC;IAM/C,WAAW,CAAC,SAAS,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,YAAY,GAAG,OAAO,CAAC,OAAO,CAAC;CAOrF;AAID;;;GAGG;AACH,eAAO,MAAM,SAAS,+DAAkE,CAAC;AAEzF;;;GAGG;AACH,eAAO,MAAM,OAAO,+DAEnB,CAAC;AAEF;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,UAAU,IAAI,OAAO,CAEpC"}
@@ -43,6 +43,20 @@ export type StreamEventDetail = {
43
43
  * @public
44
44
  */
45
45
  export type StreamEvent = CustomEvent<StreamEventDetail>;
46
+ /**
47
+ * @public
48
+ */
49
+ export declare const StreamErrorEventType = "connect-stream-error-event";
50
+ /**
51
+ * @public
52
+ */
53
+ export type StreamErrorEventDetail = Pick<StreamEventDetail, 'resourceName' | 'stream'> & {
54
+ error: any;
55
+ };
56
+ /**
57
+ * @public
58
+ */
59
+ export type StreamErrorEvent = CustomEvent<StreamErrorEventDetail>;
46
60
  /**
47
61
  * @public
48
62
  */
@@ -81,8 +95,9 @@ export interface ConnectEvents {
81
95
  * Add a stream listener.
82
96
  * @param listener - A listener callback function.
83
97
  * @param complete - A complete listener callback function.
98
+ * @param error - A error listener callback function.
84
99
  */
85
- addStreamListener(listener: Listener<StreamEvent>, complete: Listener<StreamCompleteEvent>): () => void;
100
+ addStreamListener(listener: Listener<StreamEvent>, complete: Listener<StreamCompleteEvent>, error: Listener<StreamErrorEvent>): () => void;
86
101
  /**
87
102
  * Add a commit listener.
88
103
  * @param listener - A listener callback function.
@@ -108,6 +123,13 @@ export interface ConnectEventsEmitter extends ConnectEvents {
108
123
  * @param functions - Any functions provided.
109
124
  */
110
125
  onStreamEvent(resourceName: string, message: Message<MessageDetails.DataserverRequest>, stream: SocketObservable<any>, functions: StreamEventFunctions): void;
126
+ /**
127
+ * Called by Connect.
128
+ * @param resourceName - The name of the resource.
129
+ * @param stream - The actual stream itself.
130
+ * @param error - The error that occurred.
131
+ */
132
+ onStreamErrorEvent(resourceName: string, stream: SocketObservable<any>, error: any): void;
111
133
  /**
112
134
  * Called by Connect.
113
135
  * @param resourceName - The name of the resource.
@@ -137,10 +159,14 @@ export declare class DefaultConnectEvents implements ConnectEventsEmitter {
137
159
  protected streamListeners: import("@genesislcap/foundation-utils").Observer<StreamEvent>;
138
160
  /** @internal */
139
161
  protected streamCompleteListeners: import("@genesislcap/foundation-utils").Observer<StreamCompleteEvent>;
162
+ /** @internal */
163
+ protected streamErrorListeners: import("@genesislcap/foundation-utils").Observer<StreamErrorEvent>;
140
164
  /** {@inheritDoc ConnectEvents.addStreamListener} */
141
- addStreamListener(listener: Listener<StreamEvent>, complete: Listener<StreamCompleteEvent>): () => void;
165
+ addStreamListener(listener: Listener<StreamEvent>, complete: Listener<StreamCompleteEvent>, error: Listener<StreamErrorEvent>): () => void;
142
166
  /** {@inheritDoc ConnectEventsEmitter.onStreamEvent} */
143
167
  onStreamEvent(resourceName: string, message: Message<MessageDetails.DataserverRequest>, stream: SocketObservable<any>, functions: StreamEventFunctions): void;
168
+ /** {@inheritDoc ConnectEventsEmitter.onStreamErrorEvent} */
169
+ onStreamErrorEvent(resourceName: string, stream: SocketObservable<any>, error: any): void;
144
170
  /** {@inheritDoc ConnectEventsEmitter.onStreamCompleteEvent} */
145
171
  onStreamCompleteEvent(resourceName: string, stream: SocketObservable<any>): void;
146
172
  /** @internal */
@@ -1 +1 @@
1
- {"version":3,"file":"connect.events.d.ts","sourceRoot":"","sources":["../../../src/connect/connect.events.ts"],"names":[],"mappings":"AAAA,OAAO,EAAkB,QAAQ,EAAE,MAAM,+BAA+B,CAAC;AAEzE,OAAO,KAAK,EAAE,uBAAuB,EAAE,0BAA0B,EAAE,MAAM,mBAAmB,CAAC;AAC7F,OAAO,KAAK,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AACzD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAEjD;;GAEG;AACH,eAAO,MAAM,eAAe,yBAAyB,CAAC;AAEtD;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC9B,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,WAAW,CAAC,iBAAiB,CAAC,CAAC;AAEzD;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAAG;IACjC,SAAS,CAAC,EAAE,QAAQ,CAAC;IACrB,OAAO,CAAC,EAAE,QAAQ,CAAC;IACnB,cAAc,CAAC,EAAE,uBAAuB,CAAC;IACzC,iBAAiB,CAAC,EAAE,0BAA0B,CAAC;CAChD,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,eAAe,yBAAyB,CAAC;AAEtD;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC9B,SAAS,EAAE,oBAAoB,CAAC;IAChC,OAAO,EAAE,OAAO,CAAC,cAAc,CAAC,iBAAiB,CAAC,CAAC;IACnD,YAAY,EAAE,MAAM,CAAC;IACrB,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SocketConnectOptions } from './socket';
2
+ import type { SocketConnectOptions } from './socket.types';
3
3
  /**
4
4
  * The connection status of the Genesis client.
5
5
  * @public
@@ -18,66 +18,19 @@ export interface ConnectConfig {
18
18
  * Options for automatic reconnection on connection loss.
19
19
  */
20
20
  reconnect: SocketReconnectOptions;
21
- }
22
- /**
23
- * Configuration options for http polling.
24
- * @public
25
- */
26
- export interface PollingConfiguration {
27
- /**
28
- * The temporary polling frequency.
29
- */
30
- TEMP_FREQUENCY: number;
31
- /**
32
- * The expected amount of HTTP polling attempts to be performed.
33
- * @remarks TEMP_FREQUENCY * AMOUNT_OF_POLLS = the total polling time/duration
34
- */
35
- AMOUNT_OF_POLLS: number;
36
- /**
37
- * The queries to be polled.
38
- */
39
- QUERIES: string[];
40
- }
41
- /**
42
- * Configuration options for http connection.
43
- * @public
44
- */
45
- export interface HttpPollingConfig {
46
- /**
47
- * The frequency of polling.
48
- */
49
- POLLING_FREQUENCY?: number;
50
- /**
51
- * The interval map of polling.
52
- */
53
- POLLING_INTERVAL_MAP?: {
54
- [resource: string]: number;
55
- };
56
21
  /**
57
- * The map of polling configuration.
22
+ * Check for web socket url pattern.
58
23
  */
59
- POLLING_MAP?: {
60
- [key: string]: PollingConfiguration;
61
- };
24
+ isWebSocketExpression: RegExp;
62
25
  }
63
26
  /**
64
- * Configuration options for the Connect (HTTP) instance.
27
+ * The default configuration for connecting to a WS service.
65
28
  * @public
66
29
  */
67
- export interface HttpConnectConfig {
68
- /**
69
- * Configuration options for http polling.
70
- */
71
- polling: HttpPollingConfig;
72
- }
30
+ export declare const defaultConnectConfig: ConnectConfig;
73
31
  /**
74
32
  * Configuration options for the Connect (WS) instance.
75
33
  * @internal
76
34
  */
77
35
  export declare const ConnectConfig: import("@microsoft/fast-foundation").InterfaceSymbol<ConnectConfig>;
78
- /**
79
- * Configuration options for the Connect (HTTP) instance.
80
- * @internal
81
- */
82
- export declare const HttpConnectConfig: import("@microsoft/fast-foundation").InterfaceSymbol<HttpConnectConfig>;
83
36
  //# sourceMappingURL=connect.types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"connect.types.d.ts","sourceRoot":"","sources":["../../../src/connect/connect.types.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;AAClE,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;AAErD;;;GAGG;AACH,MAAM,MAAM,gBAAgB,GAAG,WAAW,GAAG,cAAc,GAAG,MAAM,CAAC;AAErE;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,OAAO,EAAE,oBAAoB,CAAC;IAE9B;;OAEG;IACH,SAAS,EAAE,sBAAsB,CAAC;CACnC;AAED;;;GAGG;AACH,MAAM,WAAW,oBAAoB;IACnC;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;IAEvB;;;OAGG;IACH,eAAe,EAAE,MAAM,CAAC;IAExB;;OAEG;IACH,OAAO,EAAE,MAAM,EAAE,CAAC;CACnB;AAED;;;GAGG;AACH,MAAM,WAAW,iBAAiB;IAChC;;OAEG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAE3B;;OAEG;IACH,oBAAoB,CAAC,EAAE;QAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAEtD;;OAEG;IACH,WAAW,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,oBAAoB,CAAA;KAAE,CAAC;CACvD;AAED;;;GAGG;AACH,MAAM,WAAW,iBAAiB;IAChC;;OAEG;IACH,OAAO,EAAE,iBAAiB,CAAC;CAC5B;AAED;;;GAGG;AACH,eAAO,MAAM,aAAa,qEAAsC,CAAC;AAEjE;;;GAGG;AACH,eAAO,MAAM,iBAAiB,yEAA0C,CAAC"}
1
+ {"version":3,"file":"connect.types.d.ts","sourceRoot":"","sources":["../../../src/connect/connect.types.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;AAClE,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAE3D;;;GAGG;AACH,MAAM,MAAM,gBAAgB,GAAG,WAAW,GAAG,cAAc,GAAG,MAAM,CAAC;AAErE;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,OAAO,EAAE,oBAAoB,CAAC;IAE9B;;OAEG;IACH,SAAS,EAAE,sBAAsB,CAAC;IAElC;;OAEG;IACH,qBAAqB,EAAE,MAAM,CAAC;CAC/B;AAED;;;GAGG;AACH,eAAO,MAAM,oBAAoB,EAAE,aAelC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,aAAa,qEAEzB,CAAC"}
@@ -3,16 +3,11 @@ import { BehaviorSubject, Observable } from 'rxjs';
3
3
  import type { Metadata, SchemaResponse } from '../metadata';
4
4
  import { MetaCache } from '../metadata';
5
5
  import { Session } from '../session';
6
- import { Connect } from './connect';
7
- import { HttpConnectConfig } from './connect.types';
6
+ import type { Connect } from './connect';
8
7
  import { Http } from './http';
8
+ import { HttpConnectConfig } from './http.connect.types';
9
9
  import { CommitParams, Message, MessageBuilder, RequestParams } from './message';
10
10
  import { SocketObservable } from './socket';
11
- /**
12
- * The default configuration for connecting to an HTTP service.
13
- * @public
14
- */
15
- export declare const defaultHttpConnectConfig: HttpConnectConfig;
16
11
  /**
17
12
  * The default implementation for the Connect interface (HTTP-only).
18
13
  * @public
@@ -38,7 +33,7 @@ export declare class DefaultHttpConnect implements Connect {
38
33
  * @internal
39
34
  */
40
35
  private streams;
41
- constructor(http: Http, messageBuilder: MessageBuilder, session: Session, metaCache: MetaCache, serializer: JSONSerializer, config?: HttpConnectConfig);
36
+ constructor(http: Http, messageBuilder: MessageBuilder, session: Session, metaCache: MetaCache, serializer: JSONSerializer, config: HttpConnectConfig);
42
37
  /**
43
38
  * Checks if the host is available by sending a heartbeat ping message and waiting for the response.
44
39
  * @internal
@@ -52,6 +47,7 @@ export declare class DefaultHttpConnect implements Connect {
52
47
  disconnect(): void;
53
48
  snapshot(resourceName: string, params?: any): Promise<Message>;
54
49
  stream(resourceName: string, onMessage: Function, onError: Function, params?: any): SocketObservable<Message>;
50
+ streamState(resourceName: string, onMessage?: Function, onError?: Function, params?: any, initialState?: any[]): Observable<any[]>;
55
51
  streamWithoutAutoTeardown(resourceName: string, onMessage: Function, onError: Function, params?: any): SocketObservable<Message<any>>;
56
52
  private getMessage;
57
53
  getMoreRows(sourceRef: string): Promise<Message>;
@@ -1 +1 @@
1
- {"version":3,"file":"http.connect.d.ts","sourceRoot":"","sources":["../../../src/connect/http.connect.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAG5E,OAAO,EACL,eAAe,EAKf,UAAU,EAGX,MAAM,MAAM,CAAC;AACd,OAAO,KAAK,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC5D,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAErC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,OAAO,EACL,YAAY,EAEZ,OAAO,EACP,cAAc,EAGd,aAAa,EACd,MAAM,WAAW,CAAC;AACnB,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAgB5C;;;GAGG;AACH,eAAO,MAAM,wBAAwB,EAAE,iBAqBtC,CAAC;AAEF;;;GAGG;AACH,qBAAa,kBAAmB,YAAW,OAAO;IAqCjC,IAAI,EAAE,IAAI;IACP,OAAO,CAAC,cAAc;IAC7B,OAAO,CAAC,OAAO;IACb,OAAO,CAAC,SAAS;IACZ,OAAO,CAAC,UAAU;IACL,OAAO,C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,CAAC;IAYpF,OAAO,CAAC,UAAU;IAkDlB,OAAO,CAAC,eAAe;IAOvB,OAAO,CAAC,8BAA8B;IAmBtC,OAAO,CAAC,MAAM,CAAC,OAAO;IAItB,OAAO,CAAC,MAAM,CAAC,MAAM;CAUtB;AAED;;;GAGG;AACH,eAAO,MAAM,WAAW,+DAAsE,CAAC"}
@@ -0,0 +1,62 @@
1
+ /**
2
+ * Configuration options for http polling.
3
+ * @public
4
+ */
5
+ export interface PollingConfiguration {
6
+ /**
7
+ * The temporary polling frequency.
8
+ */
9
+ TEMP_FREQUENCY: number;
10
+ /**
11
+ * The expected amount of HTTP polling attempts to be performed.
12
+ * @remarks TEMP_FREQUENCY * AMOUNT_OF_POLLS = the total polling time/duration
13
+ */
14
+ AMOUNT_OF_POLLS: number;
15
+ /**
16
+ * The queries to be polled.
17
+ */
18
+ QUERIES: string[];
19
+ }
20
+ /**
21
+ * Configuration options for http connection.
22
+ * @public
23
+ */
24
+ export interface HttpPollingConfig {
25
+ /**
26
+ * The frequency of polling.
27
+ */
28
+ POLLING_FREQUENCY?: number;
29
+ /**
30
+ * The interval map of polling.
31
+ */
32
+ POLLING_INTERVAL_MAP?: {
33
+ [resource: string]: number;
34
+ };
35
+ /**
36
+ * The map of polling configuration.
37
+ */
38
+ POLLING_MAP?: {
39
+ [key: string]: PollingConfiguration;
40
+ };
41
+ }
42
+ /**
43
+ * Configuration options for the Connect (HTTP) instance.
44
+ * @public
45
+ */
46
+ export interface HttpConnectConfig {
47
+ /**
48
+ * Configuration options for http polling.
49
+ */
50
+ polling: HttpPollingConfig;
51
+ }
52
+ /**
53
+ * The default configuration for connecting to an HTTP service.
54
+ * @public
55
+ */
56
+ export declare const defaultHttpConnectConfig: HttpConnectConfig;
57
+ /**
58
+ * Configuration options for the Connect (HTTP) instance.
59
+ * @internal
60
+ */
61
+ export declare const HttpConnectConfig: import("@microsoft/fast-foundation").InterfaceSymbol<HttpConnectConfig>;
62
+ //# sourceMappingURL=http.connect.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"http.connect.types.d.ts","sourceRoot":"","sources":["../../../src/connect/http.connect.types.ts"],"names":[],"mappings":"AAGA;;;GAGG;AACH,MAAM,WAAW,oBAAoB;IACnC;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;IAEvB;;;OAGG;IACH,eAAe,EAAE,MAAM,CAAC;IAExB;;OAEG;IACH,OAAO,EAAE,MAAM,EAAE,CAAC;CACnB;AAED;;;GAGG;AACH,MAAM,WAAW,iBAAiB;IAChC;;OAEG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAE3B;;OAEG;IACH,oBAAoB,CAAC,EAAE;QAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAEtD;;OAEG;IACH,WAAW,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,oBAAoB,CAAA;KAAE,CAAC;CACvD;AAED;;;GAGG;AACH,MAAM,WAAW,iBAAiB;IAChC;;OAEG;IACH,OAAO,EAAE,iBAAiB,CAAC;CAC5B;AAED;;;GAGG;AACH,eAAO,MAAM,wBAAwB,EAAE,iBAqBtC,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,iBAAiB,yEAE7B,CAAC"}
@@ -7,5 +7,6 @@ export * from './message';
7
7
  export * from './serializers';
8
8
  export * from './socket.status';
9
9
  export * from './socket';
10
+ export * from './socket.types';
10
11
  export * from './reconnectStrategy';
11
12
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/connect/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,iBAAiB,CAAC;AAChC,cAAc,UAAU,CAAC;AACzB,cAAc,qBAAqB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/connect/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,iBAAiB,CAAC;AAChC,cAAc,UAAU,CAAC;AACzB,cAAc,gBAAgB,CAAC;AAC/B,cAAc,qBAAqB,CAAC"}
@@ -215,7 +215,7 @@ export type Message<T = void | any> = {
215
215
  /**
216
216
  * @public
217
217
  */
218
- export type PingMessage = Pick<Message, 'MESSAGE_TYPE' | 'SOURCE_REF' | 'DETAILS'> & {
218
+ export type PingMessage = Pick<Message, 'MESSAGE_TYPE' | 'SOURCE_REF' | 'DETAILS' | 'SESSION_AUTH_TOKEN'> & {
219
219
  VERBOSE?: boolean;
220
220
  [key: string]: any;
221
221
  };
@@ -275,12 +275,16 @@ export declare const messageOrThrow: (message: Message) => Message<any>;
275
275
  /**
276
276
  * Check if the message contains an error code.
277
277
  * @param message - The message object.
278
- * @param code - The error code.
278
+ * @param code - The error code. Either a {@link http-status-codes#StatusCodes | StatusCodes} number or an entire status code string.
279
279
  * @public
280
280
  */
281
281
  export declare const messageHasErrorCode: (message: Message, code: string | number) => boolean;
282
282
  /**
283
283
  * A utility class for building different types of messages.
284
+ *
285
+ * @privateRemarks
286
+ * The SESSION_AUTH_TOKEN etc in messages should probably be removed with the move to cookies.
287
+ *
284
288
  * @public
285
289
  */
286
290
  export interface MessageBuilder {
@@ -1 +1 @@
1
- {"version":3,"file":"message.d.ts","sourceRoot":"","sources":["../../../src/connect/message.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,+BAA+B,CAAC;AAErD,OAAO,EAAE,QAA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AW/B,mBAAmB,CAAC,CAAC,GAAG,GAAG,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,YAAY,GAAG,OAAO,CAAC,CAAC,CAAC;IASlF,yBAAyB,IAAI,OAAO,CAAC,cAAc,CAAC,YAAY,CAAC;IAYjE,2BAA2B,CAChC,QAAQ,EAAE,MAAM,EAChB,WAAW,EAAE,MAAM,EACnB,WAAW,EAAE,MAAM,GAClB,OAAO,CAAC,cAAc,CAAC,cAAc,CAAC;IAYlC,2BAA2B,CAChC,QAAQ,EAAE,MAAM,EAChB,SAAS,EAAE,MAAM,EACjB,SAAS,GAAE,MAAiB,GAC3B,OAAO,CAAC,cAAc,CAAC,cAAc,CAAC;IAYlC,gCAAgC,CACrC,QAAQ,EAAE,MAAM,EAChB,UAAU,EAAE,MAAM,EAClB,WAAW,EAAE,MAAM,EACnB,SAAS,GAAE,MAAiB,GAC3B,OAAO,CAAC,cAAc,CAAC,mBAAmB,CAAC;IAavC,qBAAqB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO;IAWjD,wBAAwB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO;IAOpD,4BAA4B,CACjC,OAAO,EAAE,OAAO,EAChB,WAAW,GAAE,MAA0C,GACtD,WAAW;IAed,8DAA8D;IACvD,0BAA0B,CAAC,OAAO,UAAQ,GAAG,WAAW;CAShE;AAED;;;GAGG;AACH,eAAO,MAAM,cAAc,sEAE1B,CAAC"}
@@ -1,10 +1,11 @@
1
1
  import { User } from '@genesislcap/foundation-user';
2
2
  import { JSONSerializer, UUID } from '@genesislcap/foundation-utils';
3
- import { Observable, Observer, Subject, Subscription } from 'rxjs';
3
+ import { Observable, Subject, Subscription } from 'rxjs';
4
4
  import { Session } from '../session';
5
- import { Message, MessageBuilder, PingMessage, PongMessage } from './message';
5
+ import { Message, MessageBuilder } from './message';
6
6
  import { SocketReconnectOptions } from './reconnectStrategy';
7
7
  import { SocketStatus } from './socket.status';
8
+ import type { SocketConnectOptions } from './socket.types';
8
9
  /**
9
10
  * Subject that wraps a WebSocketSubject and provides a Subject interface for sending and receiving messages.
10
11
  * @public
@@ -26,60 +27,6 @@ export declare class SocketObservable<T> extends Observable<T> {
26
27
  * @public
27
28
  */
28
29
  export { Subscription as SocketSubscription };
29
- /**
30
- * The Socket connection options definition.
31
- * @public
32
- */
33
- export type SocketConnectOptions = {
34
- /**
35
- * Experimental flag to force reconnection all error scenarios (1011, 1012, etc). Won't rely on reconnectAttempts value.
36
- * @experimental
37
- * @remarks
38
- * This will force the socket to reconnect if the connection is lost even on "final" errors. Only disconnects when directly calling reset()
39
- * @see Socket#reset
40
- */
41
- alwaysOn?: boolean;
42
- /**
43
- * An observer to receive notifications of incoming messages from the server.
44
- */
45
- connectObserver?: Observer<Message>;
46
- /**
47
- * Enable sending heartbeat messages to the server to prevent the connection from timing out.
48
- */
49
- enableHeartbeat?: boolean;
50
- /**
51
- * Enable logging of heartbeat messages.
52
- */
53
- enableHeartbeatLogging?: boolean;
54
- /**
55
- * Enable logging of incoming and outgoing WS messages.
56
- */
57
- enableMessageLogging?: boolean;
58
- /**
59
- * Interval between heartbeat messages
60
- * @remarks
61
- * Time in milliseconds
62
- */
63
- heartbeatInterval?: number;
64
- /**
65
- * Server will send resource level information
66
- */
67
- verboseHeartbeat?: boolean;
68
- /**
69
- * Called with the ping message before it is sent
70
- * @param message - The outgoing ping message.
71
- */
72
- heartbeatPingCallback?: (message: PingMessage) => void;
73
- /**
74
- * Called with the pong message after it is received
75
- * @param message - The incoming pong message.
76
- */
77
- heartbeatPongCallback?: (message: PongMessage) => void;
78
- /**
79
- * The path to a proxy server to use for the connection.
80
- */
81
- proxyPath?: string;
82
- };
83
30
  /**
84
31
  * The Socket message handler definition.
85
32
  * @public
@@ -1 +1 @@
1
- {"version":3,"file":"socket.d.ts","sourceRoot":"","sources":["../../../src/connect/socket.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,8BAA8B,CAAC;AACpD,OA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AAE,aAAa,UAAO,GAAG,OAAO,CAAC,OAAO,GAAG,GAAG,CAAC;IAyBhF,aAAa,CAAC,CAAC,EACpB,OAAO,EAAE,OAAO,CAAC,CAAC,GAAG,GAAG,CAAC,EACzB,SAAS,EAAE,QAAQ,EACnB,OAAO,EAAE,QAAQ,EACjB,UAAU,CAAC,EAAE,QAAQ,GACpB,UAAU,CAAC,OAAO,CAAC;IAgDf,4BAA4B,CAAC,CAAC,EACnC,OAAO,EAAE,OAAO,CAAC,CAAC,GAAG,GAAG,CAAC,EACzB,SAAS,EAAE,QAAQ,EACnB,OAAO,EAAE,QAAQ,GAChB,UAAU,CAAC,OAAO,CAAC;IAcf,cAAc,QAAO,cAAc,OAAO,CAAC,CAAoB;IAEtE,OAAO,CAAC,iBAAiB;IAezB,OAAO,CAAC,cAAc;IAItB,OAAO,CAAC,oBAAoB;IAI5B,OAAO,CAAC,iBAAiB;IAUzB,OAAO,CAAC,kBAAkB;CAkB3B;AAED;;;GAGG;AACH,eAAO,MAAM,MAAM,8DAAgE,CAAC;AAEpF;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,SAAS,IAAI,MAAM,CAElC"}
@@ -0,0 +1,57 @@
1
+ import type { Observer } from 'rxjs';
2
+ import type { Message, PingMessage, PongMessage } from './message';
3
+ /**
4
+ * The Socket connection options definition.
5
+ * @public
6
+ */
7
+ export type SocketConnectOptions = {
8
+ /**
9
+ * Experimental flag to force reconnection all error scenarios (1011, 1012, etc). Won't rely on reconnectAttempts value.
10
+ * @experimental
11
+ * @remarks
12
+ * This will force the socket to reconnect if the connection is lost even on "final" errors. Only disconnects when directly calling reset()
13
+ * @see Socket#reset
14
+ */
15
+ alwaysOn?: boolean;
16
+ /**
17
+ * An observer to receive notifications of incoming messages from the server.
18
+ */
19
+ connectObserver?: Observer<Message>;
20
+ /**
21
+ * Enable sending heartbeat messages to the server to prevent the connection from timing out.
22
+ */
23
+ enableHeartbeat?: boolean;
24
+ /**
25
+ * Enable logging of heartbeat messages.
26
+ */
27
+ enableHeartbeatLogging?: boolean;
28
+ /**
29
+ * Enable logging of incoming and outgoing WS messages.
30
+ */
31
+ enableMessageLogging?: boolean;
32
+ /**
33
+ * Interval between heartbeat messages
34
+ * @remarks
35
+ * Time in milliseconds
36
+ */
37
+ heartbeatInterval?: number;
38
+ /**
39
+ * Server will send resource level information
40
+ */
41
+ verboseHeartbeat?: boolean;
42
+ /**
43
+ * Called with the ping message before it is sent
44
+ * @param message - The outgoing ping message.
45
+ */
46
+ heartbeatPingCallback?: (message: PingMessage) => void;
47
+ /**
48
+ * Called with the pong message after it is received
49
+ * @param message - The incoming pong message.
50
+ */
51
+ heartbeatPongCallback?: (message: PongMessage) => void;
52
+ /**
53
+ * The path to a proxy server to use for the connection.
54
+ */
55
+ proxyPath?: string;
56
+ };
57
+ //# sourceMappingURL=socket.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"socket.types.d.ts","sourceRoot":"","sources":["../../../src/connect/socket.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,MAAM,CAAC;AACrC,OAAO,KAAK,EAAE,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAEnE;;;GAGG;AACH,MAAM,MAAM,oBAAoB,GAAG;IACjC;;;;;;OAMG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB;;OAEG;IACH,eAAe,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,CAAC;IAEpC;;OAEG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAE1B;;OAEG;IACH,sBAAsB,CAAC,EAAE,OAAO,CAAC;IAEjC;;OAEG;IACH,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAE/B;;;;OAIG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B;;OAEG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B;;;OAGG;IACH,qBAAqB,CAAC,EAAE,CAAC,OAAO,EAAE,WAAW,KAAK,IAAI,CAAC;IACvD;;;OAGG;IACH,qBAAqB,CAAC,EAAE,CAAC,OAAO,EAAE,WAAW,KAAK,IAAI,CAAC;IACvD;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { Message } from './message';
2
+ export declare const updateState: (state: Array<any>, update: Message) => Array<any>;
3
+ //# sourceMappingURL=updateState.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"updateState.d.ts","sourceRoot":"","sources":["../../../src/connect/updateState.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC,eAAO,MAAM,WAAW,UAAW,MAAM,GAAG,CAAC,UAAU,OAAO,KAAG,MAAM,GAAG,CA+BzE,CAAC"}