Project

Profile

Help

Support #3978

closed

Blocked thread while running saxon transformation

Added by Ansh Sahajpal over 5 years ago. Updated about 4 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
s9api API
Sprint/Milestone:
-
Start date:
2018-10-18
Due date:
% Done:

0%

Estimated time:
Legacy ID:
Applies to branch:
Fix Committed on Branch:
Fixed in Maintenance Release:
Platforms:

Description

We are seeing the following teace in our thread dumps while running saxon xsl transformation.


priority:5 - threadId:0x000000002f7ef800 - nativeId:0x141c - state:BLOCKED
stackTrace:
java.lang.Thread.State: BLOCKED (on object monitor)
at java.io.PrintStream.flush(PrintStream.java:335)
- waiting to lock <0x0000000555fd2c20> (a java.io.PrintStream)
at net.sf.saxon.serialize.UTF8Writer.flush(UTF8Writer.java:105)
at net.sf.saxon.serialize.XMLEmitter.close(XMLEmitter.java:303)
at net.sf.saxon.serialize.MessageEmitter.close(MessageEmitter.java:39)
at net.sf.saxon.Controller.closeMessageEmitter(Controller.java:2698)
at net.sf.saxon.Controller.transformDocument(Controller.java:2345)
at net.sf.saxon.Controller.transform(Controller.java:1892)
at net.sf.saxon.s9api.XsltTransformer.transform(XsltTransformer.java:579)
at net.sf.saxon.jaxp.TransformerImpl.transform(TransformerImpl.java:185)
at com.adeptia.indigo.services.mapping.MappingTransformation$5.run(MappingTransformation.java:1453)
at java.lang.Thread.run(Thread.java:745)

We are running a transformation and takong the output of transformation in a StreamResult object instantiated with a StringWriter

StringWriter sw=new  StringWriter();
StreamResult _result=new StreamResult(sw);
_transformer.transform(new StreamSource(getSourceDataStream()), _result);
String output=sw.toString();
sw.flush();
sw.close();

Our concerns regarding the issue is are:-

  1. What is actually being emitted and flushed out to the standard input stream (is it the output of transformation?)

  2. If its not the output of transformation then, is it possible to avoid the emission of these messages to standard output stream?

We are on saxon versio 9.8 EE.

Please register to edit this issue

Also available in: Atom PDF