Commit graph

181 commits

Author SHA1 Message Date
Joao Duarte
c4e505853e make dissect filter a default plugin
Fixes #6729 Fixes #6629
2017-02-18 11:55:12 -08:00
Jordan Sissel
3d5b7eca51 Pin minitar. Works around https://github.com/halostatue/minitar/issues/23
Fixes #6659
2017-02-07 19:40:01 -05:00
Colin Surprenant
193022c97b exclusive file locking class and tests
use new bin/ruby and bundler without :development

refactor to DRY and use expected exception

added original Apache 2.0 license and some cosmetics

exclude bin/lock from packaging

rename variables
2017-01-31 13:50:24 -05:00
Suyog Rao
2eb8b661ba Generate notice file during artifact build (#6538)
* Generate notice file during artifact build

Adjust our existing NOTICE.txt file to be built every time. This ensures
we collect LICENSE and NOTICE information of all bundled Logstash and non-Logstash
dependencies.

Changes:

* if NOTICE file is present in gems, include that text in our own NOTICE.TXT file.
* we also need to include the whole copyright block in NOTICE (meaning copyright + license)
2017-01-16 10:10:18 -08:00
Suyog Rao
fedcd9a171 Build queue along with other gems
Fixes #6473
2017-01-03 14:04:00 -05:00
Pier-Hugues Pellerin
e1b7583545 Allow rake version:set to update the logstash-core-queue-jruby gem 2016-12-08 14:32:46 -05:00
Jordan Sissel
4f6d9d1c86 Add comment referring to another research effort
Fixes #6276
2016-12-06 13:17:36 -05:00
Pier-Hugues Pellerin
fe8c438b24 Logstash-docgen tool v2
**Motivation**: We have decided to rewrite the documentation generator to add more features
to our documentation and to fix some outstanding bugs.

This PR addresses the following problem:
- Hard to add new features to the code base.
- The code was tied with Logstash.
- No easy way to publish the doc for a single plugin
- The plugin author was not able to test their documentation changes
- The reported errors were hard to understand.
- No easy way to automate it.
- the minimal requirement on base classes.

Fixes #5720
2016-11-30 19:57:40 -05:00
Suyog Rao
e2c84056a0 Add cef codec to default plugins
Fixes #6270
2016-11-17 13:26:47 -05:00
Colin Surprenant
ab05082a89 merge feature/java_persistence into 5.x 2016-10-31 17:03:40 -04:00
Suyog Rao
6c4fed1154 Remove logrotate completely
Fixes #5903
2016-09-13 19:39:28 -04:00
Suyog Rao
b7846a1f11 use the right props file
Fixes #5903
2016-09-13 19:39:28 -04:00
Suyog Rao
e2d2977870 add package specific log4j2 logging props
Fixes #5894

Fixes #5903
2016-09-13 19:39:27 -04:00
Suyog Rao
254297eec7 [5.x] Bump version to 5.1.0 (#5881)
* [5.x] Bump version to 5.1.0
2016-09-08 08:35:53 -07:00
Tal Levy
b545b83390 Migrate Logstash to Log4j2 Logging (#5651)
Migrate to use Log4j2 for Logstash logging
2016-08-26 18:11:22 +00:00
Pere Urbón
2c25592fd5 add bin/rspec and bin/rspec.bat to the packaging exclude list (#5667) 2016-08-24 09:54:32 +01:00
Pier-Hugues Pellerin
23e87bc44f Remove spec/integration
With the addition of the qa acceptance test suite we have decide that we
don't need to maintain this suite also since the acceptance test are
running really similar test.

Fixes: #5744

Fixes #5760
2016-08-14 15:09:29 -04:00
Pere Urbon-Bayes
eb0075daf9 remove jms from skip list
Fixes #5555
2016-06-28 04:59:26 -04:00
Joao Duarte
c03c5523a3 add data.path setting
Fixes #5528
2016-06-24 07:32:25 -04:00
Joao Duarte
0313712a37 avoid using duplicate logstash.yml for rpm/deb
Fixes #5537
2016-06-22 14:10:18 -04:00
Joao Duarte
fa0eeb579f add single command release task and other release support tooling
Purpose:

* manage releases through a minimum number of rake tasks
* simplify building of snapshot builds
* create staged artifacts, candidates for releases, that required no changes to become releases
* this means the snapshot release process will not involve publishing gems, therefore:
* the gem artifacts should only be published to rubygems as a final artifact, at the time of GA

Changes:

* release artifacts no longer depend on gems of core components
* all core components are used locally AS-IS to minimize code changes between snapshot, RC and GA
* `versions.yml` describes the versions of all logstash parts and package
  * `rake version:set[version]` manage the yaml file and push the changes to the gemspecs/version.rb files
  * `rake version:set_plugin_api[version]` manage the yaml file and push the changes to the gemspecs/version.rb files
  * `rake artifact:all` generates SNAPSHOT artifacts: tar.gz, zip, rpm, deb
  * `RELEASE=1 rake artifact:all` creates release candidate artifacts + 4 gems: logstash-core, logstash-core-event, logstash-core-event-java and logstash-core-plugin-api

implements #5416 and #5414

Fixes #5460
2016-06-21 12:29:18 +01:00
Pier-Hugues Pellerin
1c6f97b86a Allow to run acceptance test with the local logstash
This change introduce a new command ci/ci_acceptance which is
responsable of building the packages, bootstraping the acceptance test
environment, launching the VMs and running the tests.

You can use the following command to target specific platform.

```
ci/ci_acceptance.sh all
ci/ci_acceptance.sh centos
ci/ci_acceptance.sh debian
```

This PR also add a new rake task to build all the artifacts in a single
run called rake artifact:all it make sure we only install the plugin
only once and make the build process faster.

Fixes #5350
2016-06-02 14:37:16 +00:00
Aaron Mildenstein
6c886845e6 Update packaging to use /usr/share/logstash
Update after-install scripts

Use /usr/lib/logstash instead of /opt/logstash

More revisions.

Using `/usr/share/logstash` instead of `/usr/lib/logstash`

Track these new files

More work in progress.

Proper arg parsing obtained

WIP: Use jvm.options like ES

Remove facter dependency

Due to an update from @jordansissel on pleaserun, facter is no longer necessary

Revert Gemfile to proper version

Latest work in progress.

I added a simple test to logstash.lib.sh to catch empty strings in java options.

Added `startup.options`, and touched up `jvm.options`

Edited the package scripts to make things play nice with new paths.

Tweaked `system-install` to allow users to provide their own `startup.options` file.

Patch up merge failure

Changes to work with the new logstash.yml

Add fpm dependency (build fails without it)

Fix missing gems in Gemfile

Don't know how these got lost

Use /etc/logstash for configuration in packages

Update the instructions/documentation for...

...startup.options

Merging proposed changes

Remove mustache and clamp

They're covered by pleaserun anyway

Prune config dir from /usr/share/logstash...

...but only when using RPM/DEB packages
2016-05-25 11:43:48 -06:00
Joao Duarte
3a6b1dafaa introduce yaml settings file and cli long switches
* by default lives in LOGSTASH_HOME/config/logstash.yml
* location can be changed by $LS_SETTINGS_DIR or --path.settings
* overrides defaults of LogStash::Environment, BUT
* CLI flags override the yaml file
* several breaking changes to cli flag names (see config/logstash.yml)
* setting values are now type checked (see Setting and Settings classes)

Fixes #5313
2016-05-19 19:20:37 +01:00
Suyog Rao
ad17228d3a Remove java7 from rakelib
Fixes #5298
2016-05-13 22:29:29 +00:00
Suyog Rao
e2e995a454 Remove more plugins, add back netflow
Fixes #5254
2016-05-13 18:04:04 +00:00
Suyog Rao
1f775e61c6 Update default plugins for 5.0
5.0 is a chance for us to review and remove any plugins that we don't have to bundle by default. These plugins are still supported and maintained, but the default package should only contain most popular, most used plugins.

Removed plugins:

logstash-filter-anonymize: Replaced with newer logstash-filter-fingerprint
logstash-input-zeromq/output: Not a lot of users. Most users seem to prefer rabbitmq, redis, kafka as broker

Please comment if you'd like to remove more/less

Fixes #5254
2016-05-13 18:04:03 +00:00
Pere Urbon-Bayes
3c453476c2 move micro benchmarks and the check pull changelog tool inside the tools folder
Fixes #5268
2016-05-12 06:56:25 +00:00
Pere Urbon-Bayes
834d52a9aa refactor integration test to be inside the specs directory and not in the main level
Fixes #5268
2016-05-12 06:56:25 +00:00
Pier-Hugues Pellerin
6ea07db5d9 Remove the architecture in the RPM and Debian artifacts
Logstash will now generate theses filenames instead:

```
logstash-5.0.0.rpm
logstash-5.0.0.deb
```
Fixes #5249

Fixes #5262
2016-05-09 19:21:57 +00:00
Pier-Hugues Pellerin
5ea32cd053 Remove oldlogstashjson from the default plugin list
This plugins was used to migrate from logstash json schema 0 to 1.

Fixes #5245
2016-05-05 17:18:28 +00:00
Colin Surprenant
b0e2c7621b add --preserve option to plugin install
add missing overwrite method and preserve @gems_by_name when updating

log options preservation

discards no constrains constrains

rewording
2016-04-29 16:11:51 -04:00
Joao Duarte
d61e9a2e47 converted static I18n test to rspec
Fixes #5158
2016-04-27 14:49:41 +00:00
Joao Duarte
b00ca2238e add static analysis rake task for i18n usage
Fixes #5158
2016-04-27 14:49:41 +00:00
Pier-Hugues Pellerin
41140321a0 1g
Fixes #5198
2016-04-26 19:35:17 +00:00
Pier-Hugues Pellerin
eb4e73602f Set the HEAP Size to 1gig when running rake tasks
Logstash uses by default in the shell script 1 gig of memory for the
JVM. but when we use rake it uses the default settings of JRUBY and
start a vm 500megs of memory. The recent changes in JRUBY and
JRuby-OpenSSL have increased the base memory and make the installing of
plugins with a OOM issues. This PR make sure the CI scripts and the rake
jruby launch uses the default of 1gig.

Fixes: #5179

Fixes #5198
2016-04-26 19:35:16 +00:00
Jordan Sissel
e952f19904 Force RPM OS to be set to linux. Fixes #5147
Fixes #5156
2016-04-21 15:08:46 +00:00
Colin Surprenant
70128d4273 upgrade to JRuby 1.7.25 and required jruby-openssl 0.9.16 to match JRuby 2016-04-20 14:07:37 -04:00
Pier-Hugues Pellerin
6c47f49638 Normalize the name of the generated artifacts
This PR introduce a unified naming scheme for all our artifacts and will
produce the following files:

logstash-5.0.0-alpha1_all.deb
logstash-5.0.0-alpha1.tar.gz
logstash-5.0.0-alpha1.zip
logstash-5.0.0-alpha1.noarch.rpm

Fix #5100

Fixes #5125
2016-04-18 13:22:28 +00:00
Tal Levy
92c619de82 build core gems in same process as rake command instead of spawning new process
Fixes #5075
2016-04-11 21:26:23 +00:00
Pier-Hugues Pellerin
37bbfba0b9 Remove some plugins that failed the build when creating the tar.gz
Fixes #5054
2016-04-07 14:39:37 +00:00
Pere Urbon-Bayes
5fffa324fc fix Rakelib package.rake to use logstash-plugin pack to generate the plugins bundle
Fixes #5049
2016-04-07 13:06:00 +00:00
Colin Surprenant
2aa720f81f revert to jruby 1.7.23 for regex regression 2016-04-04 14:41:57 -04:00
Pere Urbon-Bayes
5808782345 Make the logstash-core-plugin-api install locally in case of having a :path in the Gemfile, works the same way as other "core" gems used for master branch.
Fixes #4908
2016-03-29 13:47:17 +00:00
Suyog Rao
683302e26d Rename bin/plugin to bin/logstash-plugin
This adds support for packs and fixes the problem where bin/plugin
pollutes the PATH namespace

Fixes #4871

Fixes #4874
2016-03-24 00:23:15 +00:00
Joao Duarte
fffe5883ae include hidden ruby-maven directory in packaging
ruby-maven ships a hidden directory called .mvn that
needs to be included in the package.
Currently the list of files to be packaged is generated using
Rake::FileList[globs] which excludes hidden files by default
(same happens with Dir.glob).

The fix is to ensure the contents of that directory are included
by explicitly referencing it.

For example, the file "extensions.xml", included in this directory,
is responsible for loading the ruby DSL for POMs. Not carrying this
file in the logstash package breaks any plugin update that uses
jar-dependencies.

Fixes #4845
2016-03-18 20:48:29 +00:00
Pere Urbon-Bayes
42710a4ffd add expectations for json and plain text responses for the hot threads api tests
format test properly for the node_spec api

Introduce a more proper organization of the dummy/mock runner to avoid
having wrong state propagaged across the different tests. This was
discovered by the unnecessary need to have the rubydebug codec as it was
due to wrong pipeline startup.

make the node stats test sync with last changes in data formats

improve web api service logic from reviews

remove the requirement of using output-null as only with output {} you get the same effect

Fixes #4782
2016-03-14 14:07:25 +00:00
Pere Urbon-Bayes
79e2d0040f Make sure all web api test are actually going through the hole pipe and getting data out of a real logstash execution.
Test improvements:

* Cleanup non used fixture.
* Improve node_stats tests by adding omre context and format checks.
* Add a new node_specs endpoint test that checks the expected data is
  returned for the hot_threads resource.

Fixes #4782
2016-03-14 14:07:25 +00:00
JWhy
c75a7af326 Fix deb packaging task description
Fix description of the task package("ubuntu", ...). Likely caused by copy-paste.

Fixes #4601
2016-02-02 14:25:51 +00:00
Colin Surprenant
5a522a0037 code cleanups and integration work for defaulting to Java Event implementation
cleaned dependencies, removed Guava code

default to java event

also compile java event

use json-unit for json result assertions

remove Java 8 specific constructs to be able to compile on Java 7

use jar-dependencies

better jar file loading

copy jar into lib after build

add post-build copy and clean of gem jar and re-indented file

fix jar destination

include generated jar in gem

remove useless ArrayList constructions

add tests for KeyNode.join method

remove useless  shadow and disable unchecked warnings

update gradle dependency to 2.8

fix deprecated asserEquals usage

simplify convoluted list contruction

fix array fields nil values handling

moar nil value tests

simplify for loop
2016-01-26 12:39:35 -05:00