Skip to content
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

Recover geoip.region_iso_code field in test expectations #8204

Merged
merged 2 commits into from
Sep 5, 2018

Conversation

jsoriano
Copy link
Member

@jsoriano jsoriano commented Sep 3, 2018

This field appears on ES 6.5.X

This reverts part of commit e229852.

This field appears on ES 6.5.X

This reverts part of commit e229852.
@jsoriano jsoriano force-pushed the region-iso-fields-6.5 branch from 668cd7d to 3f2c4e3 Compare September 3, 2018 17:22
@jsoriano jsoriano changed the title Recover geoip.region_iso_code fiend in test expectations Recover geoip.region_iso_code field in test expectations Sep 3, 2018
Copy link
Contributor

@exekias exekias left a comment

Choose a reason for hiding this comment

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

LGTM, I guess we should see green on these tests

@jsoriano
Copy link
Member Author

jsoriano commented Sep 3, 2018

jenkins, test this again

@jsoriano
Copy link
Member Author

jsoriano commented Sep 3, 2018

Tests fixed in travis, affected tests also passed on jenkins but other things failed, I think they are unrelated but lets wait for another run.

@jsoriano
Copy link
Member Author

jsoriano commented Sep 4, 2018

"Fixed" tests failed now in jenkins, @ruflin do you know if it is possible that different geoip plugin versions are used in jenkins and travis? Maybe we need to do these tests less strict with the comparison of objects.

@ruflin
Copy link
Contributor

ruflin commented Sep 4, 2018

It could be that a different "snapshot" of Elasticsearch is used and we have to invalidate the cache in Jenkins. I thought it does it checks automatically every time because we use the --pull flag.

What happens if you run it locally?

@jsoriano
Copy link
Member Author

jsoriano commented Sep 4, 2018

Locally it works, it also worked on travis, and it seemed to work in the first jenkins build too.

@jsoriano
Copy link
Member Author

jsoriano commented Sep 4, 2018

I'm worried that this kind of plugins that inject fields could make us to need to revisit these checks from time to time, what about completely ignoring the geoip fields for this test?

@jsoriano jsoriano force-pushed the region-iso-fields-6.5 branch 2 times, most recently from 2e7b7cb to cc0f27e Compare September 4, 2018 09:56
@jsoriano
Copy link
Member Author

jsoriano commented Sep 4, 2018

I have added a whitelist for fields that may change, though the geoip fields could be placed on any target field that doesn't need to contain geoip, so I'm not sure of this change.
If accepted with the whitelist this should be merged also in master.

Opinions?

@ruflin
Copy link
Contributor

ruflin commented Sep 4, 2018

I think there are 2 parts here:

  • Validating that the fields are there
  • Checking if the fields are identical

I agree that the identical part is not optimal for geoip to run tests on as it might change over time. At the same time I think we should check that the fields are there and if some are added / removed we should know as it could be that our dashboards rely on it.

Could we modify it that for the whitelist fields we don't do a comparison but still a check if they are there?

If it was working first and then stopped working I would assume it's a different jenkins worker and they have different versions of the docker image.

@jsoriano
Copy link
Member Author

jsoriano commented Sep 4, 2018

I agree that the identical part is not optimal for geoip to run tests on as it might change over time. At the same time I think we should check that the fields are there and if some are added / removed we should know as it could be that our dashboards rely on it.

Good point on dashboards.

Could we modify it that for the whitelist fields we don't do a comparison but still a check if they are there?

In the case of geoip.region_iso_code it wouldn't be enough, as the problem was that in some versions it was present and in others it wasn't.

I'm going to try to make it work as it was before, without the whitelist thing, this hasn't been so problematic till now, and I can open another PR to discuss how to do the separation of checking equality and validating that fields are there.

@jsoriano jsoriano force-pushed the region-iso-fields-6.5 branch from cc0f27e to 3f2c4e3 Compare September 4, 2018 14:00
@jsoriano jsoriano force-pushed the region-iso-fields-6.5 branch from 143c439 to 45b31e6 Compare September 4, 2018 14:59
@jsoriano
Copy link
Member Author

jsoriano commented Sep 4, 2018

Affected test passed after adding an explicit pull.

@jsoriano
Copy link
Member Author

jsoriano commented Sep 4, 2018

jenkins, test this again

Copy link
Contributor

@ruflin ruflin left a comment

Choose a reason for hiding this comment

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

Should we forward port this change?

@jsoriano
Copy link
Member Author

jsoriano commented Sep 5, 2018

Yes, I will open a PR to master with the second commit here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants