eKuiper has implemented the following plugins. At present, some of these plug-ins are examples used to describe the plug-in development process, and some are contributed by community developers. Please read the relevant documents carefully before using the plugins.
Developers of eKuiper plugin can specify metadata files during the development process. These metadata files are mainly used in the following aspects:
plugins/sinks
and plugins/sources
, if the developer provides related metadata files, eKuiper will automatically compile the plugins when the version is released, and then automatically upload these plugins to the EMQ plugin download website: www.emqx.io/downloads/kuiper/vx.x.x/plugins, where x.x.x
is the version number.Note: Due to the limitations of Golang plugins, these automatically compiled plugins can run in the container of the corresponding version released by eKuiper. However, for the directly downloaded binary installation package, or the binary package compiled by the user , these downloaded plugins are not guaranteed to work properly.
Name | Description | Remarks |
---|---|---|
zmq | The plugin listens to Zero Mq messages and sends them to the eKuiper stream | Sample of plugin, not available in production environment |
random | The plugin generates messages according to the specified pattern | Sample of plugin, not available in production environment |
Most attributes of source are specified by the user through the corresponding configuration file, and the user cannot configure it during the creation of the stream. In the metadata file provided by the plugin developer, only the following parts need to be specified.
This part of the content defines which library dependencies are used by the plugin (the format is github.com/x/y@version
). During the compilation of the plugin, this information is read and the relevant library dependencies are added to the go.mod
of the project. The content of this configuration item is a string array.
trial: indicates whether the plugin is under beta test stage
author
This part contains the author information of the plugin. The plugin developer can provide this information as appropriate. The information of this part will be displayed in the plugin information list of the management console.
website
helpUrl
The help file address of the plug-in. The console will link to the corresponding help file according to the language support.
zh_CN: Chinese document help address
description
A simple description of the plugin. The console supports multiple languages.
The list of attributes supported by the plugin and the configuration related to each attribute.
true
, indicating that the user can provide the value of the field;type: field type; This field must be provided;
values: If the control type is list-box
or radio
, this field must be provided;
Array: The data type can be number, character, boolean, etc.
The following is a sample of metadata file.
{
"libs": [""],
"about": {
"trial": false,
"author": {
"name": "",
"email": "",
"company": "",
"website": ""
},
"helpUrl": {
"en_US": "",
"zh_CN": ""
},
"description": {
"en_US": "",
"zh_CN": ""
}
},
"properties": {
"default": [{
"name": "",
"default": "",
"optional": false,
"control": "",
"type": "",
"hint": {
"en_US": "",
"zh_CN": ""
},
"label": {
"en_US": "",
"zh_CN": ""
}
}, {
"name": "",
"default": [{
"name": "",
"default": "",
"optional": false,
"control": "",
"type": "",
"hint": {
"en_US": "",
"zh_CN": ""
},
"label": {
"en_US": "",
"zh_CN": ""
}
}],
"optional": false,
"control": "",
"type": "",
"hint": {
"en_US": "",
"zh_CN": ""
},
"label": {
"en_US": "",
"zh_CN": ""
}
}]
}
}
Name | Description | Remarks |
---|---|---|
file | The plugin saves the analysis results to a specified file system | Sample of plugin, not available in production environment |
zmq | The plugin sends the analysis results to the topic of Zero Mq | Sample of plugin, not available in production environment |
Influxdb | The plugin sends the analysis results to InfluxDB | Provided by @smart33690 |
TDengine | The plugin sends the analysis results to TDengine |
The metadata file format is JSON and is mainly divided into the following parts:
The content of this part defines which library dependencies are used by the plugin (the format is github.com/x/y@version
). During the compilation of the plugin, this information is read and the relevant library dependencies are added to the go.mod
of the project. The content of this configuration item is a string array.
trial: indicates whether the plugin is under beta test stage
author
This part contains the author information of the plugin. The plugin developer can provide this information as appropriate. The information of this part will be displayed in the plugin information list of the management console.
name
helpUrl
The help file address of the plugin. The console will link to the corresponding help file according to the language support.
* en_US: English document help address
zh_CN: Chinese document help address
description
A simple description of the plugin. The console supports multiple languages.
The list of attributes supported by the plugin and the configuration related to each attribute.
true
, indicating that the user can provide the value of the field;type: field type; This field must be provided;
values: If the control type is list-box
or radio
, this field must be provided;
Array: The data type can be number, character, boolean, etc.
The following is a sample of metadata file.
{
"about": {
"trial": false,
"author": {
"name": "",
"email": "",
"company": "",
"website": ""
},
"helpUrl": {
"en_US": "",
"zh_CN": ""
},
"description": {
"en_US": "",
"zh_CN": ""
}
},
"libs": [""],
"properties": [{
"name": "",
"default": "",
"optional": false,
"control": "",
"type": "",
"hint": {
"en_US": "",
"zh_CN": ""
},
"label": {
"en_US": "",
"zh_CN": ""
}
}]
}
Name | Description | Remarks |
---|---|---|
echo | Output parameter value as it is | Plugin sample, not available for production environment |
countPlusOne | Output the value of the parameter length plus one | Plugin sample, not available for production environment |
accumulateWordCount | The function counts how many words there are | Plugin sample, not available for production environment |
resize | Create a scaled image with new dimensions (width, height). If width or height is set to 0, it is set to the reserved value of aspect ratio | Plugin sample, not available for production environment |
thumbnail | Reduce the image that retains the aspect ratio to the maximum size (maxWidth, maxHeight). | Plugin sample, not available for production environment |
eKuiper has many built-in functions that can perform calculations on data. (Refer to https://github.com/lf-edge/ekuiper/blob/master/docs/zh_CN/sqls/built-in_functions.md for specific documentation)
The metadata file format is JSON and is mainly divided into the following parts:
trial: indicates whether the plugin is under beta test stage
author
This part contains the author information of the plugin. The plugin developer can provide this information as appropriate. The information of this part will be displayed in the plugin information list of the management console.
name
helpUrl
The help file address of the plugin. The console will link to the corresponding help file according to the language support.
* en_US: English document help address
zh_CN: Chinese document help address
description
A simple description of the plugin. The console supports multiple languages.
The following is a sample of metadata file.
{
"about": {
"trial":false,
"author": {
"name": "",
"email": "",
"company": "",
"website": ""
},
"helpUrl": {
"en_US": "",
"zh_CN": ""
},
"description": {
"en_US": "",
"zh_CN": ""
}
},
"functions": [{
"name": "",
"example": "",
"hint": {
"en_US": "",
"zh_CN": ""
}
}]
}