standalone
Installation & Configuration
To simplify matters, it’s advised to parameter same network assembly on both servers. For example, a reader named U: on the moovapps process server and on the server used to execute birt pointing on the same folder of the same spot.
On the moovapps-process server
-
Install the add-on
-
Copy the file from this zip
packaging\VDoc_BirtHelper.xml
-
Paste the file in
[VDOC_HOME]\custom\packaging\VDoc_BirtHelper.xml
-
Modify the file to configure the birt generation server:
<param name="host" value="VSOFT0073" /> <param name="port" value="5000" />
-
Do an applyconflig applyconfig
On the birt generation server
Installation
You’ll need to get back several resources:
- The zip packaging of the birt generation server
- The zip runtime 4.5.0
First, we’ll create a folder [BIRT_HOME]
in which we unzip the Birt generation server.
You should have a structure like this:
[BIRT_HOME]
│ conf.properties
│ log4j.properties
│ start.bat
│
├───lib
│ hamcrest-core-1.3.jar
│ junit-4.12.jar
│ log4j-1.2.14.jar
│ vdoc-birt-helper-<version>.jar
│
└───ReportEngine
Next add the ReportEngine of BIRT who’s in birt-runtime-<version>.zip\birt-runtime-<version>\ReportEngine
instead of the folder [BIRT_HOME]\ReportEngine
.
You will then have such a folder structure:
[BIRT_HOME]
│ conf.properties
│ log4j.properties
│ start.bat
│
├───lib
│ hamcrest-core-1.3.jar
│ junit-4.12.jar
│ log4j-1.2.14.jar
│ vdoc-birt-helper-<version>.jar
│
└───ReportEngine
│ genReport.bat
│ genReport.sh
│
├───lib
│ com.ibm.icu_54.1.1.v201501272100.jar
│ com.lowagie.text_2.1.7.v201004222200.jar
│ ...
│
└───samples
hello_world.rptdesign
If the generation server hadn’t JAVA_HOME you can add the folder JDKPart64 from moovapps-process in the folder [BIRT_HOME]
Configuration
The file conf.properties
allows to configure the birt server.
birt.server.port=5000
birt.server.executor.max=2
birt.server.thread.timeout=5000
- birt.server.port => listening port of the server
- birt.server.executor.max => number max of conversion at the same time
- birt.server.thread.timeout => max duration of a conversion
The file log4j.properties
permette de configurer le log du server.
cf : la documentation log4j 1.2
Le fichier start.bat
allows to configure the server’s log.
Use example
var designFile = new java.io.File("\\\\machine_birt_server\\birt\\rptdesign\\hello_world.rptdesign");
var outputFile= new java.io.File("\\\\machine_birt_server\\birt\\result\\hello_world.pdf");
Packages.com.vdoc.sdk.commons.backend.birt.BIRTHelper.createReport(designFile, outputFile);
The files rptdesign mustn’t be at the root of a reader or a storage volume. In the example above, they are placed in a sub-repertory “rptdesing” of the network reader.
The new File of the rptdesign is made from the moovapps-process server’s filesystem. The new File outpout is made from the birt generation server’s filesystem.
Installation as service
For more details about the JavaServiceWrapper’s usage, see: https://wrapper.tanukisoftware.com/doc/english/introduction.html
Preparations
- Get a wrapper-windows-x86 back from https://wrapper.tanukisoftware.com/doc/english/download.jsp#stable and extract it in a WRAPPER_HOME repertory
- Get a jvm x86 back, its installation’s repertory will be noticed as JVM_x86
- Do the standalone installation in a BIRT_HOME repertory
Create a repertory BIRT_SERVICE_HOME
- In birt_service, create a bin repertory
- In birt_service, create a conf repertory
- In birt_service, create a lib repertory
- In birt_service, create a logs repertory Your repertory [BIRT_SERVICE_HOME] must look like this:
[BIRT_SERVICE_HOME]
├───bin
├───conf
├───lib
└───logs
Copy elements from [WRAPPER_HOME] to [BIRT_SERVICE_HOME]\bin
- Copy [WRAPPER_HOME]\bin\wrapper.exe to [BIRT_SERVICE_HOME]\bin
- Copy [WRAPPER_HOME]\bin\App.bat.in to [BIRT_SERVICE_HOME]\bin an rename it birt.bat
- Copy [WRAPPER_HOME]\bin\InstallApp-NT.bat.in to [BIRT_SERVICE_HOME]\bin an rename it Install-birt.bat
- Copy [WRAPPER_HOME]\bin\UninstallApp-NT.bat.in to [BIRT_SERVICE_HOME]\bin an rename it Uninstall-birt.bat Your repertory [BIRT_SERVICE_HOME] must look like this:
[BIRT_SERVICE_HOME]
├───bin
│ birt.bat
│ Install-birt.bat
│ Uninstall-birt.bat
│ wrapper.exe
│
├───conf
├───lib
└───logs
Copy elements from [BIRT_HOME] to [BIRT_SERVICE_HOME]\bin
- Copy [BIRT_HOME]\conf.properties to [BIRT_SERVICE_HOME]\bin
- Copy [BIRT_HOME]\log4j.properties to [BIRT_SERVICE_HOME]\bin Your repertory [BIRT_SERVICE_HOME] must look like this:
[BIRT_SERVICE_HOME]
├───bin
│ birt.bat
│ conf.properties
│ Install-birt.bat
│ log4j.properties
│ Uninstall-birt.bat
│ wrapper.exe
├───conf
├───lib
└───logs
Copy elements from [WRAPPER_HOME] to [BIRT_SERVICE_HOME]\lib
- Copy [WRAPPER_HOME]\lib\wrapper.dll to [BIRT_SERVICE_HOME]\bin
- Copy [WRAPPER_HOME]\lib\wrapper.jar to [BIRT_SERVICE_HOME]\bin Your repertory [BIRT_SERVICE_HOME] must look like this:
[BIRT_SERVICE_HOME]
├───bin
│ birt.bat
│ conf.properties
│ Install-birt.bat
│ log4j.properties
│ Uninstall-birt.bat
│ wrapper.exe
├───conf
├───lib
│ wrapper.dll
│ wrapper.jar
└───logs
Copy elements from [BIRT_HOME] to [BIRT_SERVICE_HOME]\lib
- Copy [BIRT_HOME]\lib\hamcrest-core-1.3.jar to [BIRT_SERVICE_HOME]\lib
- Copy [BIRT_HOME]\lib\junit-4.12.jar to [BIRT_SERVICE_HOME]\lib
- Copy [BIRT_HOME]\lib\log4j-1.2.14.jar to [BIRT_SERVICE_HOME]\lib
- Copy [BIRT_HOME]\lib\vdoc-birt-helper-2.0.1.jar to [BIRT_SERVICE_HOME]\lib Your repertory [BIRT_SERVICE_HOME] must look like this:
[BIRT_SERVICE_HOME]
├───bin
│ birt.bat
│ conf.properties
│ Install-birt.bat
│ log4j.properties
│ Uninstall-birt.bat
│ wrapper.exe
├───conf
├───lib
│ hamcrest-core-1.3.jar
│ junit-4.12.jar
│ log4j-1.2.14.jar
│ vdoc-birt-helper-2.0.1.jar
│ wrapper.dll
│ wrapper.jar
└───logs
Copy from ReportEngine of [BIRT_HOME] to [BIRT_SERVICE_HOME]
- Copy [BIRT_HOME]\ReportEngine to [BIRT_SERVICE_HOME] Your repertory [BIRT_SERVICE_HOME] must look like this:
[BIRT_SERVICE_HOME]
├───bin
│ birt.bat
│ conf.properties
│ Install-birt.bat
│ log4j.properties
│ Uninstall-birt.bat
│ wrapper.exe
├───conf
├───lib
│ hamcrest-core-1.3.jar
│ junit-4.12.jar
│ log4j-1.2.14.jar
│ vdoc-birt-helper-2.0.1.jar
│ wrapper.dll
│ wrapper.jar
├───logs
└───ReportEngine
│ genReport.bat
│ genReport.sh
├───lib
│ com.ibm.icu_54.1.1.v201501272100.jar
│ com.lowagie.text_2.1.7.v201004222200.jar
│ ...
│
└───samples
hello_world.rptdesign
Copy of wrapper.conf to [BIRT_SERVICE_HOME]\conf
- Get the example file wrapper.conf Your repertory [BIRT_SERVICE_HOME] must look like this:
[BIRT_SERVICE_HOME]
├───bin
│ birt.bat
│ conf.properties
│ Install-birt.bat
│ log4j.properties
│ Uninstall-birt.bat
│ wrapper.exe
├───conf
│ wrapper.conf
├───lib
│ hamcrest-core-1.3.jar
│ junit-4.12.jar
│ log4j-1.2.14.jar
│ vdoc-birt-helper-2.0.1.jar
│ wrapper.dll
│ wrapper.jar
├───logs
└───ReportEngine
│ genReport.bat
│ genReport.sh
├───lib
│ com.ibm.icu_54.1.1.v201501272100.jar
│ com.lowagie.text_2.1.7.v201004222200.jar
│ ...
│
└───samples
hello_world.rptdesign
Configuration of [BIRT_SERVICE_HOME]\conf\wrapper.conf
- Declare set.MYAPP_HOME= with the path to the repertory [BIRT_SERVICE_HOME]
- Declare set.JAVA_HOME= with the path to the repertory [JVM_X86]
- Declare wrapper.java.mainclass= avec org.tanukisoftware.wrapper.WrapperSimpleApp
- Declare wrapper.java.classpath.1= with %MYAPP_HOME%\lib*
- Declare wrapper.java.classpath.2= with %MYAPP_HOME%\ReportEngine\lib*
- Declare wrapper.java.additional.1= with -Xms1G
- Declare wrapper.java.additional.2= with -Xmx1G
- Declare wrapper.java.additional.3= with -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=5005
- Declare wrapper.app.parameter.1= with com.vdoc.sdk.commons.backend.birt.StandaloneBirtServerRunner
- Declare wrapper.app.parameter.2= with -DBIRT_HOME="%MYAPP_HOME%\ReportEngine"
Usage
- [BIRT_SERVICE_HOME]\bin\birt.bat allows to start the birt server
- [BIRT_SERVICE_HOME]\bin\Install-birt.bat allows to install the birt server as a service
- [BIRT_SERVICE_HOME]\bin\Uninstall-birt.bat allows to uninstall the service