Skip to content

vol2: ScopeEvaluator.invokeFilter resolves Method via reflection on every scope check call #6722

@mdproctor

Description

@mdproctor

Found during code review of #6718

ScopeEvaluator.invokeFilter() runs Arrays.stream(pred.getClass().getMethods()).filter(...) on every invocation. This is called per scope check (not()/exists() evaluation) on the hot path.

ReteEngine already resolves the Method once at wiring time (resolveTestMethod). ScopeEvaluator should do the same — cache the resolved Method on the LambdaConstraint at store time, or pass a pre-resolved Method alongside the predicate.

Refs #6718, #6714 (TupleFilterProcessor)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    Status
    📋 Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions