processMessage() retrieves no information about errors when images, that are included within the xsl, are missing. This error is serious, because it is not possible to implement an own logger (extending log4j logger) that overwrites the error()-method. We need the information when pictures are missing.
An idea to solve the problem: Put some additional actions into the contructors of class FopImageException, like this: public class FopImageException extends Exception { public FopImageException() { super(); // JUN 2003-08-08 -- appended lines MessageHandler.error("No message text available." + this.getMessage()); // JUN 2003-08-08 } public FopImageException(String message) { super(message); // JUN 2003-08-08 -- appended lines MessageHandler.error(message); // JUN 2003-08-08 } }
A 2nd solution is to stop the processing. This may be more useful in many cases. I changed org.apache.fop.fo.flow.ExternalGraphic.layout(): ... catch (MalformedURLException urlex) { // bad URL log.error("Error while creating area : " + urlex.getMessage()); throw new FOPException ("Error while creating area : " + urlex.getMessage()); } catch (FopImageException imgex) { // image error log.error("Error while creating area : " + imgex.getMessage()); throw new FOPException ("Error while creating area : " + imgex.getMessage()); } ...
Fixed in FOP 0.94 and probably earlier versions
batch transition pre-FOP1.0 resolved+fixed bugs to closed+fixed