Commit graph

205 commits

Author SHA1 Message Date
Guy Boertje
9b09d4c899 bump JrJackson/Jackson versions, source all version refs from versions.yml
final (I hope) fixes for consolidated versioning.

After testing with rake artifact:zip, need to try both files.
Add desc to rake test:install-* tasks, tired of
  not seeing them in rake -vT

changes requested via review

Fixes #8373
2017-09-26 15:29:58 +00:00
Colin Surprenant
83fde50920 pick jvm.options for rspec.bat 2017-09-21 15:45:13 -04:00
Colin Surprenant
0e3b9a3eb1 refactor linux launch scripts per #8261
remove dripmain.rb
2017-09-19 16:40:21 -04:00
Colin Surprenant
83f6c9fa04 update plugin manager script for setup.bat changes 2017-09-15 17:57:46 -04:00
Colin Surprenant
e9a8812317 reword windows launch script
fixes

fix jvm.options parsing

windows compatible URI
2017-09-14 16:24:34 -04:00
Armin
d1eecfc208 Benchmark: added run script
Fixes #7875
2017-08-02 15:16:16 +00:00
Colin Surprenant
f3f24dc706 reference correct class path 2017-07-18 16:21:09 -04:00
Pier-Hugues Pellerin
76286b4f0e use jruby 9.1.9.0
Work done by @guyboertje and @ph

Since JRuby 1.7.25 is now EOL we are migrating Logstash to use JRuby 9k and JDK8 only,
Not much needed updating to make this work, its was mostly a drop in replacement from the previous version.

The major point was the change in the implementation of Time in JRuby, JRuby now use `java.time`
instead of joda time, this allow JRuby to have nanoseconds precision on time object.
2017-06-12 12:35:10 -04:00
Armin
12264efad2 #7329 invoker script for convert jar
Fixes #7335
2017-06-07 07:17:53 +00:00
Wainer dos Santos Moschetta
4163af5bea Add test case for FileLockFactory
This change introduce a test for cross-process/jvm file locking
using the FileLockFactory class. It uses a client program that
will lock a file aftwards the test case proceed.

Fixes #6610

Fixes #7117
2017-05-24 02:20:36 +00:00
Bernd
ec87eb7642 removed unreachable code (#5215) 2017-05-19 11:32:24 -07:00
Wainer dos Santos Moschetta
d4e7705b14 Quote shell script variables handling paths.
Some variables that hold path in Linux shell scripts
are not properly quoted, thus undefined behaviors may
show up (e.g. a link path with space).

This change enclose variables with quotes in bin/logstash,
bin/logstash.lib.sh and, bin/system-install scripts.

Fixes #6596

Fixes #6877
2017-04-04 15:00:48 -04:00
manni19682
933c936917 Search java executable in %PATH%
Fixes #6860
2017-03-31 14:00:41 -04:00
Josh Soref
a06dc211ff Spelling fixes (#6806)
Spelling fixes across the board.
2017-03-29 19:33:26 -07:00
Aaron Mildenstein
0d90e12c54 Update pleaserun and system-install
This will now put ENV variables from the `startup.options` file into `/etc/default/logstash` or `/etc/sysconfig/logstash` (or whatever service name you chose), and use the updated pleaserun to ensure these are honored at start time for whichever init system you use (systemd, upstart, SysV).

fixes #6482

Fixes #6660
2017-02-09 12:12:33 -05:00
Colin Surprenant
d79e3730fe 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:47:07 -05:00
Colin Surprenant
ca9ff9172d add bin/ruby command to launch ruby scripts using the logstash launcher
use bin/ruby instead of hardcoded vendorized jruby

without :development

remove symlink check per PR discussiom, will re-introduce in a followup PR
2017-01-30 17:05:23 -05:00
Aaron Mildenstein
35999aeeab Change system-install to allow manual selection
Now you can specify 3 arguments, each dependent on the previous:

1. full path to the `startup.options` file
2. the startup variant (sysv, upstart, systemd)
3. the version of the startup variant (usually unnecessary, can safely be left blank)

Present behavior is preserved.  If `system-install` is called with no arguments, it autodetects and installs the detected variant.

Fixes #6338
2016-12-09 12:57:16 -05:00
Aaron Mildenstein
60b6a9f72e Have logstash.lib.sh find jvm.options
This will work if `--path.settings` is properly used on the command line

Remove unused count variable

It isn't strictly necessary

Add double-quotes around $@

This should protect against strange spaces

fixes #6379

Fixes #6382
2016-12-09 12:19:22 -05:00
Bartłomiej Palmowski
d5d556989d Don't pass jruby opts explicitly
they are already passed via JAVA_OPTS environment variable.

Fixes #5830
2016-12-06 13:24:59 -05:00
Gérald QUINTANA
2bb69743e6 Fix Heap Dump Path on Windows
Fixes #6336
2016-12-01 23:20:38 -05:00
Shinjifox
8c9b874c98 Fixed typo for logstash cli help
The original shell script throws a error when calling it with "bin/logstash help"
# ./logstash help
ERROR: Unknown command 'help'

See: 'bin/logstash --help'

Fixes #6303
2016-11-29 05:46:42 -05:00
Colin Surprenant
f636a751f8 add support for queue.checkpoint.{acks|writes} settings
add queue.max_acked_checkpoint and queue.checkpoint_rate settings

now using checkpoint.max_acks, checkpoint.max_writes and checkpoint.max_interval

rename options

wip rework checkpointing

refactored full acked pages handling on acking and recovery

correclty close queue

proper queue open/recovery

checkpoint dump utility

checkpoint on writes

removed debug code and added missing newline

added better comment on contiguous checkpoints

fix spec for new pipeline setting
2016-11-22 14:48:58 -05:00
汪啸
1f1bbb1f89 fix wrong logic when no JAVA_OPTS set
Fixes #6034
2016-10-14 17:55:43 -04:00
Joao Duarte
72b277404b make -V/--version fast on *nix 2016-06-21 14:30:15 +01:00
Joao Duarte
bb0694d69a Revert "make -V/--version fast on *nix"
This reverts commit 562754b11a.
2016-06-17 10:00:57 +01:00
Joao Duarte
562754b11a make -V/--version fast on *nix 2016-06-16 12:46:23 +01:00
Aaron Mildenstein
4baf29dc5f Add SINCEDB_DIR env var to logstash.lib.sh
This is to fix the file input

Fixes #5385
2016-05-27 22:08:58 +00:00
Aaron Mildenstein
e40ecbb6b8 Update existing packaging to use /usr/lib/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

Fixes #5341
2016-05-25 17:25:26 +00:00
Bernd
65b1f991b0 Support ( in path and actually set JAVA_OPTS
The current logic for printing %JAVA_HOME% inside if ( ) block failes if the path contains a `(` which is the case for 32bit java (`C:\Program Files (x86)\java\jdk`)

The current logic for appending to JAVA_OPTS does not work as it will be expanded while interpreting the else block. Use goto instead.

Fixes #5214
2016-05-06 16:52:36 +00:00
Stefan Scherer
a91bf9c40b Use JAVA_EXE as variable for symlink
Signed-off-by: Stefan Scherer <scherer_stefan@icloud.com>

Fixes #4913
2016-04-21 19:46:05 +00:00
Stefan Scherer
25386c488c Show JAVA_HOME retrieved from symlink
Signed-off-by: Stefan Scherer <scherer_stefan@icloud.com>

Fixes #4913
2016-04-21 19:46:04 +00:00
Stefan Scherer
4830399de0 Retrieve JAVA_HOME from windows symlink
Signed-off-by: Stefan Scherer <scherer_stefan@icloud.com>

Fixes #4913
2016-04-21 19:46:04 +00:00
Suyog Rao
4b07413cd9 Changes after review from @purbon
Fixes #4874
2016-03-24 00:23:15 +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
Todd Bowles
62ab6f0e40 Improved the way in which JAVA_OPTS and LS_JAVA_OPTS work on windows by making it consistent with the way in which they are handled in Linux
Fixes #4758
2016-03-11 20:27:29 +00:00
Siddhartha Sahu
02f5b54c46 Add ability to configure custom gc log file
This adds ability to add gc log file to the custom $LS_LOG_DIR path

Fixes #4718
2016-02-26 19:30:11 +00:00
Suyog Rao
c136d58d32 Set LS_HEAP_SIZE correctly to 1g
Previously we had set heap size to 1g in a few places, but not everywhere

Fixes #4550
2016-01-22 17:17:34 +00:00
Aaron Mildenstein
68bdde886a Allow Logstash to be launched from a symlink
These changes allow Logstash to be launched from a symlink _only_ when the `readlink`, or suitable version of `stat` binaries are present. An error message will result if Logstash is launched from a symlink and the path cannot be discovered by one of these two methods.  The message will advise the user to use the full path instead of a symlink to launch Logstash.

fixes #4291
2015-12-04 15:25:54 -08:00
Joao Duarte
44edf5bd00 allow logstash to run in a dir with spaces
because HeapDumpPath is set, if it contains spaces the jruby_opts
function will create two strings appended by -J
even if the list of jruby opts is constructed using replacement
shell script will not escape the path correct to the heap dump path
option needs to be added as late as possible

this is a *nix fix only, windows is not affected

Fixes #4303
2015-12-04 21:27:57 +00:00
Joao Duarte
00a99c19e5 refactor concerns of runner, agent and pipeline
* move cli argument handling from agent to runner
* add a short-help message
* add interactive shell option
* log fatal messages to terminal when logging to file
* change docs:generate task to use bundle exec

Fixes #3872
2015-11-25 12:11:36 +00:00
Suyog Rao
ba88ff7d78 Uncomment heapdump location
Fixes #4205
2015-11-17 15:53:41 +00:00
Suyog Rao
d124558d79 Fix heapdump path for Windows
Fixes #4205
2015-11-17 15:53:41 +00:00
Suyog Rao
f1775d0b7e Update comment about location
Fixes #4205
2015-11-17 15:53:41 +00:00
Suyog Rao
d69cae23e6 Add option for JVM to dump its heap on OutOfMemory
Fixes #4192

Fixes #4205
2015-11-17 15:53:41 +00:00
Pier-Hugues Pellerin
1045ec8602 Change how we set the max heap size
This PR change the name of the variable to set to change the maximum
heap size on window to `LS_HEAP_SIZE` this replace the LS_MIN_MEM and
LS_MAX_MEM option.

Also We change the default size of the heap from 500m to 1g

Fixes #4085
2015-10-30 19:50:51 +00:00
Colin Surprenant
54fb7d6c78 fix bin/bundle command 2015-10-21 10:45:37 -04:00
Manus Freedom
456c726890 Fix path with space
Fixes #3372
2015-06-10 06:15:52 +00:00
Manus Freedom
cf959c7182 Revert "use windows short names => no issue with space in dir" It's a very bad idea to use short name, because you can disable short name on windows.
This reverts commit 6cb438d7fc.

Fixes #3372
2015-06-10 06:15:51 +00:00
wiibaa
6cb438d7fc use windows short names => no issue with space in dir
Fixes #3252
2015-05-19 08:16:07 +00:00