一、官网下载
文档地址:http://help.finereport.com/
二、SpringBoot2.1整合finereport10
(一)导入jar到Maven
C:\FineReport_10.0\webapps\webroot\WEB-INF\lib
新建lib.bat拷贝脚本内容并执行(Windows平台):
内容为:
call mvn install:install-file -Dfile=fine-accumulator-10.0.jar -DgroupId=com.fine -DartifactId=fine-accumulator -Dversion=10.0 -Dpackaging=jar
call mvn install:install-file -Dfile=fine-activator-10.0.jar -DgroupId=com.fine -DartifactId=fine-activator -Dversion=10.0 -Dpackaging=jar
call mvn install:install-file -Dfile=fine-core-10.0.jar -DgroupId=com.fine -DartifactId=fine-core -Dversion=10.0 -Dpackaging=jar
call mvn install:install-file -Dfile=fine-datasource-10.0.jar -DgroupId=com.fine -DartifactId=fine-datasource -Dversion=10.0 -Dpackaging=jar
call mvn install:install-file -Dfile=fine-decision-10.0.jar -DgroupId=com.fine -DartifactId=fine-decision -Dversion=10.0 -Dpackaging=jar
call mvn install:install-file -Dfile=fine-decision-report-10.0.jar -DgroupId=com.fine -DartifactId=fine-decision-report -Dversion=10.0 -Dpackaging=jar
call mvn install:install-file -Dfile=fine-report-engine-10.0.jar -DgroupId=com.fine -DartifactId=fine-report-engine -Dversion=10.0 -Dpackaging=jar
call mvn install:install-file -Dfile=fine-schedule-10.0.jar -DgroupId=com.fine -DartifactId=fine-schedule -Dversion=10.0 -Dpackaging=jar
call mvn install:install-file -Dfile=fine-schedule-report-10.0.jar -DgroupId=com.fine -DartifactId=fine-schedule-report -Dversion=10.0 -Dpackaging=jar
call mvn install:install-file -Dfile=fine-swift-log-adaptor-10.0.jar -DgroupId=com.fine -DartifactId=fine-swift-log-adaptor -Dversion=10.0 -Dpackaging=jar
call mvn install:install-file -Dfile=fine-third-10.0.jar -DgroupId=com.fine -DartifactId=fine-third -Dversion=10.0 -Dpackaging=jar
call mvn install:install-file -Dfile=fine-webui-10.0.jar -DgroupId=com.fine -DartifactId=fine-webui -Dversion=10.0 -Dpackaging=jar
(二)Maven依赖
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<artifactId>hrz-api</artifactId>
<groupId>com.hrz</groupId>
<version>1.0.0</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>hrz-reports-server</artifactId>
<name>hrz-reports-server</name>
<packaging>war</packaging>
<description>报表服务中心</description>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
</properties>
<dependencies>
<dependency>
<groupId>com.fine</groupId>
<artifactId>fine-core</artifactId>
<version>10.0</version>
</dependency>
<dependency>
<groupId>com.fine</groupId>
<artifactId>fine-activator</artifactId>
<version>10.0</version>
</dependency>
<dependency>
<groupId>com.fine</groupId>
<artifactId>fine-core</artifactId>
<version>10.0</version>
</dependency>
<dependency>
<groupId>com.fine</groupId>
<artifactId>fine-datasource</artifactId>
<version>10.0</version>
</dependency>
<dependency>
<groupId>com.fine</groupId>
<artifactId>fine-decision</artifactId>
<version>10.0</version>
</dependency>
<dependency>
<groupId>com.fine</groupId>
<artifactId>fine-decision-report</artifactId>
<version>10.0</version>
</dependency>
<dependency>
<groupId>com.fine</groupId>
<artifactId>fine-report-engine</artifactId>
<version>10.0</version>
</dependency>
<dependency>
<groupId>com.fine</groupId>
<artifactId>fine-schedule</artifactId>
<version>10.0</version>
</dependency>
<dependency>
<groupId>com.fine</groupId>
<artifactId>fine-schedule-report</artifactId>
<version>10.0</version>
</dependency>
<dependency>
<groupId>com.fine</groupId>
<artifactId>fine-swift-log-adaptor</artifactId>
<version>10.0</version>
</dependency>
<dependency>
<groupId>com.fine</groupId>
<artifactId>fine-third</artifactId>
<version>10.0</version>
</dependency>
<dependency>
<groupId>com.fine</groupId>
<artifactId>fine-webui</artifactId>
<version>10.0</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
</project>
1、 配置项目时候注意依赖顺序,spring-boot-starter-web在最上面
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
<exclusions>
<exclusion>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-tomcat</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>3.1.0</version>
<scope>provided</scope>
</dependency>
</dependencies>
(三)Web服务器配置
1、设置JVM运行参数:
-DDIAMOND.CONNECT.TIMEOUT=60000 -XX:MaxPermSize=3512m
-DDIAMOND.CONNECT.TIMEOUT=60000 -Xms768m -Xmx768m -XX:PermSize=64M -XX:MaxPermSize=512m
2、创建webapp目录: