toeverything / OctoBase

🐙 OctoBase is the open-source database behind AFFiNE, local-first, yet collaborative. A light-weight, scalable, data engine written in Rust.
https://octobase.dev
GNU Affero General Public License v3.0
1.32k stars 83 forks source link

fix(codec): wrong pos when split array #516

Closed forehalo closed 1 year ago

vercel[bot] commented 1 year ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
octobase ✅ Ready (Inspect) Visit Preview 💬 Add feedback Aug 22, 2023 10:23am
codecov[bot] commented 1 year ago

Codecov Report

Patch coverage: 91.66% and project coverage change: +0.01% :tada:

Comparison is base (606b0a5) 64.65% compared to head (b18a849) 64.67%. Report is 1 commits behind head on master.

:exclamation: Current head b18a849 differs from pull request most recent head 43c5d25. Consider uploading reports for the commit 43c5d25 to get more accurate results

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #516 +/- ## ========================================== + Coverage 64.65% 64.67% +0.01% ========================================== Files 184 184 Lines 20989 20992 +3 ========================================== + Hits 13571 13577 +6 + Misses 7418 7415 -3 ``` | [Files Changed](https://app.codecov.io/gh/toeverything/OctoBase/pull/516?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toeverything) | Coverage Δ | | |---|---|---| | [libs/jwst-codec/src/doc/store.rs](https://app.codecov.io/gh/toeverything/OctoBase/pull/516?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toeverything#diff-bGlicy9qd3N0LWNvZGVjL3NyYy9kb2Mvc3RvcmUucnM=) | `88.61% <86.66%> (+0.51%)` | :arrow_up: | | [libs/jwst-codec/src/doc/codec/content.rs](https://app.codecov.io/gh/toeverything/OctoBase/pull/516?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toeverything#diff-bGlicy9qd3N0LWNvZGVjL3NyYy9kb2MvY29kZWMvY29udGVudC5ycw==) | `84.29% <100.00%> (ø)` | | ... and [2 files with indirect coverage changes](https://app.codecov.io/gh/toeverything/OctoBase/pull/516/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=toeverything)

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

github-actions[bot] commented 1 year ago

Benchmark Results

Linux

group                                     master                                 pr
-----                                     ------                                 --
codec/jwst decode var_int (32 bit)        1.00    408.9±6.24µs        ? ?/sec    1.00    407.7±1.39µs        ? ?/sec
codec/jwst decode var_uint (32 bit)       1.00    280.8±1.00µs        ? ?/sec    1.00    280.7±0.16µs        ? ?/sec
codec/jwst decode var_uint (64 bit)       1.00    289.1±0.18µs        ? ?/sec    1.00    289.1±0.13µs        ? ?/sec
codec/jwst encode var_int (32 bit)        1.00    536.7±3.82µs        ? ?/sec    1.00    539.1±4.58µs        ? ?/sec
codec/jwst encode var_uint (32 bit)       1.00    318.1±0.65µs        ? ?/sec    1.00    318.9±1.66µs        ? ?/sec
codec/jwst encode var_uint (64 bit)       1.00    317.9±0.77µs        ? ?/sec    1.01    321.7±1.57µs        ? ?/sec
codec/lib0 decode var_int (64 bit)        1.00    296.0±0.19µs        ? ?/sec    1.00    295.9±0.20µs        ? ?/sec
codec/lib0 decode var_uint (32 bit)       1.00    418.6±0.18µs        ? ?/sec    1.00    418.6±0.24µs        ? ?/sec
codec/lib0 decode var_uint (64 bit)       1.00    385.1±0.23µs        ? ?/sec    1.00    385.1±0.21µs        ? ?/sec
codec/lib0 encode var_int (64 bit)        1.00    470.2±6.24µs        ? ?/sec    1.02    481.9±6.29µs        ? ?/sec
codec/lib0 encode var_uint (32 bit)       1.00    388.4±3.69µs        ? ?/sec    1.03    400.1±1.36µs        ? ?/sec
codec/lib0 encode var_uint (64 bit)       1.00    376.4±0.11µs        ? ?/sec    1.00    376.4±0.22µs        ? ?/sec
ops/array/jwst/insert                     1.00    377.5±1.35µs        ? ?/sec    1.00    377.6±1.30µs        ? ?/sec
ops/array/jwst/insert range               1.00    513.5±0.63µs        ? ?/sec    1.00    514.8±0.58µs        ? ?/sec
ops/array/jwst/remove                     1.00    259.0±0.49µs        ? ?/sec    1.00    258.5±2.79µs        ? ?/sec
ops/array/yrs/insert                      1.06     97.2±0.14µs        ? ?/sec    1.00     91.8±0.16µs        ? ?/sec
ops/array/yrs/insert range                1.02    117.2±0.78µs        ? ?/sec    1.00    114.7±0.72µs        ? ?/sec
ops/array/yrs/remove                      1.05    106.0±0.22µs        ? ?/sec    1.00    100.8±0.13µs        ? ?/sec
ops/text/jwst/insert                      1.00    154.0±1.06µs        ? ?/sec    1.00    153.5±0.73µs        ? ?/sec
ops/text/jwst/remove                      1.00      3.0±0.00µs        ? ?/sec    1.05      3.1±0.01µs        ? ?/sec
ops/text/yrs/insert                       1.00     43.8±0.16µs        ? ?/sec    1.01     44.2±0.05µs        ? ?/sec
ops/text/yrs/remove                       1.00      2.4±0.00µs        ? ?/sec    1.03      2.5±0.01µs        ? ?/sec
update/parse with jwst/basic.bin          1.00     67.5±0.06µs    80.9 MB/sec    1.00     67.5±0.06µs    80.9 MB/sec
update/parse with jwst/database.bin       1.00     54.2±0.08µs    61.1 MB/sec    1.00     54.3±0.08µs    61.0 MB/sec
update/parse with jwst/large.bin          1.01      3.6±0.00ms    63.8 MB/sec    1.00      3.6±0.02ms    64.2 MB/sec
update/parse with jwst/with-subdoc.bin    1.00      6.4±0.01µs   109.2 MB/sec    1.03      6.6±0.05µs   106.2 MB/sec
update/parse with yrs/basic.bin           1.01     44.8±0.28µs   121.8 MB/sec    1.00     44.2±0.06µs   123.5 MB/sec
update/parse with yrs/database.bin        1.01     36.1±0.04µs    91.7 MB/sec    1.00     35.6±0.05µs    93.0 MB/sec
update/parse with yrs/large.bin           1.02      2.3±0.02ms   101.3 MB/sec    1.00      2.2±0.01ms   103.0 MB/sec
update/parse with yrs/with-subdoc.bin     1.03      6.6±0.01µs   106.5 MB/sec    1.00      6.4±0.02µs   109.9 MB/sec

Windows

group                                     master                                 pr
-----                                     ------                                 --
codec/jwst decode var_int (32 bit)        1.06   427.6±13.39µs        ? ?/sec    1.00   402.4±18.92µs        ? ?/sec
codec/jwst decode var_uint (32 bit)       1.03   374.0±12.60µs        ? ?/sec    1.00   363.5±16.29µs        ? ?/sec
codec/jwst decode var_uint (64 bit)       1.03   377.8±12.40µs        ? ?/sec    1.00   367.8±14.25µs        ? ?/sec
codec/jwst encode var_int (32 bit)        1.03   512.3±23.61µs        ? ?/sec    1.00   499.8±15.49µs        ? ?/sec
codec/jwst encode var_uint (32 bit)       1.09    349.4±9.91µs        ? ?/sec    1.00   321.8±20.04µs        ? ?/sec
codec/jwst encode var_uint (64 bit)       1.00   334.5±12.09µs        ? ?/sec    1.00   334.6±19.15µs        ? ?/sec
codec/lib0 decode var_int (64 bit)        1.01    344.6±8.25µs        ? ?/sec    1.00   342.2±14.12µs        ? ?/sec
codec/lib0 decode var_uint (32 bit)       1.00    290.1±9.46µs        ? ?/sec    1.04    302.6±8.66µs        ? ?/sec
codec/lib0 decode var_uint (64 bit)       1.02    300.6±8.78µs        ? ?/sec    1.00   295.2±14.33µs        ? ?/sec
codec/lib0 encode var_int (64 bit)        1.01   487.5±23.39µs        ? ?/sec    1.00   480.7±18.17µs        ? ?/sec
codec/lib0 encode var_uint (32 bit)       1.00   347.2±15.36µs        ? ?/sec    1.01   349.1±11.71µs        ? ?/sec
codec/lib0 encode var_uint (64 bit)       1.00   343.9±13.36µs        ? ?/sec    1.01   346.4±16.64µs        ? ?/sec
ops/array/jwst/insert                     1.07   477.8±18.04µs        ? ?/sec    1.00   446.5±14.11µs        ? ?/sec
ops/array/jwst/insert range               1.09   637.0±14.87µs        ? ?/sec    1.00   582.3±16.09µs        ? ?/sec
ops/array/jwst/remove                     1.09   313.6±10.49µs        ? ?/sec    1.00    288.5±8.45µs        ? ?/sec
ops/array/yrs/insert                      1.08    129.5±2.95µs        ? ?/sec    1.00    120.4±4.15µs        ? ?/sec
ops/array/yrs/insert range                1.41    241.8±5.78µs        ? ?/sec    1.00    170.9±5.77µs        ? ?/sec
ops/array/yrs/remove                      1.02    188.0±4.08µs        ? ?/sec    1.00    184.3±5.99µs        ? ?/sec
ops/text/jwst/insert                      1.04    221.0±6.66µs        ? ?/sec    1.00    212.7±7.23µs        ? ?/sec
ops/text/jwst/remove                      1.26      5.5±0.26µs        ? ?/sec    1.00      4.4±0.14µs        ? ?/sec
ops/text/yrs/insert                       1.06     55.1±1.29µs        ? ?/sec    1.00     52.0±1.23µs        ? ?/sec
ops/text/yrs/remove                       1.09      4.6±0.12µs        ? ?/sec    1.00      4.3±0.15µs        ? ?/sec
update/parse with jwst/basic.bin          1.11    124.7±3.02µs    43.8 MB/sec    1.00    112.6±3.52µs    48.5 MB/sec
update/parse with jwst/database.bin       1.05     97.2±1.97µs    34.1 MB/sec    1.00     92.2±7.55µs    35.9 MB/sec
update/parse with jwst/large.bin          1.05      5.9±0.30ms    38.9 MB/sec    1.00      5.6±0.36ms    40.8 MB/sec
update/parse with jwst/with-subdoc.bin    1.14     18.9±0.63µs    37.0 MB/sec    1.00     16.7±0.53µs    42.0 MB/sec
update/parse with yrs/basic.bin           1.02     79.6±2.37µs    68.6 MB/sec    1.00     78.0±2.96µs    70.0 MB/sec
update/parse with yrs/database.bin        1.01     63.4±1.69µs    52.2 MB/sec    1.00     62.7±2.55µs    52.8 MB/sec
update/parse with yrs/large.bin           1.03      3.9±0.14ms    58.5 MB/sec    1.00      3.8±0.15ms    60.3 MB/sec
update/parse with yrs/with-subdoc.bin     1.00     12.4±0.37µs    56.6 MB/sec    1.17     14.4±0.45µs    48.6 MB/sec