-
Notifications
You must be signed in to change notification settings - Fork 520
processor_metrics_selector: Add documents for metrics_selector processor #1340
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
46bc3b9
processor_metrics_selector: Add documents for metrics_selector processor
cosmo0920 d7b2e70
Update installation/sources/build-and-install.md
cosmo0920 f5d7f47
Update pipeline/processors/metrics-selector.md
cosmo0920 4269015
Update pipeline/processors/metrics-selector.md
cosmo0920 a03c5b7
processor_metrics_selector: Add a example description for a making re…
cosmo0920 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Processors | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
# Metrics Selector | ||
|
||
The **metric_selector** processor allows you to select metrics to include or exclude (similar to the `grep` filter for logs). | ||
|
||
## Configuration Parameters <a id="config"></a> | ||
|
||
The native processor plugin supports the following configuration parameters: | ||
|
||
| Key | Description | Default | | ||
| :---------- | :--- | :--- | | ||
| Metric\_Name | Keep metrics in which the metric of name matches with the actual name or the regular expression. | | | ||
| Context | Specify matching context. Currently, metric_name is only supported. | `Metrics_Name` | | ||
| Action | Specify the action for specified metrics. INCLUDE and EXCLUDE are allowed. | | | ||
| Operation\_Type | Specify the operation type of action for metrics payloads. PREFIX and SUBSTRING are allowed. | | | ||
|
||
## Configuration Examples <a id="config_example"></a> | ||
|
||
Here is a basic configuration example. | ||
|
||
{% tabs %} | ||
{% tab title="fluent-bit.yaml" %} | ||
```yaml | ||
service: | ||
flush: 5 | ||
daemon: off | ||
log_level: info | ||
|
||
pipeline: | ||
inputs: | ||
- name: fluentbit_metrics | ||
tag: fluentbit.metrics | ||
scrape_interval: 10 | ||
|
||
processors: | ||
metrics: | ||
- name: metrics_selector | ||
metric_name: /storage/ | ||
action: include | ||
- name: metrics_selector | ||
metric_name: /fs/ | ||
action: exclude | ||
|
||
- name: labels | ||
delete: name | ||
|
||
|
||
outputs: | ||
- name: stdout | ||
match: '*' | ||
``` | ||
{% endtab %} | ||
{% endtabs %} | ||
|
||
|
||
All processors are only valid with the YAML configuration format. | ||
Processor configuration should be located under the relevant input or output plugin configuration. | ||
|
||
Metric\_Name parameter will translate the strings which is quoted with backslashes `/.../` as Regular expressions. | ||
Without them, users need to specify Operation\_Type whether prefix matching or substring matching. | ||
The default operation is prefix matching. | ||
For example, `/chunks/` will be translated as a regular expression. |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.