Skip to content

Update build scripts to support downloading ES >= 6.3 #799

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

Merged
merged 8 commits into from
Oct 17, 2018

Conversation

robbavey
Copy link
Contributor

@robbavey robbavey commented Oct 4, 2018

Update travis build target
Update artifact downloads to pull oss and standard versions of
Elasticsearch when version >= 6.3.0
Fixes tests to actually run secure integration tests
Updates version of gradle used to build master version of Elasticsearch
Fixes flaky tests

Update travis build target
Update artifact downloads to pull oss and standard versions of
 Elasticsearch when version >= 6.3.0
.travis.yml Outdated
@@ -8,9 +8,13 @@ env:
- INTEGRATION=true ES_VERSION=2.4.4 TEST_DEBUG=true
- INTEGRATION=true ES_VERSION=5.6.9 TEST_DEBUG=true
- INTEGRATION=true ES_VERSION=6.2.4 TEST_DEBUG=true
- OSS=true INTEGRATION=true ES_VERSION=6.4.2 TEST_DEBUG=true
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what if we instead only tested against the latest 2.x, 5.x, 6.x and master?
This way we only need to install x-pack on 5.x

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jsvd Makes sense - I wasn't sure if there was any value in keeping around the last version of 6.x before x-pack was opened up, but I think you're right that there isn't really.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also, taking it a bit further, I see no obvious value of testing OSS=true, when it is a subset of OSS=false, thoughts?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I've still got a little clean up to do here - not quite ready for formal review. Early PR was to get tests running on Travis in case that I might have missed locally.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But thanks for the early feedback ;)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ahahaha "go away", got it :D

Adds a DISTRIBUTION environment variable, which can be:
  legacy: OSS < 6.3
  legacyxpack: < 6.3 with xpack plugin
  oss: OSS >= 6.3
  default: standard distribution >= 6.3

Removes the exclusion filter for `secure_integration` - this was stopping
  secure integration tests from running even with tags on
Updates logstash branch to 6.4
Later versions of Elasticsearch require a later version of Gradle
in order to build
Build the client, and set the mocks on that client before calling
register to avoid race conditions
@elasticsearch-bot elasticsearch-bot self-assigned this Oct 17, 2018
- DISTRIBUTION=legacy INTEGRATION=true ES_VERSION=1.7.6 TEST_DEBUG=true
- DISTRIBUTION=legacy INTEGRATION=true ES_VERSION=2.4.4 TEST_DEBUG=true
- DISTRIBUTION=legacy INTEGRATION=true ES_VERSION=5.6.9 TEST_DEBUG=true
- DISTRIBUTION=oss INTEGRATION=true ES_VERSION=6.4.2 TEST_DEBUG=true
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we removed oss testing (only testing the default package) then we could likely get rid of the whole DISTRIBUTION environment variable, since

  • legacy means < 6.3.0
  • legacyxpack means < 6.3.0 + xpack (which we know we need because of SECURE_INTEGRATION=true)
  • default >= 6.3.0

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wanted to have the OSS testing for ILM when it comes - as it is an xpack feature, there will be different tests for open source and xpack flavours of elasticsearch

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

testing the oss won't give us more information as it's a subset of the codebase of the default distro

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oops, I only now read your comment, got it, makes sense.

Copy link
Member

@jsvd jsvd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, please squash before/during merging.

In a near future it'd be nice to improve how testing is done in travis by not using the logstash source, only the tarball (or docker image), and separating the setup part and running tests part, like we do in tcp input: https://github.com/logstash-plugins/logstash-input-tcp/blob/master/.travis.yml#L7-L8

@robbavey
Copy link
Contributor Author

Thanks @jsvd. I'll do a follow up PR to fix up the rest to make it look more like the tcp input

@robbavey robbavey merged commit 5610dd7 into logstash-plugins:master Oct 17, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants