Skip to content
This repository was archived by the owner on Aug 13, 2026. It is now read-only.
This repository was archived by the owner on Aug 13, 2026. It is now read-only.

2i Queries with Coverage Context Aren't Built Correctly [JIRA: CLIENTS-961] #658

Description

@alexmoore

I started with a test failure:

ITestCoveragePlan: fetchAllDataByUsingCoverageContext -> get null pointer exception on this line

And realized the 2i Coverage Context queries weren't including either a match or a range, so need to expand the api to cover that.

Reference:

Context with match

Context with Range

Activity

  1. changed the title [-]2i Queries with Coverage Context Aren't Built Correctly[/-] [+]2i Queries with Coverage Context Aren't Built Correctly [JIRA: CLIENTS-961][/+] on Aug 11, 2016
  2. alexmoore commented on Aug 17, 2016

    @alexmoore
    ContributorAuthor

    Don't need this just yet, but will in the future.

  3. srgg commented on Aug 18, 2016

    @srgg
    Contributor

    @alexmoore The idea was to do not overcomplicate Query Builders by introducing a specific constructor for for each possible case, therefore by using as an example BinQuery:

    here is constructors available for Builder in BinIndexQuery:

    creation with Range:
    https://github.com/basho/riak-java-client/blob/develop/src/main/java/com/basho/riak/client/api/commands/indexes/BinIndexQuery.java#L188

    creation with exact match:
    https://github.com/basho/riak-java-client/blob/develop/src/main/java/com/basho/riak/client/api/commands/indexes/BinIndexQuery.java#L204

    creation with coverage context:
    https://github.com/basho/riak-java-client/blob/develop/src/main/java/com/basho/riak/client/api/commands/indexes/BinIndexQuery.java#L171

    Usage of CoverageContext in conjunction with range or match requires to constructor a builder by using specific constructor for
    range or exact match and then to provide coverage context by using this method:
    https://github.com/basho/riak-java-client/blob/develop/src/main/java/com/basho/riak/client/api/commands/indexes/SecondaryIndexQuery.java#L523

    please let me know if I missed something or you have objections/concerns

  4. alexmoore commented on Aug 18, 2016

    @alexmoore
    ContributorAuthor

    Nope, looks good. I think I was a little confused at first how to build the match/range + coverage queries, but that straightens it out. Just need to document it then once we start pushing coverage more.

  5. Basho-JIRA commented on Sep 13, 2016

    @Basho-JIRA

    This was fixed for the 2.0.7 release.

    _[posted via JIRA by Alexander Moore]_

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions