File tree Expand file tree Collapse file tree 3 files changed +12
-9
lines changed Expand file tree Collapse file tree 3 files changed +12
-9
lines changed Original file line number Diff line number Diff line change 11export enum DataSourceErrorKind {
22 /// An unexpected error, such as an uncaught exception, further
33 /// described by the error message.
4- Unknown ,
4+ Unknown = 'UNKNOWN' ,
55
66 /// An I/O error such as a dropped connection.
7- NetworkError ,
7+ NetworkError = 'NETWORK_ERROR' ,
88
99 /// The LaunchDarkly service returned an HTTP response with an error
1010 /// status, available in the status code.
11- ErrorResponse ,
11+ ErrorResponse = 'ERROR_RESPONSE' ,
1212
1313 /// The SDK received malformed data from the LaunchDarkly service.
14- InvalidData ,
14+ InvalidData = 'INVALID_DATA' ,
1515}
Original file line number Diff line number Diff line change @@ -214,6 +214,9 @@ export interface LDClient {
214214 * The callback parameters are the context and an Error object. Errors are also output by
215215 * the {@link logger} at the error level.
216216 *
217+ * - `"dataSourceStatus"`: Event indicating that there has been a change in the status of the
218+ * data source. This will include the state of the data source as well any error information.
219+ *
217220 * @param key
218221 * The name of the event for which to listen.
219222 * @param callback
Original file line number Diff line number Diff line change 11import DataSourceStatusErrorInfo from './DataSourceStatusErrorInfo' ;
22
33export enum DataSourceState {
4- Initializing ,
5- Valid ,
6- Interrupted ,
7- SetOffline ,
8- Closed ,
4+ Initializing = 'INITIALIZING' ,
5+ Valid = 'VALID' ,
6+ Interrupted = 'INTERRUPTED' ,
7+ SetOffline = 'SET_OFFLINE' ,
8+ Closed = 'CLOSED' ,
99 // TODO: SDK-702 - Implement network availability behaviors
1010 // NetworkUnavailable,
1111}
You can’t perform that action at this time.
0 commit comments