Skip to content

Commit

Permalink
[Console] Fix performance bottleneck for large JSON payloads (elastic…
Browse files Browse the repository at this point in the history
…#57668)

* Fix Console performance bug for large request bodies

The legacy_core_editor implemenation was calculating the current editor line
count by .split('\n').length on the entire buffer which was very inefficient
in a tight loop. This caused a performance regression. Now we use the cached
line count provided by the underlying editor implementation.

* Fix performance regression inside of ace token_provider implementation

* Clean up another unnecessary use of getValue().split(..).length.

Probably was not a performance issue, just taking unnecessary steps. Not
sure that this function is even being used.
  • Loading branch information
jloleysens committed Feb 14, 2020
1 parent 46bb78e commit 73e642e
Show file tree
Hide file tree
Showing 6 changed files with 580 additions and 563 deletions.
Loading

0 comments on commit 73e642e

Please sign in to comment.