Commit d8b00b8
Improve performance of RedisInterface#make_list_length (#509)
This implementation will only execute 1 to Redis command, instead of
2n (n being the total number of elements to trim from the list).
The operation will still take O(n) time, but the constants will be
much better, since only 1 network round trip is required.1 parent 77f87b1 commit d8b00b8
1 file changed
Lines changed: 1 addition & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
38 | | - | |
39 | | - | |
40 | | - | |
| 38 | + | |
41 | 39 | | |
42 | 40 | | |
43 | 41 | | |
| |||
0 commit comments