You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/shared/v3-core-plugins/_index.md
+15-15Lines changed: 15 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,15 +1,15 @@
1
1
2
-
Use the {{% product-name %}} ProcessingEngine to run code and perform tasks
2
+
Use the {{% product-name %}} Processing engine to run code and perform tasks
3
3
for different database events.
4
4
5
-
{{% product-name %}} provides the InfluxDB 3 Processing Engine, an embedded Python VM that can dynamically load and trigger Python plugins
5
+
{{% product-name %}} provides the InfluxDB 3 Processing engine, an embedded Python VM that can dynamically load and trigger Python plugins
6
6
in response to events in your database.
7
7
8
8
## Key Concepts
9
9
10
10
### Plugins
11
11
12
-
A Processing Engine_plugin_ is Python code you provide to run tasks, such as
12
+
A Processing engine_plugin_ is Python code you provide to run tasks, such as
13
13
downsampling data, monitoring, creating alerts, or calling external services.
14
14
15
15
> [!Note]
@@ -25,16 +25,16 @@ A _trigger_ is an InfluxDB 3 resource you create to associate a database
25
25
event (for example, a WAL flush) with the plugin that should run.
26
26
When an event occurs, the trigger passes configuration details, optional arguments, and event data to the plugin.
27
27
28
-
The Processing Engine provides four types of triggers—each type corresponds to an event type with event-specific configuration to let you handle events with targeted logic.
28
+
The Processing engine provides four types of triggers—each type corresponds to an event type with event-specific configuration to let you handle events with targeted logic.
29
29
30
30
-**WAL Flush**: Triggered when the write-ahead log (WAL) is flushed to the object store (default is every second).
31
31
-**Scheduled Tasks**: Triggered on a schedule you specify using cron syntax.
32
-
-**On Request**: Triggered on a GET or POST request to the bound HTTP API endpoint at `/api/v3/engine/<CUSTOM_PATH>`.
32
+
-**On-request**: Triggered on a GET or POST request to the bound HTTP API endpoint at `/api/v3/engine/<CUSTOM_PATH>`.
33
33
-**Parquet Persistence (coming soon)**: Triggered when InfluxDB 3 persists data to object storage Parquet files.
34
34
35
-
### Activate the Processing Engine
35
+
### Activate the Processing engine
36
36
37
-
To enable the Processing Engine, start the {{% product-name %}} server with the `--plugin-dir` option and a path to your plugins directory. If the directory doesn’t exist, the server creates it.
37
+
To enable the Processing engine, start the {{% product-name %}} server with the `--plugin-dir` option and a path to your plugins directory. If the directory doesn’t exist, the server creates it.
38
38
39
39
```bash
40
40
influxdb3 serve --node-id node0 --object-store [OBJECT STORE TYPE] --plugin-dir /path/to/plugins
The `args` parameter is optional. If a plugin doesn’t require arguments, you can omit it from the trigger definition.
241
241
242
-
## Import Plugin Dependencies
242
+
## Import plugin dependencies
243
243
244
244
Use the `influxdb3 install` command to download and install Python packages that your plugin depends on.
245
245
@@ -278,10 +278,10 @@ For more information, see the `influxdb3` CLI help:
278
278
influxdb3 install package --help
279
279
```
280
280
281
-
## Trigger Types and How They Work
281
+
## Configure plugin triggers
282
282
Triggers define when and how plugins execute in response to database events. Each trigger type corresponds to a specific event, allowing precise control over automation within {{% product-name %}}.
283
283
284
-
### WAL Flush Trigger
284
+
### WAL flush trigger
285
285
286
286
When a WAL flush plugin is triggered, the plugin receives a list of `table_batches` filtered by the trigger configuration (either _all tables_ in the database or a specific table).
287
287
@@ -337,9 +337,9 @@ For more information about trigger arguments, see the CLI help:
337
337
influxdb3 create trigger help
338
338
```
339
339
340
-
### Schedule Trigger
340
+
### Schedule trigger
341
341
342
-
Schedule plugins run on a schedule specified in cron syntax. The plugin will receive the local API, the time of the trigger, and any arguments passed in the trigger definition. Here's an example of a simple schedule plugin:
342
+
Schedule plugins run on a schedule specified in cron syntax. The plugin receives the local API, the time of the trigger, and any arguments passed in the trigger definition. Here's an example of a simple schedule plugin:
343
343
344
344
```python
345
345
# see if a table has been written to in the last 5 minutes
On Request plugins are set with a `trigger-spec` of `request:<endpoint>`. The `args` parameter can be used to pass configuration to the plugin. For example, if we wanted the above plugin to run on the endpoint `/api/v3/engine/my_plugin`, we would use `request:my_plugin` as the `trigger-spec`.
397
+
On-request plugins are set with a `trigger-spec` of `request:<endpoint>`. The `args` parameter can be used to pass configuration to the plugin. For example, if we wanted the above plugin to run on the endpoint `/api/v3/engine/my_plugin`, we would use `request:my_plugin` as the `trigger-spec`.
398
398
399
399
Trigger specs must be unique across all configured plugins, regardless of which database they are tied to, given the path is the same. Here's an example to create a request trigger tied to the "hello-world' path using a plugin in the plugin-dir:
0 commit comments