6.0
/
6.0.17
Added the fetchsize parameter configuration.
6.1.5
Supported data connections to be managed in folders.
The function allows you to establish a connection between FineBI and the database, enabling FineBI to directly access the data in the database.
1. Log in to a FineBI project as the admin and choose System Management > Data Connection > Data Connection Management. Choose Create > Folder, and you can use folders to classify and manage data connections, as shown in the following figure.
Create a data connection in a folder, as shown in the following figure.
2. In the pop-up box, customize a data connection name, as shown in the following figure.
3. Select the database type. For example, if you want to connect to a MySQL database, you need to select MySQL and then click the Next button, as shown in the following figure.
4. Enter the relevant information of the database, as shown in the following figure.
The following gives details about data connection configurations. Different databases have different connection information to set. For details, see specific documents. For example, for details about how to configure MySQL connections, see MySQL Data Connection.
Data Connection Name
Name of the data connection (Name it as you like.)
Driver
Driver needed to connect to the database
Default: For some of the databases that have built-in database drivers, you can select the default option.
Custom: You need to customize drivers that do not exist in FineDataLink. For details, see Driver Management
Database Name
Name of the database to be connected to
Host
IP address of the host (or server) where the database is located
Port
Port number of the host (or server) where the database is located
Authentication Method
If the database supports multiple authentication methods, a radio group will appear.
Username Password: username and password of the database
Kerberos: client name and Keytab key path registered with KDC. For details, see Kerberos Authentication in Data Connection.
Encoding
You are advised to select Default.
Schema
Some databases require you to select a schema after they are successfully connected.
You do not need to select a schema if there is no schema option on the configuration page.
The first schema is selected by default if no schema is selected.
Use the schema prefix in SQL statements to search in a specific schema when a multi-pattern database is connected.
Data Connection URL
Automatically generated URL (No manual configuration is required.)
Click Test Connection to test if the connection is successful.
If you do not need to set a connection pool, you can click Save to complete data connection configuration.
When connecting to a database, you can perform some advanced settings as required, as shown in the following figure.
Fetchsize settings
Problems such as slow extraction from base tables and from direct-connected SQL datasets can be tuned through fetchsize.
The fetchsize parameter is used to control the number of records to be processed in batches for obtaining data from the database. A smaller value of the fetchsize parameter can reduce the memory consumption of each database query, but may require more database round trips to retrieve the complete result set; a larger value of the fetchsize parameter can reduce the number of database round trips but will increase memory usage. You can optimize the database query performance by setting the fetchsize parameter as required.
If the parameter value is less than or equal to 0 (for example: -20), the fetchsize parameter is disabled.
1. The fetchsize parameter must be set for the Oracle, DB2, and Postgre databases. Therefore, if the value of the fetchsize parameter is set to be a value less than or equal to 0, it will be automatically replaced by 128, 50, or 10000 in the three databases, respectively.
2. The fetchsize parameter is disabled for other databases by default.
SocketTimeout settings
Set the socket timeout duration (the longest time for connection waits or data transmission), exceeding which the connection will be forcibly disconnected.
If the value is null or 0, no timeout duration is set.
Set the connection pool and select the Connection Pool Setting button, as shown in the following figure.
Common Settings
Max Active Connections
maxActive
50
Represents the maximum number of active connections that the connection pool can allocate at the same time.
Test Before Connection
testOnBorrow
Yes
Executes validationQuery to check whether the connection is valid during connection application.
Regular Availability Check of Idle Connection
keepAlive
Checks the connections that need to be left to ensure that they are available.
Verification Statement
validationQuery
Default statement
Represents the SQL statement (a query statement, often in the "select x" format) used to check whether a connection is valid. You can customize the statement.
Max Wait Time
maxWait
10000ms
Obtains the maximum waiting time for a connection. If the connection is not successful in this period, it is considered a connection failure.
More Settings (not commonly used; you are advised not to modify the settings except for any special circumstance.)
Number of Initialized Connections
initialSize
0
Represents the number of physical connections established during initialization.
Min Idle Connections
minIdle
Represents the minimum number of connections.
Detection Before Returning Connections
testOnReturn
No
Executes validationQuery to check whether the connection is valid during connection returning.
Detection by Idle Connection Recycler
testWhileIdle
Indicates whether the connection is checked by the idle connection recycler (if any), and if the check fails, the connection will be removed from the pool.
Sleep Time of Idle Connection Recycler
timeBetweenEvictionRunsMillis
60000ms (60s)
This parameter is used to specify the time interval (in milliseconds) for running idle connection detection and thread cleanup in the connection pool .
Number of Idle Connections Detected by Recycler
numTestPerEvictionRun
3
Specifies the number of connections to be tested each time the idle connection recycler runs.
Time Threshold for Recycling Idle Connection
minEvictableIdleTimesMillis
1800 s
If the idle period of a connection in the connection pool exceeds the threshold and the total number of connections exceeds Min Idle Connections, the connection will be removed from the connection pool.
Time Threshold for Forcibly Recycling Idle Connection
maxEvictableIdleTimeMillis
25200s (7h)
If the idle period of a connection in the connection pool exceeds the threshold, it will be removed from the connection pool.
Time Threshold for Regularly Checking Idle Connection Availability
keepAliveBetweenTimeMillis
120000ms (2 min)
The keep-alive time of an idle connection ensures that the connection will not be unexpectedly closed after an idle period .
If you require high security, you are advised to use SSH. Check UseSSH Tunnel and enter the corresponding information.
Click Test Connection. If the connection is successful, click Save to save the configuration.
1. Put the CA certificate, client certificate, and client key under the path %FineBI%/webapps/webroot/WEB-INF/resources/certificates.
2. Select UseSSL Tunnel and add the file to the corresponding location, as shown in the following figure.
3. Click Test Connection. If the connection is successful, click Save to save the configuration.
After the data connection is successfully created, the page is shown in the following figure.
Users can edit, rename, copy, delete and test the data connections in the list, as shown in the following figure.
Test Connection
Tests whether the database configuration is successful.
Edit
Modifies data connection configuration items.
Rename
Renames the data connection.
Copy to
Copy the database and add 1 behind the name of data connection automatically.
Delete
Delete the database.
Data connection information area
Displays the database type and its creator.
Notes:
The xxx icon will not be displayed on the right side of incompatible database types.
You are not advised to modify the data connection name during data connection management. Because the table updated to local computers relies on the name of the data connection to match the database,if the name of the data connection is modified, the tables retrieved from that connection will no longer be updated, and the Modify SQL button will not exist when the connection is based on an SQL dataset.
If you want to update the database of the locally saved table, for example, when you changed from the development environment to the production environment, you only need to modify the URL of the data connection when the table name and the table structure are consistent. In this way, data from the the locally saved table can still be updated according to the data connection name.
1. Click the folder or root directory to search for data connections by the data connection name (supported case-insensitive and fuzzy search), data source type (multiple selections allowed, which are existing data source types in the table), and creator (multiple selections allowed, which are existing creators in the table), as shown in the following figure.
The following table describes Number of Active Connections and Number of Idle Connections.
Connection Pool Status
Description
Number of Active Connections
Maximum connection number that the connection pool can create. If the maximum number is 10, a program has already requested 10 connections that are in use all along, the system will pop up an error "active 10 maxActive 10" when you apply for the eleventh data connection.
Number of Idle Connections
Connections that are in idle status and can change into active connections at any time. When the idle status time of a connection exceeds the maximum idle connection time, the connection will be automatically released.
Number of Active Connections + Number of Idle Connections = Number of actual physical connections
2. You can rename or delete folders, as shown in the following figure.
3. The data connection can be dragged from folder A to folder B. You cannot drag a folder to another folder, A maximum of one layer of folders is supported.
You can use the Data Connection Timeout Detection function by clicking Data Connection Management > Global Setting to customize the timeout period of a data connection.
When a data connection times out, an error pops up: 31300010 kdc server is not connected. You can modify the timeout period manually.
When fineBI is connected to server datasets, an error message "find fieldinfo failed for table: XXX" occurs during the data preview.
The reason is that there are duplicate field names in the database table, and FineBI does not support duplicate field names and null values, as shown in the following figure. You need to modify the duplicate field names.
滑鼠選中內容,快速回饋問題
滑鼠選中存在疑惑的內容,即可快速回饋問題,我們將會跟進處理。
不再提示
10s後關閉
Submitted successfully
Network busy