This is a deviation from what the ruby URI class normally allows.
With this patch users can use "myhost:123" as an option and have it do the
right thing, as opposed to before where they'd get an error and have to
use "//myhost:123".
Fixes#5618
Fix an issue when running tests of the plugin in isolation, no default
metric was created and the metric was nil.
This commit change the behavior to always return a `NullMetric` when
plugin instances are created outside of the pipeline.
Added tests to cover all the base class of plugin that can record
metric.
Fixes#5542
The current test where only checking if the `NullMetric` Interface was
matching the original metric interface, this PR add more test around the
actual methods and fix an issue with `decrement` using too much
arguments in the context of a namespaced metric.
The test were also move into a shared example to be used in both the `NullMetric`
and the `NamedspacedMetric`.
Also the NullMetric class will no use the same validation for keys as the namespaced class and will
reject empty or nil keys.
Fixes#5545
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 #5414Fixes#5460
Any metric calls are now allowed. This should help us grow our metrics
usage without accidentally failing tests that were too rigid.
I also split some testing up to have more alignment between the 'it'
description and the execution.
Fixes#5472
If set to try this will allow the user to specify one or more values.
This generally replaces the :array type, which had fewer type checks.
The array type is still needed for lists of complex objects, e.g. hashes.
Fixes#5453
Make sure we pass the metric when we create a pipeline this make sure
the metric is correctly visible in the pipeline and remove the need to
lock the variables.
Make the expectation more robust in the metric reload scenario.
Fixes#5400 for the greater good.
Fixes#5446
When you ran this test in isolation it failed to find the corresponding
metric, Changed the behavior to force a collect before running the
tests.
Fixes#5446
Often times plugins (like the Elasticsearch output) can naturally use URIs for their configuration.
Unfortunately using the :string type here means that the password portion of the URI can easily be leaked.
This wraps the URI class in a new LogStash::Util::SafeURI class that proxies all regular URI methods but masks
the password when `#to_s` and `#inspect` are invoked.
Fixes#5439