Skip to content

[Improve] Align HugeCountStrategy with upstream TINKERPOP-2911 ConnectiveStep fixes #2995

@contrueCT

Description

@contrueCT

Feature Description (功能描述)

Background

PR #2993 introduced HugeCountStrategy to fix the negative-bound optimization issues behind #2930, #2931, and #2932.

That fix was implemented by forking an older version of TinkerPop's CountStrategy and adding HugeGraph-specific guards for negative bounds.

However, the current local fork does not yet include the upstream follow-up fix for ConnectiveStep / and() / or() handling from TINKERPOP-2911.

As a result, HugeGraph is now aligned for the negative-bound cases fixed in #2993, but it may still inherit older CountStrategy behavior for some connective-filter patterns.

Follow-up Scope

Port the upstream TINKERPOP-2911 changes for ConnectiveStep into HugeCountStrategy, and add regression coverage for connective traversal shapes.

Suggested regression cases include:

  • __.and(__.out().count().is(0), __.in().count().is(0))
  • __.or(__.out().count().is(0), __.in().count().is(0))
  • __.where(__.or(__.out("none").out().count().is(0), __.has("none")))
  • __.where(__.or(__.out("none").out().count().is(0), __.has("none").count().is(0)))

Expected Result

  • HugeCountStrategy should behave consistently with the upstream CountStrategy fixes around ConnectiveStep
  • connective and()/or() traversal shapes should no longer rely on older inherited behavior from the forked strategy
  • regression tests should cover the above traversal forms and protect against future drift

I’d be happy to follow up on this as a separate improvement issue and work on a later refinement PR.

Metadata

Metadata

Assignees

No one assigned

    Labels

    featureNew featuregremlinTinkerPop gremlintestsAdd or improve test cases

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions