<p>I'm working on a project which is using BIRT-3.7.1(pending upgrade to <a data-ipb='nomediaparse' href='
http://developer.actuate.com/community/forum/index.php?/topic/37040-when-will-the-450-runtime-be-available-in-a-maven-repository/#entry139454'>4.5 as soon as it is available in Maven</a>).</p>
<p> </p>
<p>The project is using ReportEngine API to generate reports, which is working fine in Tomcat 6. But now we are moving towards Tomcat 8, where we are facing issues related to loading external library files.</p>
<p> </p>
<p>The library files are placed relative to the design file and relative paths are given in the design file like</p>
<div>
<pre class="_prettyXprint">
<list-property name="libraries">
<structure>
<property name="fileName">../../../report/main.rptlibrary</property>
<property name="namespace">main</property>
</structure>
</list-property></pre>
</div>
<p>Since the application is loaded by the tomcat `WebappClassLoader`, the `this.getClass( ).getClassLoader( ).getResource( fileName );` call to load the resource using the class loader fails with an exception, which is causing the report generation to fail. In tomcat 8 attempts to go back more than 2 directories up(more than 2 `..`) fails with an error. Since the exception is not handled attempts to load the report using `systemId`(attempting path relative to the report design file) is not invoked.</p>
<p> </p>
<p>Even in the 4.5 release, I'm seeing any code to handle this case, how can I handle this error.</p>