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

Package ingest-geoip as a module #36898

Merged
merged 11 commits into from
Dec 22, 2018

Conversation

jasontedor
Copy link
Member

This commit moves ingest-geoip from being a plugin to being a module that is packaged with Elasticsearch distributions.

This commit moves ingest-geoip from being a plugin to being a module
that is packaged with Elasticsearch distributions.
@jasontedor jasontedor added >enhancement >breaking :Delivery/Packaging RPM and deb packaging, tar and zip archives, shell and batch scripts :Data Management/Ingest Node Execution or management of Ingest Pipelines including GeoIP v7.0.0 v6.7.0 labels Dec 20, 2018
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra

@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-features

@@ -222,6 +222,10 @@ void execute(Terminal terminal, String pluginId, boolean isBatch, Environment en
throw new UserException(ExitCodes.USAGE, "plugin id is required");
}

if ("ingest-geoip".equals(pluginId)) {
Copy link
Member Author

Choose a reason for hiding this comment

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

This change will be backported to 6.x to avoid breaking users there, and a note will be added to the migration guide. A follow-up will remove this handling in master so that 7.x will indeed report the usual error message.

@@ -231,6 +235,12 @@ void execute(Terminal terminal, String pluginId, boolean isBatch, Environment en
install(terminal, isBatch, extractedZip, env);
}

private static void handleInstallIngestGeoIp() throws UserException {
throw new UserException(
ExitCodes.OK,
Copy link
Member Author

Choose a reason for hiding this comment

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

This is deliberately status code zero so as to avoid failing automation that relies on installing this plugin during deployment.

Copy link
Member

@rjernst rjernst left a comment

Choose a reason for hiding this comment

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

Looks good but one question

@@ -84,6 +84,12 @@ void execute(Terminal terminal, Environment env, String pluginName, boolean purg
throw new UserException(ExitCodes.USAGE, "plugin name is required");
}

if ("ingest-geoip".equals(pluginName)) {
Copy link
Member

Choose a reason for hiding this comment

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

Don't they still need to be able to remove? What if they upgrade before removing the old plugin, then without the remove command working it would have to be done manually to avoid errors later?

Copy link
Member Author

Choose a reason for hiding this comment

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

Good call @rjernst. I pushed a commit to address this. Let me know what you think.

Copy link
Member

@rjernst rjernst left a comment

Choose a reason for hiding this comment

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

LGTM

e,
hasToString(Matchers.containsString(
"ingest-geoip is no longer a plugin but instead a module packaged with this distribution 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.

Can you please add a test here for the case the plugin is installed and it still gets removed?

Copy link
Member Author

Choose a reason for hiding this comment

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

I pushed 503b055.

Copy link
Member

@martijnvg martijnvg left a comment

Choose a reason for hiding this comment

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

👍

Copy link
Contributor

@jakelandis jakelandis left a comment

Choose a reason for hiding this comment

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

LGTM

@jasontedor
Copy link
Member Author

jasontedor commented Dec 21, 2018

Relates #36949

* master: (31 commits)
  Move ingest-geoip default databases out of config (elastic#36949)
  [ILM][DOCS] add extra scenario to policy update docs (elastic#36871)
  [Painless] Add String Casting Tests (elastic#36945)
  SQL: documentation improvements and updates (elastic#36918)
  [DOCS] Merges list of discovery and cluster formation settings (elastic#36909)
  Only compress responses if request was compressed (elastic#36867)
  Remove duplicate paragraph (elastic#36942)
  Fix URI to cluster stats endpoint on specific nodes (elastic#36784)
  Fix typo in unitTest task (elastic#36930)
  RecoveryMonitor#lastSeenAccessTime should be volatile (elastic#36781)
  [CCR] Add `ccr.auto_follow_coordinator.wait_for_timeout` setting (elastic#36714)
  Scripting: Remove deprecated params.ctx (elastic#36848)
  Refactor the REST actions to clarify what endpoints are deprecated. (elastic#36869)
  Add JDK 12 to CI rotation (elastic#36915)
  Improve error message for 6.x style realm settings (elastic#36876)
  Send clear session as routable remote request (elastic#36805)
  [DOCS] Remove redundant ILM attributes (elastic#36808)
  SQL: Fix bug regarding histograms usage in scripting (elastic#36866)
  Update index mappings when ccr restore complete (elastic#36879)
  Docs: Bump version to alpha2 after release
  ...
@jasontedor jasontedor merged commit e1717df into elastic:master Dec 22, 2018
jasontedor added a commit that referenced this pull request Dec 22, 2018
This commit moves ingest-geoip from being a plugin to being a module
that is packaged with Elasticsearch distributions.
@jasontedor jasontedor deleted the package-ingest-geoip-as-a-module branch December 22, 2018 12:33
@jasontedor
Copy link
Member Author

Thank you for reviewing @jakelandis, @martijnvg, and @rjernst!

@jimczi jimczi added v7.0.0-beta1 and removed v7.0.0 labels Feb 7, 2019
@danielmitterdorfer danielmitterdorfer removed the :Data Management/Ingest Node Execution or management of Ingest Pipelines including GeoIP label Feb 8, 2019
@mark-vieira mark-vieira added the Team:Delivery Meta label for Delivery team label Nov 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>breaking :Delivery/Packaging RPM and deb packaging, tar and zip archives, shell and batch scripts >enhancement Team:Delivery Meta label for Delivery team v6.7.0 v7.0.0-beta1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants