The InfluxDB source component reads data from an InfluxDB data source. To synchronize data from an InfluxDB data source to another, configure the source component first, and then the target component.
Prerequisites
An InfluxDB data source has been created. For more information, see Create an InfluxDB data source.
The account that you use to configure the properties of the InfluxDB source component must have data synchronization read permission for the data source. If you do not have the permission, you must apply for data source permissions. For more information, see Apply for data source permissions.
Procedure
In the top navigation bar of the Dataphin homepage, choose Develop > Data Integration.
On the top navigation bar, select a project. If you are using the Dev-Prod mode, you must also select an environment.
In the left-side navigation pane, click batch integration. In the batch integration list, click the batch pipeline to open its configuration page.
In the upper-right corner of the canvas, click Component Library to open the Component Library panel.
In the left-side navigation pane of the Component Library panel, select Input. From the list of source components on the right, find the InfluxDB component and drag it onto the canvas.
On the InfluxDB source component card, click the
icon to open the InfluxDB Input Configuration dialog box.In the InfluxDB Input Configuration dialog box, configure the following parameters.
Parameter
Description
Step name
The name of the InfluxDB source component. Dataphin automatically generates a name, but you can change it as needed. The name must follow these rules:
Can only contain Chinese characters, letters, underscores (_), and digits.
Cannot exceed 64 characters in length.
Data source
From the Data Source drop-down list, select an InfluxDB-type data source. The list displays all InfluxDB data sources in Dataphin, including those for which you have the data synchronization read permission and those for which you do not. You can click the
icon to copy the name of the selected data source.If you lack the data synchronization read permission for a data source, click Apply next to its name to request it. For details, see Apply for Data Source Permissions.
If no InfluxDB data sources are available, click Create Data Source in the drop-down list. For details, see Create an InfluxDB data source.
bucket (Optional)
Select a bucket from the data source. If you do not select a bucket, the component uses the bucket that was specified when the data source was registered.
measurement
Select or enter the measurement to synchronize. The name can contain letters, digits, underscores (_), hyphens (-), and periods (.).
Time range start
The start of the time range for data retrieval. You can specify a relative time, such as
-5m(the last 5 minutes),-24h(the last 24 hours), or-7d(the last 7 days). You can also use an absolute time, such as2026-01-01T00:00:00Z. For a full data load, use the start time1970-01-01T00:00:00Z.Input Filter
Enter only the content that follows the
andkeyword of the Flux filter expression, for example,r.device_id == "dev_001" and r._field == "temperature". You can also use system global variables, such as${bizdate}.Output field
The Output Fields area displays all fields from the selected table that match the filter conditions. You can perform the following operations:
The Batch Add field supports adding items in JSON, TEXT, or DDL format.
Click Batch Add.
You can perform batch configuration in JSON format. The following is an example:
// Example: [ { "index": 1, "name": "id", "type": "int(10)", "mapType": "Long", "comment": "comment1" }, { "index": 2, "name": "user_name", "type": "varchar(255)", "mapType": "String", "comment": "comment2" } ]Noteindexrepresents the column index of the specified object,namerepresents the name of the imported field, andtyperepresents the type of the imported field.For example,
"index":3,"name":"user_id","type":"String"indicates that the fourth column of the file is imported, the field name is user_id, and the field type is String.The following is an example of batch configuration in TEXT format:
// 示例: 1,id,int(10),Long,comment1 2,user_name,varchar(255),Long,comment2A row delimiter is used to separate the information in each field. The default is a newline character (\n). Supported delimiters are a newline character (\n), a semicolon (;), and a period (.).
The column delimiter is used to separate field names and field types, and the default is a comma (,).
Click OK.
Create output field.
Click New Output Field, and then fill in the Field and select the Type as prompted.
Manage output fields.
You can perform the following operations on the added fields:
Next to the Field, click and drag the
move icon to change its position.Click the
Edit icon in the Actions column to edit the existing fields.Click the Delete icon
in the Actions column to delete an existing field.
Click Confirm to save the component's configuration.