Skip to content
This repository was archived by the owner on Aug 20, 2025. It is now read-only.

METRON-1815: Separate metron-parsers into metron-parsers-common and metron-parsers-storm#1249

Closed
justinleet wants to merge 48 commits intoapache:masterfrom
justinleet:parserSplit
Closed

METRON-1815: Separate metron-parsers into metron-parsers-common and metron-parsers-storm#1249
justinleet wants to merge 48 commits intoapache:masterfrom
justinleet:parserSplit

Conversation

@justinleet
Copy link
Copy Markdown
Contributor

@justinleet justinleet commented Oct 30, 2018

Contributor Comments

Separating metron-parsers into metron-parsers-common and metron-parsers-storm in order to decouple the parsers from Storm. This builds on the work from METRON-1681, done here: #1213. It looks like a ton of changes, but most of it is pretty minor naming adjustments, moving whole files, etc.

Full dev should spin up and run exactly as it does prior to this PR, which is also how to test this.

At this point, no org.apache.storm dependency should remain in metron-parsers-common (as that now lives in metron-parsers-storm). This means that we are typically going to be running, for now, off of metron-parsers-storm jars.

Nothing changes in Ambari, because there's no actual second platform we're running on. In the future, I'd say we need to make some sort of configuration around this, but I'm fine with that being follow-on whenever we choose to build off of something other than Storm.

This also adjusts some of the integration tests, so that it's easier to extend to a new platform once we add something beyond Storm. The current solution would involve a class for every parser for every platform, which seems awful. The new solution uses a parameterized test, and simply one extended class that's platform specific. Let me know thoughts on this and if we want to refactor this differently.

The commit history is a little wonky, since this started based on his PR before it made it into master and there was a variety of merging happening there. The commits from @merrimanr are from that branch, not coauthored here. I'm a bit surprised git didn't handle it properly, but it won't matter once squashed.

Pull Request Checklist

Thank you for submitting a contribution to Apache Metron.
Please refer to our Development Guidelines for the complete guide to follow for contributions.
Please refer also to our Build Verification Guidelines for complete smoke testing guides.

In order to streamline the review of the contribution we ask you follow these guidelines and ask you to double check the following:

For all changes:

  • Is there a JIRA ticket associated with this PR? If not one needs to be created at Metron Jira.
  • Does your PR title start with METRON-XXXX where XXXX is the JIRA number you are trying to resolve? Pay particular attention to the hyphen "-" character.
  • Has your PR been rebased against the latest commit within the target branch (typically master)?

For code changes:

  • Have you included steps to reproduce the behavior or problem that is being changed or addressed?

  • Have you included steps or a guide to how the change may be verified and tested manually?

  • Have you ensured that the full suite of tests and checks have been executed in the root metron folder via:

    mvn -q clean integration-test install && dev-utilities/build-utils/verify_licenses.sh 
    
  • Have you written or updated unit tests and or integration tests to verify your changes?

  • If adding new dependencies to the code, are these dependencies licensed in a way that is compatible for inclusion under ASF 2.0?

  • Have you verified the basic functionality of the build by building and running locally with Vagrant full-dev environment or the equivalent?

For documentation related changes:

  • Have you ensured that format looks appropriate for the output in which it is rendered by building and verifying the site-book? If not then run the following commands and the verify changes via site-book/target/site/index.html:

    cd site-book
    mvn site
    

Note:

Please ensure that once the PR is submitted, you check travis-ci for build issues and submit an update to your PR as soon as possible.
It is also recommended that travis-ci is set up for your personal repository such that your branches are built there before submitting a pull request.

merrimanr and others added 28 commits September 26, 2018 11:04
# Conflicts:
#	metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/bolt/ParserBolt.java
#	metron-platform/metron-parsers/src/test/java/org/apache/metron/parsers/bolt/ParserBoltTest.java
# Conflicts:
#	metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/bolt/ParserBolt.java
#	metron-platform/metron-parsers/src/test/java/org/apache/metron/parsers/bolt/ParserBoltTest.java
@ottobackwards
Copy link
Copy Markdown
Contributor

Can we talk about the directory structure and packaging?
I think

.
└── metron-ingest
    ├── metron-ingest-common
    ├── metron-ingest-storm
    ├── metron-parsers
    └── metron-parsers-common

Might be worth thinking about.

we can have metron-injest-FOO later

@justinleet
Copy link
Copy Markdown
Contributor Author

@ottobackwards I'm not sure what you mean by ingest here? In my head "ingest" is just getting data into Kafka before the parsers (and really Metron as a whole) is involved. Could you expand a bit on what you would want each of those projects to actually contain?

I'm not opposed to organizing things a bit differently, to avoid exploding things out too much if we add other platforms (especially since it's really not hard to adjust this PR as needed), but I would have expected something more like

.
└── metron-parsers
    ├── metron-parsers-common
    └── metron-parsers-storm

@ottobackwards
Copy link
Copy Markdown
Contributor

wait, you don't have a plan??? lol. nm. just wondering. I have some old things around this, maybe I'll follow on.

@nickwallen
Copy link
Copy Markdown
Contributor

Sorry to beat a dead horse, but I was giving this a once over and saw metron-parsing-framework-storm. Could we go with the more concise metron-parsing-storm?

I'd prefer this because it matches what we already have in the Profiler; metron-profiler-common, metron-profiler-spark, metron-profiler-storm, metron-profiler-repl. I'd like to keep the same convention for naming projects.

We've already decided that the wordsparsing and parsers are different enough to denote the differences between the projects. I don't see any new information being conveyed by the word 'framework'. IMHO.

@mmiklavc
Copy link
Copy Markdown
Contributor

@justinleet @nickwallen - Doesn't matter to me either way. But again, regardless of what you do, please just add/create an appropriate description to each pom description element, provide a sensible name, and add something in the module's README to briefly describe what the project does and what belongs there.

@justinleet
Copy link
Copy Markdown
Contributor Author

@ottobackwards Do you have a preference on this? I really don't care at all.

@ottobackwards
Copy link
Copy Markdown
Contributor

Let's go with what @nickwallen said

@justinleet
Copy link
Copy Markdown
Contributor Author

kick travis

@justinleet justinleet closed this Nov 29, 2018
@justinleet justinleet reopened this Nov 29, 2018
@ottobackwards
Copy link
Copy Markdown
Contributor

can we de-conflict and get this going in?

@justinleet
Copy link
Copy Markdown
Contributor Author

@ottobackwards Deconflicted and should be good for review.

@ottobackwards
Copy link
Copy Markdown
Contributor

+1, pending travis. Great job

@justinleet
Copy link
Copy Markdown
Contributor Author

Looks like Travis died during the caching phase, post integration-test. I might need to dig in a bit more to figure out exactly what's going on here.

Relevant output

[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 26:21 min
[INFO] Finished at: 2018-12-18T15:15:37+00:00
[INFO] Final Memory: 76M/683M
[INFO] ------------------------------------------------------------------------

real 26m23.861s
user 12m38.036s
sys 0m51.080s
travis_time:end:11aa66e0:start=1545144553740350075,finish=1545146137613054166,duration=1583872704091
[0K[32;1mThe command "time $SCRIPT" exited with 0.[0m

travis_fold:start:before_cache
[0Ktravis_time:start:1113d54c
[0K$ rm -rf $HOME/.m2/repository/org/apache/metron
travis_time:end:1113d54c:start=1545146137622595527,finish=1545146137813611265,duration=191015738
[0Ktravis_fold:end:before_cache
[0Ktravis_fold:start:cache.2
[0Kstore build cache
travis_time:start:247437bc
[0Ktravis_time:end:247437bc:start=1545146137831691904,finish=1545146137837034903,duration=5342999
[0Ktravis_time:start:12526b9d
[0K[32;1mchange detected (content changed, file is created, or file is deleted):
/home/travis/build/apache/metron/metron-interface/metron-config/node_modules/.cache/uglifyjs-webpack-plugin/index-v5/21/f6/0fabf74b7a7527c88da5f5c22e6224556784e6dcb76cb2ed63c4cb47e493
/home/travis/build/apache/metron/metron-interface/metron-config/node_modules/.cache/uglifyjs-webpack-plugin/index-v5/2f/b3/2331169e1723d16b00d3c110dd78ace2dfc7ae89f9a0bd92d732ba65838f
/home/travis/build/apache/metron/metron-interface/metron-config/node_modules/.cache/uglifyjs-webpack-plugin/index-v5/38/56/4eabdf5594773ec1e768b5aa0272ba01e446f37bdf6e1364b63d71e2fde3
/home/travis/build/apache/metron/metron-interface/metron-config/node_modules/.cache/uglifyjs-webpack-plugin/index-v5/96/00/58b5622d2ca36854203ec70f4f4c9f61cec4143a7a556a607dab25d35ab6
/home/travis/build/apache/metron/metron-interface/metron-config/node_modules/.cache/uglifyjs-webpack-plugin/index-v5/9b/97/6caa7bc649793ea920dd9d528d7b83e373ce7c95fdb4f06f587aeac9b9a1
/home/travis/build/apache/metron/metron-interface/metron-config/node_modules/.cac
[0m
[32;1m...
[0m
[32;1mchanges detected, packing new archive[0m
.
.
.
.
.
.
.
.
.
.
.
.
[32;1muploading PR.1249/cache-linux-trusty-2b04eefc8144ad31797ee1ddbd17b2d210716f70ff4125c63c90506b2133c6d8--jdk-oraclejdk8.tgz[0m

The job exceeded the maximum time limit for jobs, and has been terminated.

@justinleet
Copy link
Copy Markdown
Contributor Author

kick travis

@justinleet justinleet closed this Dec 18, 2018
@justinleet justinleet reopened this Dec 18, 2018
@justinleet
Copy link
Copy Markdown
Contributor Author

@ottobackwards Kicking Travis seemed to solve the problem. I'm a bit concerned about how long the caching took, but I don't see any reason this PR would cause that effect. Are you good with this going in based on this last run?

@mmiklavc Is there anything else you want to see from this?

@mmiklavc
Copy link
Copy Markdown
Contributor

@justinleet I'm +1 as well. Thanks for tackling this!

@justinleet
Copy link
Copy Markdown
Contributor Author

https://issues.apache.org/jira/browse/METRON-1942 created for the build failure itself

@ottobackwards
Copy link
Copy Markdown
Contributor

+1 all set

@asfgit asfgit closed this in d7d4fd9 Dec 19, 2018
@mmiklavc
Copy link
Copy Markdown
Contributor

When I merged this PR into master we had another unrelated build failure from Cypress. Providing the link here in comments for context if this comes up again.

https://issues.apache.org/jira/browse/METRON-1946

JonZeolla pushed a commit to JonZeolla/metron that referenced this pull request Jan 24, 2019
…etron-parsers-storm (justinleet via mmiklavc) closes apache#1249
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants