I. Description
Spark is a general-purpose fast processing engine for big data. Spark uses Spark RDD, Spark SQL, Spark Streaming, MLlib, and GraphX to successfully solve the most important tasks and problems in the big data field such as offline batch processing, interactive query, real-time stream computing, machine learning, and graph computing.
FineReport provides two data connection methods:
Method 1: Connect in the designer. For details, please refer to: [Designer] JDBC data connection .
Method 2: Connect on the Data Decision Platform. This article mainly introduces this way.
II. Data connection
1. Configuration information
Drive | URL | Support database version | Driver Download |
---|---|---|---|
org.apache.hive.jdbc.HiveDriver | jdbc:hive2://hostname:port/databasename | 1.6.0; | hive-spark1.6 .rar |
2.1;2.3 |
2. Connection steps
1) Download the Spark driver package from the configuration information driver download link, and place the driver package under %FR_HOME%\webapps\webroot\WEB-INF\lib, and restart the report server.
2) Log in to the Data Decision System, select Management >Data Connection>Data Connection Management, click New Data Connection, and select SPARK under All options, as shown in the following figure:
Note: If a non-administrator user wants to configure a data connection, the administrator needs to assign it the authority of the data connection node under the management system. For specific operations, please refer to Data Connection Authorization.
3) Click OK to enter the data connection configuration page.
If you choose kerberos authentication, you need to fill in the name of the client registered with kdc, the keytab key path, and the URL corresponding to Kerberos authentication. For details, please refer to [Platform] Kerberos Authentication For Data Connection, as shown in the figure below:
Note: Before connecting, please check whether the corresponding IP of the machine name in /etc/hosts is a LAN IP;
Check whether the machine name setting in /etc/hostname is consistent with that in /etc/hosts;
Check whether the IP + machine name configured by the hosts of the machine where FineReport is located is correct;
When connecting locally, you need to configure the /etc/hosts file and add a remote mapping: IP+machine name, for example: 192.168.5.156 centos-phoenix.
If you do not choose kerberos authentication, it will be consistent with other database settings. According to the configuration information provided in section II.1 of this article, enter the corresponding information of the database, and you can choose to fill in the advanced settings information. For details, please refer to [Platform]Configure Data Connection). As shown below:
4) Click Test Connection, if the 「Connection Successful」prompt box pops up, it means that the database is successfully connected, as shown in the following figure:
5) After the test connection is successful, click the Save button in the upper right corner, and the data connection is added successfully. As shown below: