Github user afs commented on a diff in the pull request:
https://github.com/apache/jena/pull/111#discussion_r47664861
--- Diff:
jena-arq/src/main/java/org/apache/jena/sparql/pfunction/PropertyFunctionBase.java
---
@@ -88,24 +88,25 @@ public QueryIterator exec(QueryIterator input,
PropFuncArg argSubject, Node pred
class RepeatApplyIteratorPF extends QueryIterRepeatApply
{
- private final PropFuncArg argSubject ;
- private final Node predicate ;
- private final PropFuncArg argObject ;
+ private ExecutionContext execCxt ;
+ private PropFuncArg argSubject ;
+ private Node predicate ;
+ private PropFuncArg argObject ;
- public RepeatApplyIteratorPF(QueryIterator input, PropFuncArg
argSubject, Node predicate, PropFuncArg argObject, ExecutionContext execCxt)
- {
- super(input, execCxt) ;
- this.argSubject = argSubject ;
- this.predicate = predicate ;
- this.argObject = argObject ;
- }
+ public RepeatApplyIteratorPF(QueryIterator input, PropFuncArg
argSubject, Node predicate, PropFuncArg argObject, ExecutionContext execCxt)
+ {
+ super(input, execCxt) ;
+ this.argSubject = argSubject ;
+ this.predicate = predicate ;
+ this.argObject = argObject ;
+ }
@Override
protected QueryIterator nextStage(Binding binding)
{
- QueryIterator iter = exec(binding, argSubject, predicate,
argObject, getExecContext()) ;
+ QueryIterator iter = exec(binding, argSubject, predicate,
argObject, super.getExecContext()) ;
if ( iter == null )
- iter = IterLib.noResults(getExecContext()) ;
+ iter = IterLib.noResults(execCxt) ;
return iter ;
--- End diff --
This change is potentially significant. The execution context can change
during execution where a new context derived from the current one is produced
so please keep L108/L109.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---