anki/rslib
Damien Elmes 37151213cd Move more of the graph processing into the backend
The existing architecture serializes all cards and revlog entries in
the search range into a protobuf message, which the web frontend needs
to decode and then process. The thinking at the time was that this would
make it easier for add-ons to add extra graphs, but in the ~2.5 years
since the new graphs were introduced, no add-ons appear to have taken
advantage of it.

The cards and revlog entries can grow quite large on large collections -
on a collection I tested with approximately 2.5M reviews, the serialized
data is about 110MB, which is a lot to have to deserialize in JavaScript.

This commit shifts the preliminary processing of the data to the Rust end,
which means the data is able to be processed faster, and less needs to
be sent to the frontend. On the test collection above, this reduces the
serialized data from about 110MB to about 160KB, resulting in a more
than 2x performance improvement, and reducing frontend memory usage from
about 400MB to about 40MB.

This also makes #2043 more feasible - while it is still about 50-100%
slower than protobufjs, with the much smaller message size, the difference
is only about 10ms.
2022-12-16 21:42:17 +10:00
..
ascii_percent_encoding Ignore non-ASCII chars in ascii_percent_encoding 2022-12-09 11:47:59 +01:00
benches New TTS/AV tag handling (#1559) 2021-12-17 19:04:42 +10:00
build Move away from Bazel (#2202) 2022-11-27 15:24:20 +10:00
i18n Minor Rust cleanups (#2272) 2022-12-16 21:40:27 +10:00
i18n_helpers Minor Rust cleanups (#2272) 2022-12-16 21:40:27 +10:00
linkchecker Pin chrono; update compatible Rust crates 2022-11-30 12:38:10 +10:00
src Move more of the graph processing into the backend 2022-12-16 21:42:17 +10:00
tests/support move linkchecker into separate crate 2021-12-20 17:27:43 +10:00
.gitignore initial Bazel conversion 2020-11-01 14:26:58 +10:00
bench.sh New TTS/AV tag handling (#1559) 2021-12-17 19:04:42 +10:00
Cargo.toml Minor Rust cleanups (#2272) 2022-12-16 21:40:27 +10:00
README.md Move away from Bazel (#2202) 2022-11-27 15:24:20 +10:00

Anki's Rust code.