elastic / logstash

Logstash - transport and process your logs, events, or other data
https://www.elastic.co/products/logstash
Other
65 stars 3.5k forks source link

[meta] defaults plugins migration to new Event interface and plugin-api 2.0 #5227

Closed colinsurprenant closed 8 years ago

colinsurprenant commented 8 years ago

This is a meta issue to track progress for refactoring the defaults plugins. Core plugins migration has been completed per #5170. Related #5140.

This migration recipe goals are:

@ph has added this ruby script to automate much of the initial work: https://gist.github.com/e28dddccfbe32c3985ab51d6f9b9ec41

Plugins for core specs

ph commented 8 years ago

We can automate all of the heavy work minus the actual code/spec? Are we fine doing that?

suyograo commented 8 years ago

@ph +1 for automating..

colinsurprenant commented 8 years ago

it might be tricky to automate the addition of dependent plugins from the gemspec but the basic block

# this is temporary for the feature/plugin-api-2_0 branch and is meant for travis testing
gem "logstash-core", :path => "./logstash/logstash-core"
gem "logstash-core-plugin-api", :path => "./logstash/logstash-core-plugin-api"
gem "logstash-core-event-java", :path => "./logstash/logstash-core-event-java"
gem "logstash-devutils", :github => "elastic/logstash-devutils", :branch => "feature/plugin-api-2_0"

can be easily automated

colinsurprenant commented 8 years ago

also I've seen a bit different .travis.yml, with the integration tests flag?

suyograo commented 8 years ago

Btw, all plugins should have the integration flag set if its not already there..

colinsurprenant commented 8 years ago

I added the list of plugins done so far for passing core specs.

ph commented 8 years ago

@suyograo logstash-codec-oldlogstashjson is marked as completed but I can't find the PR.

suyograo commented 8 years ago

Here's the merge plan:

colinsurprenant commented 8 years ago

@suyograo

suyograo commented 8 years ago

@colinsurprenant updated.

colinsurprenant commented 8 years ago

@suyograo @ph also, .travis.yml should not be updated to old state, we certainly want to keep the Java 8 selection?

colinsurprenant commented 8 years ago

@suyograo @ph core-api-v1 (not v2) branch for LS 2.x development.

ph commented 8 years ago

@colinsurprenant We already have v1, it was before the shutdown change, and used to target LS 1.5?

colinsurprenant commented 8 years ago

@ph how is that possible? we only recently introduced the plugin-core-api gem recently ah yes, ok, I think I remember - it's core-api, we need to create plugin-api-v1

suyograo commented 8 years ago

@colinsurprenant core-api-v1 branch already exists and was created to continue development of plugins under v1 core API (pre shutdown changes, < LS 2.0). core-api-v2 once branched will match v2 of plugin APIs and continue development for them (pre Java Event, < LS 2.0).

Also, here is a .travis.yml we can mass update with: https://gist.github.com/suyograo/331f6384e143b147c09db51a854540c4

Includes Java 8 and --integration tags

ph commented 8 years ago

Also, here is a .travis.yml we can mass update with: https://gist.github.com/suyograo/331f6384e143b147c09db51a854540c4

I am not sure we should mass update with the bundle exec rspec --tag integration, since integration usually mean that we need to add some steps in the travis file to make sure the environment is ready to be used for integration testing. Like installing redis, rabbitmq or supporting libraries.

But this could be a good way to find which plugins are failling and change their travis.yml manually.

@colinsurprenant @suyograo core-api-v2 I agree is a weird name, another option would be to make it explicit and rename them logstash-1.5.x and logstash-2.x ;)

ph commented 8 years ago

@suyograo After discussing on slack zoom I am ok to move ahead with the core-api-v2, its only a branch name, if we change our mind in the future we can always rename it/them.

@colinsurprenant Can we move forward?

colinsurprenant commented 8 years ago

@ph @suyograo it is still confused.

For this I suggest we simply leave the core-api-v1 branch name as-is, for legacy reasons, which anyway will not be needed anymore, and introduce branches with the plugin-api name and versions.

suyograo commented 8 years ago

For this I suggest we simply leave the core-api-v1 branch name as-is, for legacy reasons, which anyway will not be needed anymore, and introduce branches with the plugin-api name and versions.

@colinsurprenant @ph I am fine with naming the branch based on plugin API version. Good with plugin-api-v1

colinsurprenant commented 8 years ago

@suyograo, @ph and myself just reviewed the tasks sequence and Houston, all engines go!