A Crystal Report server run in java.
-
Copy fonts used in report templates to
$JAVA_HOME/lib/fonts(Recommended), and set permission to this foldersudo chmod -R $JAVA_HOME/lib/fonts 755 -
Allow the TLS disabled algorithms (As Required) If the connect database version is too old, and the running Linux system is new, you maybe will have the TLS connection issue by disabled algorithms.
Edit
JAVA_HOME/conf/security/java.security, Deletejdk.tls.disabledAlgorithmsdisabled algorithms value; Edit/etc/crypto-policies/back-ends/java.config, Deletejdk.tls.disabledAlgorithmsdisabled algorithms value;
- It contains
postgres,mysql,sql serverdriver by default, Add your db driver inpom.xmlas necessary. - Upload
crystal-report-server-java.jartoSERVER_FOLDER. - Upload
lib(crystal report dependencies) toSERVER_FOLDER/lib. - Upload
*.rpt(report template files) toSERVER_FOLDER/reports. - Upload
config-prod.json(config file) toSERVER_FOLDER, configure database connection info and report template location. - Run
java -cp "./crystal-report-server-java.jar:lib/*" com.da.crystal.report.VertxApp --conf=config-prod.json --options=vertx-options.jsoninSERVER_FOLDER. - Open
http://server:port/Report/{ReportTemplateName}/{format}?param0=val0¶m1=val1in browser, you can see your report.
Note:
{ReportTemplateName}is the name of your report template file without extension,{format}is the format you want, such asdocxls,param0andparam1are the parameters of your report, give a param named withfilename, this param value will be used as the file name. Suggestion: UsingCommand SQLinstead ofTable Linkfor better performance, reduce the report generation duration.
- Implement
FormulaFunctionto define your own UF class (one function per class). - Implement
FormulaFunctionLibraryto define your own UFL class, which aggregates the UF classes into a library. - Register your UFL class in
CRConfig.xml.