Remove LongGauge and DoubleGauge and Replace with NumberGauge
- This is an unecessary distiction for Gauges and can complicate the serialization. Double/Float should serialize with decimal precision, and Jackson handles this by default.
Add custom witness to match existing Ruby API, such that existing Ruby plugins should not need changes
Remove namespace from LazyDelegatingGauge
- It was only there for logging, but newer versions (not here) will completely remove the concept of namespace.
Part of #7788Fixes#8053
Fixes an issue where if the DLQ is actively being read and written to, the consumeBlock method would
write data to the position where the data was last read from, rather than written to, leading to
plugin crashes.
Fixes#8024
This change allows for the serialized output of the metrics to be consistent w/r/t the un-initialized values. Note - the code presented here is not the current code in use, rather it is the code staged, but unused to replace the metrics store / namespace implementation.
Fixes#7885 (for a future release)
Fixes#8009
This commit broke the plugin contract with plugins like xpack and caused many issues there. Reverted until it can be better handled.
This reverts commit 92cdbe2dbd.
Fixes#7995
Change DeadLetterQueueReader, so that if a missing segment file is
encountered at startup, the next valid entry will be used instead
Fixes#7433Fixes#7457
The role of Witness is to provide an API record state of what is happening inside of Logstash, and provide means to serialize the data for consumption (not included in the commit). The Witness is implemented by chaining methods with a singleton root. For example:
Witness.instance().pipeline("main").inputs("foo").events().in(1)
Can be used to express that for the foo input in the main pipeline, 1 new event has been seen.
Witnesses may also have a snitch method, which allows the witness to snitch (tell others) the discrete values of the metrics. A snitch method is basically the getter. For example:
Witness.instance().pipeline("main").inputs("foo").events().snitch().in()
Tells you you how many events have been witnessed for the foo input in the main pipeline. In practice this the snitch is really only used for testing, but may be useful as just a standard set/get type operations. Serialization to JSON (not included in this commit) is the primary means to get data out of a Witness.
Some workflows require that a Witness forgets what it saw, for example during a pipeline reload. In these cases the Witness may completely or partially forget the data they have seen. This is implemented with a forget method. For example:
Witness.instance().pipeline("main").inputs("foo").events().forget().all();
Fixes#7947
The fixes in this commit combine to fix#7855
Fixes 3 bugs:
seekToNextEventPosition:
handles the case where a null event is encountered during the search for a matching event
handle restoration of buffer position when the next event consumed goes across block
boundaries
seekToStartOfEventInBlock:
handles the case where the only event in a block is an 'end' event
Also:
Adds new RecordIOReaderTest, and moves tests over from RecordIOWriterTest that seem to fit
that better
Fixes#7948
* Add --setup phase for modules
Without the `--setup` flag, the index template for elasticsearch, and the index-pattern, saved searches, visualizations, and dashboards for Kibana will not be published.
fixes#7959
In this patch we unify the IDs reported by LIR with those generated using config_ast.rb
This is a temporary fix until LIR execution is built. It relies on the fact that currently both LIR and config_ast.rb only operate on a single concatenated string of configurations. In the future LIR will compile different files separately, then merge their IRs. For now, however, this solution will hold.
This change also exposes the :id attribute of FilterDelegator to bring it to parity with OutputDelegator and InputDelegator which is required for testing purposes.
Fixes#7930
if force shutdown uses `with_pipelines` then it will never acquire the
`@pipelines_lock` from `shutdown_pipelines` until it terminates.
This PR makes force shutdown use `@pipelines` directly, fixing it.
Fixes#7918
Currently generated Vertex IDs are unwieldy concatenations of two sha256 hashes. This is just a pain to deal with.
This patch hashes that concatenation instead, yielding something far easier to deal with.
Fixes#7931
This changes the following:
* DRY Gauge metrics
* Remove Namespace from metrics API (never used, not needed)
* Introduce a 'dirty' flag. This will be used to assist with serialization (in a later commit).
* Change getKey to getName in the API
* Deprecate (only from Java) the future non-supported Guage types.
* Remove NumericGauge and replace with LongGuage and DoubleGuage.
* Bring code coverage back to 100%
Note this change is internally non-passive, however the Java metrics API (recently introduced in 6.0) has not been advertised as a re-usable asset.
Changes in support of #7788Fixes#7872