@fluidframework/debugger 2.0.0-dev.7.4.0.215930 → 2.0.0-dev.7.4.0.217212

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.
@@ -0,0 +1,13 @@
1
+ {
2
+ "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
3
+ "extends": "../../../common/build/build-common/api-extractor-lint.json",
4
+ "messages": {
5
+ "extractorMessageReporting": {
6
+ // TODO: remove once base config has this enabled as an error
7
+ "ae-incompatible-release-tags": {
8
+ "logLevel": "error",
9
+ "addToApiReportFile": false
10
+ }
11
+ }
12
+ }
13
+ }
@@ -14,7 +14,7 @@ import { IVersion } from '@fluidframework/protocol-definitions';
14
14
  import { ReadDocumentStorageServiceBase } from '@fluidframework/replay-driver';
15
15
  import { ReplayController } from '@fluidframework/replay-driver';
16
16
 
17
- // @public (undocumented)
17
+ // @internal (undocumented)
18
18
  export class DebuggerUI {
19
19
  protected constructor(controller: IDebuggerController, debuggerWindow: Window);
20
20
  // (undocumented)
@@ -55,10 +55,10 @@ export class DebuggerUI {
55
55
  protected wasVersionSelected: boolean;
56
56
  }
57
57
 
58
- // @public (undocumented)
58
+ // @internal (undocumented)
59
59
  export type debuggerUIFactory = (controller: IDebuggerController) => IDebuggerUI | null;
60
60
 
61
- // @public
61
+ // @internal
62
62
  export class DebugReplayController extends ReplayController implements IDebuggerController {
63
63
  // (undocumented)
64
64
  connectToUi(ui: IDebuggerUI): void;
@@ -123,14 +123,14 @@ export class DebugReplayController extends ReplayController implements IDebugger
123
123
  protected static readonly WindowClosedSeq = -1;
124
124
  }
125
125
 
126
- // @public (undocumented)
126
+ // @internal (undocumented)
127
127
  export namespace FluidDebugger {
128
128
  export function createFromService(documentService: IDocumentService): Promise<IDocumentService>;
129
129
  // (undocumented)
130
130
  export function createFromServiceFactory(documentServiceFactory: IDocumentServiceFactory): Promise<IDocumentServiceFactory>;
131
131
  }
132
132
 
133
- // @public (undocumented)
133
+ // @internal (undocumented)
134
134
  export interface IDebuggerController {
135
135
  connectToUi(ui: IDebuggerUI): any;
136
136
  onClose(): void;
@@ -140,7 +140,7 @@ export interface IDebuggerController {
140
140
  onVersionSelection(version: IVersion): void;
141
141
  }
142
142
 
143
- // @public (undocumented)
143
+ // @internal (undocumented)
144
144
  export interface IDebuggerUI {
145
145
  addVersions(version: IVersion[]): void;
146
146
  disableNextOpButton(disable: boolean): void;
@@ -1,190 +1,26 @@
1
- import { Deferred } from '@fluidframework/core-utils';
2
1
  import { IDocumentService } from '@fluidframework/driver-definitions';
3
2
  import { IDocumentServiceFactory } from '@fluidframework/driver-definitions';
4
3
  import { IDocumentStorageService } from '@fluidframework/driver-definitions';
5
4
  import { ISequencedDocumentMessage } from '@fluidframework/protocol-definitions';
6
5
  import { ISnapshotTree } from '@fluidframework/protocol-definitions';
7
6
  import { IVersion } from '@fluidframework/protocol-definitions';
8
- import { ReadDocumentStorageServiceBase } from '@fluidframework/replay-driver';
9
- import { ReplayController } from '@fluidframework/replay-driver';
10
7
 
11
- /**
12
- * @public
13
- */
14
- export declare class DebuggerUI {
15
- private readonly controller;
16
- private readonly debuggerWindow;
17
- static create(controller: IDebuggerController): DebuggerUI | null;
18
- private static formatDate;
19
- protected selector?: HTMLSelectElement;
20
- protected versionText: HTMLDivElement;
21
- protected buttonOps?: HTMLButtonElement;
22
- protected text1?: HTMLDivElement;
23
- protected text2?: HTMLDivElement;
24
- protected text3?: HTMLDivElement;
25
- protected lastOpText?: HTMLDivElement;
26
- protected wasVersionSelected: boolean;
27
- protected versions: IVersion[];
28
- protected documentClosed: boolean;
29
- protected constructor(controller: IDebuggerController, debuggerWindow: Window);
30
- private attachDownloadOpsListener;
31
- addVersions(versions: IVersion[]): void;
32
- updateVersion(index: number, version: IVersion, seqNumber: number): void;
33
- versionSelected(seqNumber: number, version: IVersion | string): void;
34
- disableNextOpButton(disable: boolean): void;
35
- updateNextOpText(ops: ISequencedDocumentMessage[]): void;
36
- updateVersionText(versionCount: number): void;
37
- updateLastOpText(lastKnownOp: number, stillLoading: boolean): void;
38
- private download;
39
- }
8
+ /* Excluded from this release type: DebuggerUI */
40
9
 
41
- /**
42
- * @public
43
- */
44
- export declare type debuggerUIFactory = (controller: IDebuggerController) => IDebuggerUI | null;
10
+ /* Excluded from this release type: debuggerUIFactory */
45
11
 
46
- /**
47
- * Replay controller that uses pop-up window to control op playback
48
- *
49
- * @public
50
- */
51
- export declare class DebugReplayController extends ReplayController implements IDebuggerController {
52
- static create(createUi: debuggerUIFactory): DebugReplayController | null;
53
- protected static readonly WindowClosedSeq = -1;
54
- protected static seqFromTree(documentStorageService: IDocumentStorageService, tree: ISnapshotTree | null): Promise<number>;
55
- protected ui: IDebuggerUI;
56
- protected stepsDeferred?: Deferred<number>;
57
- protected startSeqDeferred: Deferred<number>;
58
- protected retryFetchOpsOnEndOfFile: boolean;
59
- protected documentService?: IDocumentService;
60
- protected documentStorageService?: IDocumentStorageService;
61
- protected versions: IVersion[];
62
- protected stepsToPlay: number;
63
- protected lastOpReached: boolean;
64
- protected versionCount: number;
65
- protected storage?: ReadDocumentStorageServiceBase;
66
- private shouldUseController;
67
- connectToUi(ui: IDebuggerUI): void;
68
- onClose(): void;
69
- onVersionSelection(version: IVersion): Promise<void>;
70
- onOpButtonClick(steps: number): void;
71
- onSnapshotFileSelection(file: File): void;
72
- onDownloadOpsButtonClick(anonymize: boolean): Promise<string>;
73
- private fetchOpsFromDeltaStorage;
74
- fetchTo(currentOp: number): number | undefined;
75
- isSelectionMade(): boolean;
76
- downloadVersionInfo(documentStorageService: IDocumentStorageService, prevRequest: Promise<void>, index: number, version: IVersion): Promise<void>;
77
- initStorage(documentService: IDocumentService): Promise<boolean>;
78
- readBlob(blobId: string): Promise<ArrayBufferLike>;
79
- getVersions(versionId: string | null, count: number): Promise<IVersion[]>;
80
- getSnapshotTree(versionRequested?: IVersion): Promise<ISnapshotTree | null>;
81
- getStartingOpSequence(): Promise<number>;
82
- /**
83
- * Return true if we are done processing ops
84
- */
85
- isDoneFetch(currentOp: number, lastTimeStamp?: number): boolean;
86
- replay(emitter: (op: ISequencedDocumentMessage[]) => void, fetchedOps: ISequencedDocumentMessage[]): Promise<void>;
87
- protected resolveStorage(seq: number, storage: ReadDocumentStorageServiceBase, version: IVersion | string): void;
88
- }
12
+ /* Excluded from this release type: DebugReplayController */
89
13
 
90
- /**
91
- * @public
92
- */
93
- export declare namespace FluidDebugger {
94
- /**
95
- * Creates document service wrapper that pops up Debugger window and allows user to play ops one by one.
96
- * User can chose to start with any snapshot
97
- * If pop-ups are disabled, we continue without debugger.
98
- * @param documentService - original document service to use to fetch ops / snapshots.
99
- */
100
- export function createFromService(documentService: IDocumentService): Promise<IDocumentService>;
101
- export function createFromServiceFactory(documentServiceFactory: IDocumentServiceFactory): Promise<IDocumentServiceFactory>;
102
- }
14
+ /* Excluded from this release type: Deferred */
103
15
 
104
- /**
105
- * @public
106
- */
107
- export declare interface IDebuggerController {
108
- /**
109
- * Initialization. UI layers calls into controller to connect the two.
110
- * @param ui - UI layer
111
- */
112
- connectToUi(ui: IDebuggerUI): any;
113
- /**
114
- * Called by UI layer when debugger window is closed by user
115
- * If called before user makes selection of snapshot/file, original
116
- * document service is returned to loader (instead of debugger service) and normal document load continues.
117
- */
118
- onClose(): void;
119
- /**
120
- * UI Layer notifies about selection of version to continue.
121
- * On successful load, versionSelected() is called.
122
- * @param version - Snapshot version to start from.
123
- */
124
- onVersionSelection(version: IVersion): void;
125
- /**
126
- * UI Layer notifies about selection of version to continue.
127
- * On successful load, versionSelected() is called.
128
- * @param version - File to load snapshot from
129
- */
130
- onSnapshotFileSelection(file: File): void;
131
- /**
132
- * "next op" button is clicked in the UI
133
- * @param steps - number of ops to play.
134
- */
135
- onOpButtonClick(steps: number): void;
136
- /**
137
- * "Download ops" option is clicked in the UI. Returns JSON of the full opStream when available.
138
- * @param anonymize - anonymize the ops json using the sanitization tool
139
- */
140
- onDownloadOpsButtonClick(anonymize: boolean): Promise<string>;
141
- }
16
+ /* Excluded from this release type: FluidDebugger */
142
17
 
143
- /**
144
- * @public
145
- */
146
- export declare interface IDebuggerUI {
147
- /**
148
- * Version information is provided.
149
- * Expect updates (information about seq#, timestamp) through updateVersion() calls
150
- */
151
- addVersions(version: IVersion[]): void;
152
- /**
153
- * Call when new version is downloaded from storage
154
- * Expect multiple callbacks.
155
- */
156
- updateVersion(index: number, version: IVersion, seqNumber: number): void;
157
- /**
158
- * Called in response to successful onVersionSelection() or onSnapshotFileSelection() call
159
- * and provides extra information about selection.
160
- * It expected that UI layer would change its mode as result of this call, i.e. switch to
161
- * displaying op playback controls (if this is supported)
162
- * Note: There maybe no call to versionSelected() in response to onSnapshotFileSelection() call
163
- * if file does not exist, has wrong name of wrong format.
164
- * @param version - version, file name, or undefined if playing ops.
165
- */
166
- versionSelected(seqNumber: number, version: IVersion | string): void;
167
- /**
168
- * Called by controller in response to new ops being downloaded
169
- * Called with disable = true if there are no (currently) ops to play
170
- */
171
- disableNextOpButton(disable: boolean): void;
172
- /**
173
- * Called by controller when new ops arrive (or we are done playing previous batch)
174
- * Indicates next batch of ops that would be played when UI calls controller's onOpButtonClick()
175
- * Called with ops=[] when there are no ops to play.
176
- */
177
- updateNextOpText(ops: ISequencedDocumentMessage[]): void;
178
- /**
179
- * Called periodically when new versions are downloaded from server
180
- */
181
- updateVersionText(versionsLeft: number): void;
182
- /**
183
- * Called periodically to notify about last known op
184
- * @param lastKnownOp - seq number of last known op. -1 if can't play ops in this mode (load from file)
185
- * @param stillLoading - true if we did not reach yet the end of the stream
186
- */
187
- updateLastOpText(lastKnownOp: number, stillLoading: boolean): void;
188
- }
18
+ /* Excluded from this release type: IDebuggerController */
19
+
20
+ /* Excluded from this release type: IDebuggerUI */
21
+
22
+ /* Excluded from this release type: ReadDocumentStorageServiceBase */
23
+
24
+ /* Excluded from this release type: ReplayController */
189
25
 
190
26
  export { }
@@ -1,190 +1,29 @@
1
- import { Deferred } from '@fluidframework/core-utils';
2
- import { IDocumentService } from '@fluidframework/driver-definitions';
3
- import { IDocumentServiceFactory } from '@fluidframework/driver-definitions';
4
- import { IDocumentStorageService } from '@fluidframework/driver-definitions';
5
1
  import { ISequencedDocumentMessage } from '@fluidframework/protocol-definitions';
6
2
  import { ISnapshotTree } from '@fluidframework/protocol-definitions';
7
3
  import { IVersion } from '@fluidframework/protocol-definitions';
8
- import { ReadDocumentStorageServiceBase } from '@fluidframework/replay-driver';
9
- import { ReplayController } from '@fluidframework/replay-driver';
10
4
 
11
- /**
12
- * @public
13
- */
14
- export declare class DebuggerUI {
15
- private readonly controller;
16
- private readonly debuggerWindow;
17
- static create(controller: IDebuggerController): DebuggerUI | null;
18
- private static formatDate;
19
- protected selector?: HTMLSelectElement;
20
- protected versionText: HTMLDivElement;
21
- protected buttonOps?: HTMLButtonElement;
22
- protected text1?: HTMLDivElement;
23
- protected text2?: HTMLDivElement;
24
- protected text3?: HTMLDivElement;
25
- protected lastOpText?: HTMLDivElement;
26
- protected wasVersionSelected: boolean;
27
- protected versions: IVersion[];
28
- protected documentClosed: boolean;
29
- protected constructor(controller: IDebuggerController, debuggerWindow: Window);
30
- private attachDownloadOpsListener;
31
- addVersions(versions: IVersion[]): void;
32
- updateVersion(index: number, version: IVersion, seqNumber: number): void;
33
- versionSelected(seqNumber: number, version: IVersion | string): void;
34
- disableNextOpButton(disable: boolean): void;
35
- updateNextOpText(ops: ISequencedDocumentMessage[]): void;
36
- updateVersionText(versionCount: number): void;
37
- updateLastOpText(lastKnownOp: number, stillLoading: boolean): void;
38
- private download;
39
- }
5
+ /* Excluded from this release type: DebuggerUI */
40
6
 
41
- /**
42
- * @public
43
- */
44
- export declare type debuggerUIFactory = (controller: IDebuggerController) => IDebuggerUI | null;
7
+ /* Excluded from this release type: debuggerUIFactory */
45
8
 
46
- /**
47
- * Replay controller that uses pop-up window to control op playback
48
- *
49
- * @public
50
- */
51
- export declare class DebugReplayController extends ReplayController implements IDebuggerController {
52
- static create(createUi: debuggerUIFactory): DebugReplayController | null;
53
- protected static readonly WindowClosedSeq = -1;
54
- protected static seqFromTree(documentStorageService: IDocumentStorageService, tree: ISnapshotTree | null): Promise<number>;
55
- protected ui: IDebuggerUI;
56
- protected stepsDeferred?: Deferred<number>;
57
- protected startSeqDeferred: Deferred<number>;
58
- protected retryFetchOpsOnEndOfFile: boolean;
59
- protected documentService?: IDocumentService;
60
- protected documentStorageService?: IDocumentStorageService;
61
- protected versions: IVersion[];
62
- protected stepsToPlay: number;
63
- protected lastOpReached: boolean;
64
- protected versionCount: number;
65
- protected storage?: ReadDocumentStorageServiceBase;
66
- private shouldUseController;
67
- connectToUi(ui: IDebuggerUI): void;
68
- onClose(): void;
69
- onVersionSelection(version: IVersion): Promise<void>;
70
- onOpButtonClick(steps: number): void;
71
- onSnapshotFileSelection(file: File): void;
72
- onDownloadOpsButtonClick(anonymize: boolean): Promise<string>;
73
- private fetchOpsFromDeltaStorage;
74
- fetchTo(currentOp: number): number | undefined;
75
- isSelectionMade(): boolean;
76
- downloadVersionInfo(documentStorageService: IDocumentStorageService, prevRequest: Promise<void>, index: number, version: IVersion): Promise<void>;
77
- initStorage(documentService: IDocumentService): Promise<boolean>;
78
- readBlob(blobId: string): Promise<ArrayBufferLike>;
79
- getVersions(versionId: string | null, count: number): Promise<IVersion[]>;
80
- getSnapshotTree(versionRequested?: IVersion): Promise<ISnapshotTree | null>;
81
- getStartingOpSequence(): Promise<number>;
82
- /**
83
- * Return true if we are done processing ops
84
- */
85
- isDoneFetch(currentOp: number, lastTimeStamp?: number): boolean;
86
- replay(emitter: (op: ISequencedDocumentMessage[]) => void, fetchedOps: ISequencedDocumentMessage[]): Promise<void>;
87
- protected resolveStorage(seq: number, storage: ReadDocumentStorageServiceBase, version: IVersion | string): void;
88
- }
9
+ /* Excluded from this release type: DebugReplayController */
89
10
 
90
- /**
91
- * @public
92
- */
93
- export declare namespace FluidDebugger {
94
- /**
95
- * Creates document service wrapper that pops up Debugger window and allows user to play ops one by one.
96
- * User can chose to start with any snapshot
97
- * If pop-ups are disabled, we continue without debugger.
98
- * @param documentService - original document service to use to fetch ops / snapshots.
99
- */
100
- export function createFromService(documentService: IDocumentService): Promise<IDocumentService>;
101
- export function createFromServiceFactory(documentServiceFactory: IDocumentServiceFactory): Promise<IDocumentServiceFactory>;
102
- }
11
+ /* Excluded from this release type: Deferred */
103
12
 
104
- /**
105
- * @public
106
- */
107
- export declare interface IDebuggerController {
108
- /**
109
- * Initialization. UI layers calls into controller to connect the two.
110
- * @param ui - UI layer
111
- */
112
- connectToUi(ui: IDebuggerUI): any;
113
- /**
114
- * Called by UI layer when debugger window is closed by user
115
- * If called before user makes selection of snapshot/file, original
116
- * document service is returned to loader (instead of debugger service) and normal document load continues.
117
- */
118
- onClose(): void;
119
- /**
120
- * UI Layer notifies about selection of version to continue.
121
- * On successful load, versionSelected() is called.
122
- * @param version - Snapshot version to start from.
123
- */
124
- onVersionSelection(version: IVersion): void;
125
- /**
126
- * UI Layer notifies about selection of version to continue.
127
- * On successful load, versionSelected() is called.
128
- * @param version - File to load snapshot from
129
- */
130
- onSnapshotFileSelection(file: File): void;
131
- /**
132
- * "next op" button is clicked in the UI
133
- * @param steps - number of ops to play.
134
- */
135
- onOpButtonClick(steps: number): void;
136
- /**
137
- * "Download ops" option is clicked in the UI. Returns JSON of the full opStream when available.
138
- * @param anonymize - anonymize the ops json using the sanitization tool
139
- */
140
- onDownloadOpsButtonClick(anonymize: boolean): Promise<string>;
141
- }
13
+ /* Excluded from this release type: FluidDebugger */
142
14
 
143
- /**
144
- * @public
145
- */
146
- export declare interface IDebuggerUI {
147
- /**
148
- * Version information is provided.
149
- * Expect updates (information about seq#, timestamp) through updateVersion() calls
150
- */
151
- addVersions(version: IVersion[]): void;
152
- /**
153
- * Call when new version is downloaded from storage
154
- * Expect multiple callbacks.
155
- */
156
- updateVersion(index: number, version: IVersion, seqNumber: number): void;
157
- /**
158
- * Called in response to successful onVersionSelection() or onSnapshotFileSelection() call
159
- * and provides extra information about selection.
160
- * It expected that UI layer would change its mode as result of this call, i.e. switch to
161
- * displaying op playback controls (if this is supported)
162
- * Note: There maybe no call to versionSelected() in response to onSnapshotFileSelection() call
163
- * if file does not exist, has wrong name of wrong format.
164
- * @param version - version, file name, or undefined if playing ops.
165
- */
166
- versionSelected(seqNumber: number, version: IVersion | string): void;
167
- /**
168
- * Called by controller in response to new ops being downloaded
169
- * Called with disable = true if there are no (currently) ops to play
170
- */
171
- disableNextOpButton(disable: boolean): void;
172
- /**
173
- * Called by controller when new ops arrive (or we are done playing previous batch)
174
- * Indicates next batch of ops that would be played when UI calls controller's onOpButtonClick()
175
- * Called with ops=[] when there are no ops to play.
176
- */
177
- updateNextOpText(ops: ISequencedDocumentMessage[]): void;
178
- /**
179
- * Called periodically when new versions are downloaded from server
180
- */
181
- updateVersionText(versionsLeft: number): void;
182
- /**
183
- * Called periodically to notify about last known op
184
- * @param lastKnownOp - seq number of last known op. -1 if can't play ops in this mode (load from file)
185
- * @param stillLoading - true if we did not reach yet the end of the stream
186
- */
187
- updateLastOpText(lastKnownOp: number, stillLoading: boolean): void;
188
- }
15
+ /* Excluded from this release type: IDebuggerController */
16
+
17
+ /* Excluded from this release type: IDebuggerUI */
18
+
19
+ /* Excluded from this release type: IDocumentService */
20
+
21
+ /* Excluded from this release type: IDocumentServiceFactory */
22
+
23
+ /* Excluded from this release type: IDocumentStorageService */
24
+
25
+ /* Excluded from this release type: ReadDocumentStorageServiceBase */
26
+
27
+ /* Excluded from this release type: ReplayController */
189
28
 
190
29
  export { }