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
Pipeline register hooks + hash fix #6677
Conversation
Selector, | ||
LogStash::Compiler::LSCL::AST::RegExpOperator, | ||
LogStash::Compiler::LSCL::AST::RegExp, | ||
LogStash::Compiler::LSCL::AST::String # Strings work as rvalues! :p |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was a shock.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was shocked too.
@@ -7,7 +7,7 @@ | |||
import org.logstash.config.ir.SourceComponent; | |||
import org.logstash.config.ir.SourceMetadata; | |||
|
|||
/** | |||
/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This isn't really a javadoc
2df5dc4
to
40f2e9c
Compare
.gitignore
Outdated
@@ -37,9 +37,6 @@ qa/Gemfile.lock | |||
*.iws | |||
*.iml | |||
.gradle | |||
**/.gradle/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These aren't in master and shouldn't be in LIR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you explain the asserts you are doing at https://github.com/elastic/logstash/pull/6677/files#diff-f9fdf28f867b25593d8af2d613584817R147
Shouldn't we check the branch hash values and compare them?
Selector, | ||
LogStash::Compiler::LSCL::AST::RegExpOperator, | ||
LogStash::Compiler::LSCL::AST::RegExp, | ||
LogStash::Compiler::LSCL::AST::String # Strings work as rvalues! :p |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was shocked too.
# Maybe we really shouldn't handle these anymore... | ||
if regexp.class == org.logstash.config.ir.expression.ValueExpression | ||
regexp = jdsl.eRegex(regexp.get) | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I live in a world where I do prefer explicit, I wasn't aware that we were handle theses case.
Can we create an issue that target 6.0?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -218,7 +218,7 @@ def get_recursively(key_paths, map, new_hash) | |||
key_candidates = extract_filter_keys(key_paths.shift) | |||
|
|||
key_candidates.each do |key_candidate| | |||
raise MetricNotFound, "For path: #{key_candidate}" if map[key_candidate].nil? | |||
raise MetricNotFound, "For path: #{key_candidate}. Map keys: #{map.keys}" if map[key_candidate].nil? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
make sense here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I hit a weird bug, this made it easier to discover :)
|
||
Graph g = imperative.toGraph(); | ||
g.validate(); // Double validate just because that's the point of this test | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure I understand the assert in this test?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ph well, there's no assert here because validate
will throw an InvalidIRException
if it fails.
Also this PR superseed this one #6517 ? correct? |
oops unit test are failling! |
40f2e9c
to
f4b8f58
Compare
Add UniversalPlugin hooks for pipeline events
f4b8f58
to
2d2cd27
Compare
This PR does three things:
[foo] =~ "bar"