Skip to content

Commit

Permalink
Doc:Highlight difference between static and streaming filter
Browse files Browse the repository at this point in the history
  • Loading branch information
karenzone committed Sep 30, 2020
1 parent 14410ed commit aea11bf
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 3 deletions.
4 changes: 4 additions & 0 deletions docs/filter-jdbc_static.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ This filter enriches events with data pre-loaded from a remote database.
This filter is best suited for enriching events with reference data that is
static or does not change very often, such as environments, users, and products.

TIP: If you need to process dynamic data, consider using the
{logstash-ref}/plugins-filters-jdbc_streaming.html[JDBC streaming filter plugin]
instead.

This filter works by fetching data from a remote database, caching it in a
local, in-memory https://db.apache.org/derby/manuals/#docs_10.14[Apache Derby]
database, and using lookups to enrich events with data cached in the local
Expand Down
10 changes: 8 additions & 2 deletions docs/filter-jdbc_streaming.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,13 @@ include::{include_path}/plugin_header-integration.asciidoc[]

==== Description

This filter executes a SQL query and store the result set in the field
//We could use a better general, introductory description here.

TIP: If you need to process data that doesn't change often, consider using the
{logstash-ref}/plugins-filters-jdbc_static.html[JDBC static filter plugin]
instead.

This filter executes a SQL query and stores the result set in the field
specified as `target`.
It will cache the results locally in an LRU cache with expiry.

Expand All @@ -46,7 +52,7 @@ filter {
[id="plugins-{type}s-{plugin}-prepared_statements"]
==== Prepared Statements

Using server side prepared statements can speed up execution times as the server optimises the query plan and execution.
Using server side prepared statements can speed up execution times as the server optimizes the query plan and execution.

NOTE: Not all JDBC accessible technologies will support prepared statements.

Expand Down
18 changes: 17 additions & 1 deletion docs/index.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,28 @@ include::{include_path}/plugin_header.asciidoc[]

==== Description

The JDBC Integration Plugin provides integrated plugins for working with databases that provide JDBC drivers:
The JDBC Integration Plugin provides integrated plugins for working with
databases that provide JDBC drivers:

- {logstash-ref}/plugins-inputs-jdbc.html[JDBC Input Plugin]
- {logstash-ref}/plugins-filters-jdbc_static.html[JDBC Static Filter Plugin]
- {logstash-ref}/plugins-filters-jdbc_streaming.html[JDBC Streaming Filter Plugin]

[id="plugins-{type}s-{plugin}-static_or_streaming"]
===== JDBC Static? Or JDBC Streaming?

The JDBC integration plugin offers two JDBC filtering options--JDBC static and
JDBC streaming. Use the one that best fits your use case.

* **{logstash-ref}/plugins-filters-jdbc_static.html[JDBC static filter].**
Best suited for enriching events with reference data that is static or does not
change very often, such as environments, users, and products.

* **{logstash-ref}/plugins-filters-jdbc_streaming.html[JDBC streaming filter].**
Best suited for filtering data that is transmitted in a steady, continuous flow.
This plugin continues to receive incoming data while data received earlier is
being processed.

:no_codec!:


0 comments on commit aea11bf

Please sign in to comment.