RegEx on Message Context with capturing groups search field expression type plugin
Easily extract unique values from context properties using the Nodinite RegEx on Message Context with Capturing Groups Search Field Expression Plugin. This page shows you how to configure, test, and use this plugin with clear input, configuration, and result examples.
✅ Extract single or multiple unique values from named context properties
✅ Use powerful RegEx expressions with capturing groups for advanced extraction
✅ Designed for high performance and self-service log views
What is the RegEx on Message Context with Capturing Groups Plugin?
The Nodinite RegEx on Message Context with Capturing Groups plugin lets you extract one or more unique values from the collection of context properties in the payload of Log Events. Use it to process messages where you need to target specific context properties and extract values using RegEx with capturing groups.
- Extract single or multiple unique values from named context properties
- Use RegEx expressions with capturing groups, global, and multiline options
- Ideal for small payloads and business integration scenarios
Use this plugin for extracting values from messages with context properties using RegEx.
How It Works: Input → Context Property → RegEx Expression → Result
Each example below clearly separates the Input (context property value), the Context Property (property name), the RegEx Expression (pattern), and the Result (output value).
Quick Example
Input:
ORD|101|ExampleCompany1|456|Company Name ACME |...
Context Property:
OrderRecord
RegEx Expression:
^(?:(.*?)\|){4}
Result:
456
Examples
Example 1: Extract the 4th Field from a Context Property Using RegEx
Input:
ORD|101|ExampleCompany1|456|Company Name ACME |Dieselgate valley 1|123 45|Flameburg|
Context Property:
OrderRecord
RegEx Expression:
^(?:(.*?)\|){4}
Result:
456
Valid expression with state output, unique values, and total count.
Features
- Extract single or multiple unique values from named context properties
- Use RegEx expressions with capturing groups, global, and multiline options
- Designed for small payloads and high performance
Note: This plugin loads the entire message into RAM. Only use it for small payloads.
How to Use
- Select the 'RegEx on Message Context with capturing groups' expression type plugin when configuring a Search Field.
- Enter the name of the context property to extract the value from.
- Enter the RegEx expression to match/style the content.
- RegEx groups: Enter the number or name of RegEx group(s) to return (leave empty for all matches)
- Global: When checked, do not return on first match
- Multi line: When checked, use
^
for start of line and$
for end of line
- Finalize the configuration and select the Message Types to apply the expression.
- Optionally, perform a re-index operation (Add or manage Search Field).
Extracted values are stored for as long as the Message Type retention is configured.
Test Expression
You can test your configuration in the 'Test Expression' tab when setting up a Search Field:
- Enter a sample payload in the 'Message Body' tab
- Select the 'RegEx on Message Context with capturing groups' plugin
Here's an example selecting the 'RegEx on Message Context with capturing groups' expression type plugin. - Enter the name of the context property and the RegEx expression
- Review the output and adjust as needed
If the expression is valid, you will see the unique values and total count:
Valid expression with state output, unique values, and total count.
If the expression is invalid or does not match any data, you will see:
Example of an invalid expression yielding no result.
Related Plugins and Topics
- RegEx
- RegEx with capturing groups
- RegEx on Message Context
- XPath with RegEx
- Formula – For advanced options using nested expressions
Mermaid Diagram: Search Field Expression Flow
This diagram shows how the RegEx on Message Context with capturing groups plugin fits into the overall search field expression process.
Next Step
Learn More
- What are Search Fields?
- What are Search Field Expressions?
- What are Message Types?
- What are Log Views?