v1.0.3: Support string list, with TTL

This commit is contained in:
2024-02-04 16:51:04 +01:00
parent 4b032a90cf
commit c597467656
4 changed files with 164 additions and 34 deletions

View File

@ -1,6 +1,6 @@
# RedisLookupPlugin Plugin for Graylog
Plugin to add Redis Data Adapter in read/write to graylog so you can store and retrieve key/values from pipelines
Plugin to add Redis Data Adapter in read/write to graylog so you can store and retrieve key/values and lists of string values from pipelines
Support Redis authentication (with password and username/password)
**Required Graylog version:** 5.0 and later
@ -8,7 +8,7 @@ Support Redis authentication (with password and username/password)
Installation
------------
[Download the plugin](https://git.nosd.in/yo/graylog-redis-lookup-plugin/releases/download/v1.0.0/graylog-plugin-redis-lookup-1.0.0.jar)
[Download the plugin](https://git.nosd.in/yo/graylog-redis-lookup-plugin/releases/download/v1.0.3/graylog-plugin-redis-lookup-1.0.3.jar)
and place the `.jar` file in your Graylog plugin directory. The plugin directory
is the `plugins/` folder relative from your `graylog-server` directory by default
and can be configured in your `graylog.conf` file.
@ -35,8 +35,18 @@ Usage
* Use 'lookup_clear_key(lookup_table, key)' to remove key
* Use 'lookup_has_value(lookup_table, key)' to test key existence
* Use 'lookup_assign_ttl(lookup_table, key, ttl)' to change TTL of existing key
* Use 'lookup_set_string_list(lookup_table, key, value, [ttl])' to create a list named "key"
* Use 'lookup_add_string_list(lookup_table, key, value, [keep_duplicates])' to add value list to existing list
* Use 'lookup_remove_string_list(lookup_table, key, value) to remove a string from list "key"
By default keys will be created in Redis with the default TTL defined at data adapter creation time
By default single value keys will be created in Redis with the default TTL defined at data adapter creation time
Be aware that only setting TTL with 'lookup_assign_ttl' of 'lookup_set_string_list' alter TTL value in Redis ; so a list created with a TTL of 3600 will expire in 3600 seconds, even if it was updated with 'lookup_add_string_list' some seconds before expiration.
Known bugs
----------
Deletion via lookup_remove_string_list, lookup_clear_key or keep_duplicates=false sometimes not done.
Getting started