Files
sdk/pkg/analysis_server
Jens Johansen 3873af28e9 [analyzer server] Legacy protocol debounces getFixes and getAsssits requests too; benchmark
In reports of the analyzer being slow we've seen `edit.getFixes` causing
a long queue because they take longer to execute than the wait before
the next one comes in.

While we haven't been able to reproduce that, this CL adds a benchmark
that fires *a lot* of both `edit.getFixes` (seen in reports from users)
and `edit.getAssists` (which seems, locally at least, to happen every
time the cursor moves), and debounces them, changing the benchmark
results from

```
4 files / CodeType.ImportCycle:
Initial analysis: 1.322030
Completion after change: 3.096128

4 files / CodeType.ImportChain:
Initial analysis: 1.361750
Completion after change: 3.500849

4 files / CodeType.ImportExportCycle:
Initial analysis: 1.349346
Completion after change: 3.065497

4 files / CodeType.ImportExportChain:
Initial analysis: 1.367151
Completion after change: 3.246891

4 files / CodeType.ImportCycleExportChain:
Initial analysis: 1.360573
Completion after change: 3.393901
```

to

```
4 files / CodeType.ImportCycle:
Initial analysis: 1.322070
Completion after change: 0.546532

4 files / CodeType.ImportChain:
Initial analysis: 1.410870
Completion after change: 0.649789

4 files / CodeType.ImportExportCycle:
Initial analysis: 1.349923
Completion after change: 0.741040

4 files / CodeType.ImportExportChain:
Initial analysis: 1.360396
Completion after change: 0.638332

4 files / CodeType.ImportCycleExportChain:
Initial analysis: 1.354682
Completion after change: 0.658086
```

Change-Id: Icb0423133726e02e08e204b1c59209264889f8a6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/413682
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
2025-03-11 00:22:15 -07:00
..

analysis_server

A long-running process that provides analysis results to other tools.

The analysis server is designed to provide on-going analysis of one or more code bases as those code bases are changing.

Using the server

The analysis server is not intended to be used stand-alone, and therefore does not have a human-friendly user interface.

Clients (typically tools, such as an editor) are expected to run the analysis server in a separate process and communicate with it using a JSON protocol. The original protocol is specified in the file analysis_server/doc/api.html and Language Server Protocol support is documented in tool/lsp_spec/README.md.

Features and bugs

Please file feature requests and bugs at the issue tracker.