Github user nickwallen commented on a diff in the pull request:
https://github.com/apache/incubator-metron/pull/395#discussion_r92923500
--- Diff:
metron-platform/metron-common/src/test/java/org/apache/metron/common/utils/StellarExecutor.java
---
@@ -0,0 +1,84 @@
+package org.apache.metron.common.utils;
--- End diff --
Ah, yes, good catch. We should bring these two together. Hmm.
The immediate problem for me with `StellarProcessorUtils` as-is, is that I
can't set a function resolver. If I simply add another 'run' method so the user
can specify a function resolver, then we're going to have quite a few different
run methods, which gets a little confusing in my opinion.
The other thing I prefer about the approach of `StellarExecutor` is that
each time I call `run` I don't need to pass in all of the extraneous data
structures, like the function resolver, the context and the variable resolver.
I'd prefer to have a way to set all of these, in the `setup` method of my test.
I think this makes each individual test case easier to read.
Which do you prefer? If we can find one way of doing it, I'd be willing to
go through and transition everything to one way or the other.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---