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

Remove ruby execution engine #12517

Merged
merged 3 commits into from
Dec 15, 2020
Merged

Remove ruby execution engine #12517

merged 3 commits into from
Dec 15, 2020

Conversation

kaisecheng
Copy link
Contributor

@kaisecheng kaisecheng commented Dec 14, 2020

Fixed: #11236

This PR removes the Ruby Execution Engine
The Java Execution Engine has been the default engine since Logstash 7.0, and is capable of using plugins written in either Ruby or Java; removing the Ruby Execution Engine will not affect our ability to run existing pipelines, but will greatly reduce the surface area of all features and fixes within the engine(s). We will no longer need to target two engines simultaneously.

Ruby execution engine uses Treetop to parse Logstash config files and convert them to executable code which is being referenced by Java pipeline, so Treetop stays in the project.

  • remove Logstash::Pipeline
  • rewrite test cases which depend on ruby pipeline
  • remove logstash/event, Logstash::SignalEvent
  • remove Engine.Ruby on java side
  • remove config pipeline.java_execution

This PR will split into three smaller to feature branch for review
#12496 remove Logstash::Pipeline, Engine.Ruby, rewrite test cases
#12505 remove Logstash::SignalEvent
#12506 remove config pipeline.java_execution

A follow up will be removing logstash/pipeline in logstash-devutils

Fix Logstash::SHUTDOWN event dependency

* remove Logstash::Pipeline
* remove Engine.Ruby
* rewrite test cases which depend on ruby pipeline
Fixed: #11236
* remove config pipeline.java_execution
* remove ruby engine doc
Fixed: #11236
@kaisecheng kaisecheng mentioned this pull request Dec 14, 2020
9 tasks
@kaisecheng kaisecheng requested a review from andsel December 14, 2020 15:56
Copy link
Contributor

@andsel andsel left a comment

Choose a reason for hiding this comment

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

I think the commits should be squashed, LGTM

@kaisecheng kaisecheng merged commit 4bc9dad into master Dec 15, 2020
# for backward compatibility
# logstash-devutils-1.3.6 logstash_helpers has dependency on this class
module LogStash
class Pipeline
Copy link
Contributor

@kares kares Dec 21, 2020

Choose a reason for hiding this comment

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

NOTE: any plugin doing require 'logstash/pipeline' (e.g. in specs) will be broken by this.
Wonder if it was considered to have this file around as:

require 'logstash/java_pipeline'
module LogStash
  Pipeline = JavaPipeline
end

Seems an implementation detail whether require 'logstash/java_pipeline' gets required,
unless there's a strong need to break old users of require 'logstash/pipeline'

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is a nice suggestion. I was thinking to remove everything completely including the plugins.

@@ -101,10 +101,6 @@ With this command, Logstash concatenates three config files, `/tmp/one`, `/tmp/t
If you wish to use both defaults, please use the empty string for the `-e` flag.
The default is nil.

*`--java-execution`*::
Copy link
Member

Choose a reason for hiding this comment

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

Latergram:

I think we can do to make this transition easier for our users, especially for those who opt for explicit configuration or who control their configuration with environment variables.

  • 7.x: the false value for --java-execution or java.execution is deprecated. We emit a deprecation log that REE is deprecated and will be removed in "a future major release of Logstash". To solve this deprecation warning, the user can either remove the flag or set its value to true.
  • 8.x: the --java-execution or java.execution option itself is deprecated, and only accepts the true value. When this is specified, we emit a deprecation log about the option being removed in "a future major release of Logstash"

The primary goal that this path accomplishes is that explicit configuration from Logstash 7.$last that contains no deprecations works without modification in 8.0.0. It allows our users to be explicit in their configuration of 7.x and does not require an intermediate step where they are required to remove settings from their config that are meaningful in Logstash 7 prior to upgrading to Logstash 8.

The other transition option is to fast-track the removal of the setting, but I think that may be less clear to the user.

  • 7.x: the --java-execution or java.execution option itself is deprecated.
    • When this option is specified as true, we emit a deprecation log indicating that it is not needed and the option will be removed in "a future major release of Logstash".
    • When the option is specified as false, we emit a different deprecation log indicating that both REE and the option will be removed in "a future major release of Logstash".

Note that the fast-track will make environment variable control of the config file not possible.

yaauie added a commit to yaauie/logstash that referenced this pull request Oct 19, 2021
@yaauie yaauie mentioned this pull request Oct 19, 2021
2 tasks
yaauie added a commit to yaauie/logstash that referenced this pull request Oct 19, 2021
yaauie added a commit to yaauie/logstash that referenced this pull request Oct 19, 2021
yaauie added a commit that referenced this pull request Oct 19, 2021
* ecs: remove warning when opting-in per-pipeline or globally

* ecs: align with v8 for version after v1

* add deprecation warning for Ruby Execution, removed in #12517
@yaauie yaauie mentioned this pull request Sep 21, 2022
3 tasks
@jsvd jsvd deleted the remove-ruby-execution-engine branch June 2, 2023 12:14
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.

remove ruby execution
4 participants