nickwallen opened a new pull request #1522: METRON-2271 Reorganize Travis Builds
URL: https://github.com/apache/metron/pull/1522
 
 
   We are increasingly hitting the 50 minute time limit on our integration test 
job in Travis.  This 
    causes the entire Travis build to fail.  My goal here is to make minor 
modifications to avoid these failures until we can come back for a more 
comprehensive review of our integration tests to address the issue of total run 
time.
   
   ### Background
   
   The way in which we organize the Travis build currently causes each job to 
build *all* of Metron, *every* time.  Although we attempt to cache the local 
Maven repository to avoid repetitively building Metron, in practice all of the 
jobs in a build start roughly in parallel and so this cache is never used.  The 
result is that every job builds all of Metron. 
   
   As evidence review how long it takes for the license verification job to 
complete.  While this should take a few seconds/minutes, this always takes 15+ 
minutes because the job does a full build of Metron.  It is never able to 
re-use what was built and cached by any other job.
   
   ### Solution
   
   By reorganizing the build, so that each job only builds the modules that it 
needs (and avoid a one-size-fits-all "install" step) we save enough time to 
avoid breaching the 50 minute time limit on any individual job.  In addition, I 
added names to each job to improve clarity in the Travis UI and split out the 
the UI tests so that the Alerts and Management tests run separately.
   
   These are the advantages that I see with this change.
   
   1. This will prevent us from unnecessarily breaching the 50 minute time 
limit for the integration test job with minimal effort or risk as compared to 
re-architecting the integration tests.
   
   1. We get more immediate feedback. If you messed up the licenses, you're 
going to know in a minute, rather than after 20 minutes.
   
   1. We have a much more accurate picture of how long each step is taking.  
Previously the site-book appeared to take 16-18 minutes, but it is now very 
clear that it takes 1-2 minutes.
   
   1. The total aggregate run time was previously 2.25-2.5 hours, but is now 
about 1.5 hours.  This is less load on Travis and we like Travis, so let's help 
him out.
   
   
   See https://travis-ci.org/nickwallen/metron/builds/592235729 to see how this 
looks in Travis.
   
   ## Pull Request Checklist
   
   Thank you for submitting a contribution to Apache Metron.  
   Please refer to our [Development 
Guidelines](https://cwiki.apache.org/confluence/pages/viewpage.action?pageId=61332235)
 for the complete guide to follow for contributions.  
   Please refer also to our [Build Verification 
Guidelines](https://cwiki.apache.org/confluence/display/METRON/Verifying+Builds?show-miniview)
 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](https://issues.apache.org/jira/browse/METRON/?selectedTab=com.atlassian.jira.jira-projects-plugin:summary-panel).
   - [ ] 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](http://www.apache.org/legal/resolved.html#category-a)?
   - [ ] 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
     ```
   
   - [ ] Have you ensured that any documentation diagrams have been updated, 
along with their source files, using [draw.io](https://www.draw.io/)? See 
[Metron Development 
Guidelines](https://cwiki.apache.org/confluence/display/METRON/Development+Guidelines)
 for instructions.
   
   #### 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](https://travis-ci.org) is set up for 
your personal repository such that your branches are built there before 
submitting a pull request.
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to