Commit 6533304
authored
feat(meta): Add conflict-free sequence generator v1 (#18273)
Introduce a new conflict-free sequence generator (storage version 1)
alongside the existing version 0 generator. The v1 generator eliminates
conflicts during concurrent sequence number generation by using a new
`FetchAddU64` operation instead of check-and-set semantics.
Key changes:
- V1 generator stores sequence values in external standalone keys
- Uses atomic FetchAddU64 operation for conflict-free updates
- V0 generator remains unchanged for backward compatibility
The FetchAddU64 operation performs in-place atomic updates without
requiring metadata assertions, eliminating conflicts between concurrent
sequence requests and improving throughput for sequence generation
workloads.
Both storage versions coexist, allowing gradual migration from the
conflict-prone v0 implementation to the high-concurrency v1 design.
**Non-Breaking**:
This Commit just add this function but does not used anywhere.1 parent e486e3f commit 6533304
File tree
20 files changed
+576
-104
lines changed- src
- meta
- api/src
- app/src
- schema
- proto-conv
- src
- tests/it
- protos/proto
- types/src
- proto_display
- proto_ext
- query/service/src/interpreters
20 files changed
+576
-104
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
| 40 | + | |
40 | 41 | | |
41 | 42 | | |
42 | 43 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
| 52 | + | |
52 | 53 | | |
53 | 54 | | |
54 | 55 | | |
| |||
346 | 347 | | |
347 | 348 | | |
348 | 349 | | |
349 | | - | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
350 | 353 | | |
351 | 354 | | |
352 | 355 | | |
| |||
5764 | 5767 | | |
5765 | 5768 | | |
5766 | 5769 | | |
5767 | | - | |
| 5770 | + | |
| 5771 | + | |
| 5772 | + | |
| 5773 | + | |
| 5774 | + | |
| 5775 | + | |
| 5776 | + | |
| 5777 | + | |
| 5778 | + | |
5768 | 5779 | | |
5769 | 5780 | | |
| 5781 | + | |
| 5782 | + | |
| 5783 | + | |
| 5784 | + | |
| 5785 | + | |
| 5786 | + | |
| 5787 | + | |
| 5788 | + | |
| 5789 | + | |
| 5790 | + | |
| 5791 | + | |
5770 | 5792 | | |
5771 | 5793 | | |
5772 | 5794 | | |
| |||
5782 | 5804 | | |
5783 | 5805 | | |
5784 | 5806 | | |
| 5807 | + | |
5785 | 5808 | | |
5786 | 5809 | | |
5787 | 5810 | | |
| |||
5803 | 5826 | | |
5804 | 5827 | | |
5805 | 5828 | | |
| 5829 | + | |
5806 | 5830 | | |
5807 | 5831 | | |
5808 | | - | |
5809 | 5832 | | |
5810 | 5833 | | |
5811 | | - | |
5812 | | - | |
5813 | | - | |
| 5834 | + | |
| 5835 | + | |
| 5836 | + | |
| 5837 | + | |
| 5838 | + | |
5814 | 5839 | | |
5815 | 5840 | | |
5816 | 5841 | | |
| |||
5821 | 5846 | | |
5822 | 5847 | | |
5823 | 5848 | | |
5824 | | - | |
| 5849 | + | |
5825 | 5850 | | |
5826 | 5851 | | |
5827 | 5852 | | |
| |||
5833 | 5858 | | |
5834 | 5859 | | |
5835 | 5860 | | |
| 5861 | + | |
| 5862 | + | |
| 5863 | + | |
| 5864 | + | |
| 5865 | + | |
| 5866 | + | |
| 5867 | + | |
| 5868 | + | |
| 5869 | + | |
| 5870 | + | |
5836 | 5871 | | |
5837 | 5872 | | |
5838 | 5873 | | |
5839 | 5874 | | |
5840 | 5875 | | |
5841 | 5876 | | |
5842 | 5877 | | |
| 5878 | + | |
5843 | 5879 | | |
5844 | 5880 | | |
5845 | 5881 | | |
| |||
5852 | 5888 | | |
5853 | 5889 | | |
5854 | 5890 | | |
| 5891 | + | |
5855 | 5892 | | |
5856 | 5893 | | |
5857 | 5894 | | |
| |||
5863 | 5900 | | |
5864 | 5901 | | |
5865 | 5902 | | |
| 5903 | + | |
| 5904 | + | |
| 5905 | + | |
| 5906 | + | |
| 5907 | + | |
| 5908 | + | |
| 5909 | + | |
| 5910 | + | |
| 5911 | + | |
| 5912 | + | |
| 5913 | + | |
| 5914 | + | |
| 5915 | + | |
| 5916 | + | |
| 5917 | + | |
| 5918 | + | |
| 5919 | + | |
| 5920 | + | |
5866 | 5921 | | |
5867 | 5922 | | |
5868 | 5923 | | |
| |||
0 commit comments