GitHub user dkuppitz opened a pull request:

    https://github.com/apache/tinkerpop/pull/950

    TINKERPOP-2058 Contains predicates should rely on Compare predicates

    https://issues.apache.org/jira/browse/TINKERPOP-2058
    
    If the object to be filtered is a number, `Contains` predicates will now 
scan the provided collection, comparing each element using `Compare.eq`. For 
non-numeric values `Contains.within` will still use `collection.contains()` in 
order to make use of search-optimized data types (e.g. `Set`).
    
    This is a breaking change as the test suite previously ensured that number 
types had an effect on `Contains` predicates. This, however, was inconsistent 
with `Compare` predicates which ignore the number type.
    
    `docker/build.sh -t -i -n` passed.
    
    VOTE +1

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/apache/tinkerpop TINKERPOP-2058

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/tinkerpop/pull/950.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #950
    
----
commit ec0d8805fe18e6d1985af5544106f78169f3f5b4
Author: Daniel Kuppitz <daniel_kuppitz@...>
Date:   2018-10-04T14:15:09Z

    TINKERPOP-2058 Use `Compare.eq` in `Contains.within` to ensure equal filter 
behaviors.
    
    If the object to be filtered is a number, `Contains` predicates will now 
scan the provided collection, comparing
    each element using `Compare.eq`. For non-numeric values `Contains.within` 
will still use `collection.contains()`
    in order to make use of search-optimized data types (e.g. `Set`).

----


---

Reply via email to