Project

Profile

Help

SaxonEE 9.5.1.8: TraceListener methods are not being called 9.5.1.8 EE

Added by Dave MacDonald almost 7 years ago

Our application is setting a custom trace listener on the dynamic context for XQuery evaluations. The custom listener inherits from net.sf.saxon.trace.XQueryTraceListener but overrides most of its methods.

I can see in the debugger that our application creates the custom listener instance and sets it as the trace listener on the dynamic context associated with the XQuery expression that is to be evaluated.

However, none of the methods of the instance is invoked, although the associated XQuery expression is definitely evaluated.

I'm new to this area of our codebase, but the code itself is from 6 years ago, with only minor changes since then. I can't see why the it isn't being invoked...

Any pointers greatly appreciated.


Replies (2)

RE: SaxonEE 9.5.1.8: TraceListener methods are not being called 9.5.1.8 EE - Added by Michael Kay almost 7 years ago

You need to enable tracing both at compile time and at run time.

XQueryCompiler.setCompileWithTracing();

XQueryEvaluator.setTraceListener();

    (1-2/2)

    Please register to reply