• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

tarantool / crud
89%
master: 89%

Build:
Build:
LAST BUILD BRANCH: TNTP-2109-bucket-ref
DEFAULT BRANCH: master
Repo Added 12 Aug 2021 03:45PM UTC
Files 63
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

LAST BUILD ON BRANCH DifferentialOrange/gh-418-conditions-order
branch: DifferentialOrange/gh-418-conditions-order
CHANGE BRANCH
x
Reset
  • DifferentialOrange/gh-418-conditions-order
  • 0x501D/ci-tt
  • AnaNek/check-for-incorrect-call-mode
  • AnaNek/gh-314-fix-vshard-sharding-func
  • AnaNek/parameterization-for-call-test
  • AnaNek/select-no-indexes-fix
  • DIfferentialOrange/release-1.3.0
  • DifferentialOranage/gh-373-datetime-conditions
  • DifferentialOrange/HTTP-API-improvements
  • DifferentialOrange/ci-health
  • DifferentialOrange/ci-health-tt
  • DifferentialOrange/clarify-license
  • DifferentialOrange/crud-metrics-params
  • DifferentialOrange/fix-0.10.0-changelog
  • DifferentialOrange/fix-dev-checks
  • DifferentialOrange/fix-flaky-schema
  • DifferentialOrange/fix-flaky-vshard-test
  • DifferentialOrange/fix-readme-update-links
  • DifferentialOrange/fix-tests-2.10.1
  • DifferentialOrange/gh-211-cluacov-fix
  • DifferentialOrange/gh-212-reload-sharding-keys
  • DifferentialOrange/gh-212-reload-sharding-keys-final
  • DifferentialOrange/gh-213-optimize-map-reduce
  • DifferentialOrange/gh-224-operation-stats
  • DifferentialOrange/gh-225-vshard-performance
  • DifferentialOrange/gh-234-optimize-know-bucket_id
  • DifferentialOrange/gh-236-tmp-test-master
  • DifferentialOrange/gh-236-tmp-test-new
  • DifferentialOrange/gh-241-field-number-doc
  • DifferentialOrange/gh-249-fix-luacov
  • DifferentialOrange/gh-253-design-doc-reload
  • DifferentialOrange/gh-255-forbid-len-by-id
  • DifferentialOrange/gh-271-select-nil-err-merger
  • DifferentialOrange/gh-278-sharding-mismatch
  • DifferentialOrange/gh-284-tolerated-error-lost
  • DifferentialOrange/gh-286-age-nan
  • DifferentialOrange/gh-308-fail-after-drop
  • DifferentialOrange/gh-310-ddl-record-delete
  • DifferentialOrange/gh-312-yield
  • DifferentialOrange/gh-326-improve-warning-message
  • DifferentialOrange/gh-328-flatten-for-sequence
  • DifferentialOrange/gh-332-role-cfg
  • DifferentialOrange/gh-365-drop-old-select
  • DifferentialOrange/gh-377-no-rows-error
  • DifferentialOrange/gh-403-names-as-keys
  • DifferentialOrange/gh-404-follow-up
  • DifferentialOrange/gh-407-no-uuid
  • DifferentialOrange/gh-409-master-discovery
  • DifferentialOrange/gh-412-3.0-grants
  • DifferentialOrange/gh-412-test-stabilization
  • DifferentialOrange/gh-415-role-for-tarantool3
  • DifferentialOrange/gh-422-nil-conditions
  • DifferentialOrange/gh-437-fix-sharding-many
  • DifferentialOrange/gh-44-vshard-groups
  • DifferentialOrange/iproto-tuple-formats-fixes
  • DifferentialOrange/no-gh-fix-coveralls
  • DifferentialOrange/no-gh-new-vshard-for-reusable
  • DifferentialOrange/no-gh-remove-metrics-for-master
  • DifferentialOrange/no-gh-retry-tests
  • DifferentialOrange/no-gh-schema
  • DifferentialOrange/no-gh-update-readme
  • DifferentialOrange/readme-sharding-duplicate-rows
  • DifferentialOrange/readme-version
  • DifferentialOrange/release-0.11.0
  • DifferentialOrange/release-0.11.1
  • DifferentialOrange/release-0.11.2
  • DifferentialOrange/release-0.11.3
  • DifferentialOrange/release-0.12.1
  • DifferentialOrange/release-0.13.0
  • DifferentialOrange/release-0.14.0
  • DifferentialOrange/release-1.0.0
  • DifferentialOrange/release-1.1.0
  • DifferentialOrange/release-1.1.1
  • DifferentialOrange/release-1.2.0
  • DifferentialOrange/release-1.4.0
  • DifferentialOrange/release-1.4.1
  • DifferentialOrange/release-1.4.2
  • DifferentialOrange/release-1.4.3
  • DifferentialOrange/release-1.5.0
  • DifferentialOrange/release-1.5.1
  • DifferentialOrange/release-1.5.2
  • DifferentialOrange/run-ci
  • DifferentialOrange/support-older-cartridges
  • DifferentialOrange/tarantool-version-parsing-3.x
  • TNTP-2109-bucket-ref
  • Totktonada/add-a-license
  • Totktonada/add-playground
  • Totktonada/ci-add-tarantool-2.10
  • Totktonada/doc-enhancements
  • Totktonada/fix-tarantool-2-10-determination
  • Totktonada/gh-203-add-tarantoolctl-install-into-readme
  • Totktonada/gh-220-bucket-id-is-ignored
  • Totktonada/polish-version-checks
  • Totktonada/readme-fix-update-cache-recipe
  • Totktonada/release-0.10.0
  • Totktonada/release-0.12.0
  • Totktonada/release-0.9.0
  • Totktonada/skip-merger-creation-for-one-replicaset
  • Totktonada/test-fix-timeout-error-message
  • Totktonada/update-cartridge-dependency
  • Totktonada/use-setup-tarantool-for-1.10.6
  • Totktonada/workaround-luacov-coveralls-installation-fail
  • batch-insert-upsert
  • better0fdead/gc-fix-readview
  • better0fdead/readview
  • bump_cmake
  • count-implementation
  • doc-add-full-space-format
  • drop-heap
  • ee-sync/2025-09-08
  • ee-sync/vshard-request-timeout
  • fix-cluacov-rockspec-uri
  • fix-opts-damage
  • fix-timeout-select-pairs
  • fix-typo-readme
  • igrishnov/gh-204-add-hardcoded-versioning-support
  • igrishnov/gh-236-update-stale-schema-metadata-gen
  • igrishnov/gh-236-update-stale-schema-metadata-gen-new-approach
  • igrishnov/gh-250-change-dev-env-var-naming
  • igrishnov/gh-267-noreturn-opt-for-DML-operations
  • igrishnov/gh-331-master-conn-check-for-get-space-utils
  • igrishnov/gh-95-master-timeout-fetch-for-get-space-utils
  • igrishnov/gh-x-test-master-ci
  • ligurio/bump-luatest
  • ligurio/fix-coveralls-paths
  • ligurio/gh-166-sharding-keys
  • ligurio/gh-219-jsonpath-sharding-key
  • ligurio/ldoc-support
  • ligurio/not_covered
  • ligurio/remove-extra-whitespaces
  • ligurio/revert-remove-tuple-keydef
  • ligurio/typo
  • ligurio/update-test-matrix
  • ligurio/update_test_matrix
  • ligurio/use_luatest_native_asserts
  • master
  • merge-ee-into-ce
  • oleg-jukovec/fix-after-behavior
  • oleg-jukovec/gh-276-log-select-nil
  • oleg-jukovec/gh-364-vshard-tests
  • oleg-jukovec/gh-366-vshard-user-experience
  • oleg-jukovec/no-gh-readme_many_fix
  • perf-test
  • psergee/fix-crud-delete-error-message
  • psergee/gh-229-crud-storage-init-status
  • psergee/gh-consistent-select-error-description
  • refs/heads/igrishnov/gh-236-update-stale-schema-metadata-gen
  • refs/pull/330/merge
  • refs/pull/335/merge
  • refs/pull/374/merge
  • refs/pull/387/merge
  • refs/pull/390/merge
  • refs/pull/393/merge
  • refs/pull/400/merge
  • refs/pull/410/merge
  • refs/pull/444/merge
  • refs/tags/0.10.0
  • refs/tags/0.11.0
  • refs/tags/0.11.1
  • refs/tags/0.11.2
  • refs/tags/0.11.3
  • refs/tags/0.12.0
  • refs/tags/0.12.1
  • refs/tags/0.13.0
  • refs/tags/0.14.0
  • refs/tags/0.14.1
  • refs/tags/0.9.0
  • refs/tags/1.0.0
  • refs/tags/1.1.0
  • refs/tags/1.1.1
  • refs/tags/1.2.0
  • refs/tags/1.3.0
  • refs/tags/1.4.0
  • refs/tags/1.4.1
  • refs/tags/1.4.2
  • refs/tags/1.4.3
  • refs/tags/1.5.0
  • refs/tags/1.5.1
  • refs/tags/1.5.2
  • refs/tags/1.6.0
  • refs/tags/1.6.1
  • release-1.6.1
  • sharding-pk-bucket-id-null
  • support-custom-sharding-func
  • update-errors
  • vakhov/TNTP-4009-bucket-id-validation
  • vakhov/release-1.6.0
  • vakhov/rm-skip-vshard-config
  • ylobankov/bump-actions-version

05 Feb 2024 11:43AM UTC coverage: 88.608% (+0.002%) from 88.606%
7783904305

Pull #419

github

DifferentialOrange
scan: fix filter erroneous early exit

The issue described below is related to the read operations which
allows to scan: `crud.select`, `crud.pairs`, `crud.count`,
`readview:select` and `readview:pairs`.

The erroneous behavior reported by [1] and #418 is as follows:
- result changes when reordering operation conditions;
- when `>=` condition operation is changed to `=`, there are more rows
  in the result.

The reason is as follows. Scanning read operates with two entities:
an iterator and a filter. The iterator includes an index, a starting
value and iterator type (EQ, GT, etc.). The iterator is built from
conditions, if possible, otherwise primary index is used. Remaining
conditions form the filter, so the actual result satisfies all operation
conditions.

The filter supports early exit. Let's consider the following example.
For `crud.select(space, {{'>=', 'id', 1}, {'<=', 'id', 10}})`, where
`id` is an index (or an indexed field), the iterator uses index
`id`, starts from key = `1` and goes by GE rules, covering [1, +inf)
ordered keys. On the other hand, when iterator reaches the tuple
with `id` = `11`, all tuples after this one will never satisfy
the second condition, because our iterator yields tuples sorted by `id`
(due to underlying index). So filter tells than there is no reason
to scan anymore, and we finish the scanning procedure.

Before this patch, the function behind early exit decision had worked
as follows: "if the condition is an index, we go in forward (reverse)
order and `<=` or `<` (`>=` or `>`) condition is violated, there is no
reason to scan anymore". But the valid approach is "if the condition is
SCANNING index...". Before this patch, filter had assumed that if the
condition for index is specified, tuples are ordered, but it works only
if iterator uses the same index as in the condition. This patch fixes
the issue.

The erroneous behavior may happen in the following case:
- there are multiple conditions,
- there are at least tw... (continued)
Pull Request #419: scan: fix filter erroneous early exit

11 of 12 new or added lines in 4 files covered. (91.67%)

1 existing line in 1 file now uncovered.

4729 of 5337 relevant lines covered (88.61%)

6308.12 hits per line

Relevant lines Covered
Build:
Build:
5337 RELEVANT LINES 4729 COVERED LINES
6308.12 HITS PER LINE
Source Files on DifferentialOrange/gh-418-conditions-order
  • Tree
  • List 61
  • Changed 33
  • Source Changed 0
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line

Recent builds

Builds Branch Commit Type Ran Committer Via Coverage
7783904305 DifferentialOrange/gh-418-conditions-order scan: fix filter erroneous early exit The issue described below is related to the read operations which allows to scan: `crud.select`, `crud.pairs`, `crud.count`, `readview:select` and `readview:pairs`. The erroneous behavior reported by [1] and... Pull #419 05 Feb 2024 11:57AM UTC DifferentialOrange github
88.61
7781050686 DifferentialOrange/gh-418-conditions-order scan: fix filter erroneous early exit The issue described below is related to the read operations which allows to scan: `crud.select`, `crud.pairs`, `crud.count`, `readview:select` and `readview:pairs`. The erroneous behavior reported by [1] and... Pull #419 05 Feb 2024 07:49AM UTC DifferentialOrange github
88.61
7758011815 DifferentialOrange/gh-418-conditions-order scan: fix filter erroneous early exit The issue described below is related to the read operations which allows to scan: `crud.select`, `crud.pairs`, `crud.count`, `readview:select` and `readview:pairs`. The erroneous behavior reported by [1] and... Pull #419 02 Feb 2024 03:37PM UTC DifferentialOrange github
88.61
See All Builds (1209)
  • Repo on GitHub
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc