Integrating by building a JReport Enterprise Server WAR

The self-contained JReport Enterprise Server can be deployed as a single WAR file. After specifying the reporthome and configuring the database information, you can build the WAR file using the tool makewar.bat/makewar.sh in <install_root>\bin. To generate the WAR file, execute the command with the buildWar parameter. For example:

makewar.bat/makewar.sh buildWar

Structure of the JReport Enterprise Server WAR

For example, here you can create a JReport Enterprise Server WAR file named jreport.war. The structure of the JReport Enterprise Server WAR is as below:

jreport.war

WEB-INF/

web.xml

lib/ -- This folder contains all resources in the JReport Enterprise Server library.

admin/ -- This folder contains JSP files for the JReport Administration page.

jinfonet/ -- This folder contains JSP files for the JReport Console page.

dhtmljsp/ --This folder contains JSP files for viewing DHTML reports.

WEB-INF/web.xml

The following is the default content in the web.xml file of the JReport Enterprise Server WAR:

<?xml version="1.0" encoding="ISO-8859-1"?> <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, 
Inc.//DTD Web Application 2.3//EN" 
"http://java.sun.com/dtd/web-app_2_3.dtd"> 

<web-app>
<listener> 
<listener-class>jet.server.servlets.JRServerContextListener</listener-class>
</listener>

<servlet>
<servlet-name>jrserver</servlet-name>
<servlet-class>jet.server.servlets.JRServlet</servlet-class>
</servlet>

<servlet>
<servlet-name>sendfile</servlet-name>
<servlet-class>jet.server.servlets.SendFileServlet</servlet-class>
</servlet>

<servlet>
<servlet-name>dhtml</servlet-name>
<servlet-class>jet.web.dhtml.DHTMLlet</servlet-class>
</servlet>

<servlet>
<servlet-name>help</servlet-name>
<servlet-class>jet.web.dhtml.JHelplet</servlet-class> 
</servlet>

<servlet-mapping>
<servlet-name>jrserver</servlet-name> 
<url-pattern>/jrserver/*</url-pattern> 
</servlet-mapping>

<servlet-mapping>
<servlet-name>sendfile</servlet-name>
<url-pattern>/sendfile/*</url-pattern>
</servlet-mapping>

<servlet-mapping>
<servlet-name>dhtml</servlet-name> 
<url-pattern>/dhtml/*</url-pattern>
</servlet-mapping>

<servlet-mapping>
<servlet-name>help</servlet-name>
<url-pattern>/help/*</url-pattern> 
</servlet-mapping>

</web-app>