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
Discussion about new filtering mechanism of v11 #216
Comments
Why closed? |
It's mistake :( |
TL;NR Idea1Idea1 looks difficult to grasp. Idea1 passes copied messages like <filter **>
type copy
# message goes here
<filter>
<match **>
# message goes here
</match> But, in v10, <match **>
type copy
<store>
# message goes here
</store>
<store>
# message goes here
</store>
</match> The behavior is completely different, and porting configuration of fluentd v10 to v11 looks hard to do. Idea2I simply don't understand what's going on on the example B of Idea2. Where does the label <label @aggregate_and_archive>
# forwarded data go to aggregate, then to archive
<source>
type forward
# source can't have nested match
</source> Idea3Idea3 can not be. It is not completely compatible with v10. Idea4This looks good, but I do not like Why don't you add an option <match copy **>
type groupcounter
<match>
type mongodb
</match>
</copy>
# archive
<match **>
type s3
</match> I don't know how to add options to apache-like configuration, though.... Idea5There was no explanation of Idea5, but is this a modified version of Idea4 on the point of I feel
is a good feature although I think we still should discuss on ConclusionIt looks Idea4 is good. I suggested |
@sonots thank you for your feedback! |
@sonots I added descriptions about Idea 5. |
I think, idea1 is a broken syntax. <filter **>
type copy
<match **>
type file
# 2 level nested
path /path/to/x.log
</match>
</filter>
<match **>
type file
# 1 level nested
path /path/to/y.log
</match> And we must modify tags to judge what to do for each events, with idea1. |
NOTE: we can use 'apache' syntax highlighting with GitHub flavored markdown. |
Thank you for description for Idea5 and letting me know about
I before came up with the same thing with |
Breaking compatibilities on idea5 is not problem for me, because:
But, <label @procedure>
<match ** copy>
type file
</match>
<match ** copy>
type forward
</match>
</label> It may better to use other directive name to explain |
Do you mean |
Having "most of" compatibility is still important. It's easy to say "add directive" in a document but difficult to explain if matching rules changed. |
Only reason why current code requires |
Alternative directives seems fine, but |
I look through 5 ideas and examples. I felt all of them are hard understand For the example A: |
Goal of idea 2 and 4 is to make plugin development easy to create a new filter plugin. With idea 2 or 4, Fluentd core can support plugins ( Regarding <source>
type forward
</source>
# forward s3.** logs to s3
<match s3.**>
type s3
</match> This receives logs and forward "some" logs to S3. <source>
type forward
</source>
<match **>
type copy
# I want to monitor all in-comming logs
<store>
type groupcounter
</store>
# forward s3.** logs to s3
<store s3.**>
type s3
</store>
</match> This doesn't work because we can't use match pattern to <source>
type forward
</source>
# I want to monitor all in-comming logs
<copy **>
type groupcounter
</copy>
# forward s3.** logs to s3
<match s3.**>
type s3
</match> |
@tagomoris do you mean having concept of
|
I removed idea 1 and 3. I agreed idea 1 is semantically broken. Idea 3 won't be better than 2 or 4. |
@frsyuki Yes, tag name |
@frsyuki . I understand what your meaning. That's my another suggestions: let all matched out plugin can received the message instead of only the first one. Things will become easy if that. For your example in comments, we can:
|
@mingqi Yes, that's a possible idea. But users already have configuration file like this: # monitor throughout of logs from certain application locally
<match app1.**>
type groupcounter
...
</match>
# forward everything else (logs not from app1) to remote aggregation server
<match **>
type forward
<server>
...
</server>
</match> I think it's confusing for existent users if we change the meaning of New users can use the new tag, and existent users can keep using |
@tagomoris How about |
@masa please comment here if you have ideas. I think you know a lot of actual users of Fluentd. |
@frsyuki <subscribe **>
type forward
</subscribe>
<match **>
type file
</match> Of course, we should hear voices of native English talkers. |
I asked some people around me (physically) about naming. Comments were almost same with yours:
|
Some more topic about this issue:
I'll write some comments for each topics above. |
Here is my idea:
|
I think that match should be able to emit events to both of nested matches and specified label. |
Sounds good idea. # emit to the top-level
<source>
type forward
</source>
# filter & emit to a nested match
<match ** copy>
type some_filter
<match **>
type file
</match>
</match>
# pass-through because match has copy option
# filter & emit to a label
<match **>
type some_filter
to_label @xyz
</match>
# emit to a label
<source>
type http
to_label @xyz
</source>
<label xyz>
<match **>
...
</match>
</label> |
What I mean with <match servicename.** copy => @label>
type foo_filter
</match> This |
Syntax should be changed: <match idea1.** copy => @label >
type foo_filter
</match>
<match idea2.** copy : @label >
type foo_filter
</match>
<match idea3.** copy @label >
type foo_filter
</match> |
Base class (Agent class (for now)) will handle This is good but trivial I think > plugin code cannot access this attribute. For me, your extra syntax looks confusing. I was confused that the copied events go to the specified label directly. Syntax should be either of: <match idea0.** copy>
type foo_filter
to_label @label
</match> or <match idea4.** copy>
type foo_filter
<match>
type redirect
to_label @label
</match>
</match> or possibly, <match idea5.** copy>
type foo_filter
<match>
to_label @label # assuming default type is out_redirect
</match>
</match> |
How about this example?
|
v12 is already released! |
I have several ideas for the design and need feedback about it. Here is the design document:
https://github.com/fluent/fluentd/wiki/V11-filter-syntax
The text was updated successfully, but these errors were encountered: