@prometheus-io/lezer-promql 0.55.0-rc.0 → 0.300.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +58 -12
- package/dist/index.cjs +29 -7
- package/dist/index.d.ts +1 -1
- package/dist/index.es.js +29 -5
- package/package.json +3 -2
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,54 @@
|
|
|
2
2
|
|
|
3
3
|
## unreleased
|
|
4
4
|
|
|
5
|
+
## 3.0.0-beta.1 / 2024-10-09
|
|
6
|
+
|
|
7
|
+
* [CHANGE] regexp `.` now matches all characters (performance improvement). #14505
|
|
8
|
+
* [CHANGE] `holt_winters` is now called `double_exponential_smoothing` and moves behind the [experimental-promql-functions feature flag](https://prometheus.io/docs/prometheus/latest/feature_flags/#experimental-promql-functions). #14930
|
|
9
|
+
* [CHANGE] API: The OTLP receiver endpoint can now be enabled using `--web.enable-otlp-receiver` instead of `--enable-feature=otlp-write-receiver`. #14894
|
|
10
|
+
* [CHANGE] Prometheus will not add or remove port numbers from the target address. `no-default-scrape-port` feature flag removed. #14160
|
|
11
|
+
* [CHANGE] Logging: the format of log lines has changed a little, along with the adoption of Go's Structured Logging package. #14906
|
|
12
|
+
* [CHANGE] Don't create extra `_created` timeseries if feature-flag `created-timestamp-zero-ingestion' is enabled. #14738
|
|
13
|
+
* [CHANGE] Float literals and time durations being the same is now a stable fetaure. #15111
|
|
14
|
+
* [ENHANCEMENT] UI: Many fixes and improvements. #14898, #14899, #14907, #14908, #14912, #14913, #14914, #14931, #14940, #14945, #14946, #14972, #14981, #14982, #14994, #15096
|
|
15
|
+
* [ENHANCEMENT] UI: Web UI now displays notifications, e.g. when starting up and shutting down. #15082
|
|
16
|
+
* [ENHANCEMENT] PromQL: Introduce exponential interpolation for native histograms. #14677
|
|
17
|
+
* [ENHANCEMENT] TSDB: Add support for ingestion of out-of-order native histogram samples. #14850, #14546
|
|
18
|
+
* [ENHANCEMENT] Alerts: remove metrics for removed Alertmanagers. #13909
|
|
19
|
+
* [ENHANCEMENT] Scraping: support Created-Timestamp feature on native histograms. #14694
|
|
20
|
+
* [ENHANCEMENT] Kubernetes SD: Support sidecar containers in endpoint discovery. #14929
|
|
21
|
+
* [ENHANCEMENT] Consul SD: Support catalog filters. #11224
|
|
22
|
+
* [PERF] TSDB: Parallelize deletion of postings after head compaction. #14975
|
|
23
|
+
* [PERF] TSDB: Chunk encoding: shorten some write sequences. #14932
|
|
24
|
+
* [PERF] TSDB: Grow postings by doubling. #14721
|
|
25
|
+
* [PERF] Relabeling: Optimize adding a constant label pair. #12180
|
|
26
|
+
* [BUGFIX] Scraping: Unit was missing when using protobuf format. #15095
|
|
27
|
+
* [BUGFIX] PromQL: Only return "possible non-counter" annotation when `rate` returns points. #14910
|
|
28
|
+
* [BUGFIX] TSDB: Chunks could have one unnecessary zero byte at the end. #14854
|
|
29
|
+
* [BUGFIX] "superfluous response.WriteHeader call" messages in log. #14884
|
|
30
|
+
* [BUGFIX] PromQL: Unary negation of native histograms. #14821
|
|
31
|
+
* [BUGFIX] PromQL: Handle stale marker in native histogram series (e.g. if series goes away and comes back). #15025
|
|
32
|
+
* [BUGFIX] Autoreload: Reload invalid yaml files. #14947
|
|
33
|
+
|
|
34
|
+
## 3.0.0-beta.0 / 2024-09-05
|
|
35
|
+
|
|
36
|
+
Release 3.0.0-beta.0 includes new features such as a brand new UI and UTF-8 support enabled by default. As a new major version, several breaking changes are introduced. The breaking changes are mainly around the removal of deprecated feature flags and CLI arguments, and the full list can be found below. Most users should be able to try this release out of the box without any configuration changes.
|
|
37
|
+
|
|
38
|
+
As is traditional with a beta release, we do **not** recommend users install 3.0.0-beta on critical production systems, but we do want everyone to test it out and find bugs.
|
|
39
|
+
|
|
40
|
+
* [CHANGE] UI: The old web UI has been replaced by a completely new one that is less cluttered and adds a few new features (PromLens-style tree view, better metrics explorer, "Explain" tab). However, it is still missing some features of the old UI (notably, exemplar display and heatmaps). To switch back to the old UI, you can use the feature flag `--enable-feature=old-ui` for the time being. #14872
|
|
41
|
+
* [CHANGE] PromQL: Range selectors and the lookback delta are now left-open, i.e. a sample coinciding with the lower time limit is excluded rather than included. #13904
|
|
42
|
+
* [CHANGE] Kubernetes SD: Remove support for `discovery.k8s.io/v1beta1` API version of EndpointSlice. This version is no longer served as of Kubernetes v1.25. #14365
|
|
43
|
+
* [CHANGE] Kubernetes SD: Remove support for `networking.k8s.io/v1beta1` API version of Ingress. This version is no longer served as of Kubernetes v1.22. #14365
|
|
44
|
+
* [CHANGE] UTF-8: Enable UTF-8 support by default. Prometheus now allows all UTF-8 characters in metric and label names. The corresponding `utf8-name` feature flag has been removed. #14705
|
|
45
|
+
* [CHANGE] Console: Remove example files for the console feature. Users can continue using the console feature by supplying their own JavaScript and templates. #14807
|
|
46
|
+
* [CHANGE] SD: Enable the new service discovery manager by default. This SD manager does not restart unchanged discoveries upon reloading. This makes reloads faster and reduces pressure on service discoveries' sources. The corresponding `new-service-discovery-manager` feature flag has been removed. #14770
|
|
47
|
+
* [CHANGE] Agent mode has been promoted to stable. The feature flag `agent` has been removed. To run Prometheus in Agent mode, use the new `--agent` cmdline arg instead. #14747
|
|
48
|
+
* [CHANGE] Remove deprecated `remote-write-receiver`,`promql-at-modifier`, and `promql-negative-offset` feature flags. #13456, #14526
|
|
49
|
+
* [CHANGE] Remove deprecated `storage.tsdb.allow-overlapping-blocks`, `alertmanager.timeout`, and `storage.tsdb.retention` flags. #14640, #14643
|
|
50
|
+
* [ENHANCEMENT] Move AM discovery page from "Monitoring status" to "Server status". #14875
|
|
51
|
+
* [BUGFIX] Scrape: Do not override target parameter labels with config params. #11029
|
|
52
|
+
|
|
5
53
|
## 2.55.0-rc.0 / 2024-09-20
|
|
6
54
|
|
|
7
55
|
* [FEATURE] Support UTF-8 characters in label names - feature flag `utf8-names`. #14482, #14880, #14736, #14727
|
|
@@ -9,32 +57,30 @@
|
|
|
9
57
|
* [FEATURE] Scraping: Add the ability to set custom `http_headers` in config. #14817
|
|
10
58
|
* [FEATURE] Scraping: Support feature flag `created-timestamp-zero-ingestion` in OpenMetrics. #14356, #14815
|
|
11
59
|
* [FEATURE] Scraping: `scrape_failure_log_file` option to log failures to a file. #14734
|
|
12
|
-
* [FEATURE] PromQL: Delay removal of `__name__` label - feature flag `promql-delayed-name-removal`. #14477
|
|
13
60
|
* [FEATURE] OTLP receiver: Optional promotion of resource attributes to series labels. #14200
|
|
14
|
-
* [FEATURE] API: Support multiple `--web.listen-address`. #14665
|
|
15
61
|
* [FEATURE] Remote-Write: Support Google Cloud Monitoring authorization. #14346
|
|
16
62
|
* [FEATURE] Promtool: `tsdb create-blocks` new option to add labels. #14403
|
|
17
63
|
* [FEATURE] Promtool: `promtool test` adds `--junit` flag to format results. #14506
|
|
18
64
|
* [ENHANCEMENT] OTLP receiver: Warn on exponential histograms with zero count and non-zero sum. #14706
|
|
19
65
|
* [ENHANCEMENT] OTLP receiver: Interrupt translation on context cancellation/timeout. #14612
|
|
20
|
-
* [ENHANCEMENT]
|
|
66
|
+
* [ENHANCEMENT] Remote Read client: Enable streaming remote read if the server supports it. #11379
|
|
67
|
+
* [ENHANCEMENT] Remote-Write: Don't reshard if we haven't successfully sent a sample since last update. #14450
|
|
68
|
+
* [ENHANCEMENT] PromQL: Delay deletion of `__name__` label to the end of the query evaluation. This is **experimental** and enabled under the feature-flag `promql-delayed-name-removal`. #14477
|
|
21
69
|
* [ENHANCEMENT] PromQL: Experimental `sort_by_label` and `sort_by_label_desc` sort by all labels when label is equal. #14655
|
|
22
70
|
* [ENHANCEMENT] PromQL: Clarify error message logged when Go runtime panic occurs during query evaluation. #14621
|
|
23
71
|
* [ENHANCEMENT] PromQL: Use Kahan summation for better accuracy in `avg` and `avg_over_time`. #14413
|
|
72
|
+
* [ENHANCEMENT] Tracing: Improve PromQL tracing, including showing the operation performed for aggregates, operators, and calls. #14816
|
|
73
|
+
* [ENHANCEMENT] API: Support multiple listening addresses. #14665
|
|
24
74
|
* [ENHANCEMENT] TSDB: Backward compatibility with upcoming index v3. #14934
|
|
25
|
-
* [PERF] Remote-Read: Support streaming mode. #11379
|
|
26
75
|
* [PERF] TSDB: Query in-order and out-of-order series together. #14354, #14693, #14714, #14831, #14874, #14948
|
|
27
76
|
* [PERF] TSDB: Streamline reading of overlapping out-of-order head chunks. #14729
|
|
28
77
|
* [BUGFIX] SD: Fix dropping targets (with feature flag `new-service-discovery-manager`). #13147
|
|
29
78
|
* [BUGFIX] SD: Stop storing stale targets (with feature flag `new-service-discovery-manager`). #13622
|
|
30
|
-
* [BUGFIX] fix(utf8): propagate validationScheme config to scraping options. #14880
|
|
31
|
-
* [BUGFIX] PromQL: Experimental Native Histograms: Do not re-use spans between histograms. #14771
|
|
32
79
|
* [BUGFIX] Scraping: exemplars could be dropped in protobuf scraping. #14810
|
|
33
80
|
* [BUGFIX] Remote-Write: fix metadata sending for experimental Remote-Write V2. #14766
|
|
34
81
|
* [BUGFIX] Remote-Write: Return 4xx not 5xx when timeseries has duplicate label. #14716
|
|
35
|
-
* [BUGFIX] Experimental Native Histograms: many fixes for incorrect results, panics, warnings. #
|
|
82
|
+
* [BUGFIX] Experimental Native Histograms: many fixes for incorrect results, panics, warnings. #14513, #14575, #14598, #14609, #14611, #14771, #14821
|
|
36
83
|
* [BUGFIX] TSDB: Only count unknown record types in `record_decode_failures_total` metric. #14042
|
|
37
|
-
* [ENHANCEMENT] Remote-Write: Don't reshard if we haven't successfully sent a sample since last update. #14450
|
|
38
84
|
|
|
39
85
|
## 2.54.1 / 2024-08-27
|
|
40
86
|
|
|
@@ -133,7 +179,7 @@ This release changes the default for GOGC, the Go runtime control for the trade-
|
|
|
133
179
|
* [ENHANCEMENT] TSDB: Pause regular block compactions if the head needs to be compacted (prioritize head as it increases memory consumption). #13754
|
|
134
180
|
* [ENHANCEMENT] Observability: Improved logging during signal handling termination. #13772
|
|
135
181
|
* [ENHANCEMENT] Observability: All log lines for drop series use "num_dropped" key consistently. #13823
|
|
136
|
-
* [ENHANCEMENT] Observability: Log chunk snapshot and
|
|
182
|
+
* [ENHANCEMENT] Observability: Log chunk snapshot and mmapped chunk replay duration during WAL replay. #13838
|
|
137
183
|
* [ENHANCEMENT] Observability: Log if the block is being created from WBL during compaction. #13846
|
|
138
184
|
* [BUGFIX] PromQL: Fix inaccurate sample number statistic when querying histograms. #13667
|
|
139
185
|
* [BUGFIX] PromQL: Fix `histogram_stddev` and `histogram_stdvar` for cases where the histogram has negative buckets. #13852
|
|
@@ -670,7 +716,7 @@ The binaries published with this release are built with Go1.17.8 to avoid [CVE-2
|
|
|
670
716
|
|
|
671
717
|
## 2.33.0 / 2022-01-29
|
|
672
718
|
|
|
673
|
-
* [CHANGE] PromQL: Promote negative offset and `@`
|
|
719
|
+
* [CHANGE] PromQL: Promote negative offset and `@` modifier to stable features. #10121
|
|
674
720
|
* [CHANGE] Web: Promote remote-write-receiver to stable. #10119
|
|
675
721
|
* [FEATURE] Config: Add `stripPort` template function. #10002
|
|
676
722
|
* [FEATURE] Promtool: Add cardinality analysis to `check metrics`, enabled by flag `--extended`. #10045
|
|
@@ -907,7 +953,7 @@ This vulnerability has been reported by Aaron Devaney from MDSec.
|
|
|
907
953
|
* [ENHANCEMENT] Templating: Enable parsing strings in `humanize` functions. #8682
|
|
908
954
|
* [BUGFIX] UI: Provide errors instead of blank page on TSDB Status Page. #8654 #8659
|
|
909
955
|
* [BUGFIX] TSDB: Do not panic when writing very large records to the WAL. #8790
|
|
910
|
-
* [BUGFIX] TSDB: Avoid panic when
|
|
956
|
+
* [BUGFIX] TSDB: Avoid panic when mmapped memory is referenced after the file is closed. #8723
|
|
911
957
|
* [BUGFIX] Scaleway Discovery: Fix nil pointer dereference. #8737
|
|
912
958
|
* [BUGFIX] Consul Discovery: Restart no longer required after config update with no targets. #8766
|
|
913
959
|
|
|
@@ -1833,7 +1879,7 @@ information, read the announcement blog post and migration guide.
|
|
|
1833
1879
|
## 1.7.0 / 2017-06-06
|
|
1834
1880
|
|
|
1835
1881
|
* [CHANGE] Compress remote storage requests and responses with unframed/raw snappy.
|
|
1836
|
-
* [CHANGE] Properly
|
|
1882
|
+
* [CHANGE] Properly elide secrets in config.
|
|
1837
1883
|
* [FEATURE] Add OpenStack service discovery.
|
|
1838
1884
|
* [FEATURE] Add ability to limit Kubernetes service discovery to certain namespaces.
|
|
1839
1885
|
* [FEATURE] Add metric for discovered number of Alertmanagers.
|
package/dist/index.cjs
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
-
|
|
5
3
|
var lr = require('@lezer/lr');
|
|
6
4
|
var highlight = require('@lezer/highlight');
|
|
7
5
|
|
|
@@ -38,6 +36,18 @@ const inf$1 = 157,
|
|
|
38
36
|
End$1 = 28;
|
|
39
37
|
|
|
40
38
|
// Copyright 2021 The Prometheus Authors
|
|
39
|
+
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
40
|
+
// you may not use this file except in compliance with the License.
|
|
41
|
+
// You may obtain a copy of the License at
|
|
42
|
+
//
|
|
43
|
+
// http://www.apache.org/licenses/LICENSE-2.0
|
|
44
|
+
//
|
|
45
|
+
// Unless required by applicable law or agreed to in writing, software
|
|
46
|
+
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
47
|
+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
48
|
+
// See the License for the specific language governing permissions and
|
|
49
|
+
// limitations under the License.
|
|
50
|
+
|
|
41
51
|
|
|
42
52
|
const keywordTokens = {
|
|
43
53
|
inf: inf$1,
|
|
@@ -84,6 +94,18 @@ const extendIdentifier = (value, stack) => {
|
|
|
84
94
|
};
|
|
85
95
|
|
|
86
96
|
// Copyright 2022 The Prometheus Authors
|
|
97
|
+
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
98
|
+
// you may not use this file except in compliance with the License.
|
|
99
|
+
// You may obtain a copy of the License at
|
|
100
|
+
//
|
|
101
|
+
// http://www.apache.org/licenses/LICENSE-2.0
|
|
102
|
+
//
|
|
103
|
+
// Unless required by applicable law or agreed to in writing, software
|
|
104
|
+
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
105
|
+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
106
|
+
// See the License for the specific language governing permissions and
|
|
107
|
+
// limitations under the License.
|
|
108
|
+
|
|
87
109
|
|
|
88
110
|
const promQLHighLight = highlight.styleTags({
|
|
89
111
|
LineComment: highlight.tags.comment,
|
|
@@ -92,7 +114,7 @@ const promQLHighLight = highlight.styleTags({
|
|
|
92
114
|
NumberDurationLiteral: highlight.tags.number,
|
|
93
115
|
NumberDurationLiteralInDurationContext: highlight.tags.number,
|
|
94
116
|
Identifier: highlight.tags.variableName,
|
|
95
|
-
'Abs Absent AbsentOverTime Acos Acosh Asin Asinh Atan Atanh AvgOverTime Ceil Changes Clamp ClampMax ClampMin Cos Cosh CountOverTime DaysInMonth DayOfMonth DayOfWeek DayOfYear Deg Delta Deriv Exp Floor HistogramAvg HistogramCount HistogramFraction HistogramQuantile HistogramSum
|
|
117
|
+
'Abs Absent AbsentOverTime Acos Acosh Asin Asinh Atan Atanh AvgOverTime Ceil Changes Clamp ClampMax ClampMin Cos Cosh CountOverTime DaysInMonth DayOfMonth DayOfWeek DayOfYear Deg Delta Deriv Exp Floor HistogramAvg HistogramCount HistogramFraction HistogramQuantile HistogramSum DoubleExponentialSmoothing Hour Idelta Increase Irate LabelReplace LabelJoin LastOverTime Ln Log10 Log2 MaxOverTime MinOverTime Minute Month Pi PredictLinear PresentOverTime QuantileOverTime Rad Rate Resets Round Scalar Sgn Sin Sinh Sort SortDesc SortByLabel SortByLabelDesc Sqrt StddevOverTime StdvarOverTime SumOverTime Tan Tanh Time Timestamp Vector Year':
|
|
96
118
|
highlight.tags.function(highlight.tags.variableName),
|
|
97
119
|
'Avg Bottomk Count Count_values Group LimitK LimitRatio Max Min Quantile Stddev Stdvar Sum Topk': highlight.tags.operatorKeyword,
|
|
98
120
|
'By Without Bool On Ignoring GroupLeft GroupRight Offset Start End': highlight.tags.modifier,
|
|
@@ -106,13 +128,13 @@ const promQLHighLight = highlight.styleTags({
|
|
|
106
128
|
});
|
|
107
129
|
|
|
108
130
|
// This file was generated by lezer-generator. You probably shouldn't edit it.
|
|
109
|
-
const spec_Identifier = {__proto__:null,absent_over_time:333, absent:335, abs:337, acos:339, acosh:341, asin:343, asinh:345, atan:347, atanh:349, avg_over_time:351, ceil:353, changes:355, clamp:357, clamp_max:359, clamp_min:361, cos:363, cosh:365, count_over_time:367, days_in_month:369, day_of_month:371, day_of_week:373, day_of_year:375, deg:377, delta:379, deriv:381, exp:383, floor:385, histogram_count:387, histogram_fraction:389, histogram_quantile:391, histogram_stddev:393, histogram_stdvar:395, histogram_sum:397, histogram_avg:399,
|
|
131
|
+
const spec_Identifier = {__proto__:null,absent_over_time:333, absent:335, abs:337, acos:339, acosh:341, asin:343, asinh:345, atan:347, atanh:349, avg_over_time:351, ceil:353, changes:355, clamp:357, clamp_max:359, clamp_min:361, cos:363, cosh:365, count_over_time:367, days_in_month:369, day_of_month:371, day_of_week:373, day_of_year:375, deg:377, delta:379, deriv:381, exp:383, floor:385, histogram_count:387, histogram_fraction:389, histogram_quantile:391, histogram_stddev:393, histogram_stdvar:395, histogram_sum:397, histogram_avg:399, double_exponential_smoothing:401, hour:403, idelta:405, increase:407, irate:409, label_replace:411, label_join:413, last_over_time:415, ln:417, log10:419, log2:421, mad_over_time:423, max_over_time:425, min_over_time:427, minute:429, month:431, pi:433, predict_linear:435, present_over_time:437, quantile_over_time:439, rad:441, rate:443, resets:445, round:447, scalar:449, sgn:451, sin:453, sinh:455, sort:457, sort_desc:459, sort_by_label:461, sort_by_label_desc:463, sqrt:465, stddev_over_time:467, stdvar_over_time:469, sum_over_time:471, tan:473, tanh:475, timestamp:477, time:479, vector:481, year:483};
|
|
110
132
|
const parser = lr.LRParser.deserialize({
|
|
111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n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n$m&z'T$m$m$m$m'd$m'p(P(XPPP(P$mP(`P(c(i(oPPPPP(vPPP)fe^OXY#P#o#p#q#r#s$VeROXY#P#o#p#q#r#s$VQ#QRR#j#RQ#g#OQ$Y#lR$|$rQ#bZQ$U#fU$g$Q$j$wV$x$l$z%PQ#RRQ#[UR#j#QZ#n#S#T#U#V#WY#m#S#T#U#V#WR$Z#neUOXY#P#o#p#q#r#s$VeTOXY#P#o#p#q#r#s$VQ#v#XQ#w#YR$t$cd^OXY#P#o#p#q#r#s$VR#z#ZeYOXY#P#o#p#q#r#s$Vd]OXY#P#o#p#q#r#s$VR#e[Q#dZV$h$Q$j$wQ$O#aT$P#b$gR#{#ZQ$m$UR${$mQ$W#iR$p$WS$R#b#dR$k$RQSOQ#^XQ#_YQ#i#PQ$[#oQ$]#pQ$^#qQ$_#rQ$`#sR$o$VQ#o#SQ#p#TQ#q#UQ#r#VR#s#W",
|
|
115
|
-
nodeNames: "⚠ Bool Ignoring On GroupLeft GroupRight Offset Atan2 Avg Bottomk Count CountValues Group Max Min Quantile LimitK LimitRatio Stddev Stdvar Sum Topk By Without And Or Unless Start End LineComment PromQL AggregateExpr AggregateOp AggregateModifier GroupingLabels LabelName QuotedLabelName StringLiteral FunctionCallBody BinaryExpr Pow BoolModifier MatchingModifierClause Mul Div Mod Add Sub Eql Gte Gtr Lte Lss Neq FunctionCall FunctionIdentifier AbsentOverTime Identifier Absent Abs Acos Acosh Asin Asinh Atan Atanh AvgOverTime Ceil Changes Clamp ClampMax ClampMin Cos Cosh CountOverTime DaysInMonth DayOfMonth DayOfWeek DayOfYear Deg Delta Deriv Exp Floor HistogramCount HistogramFraction HistogramQuantile HistogramStdDev HistogramStdVar HistogramSum HistogramAvg
|
|
137
|
+
nodeNames: "⚠ Bool Ignoring On GroupLeft GroupRight Offset Atan2 Avg Bottomk Count CountValues Group Max Min Quantile LimitK LimitRatio Stddev Stdvar Sum Topk By Without And Or Unless Start End LineComment PromQL AggregateExpr AggregateOp AggregateModifier GroupingLabels LabelName QuotedLabelName StringLiteral FunctionCallBody BinaryExpr Pow BoolModifier MatchingModifierClause Mul Div Mod Add Sub Eql Gte Gtr Lte Lss Neq FunctionCall FunctionIdentifier AbsentOverTime Identifier Absent Abs Acos Acosh Asin Asinh Atan Atanh AvgOverTime Ceil Changes Clamp ClampMax ClampMin Cos Cosh CountOverTime DaysInMonth DayOfMonth DayOfWeek DayOfYear Deg Delta Deriv Exp Floor HistogramCount HistogramFraction HistogramQuantile HistogramStdDev HistogramStdVar HistogramSum HistogramAvg DoubleExponentialSmoothing Hour Idelta Increase Irate LabelReplace LabelJoin LastOverTime Ln Log10 Log2 MadOverTime MaxOverTime MinOverTime Minute Month Pi PredictLinear PresentOverTime QuantileOverTime Rad Rate Resets Round Scalar Sgn Sin Sinh Sort SortDesc SortByLabel SortByLabelDesc Sqrt StddevOverTime StdvarOverTime SumOverTime Tan Tanh Timestamp Time Vector Year MatrixSelector NumberDurationLiteralInDurationContext NumberDurationLiteral OffsetExpr ParenExpr SubqueryExpr UnaryExpr UnaryOp VectorSelector LabelMatchers UnquotedLabelMatcher MatchOp EqlSingle EqlRegex NeqRegex QuotedLabelMatcher StepInvariantExpr At AtModifierPreprocessors MetricName",
|
|
116
138
|
maxTerm: 249,
|
|
117
139
|
nodeProps: [
|
|
118
140
|
["group", -12,31,37,39,54,133,135,136,137,138,139,141,149,"Expr"]
|
|
@@ -219,7 +241,7 @@ const inf = 157,
|
|
|
219
241
|
HistogramStdVar = 88,
|
|
220
242
|
HistogramSum = 89,
|
|
221
243
|
HistogramAvg = 90,
|
|
222
|
-
|
|
244
|
+
DoubleExponentialSmoothing = 91,
|
|
223
245
|
Hour = 92,
|
|
224
246
|
Idelta = 93,
|
|
225
247
|
Increase = 94,
|
|
@@ -324,6 +346,7 @@ exports.Deg = Deg;
|
|
|
324
346
|
exports.Delta = Delta;
|
|
325
347
|
exports.Deriv = Deriv;
|
|
326
348
|
exports.Div = Div;
|
|
349
|
+
exports.DoubleExponentialSmoothing = DoubleExponentialSmoothing;
|
|
327
350
|
exports.End = End;
|
|
328
351
|
exports.Eql = Eql;
|
|
329
352
|
exports.EqlRegex = EqlRegex;
|
|
@@ -346,7 +369,6 @@ exports.HistogramQuantile = HistogramQuantile;
|
|
|
346
369
|
exports.HistogramStdDev = HistogramStdDev;
|
|
347
370
|
exports.HistogramStdVar = HistogramStdVar;
|
|
348
371
|
exports.HistogramSum = HistogramSum;
|
|
349
|
-
exports.HoltWinters = HoltWinters;
|
|
350
372
|
exports.Hour = Hour;
|
|
351
373
|
exports.Idelta = Idelta;
|
|
352
374
|
exports.Identifier = Identifier;
|
package/dist/index.d.ts
CHANGED
package/dist/index.es.js
CHANGED
|
@@ -34,6 +34,18 @@ const inf$1 = 157,
|
|
|
34
34
|
End$1 = 28;
|
|
35
35
|
|
|
36
36
|
// Copyright 2021 The Prometheus Authors
|
|
37
|
+
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
38
|
+
// you may not use this file except in compliance with the License.
|
|
39
|
+
// You may obtain a copy of the License at
|
|
40
|
+
//
|
|
41
|
+
// http://www.apache.org/licenses/LICENSE-2.0
|
|
42
|
+
//
|
|
43
|
+
// Unless required by applicable law or agreed to in writing, software
|
|
44
|
+
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
45
|
+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
46
|
+
// See the License for the specific language governing permissions and
|
|
47
|
+
// limitations under the License.
|
|
48
|
+
|
|
37
49
|
|
|
38
50
|
const keywordTokens = {
|
|
39
51
|
inf: inf$1,
|
|
@@ -80,6 +92,18 @@ const extendIdentifier = (value, stack) => {
|
|
|
80
92
|
};
|
|
81
93
|
|
|
82
94
|
// Copyright 2022 The Prometheus Authors
|
|
95
|
+
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
96
|
+
// you may not use this file except in compliance with the License.
|
|
97
|
+
// You may obtain a copy of the License at
|
|
98
|
+
//
|
|
99
|
+
// http://www.apache.org/licenses/LICENSE-2.0
|
|
100
|
+
//
|
|
101
|
+
// Unless required by applicable law or agreed to in writing, software
|
|
102
|
+
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
103
|
+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
104
|
+
// See the License for the specific language governing permissions and
|
|
105
|
+
// limitations under the License.
|
|
106
|
+
|
|
83
107
|
|
|
84
108
|
const promQLHighLight = styleTags({
|
|
85
109
|
LineComment: tags.comment,
|
|
@@ -88,7 +112,7 @@ const promQLHighLight = styleTags({
|
|
|
88
112
|
NumberDurationLiteral: tags.number,
|
|
89
113
|
NumberDurationLiteralInDurationContext: tags.number,
|
|
90
114
|
Identifier: tags.variableName,
|
|
91
|
-
'Abs Absent AbsentOverTime Acos Acosh Asin Asinh Atan Atanh AvgOverTime Ceil Changes Clamp ClampMax ClampMin Cos Cosh CountOverTime DaysInMonth DayOfMonth DayOfWeek DayOfYear Deg Delta Deriv Exp Floor HistogramAvg HistogramCount HistogramFraction HistogramQuantile HistogramSum
|
|
115
|
+
'Abs Absent AbsentOverTime Acos Acosh Asin Asinh Atan Atanh AvgOverTime Ceil Changes Clamp ClampMax ClampMin Cos Cosh CountOverTime DaysInMonth DayOfMonth DayOfWeek DayOfYear Deg Delta Deriv Exp Floor HistogramAvg HistogramCount HistogramFraction HistogramQuantile HistogramSum DoubleExponentialSmoothing Hour Idelta Increase Irate LabelReplace LabelJoin LastOverTime Ln Log10 Log2 MaxOverTime MinOverTime Minute Month Pi PredictLinear PresentOverTime QuantileOverTime Rad Rate Resets Round Scalar Sgn Sin Sinh Sort SortDesc SortByLabel SortByLabelDesc Sqrt StddevOverTime StdvarOverTime SumOverTime Tan Tanh Time Timestamp Vector Year':
|
|
92
116
|
tags.function(tags.variableName),
|
|
93
117
|
'Avg Bottomk Count Count_values Group LimitK LimitRatio Max Min Quantile Stddev Stdvar Sum Topk': tags.operatorKeyword,
|
|
94
118
|
'By Without Bool On Ignoring GroupLeft GroupRight Offset Start End': tags.modifier,
|
|
@@ -102,13 +126,13 @@ const promQLHighLight = styleTags({
|
|
|
102
126
|
});
|
|
103
127
|
|
|
104
128
|
// This file was generated by lezer-generator. You probably shouldn't edit it.
|
|
105
|
-
const spec_Identifier = {__proto__:null,absent_over_time:333, absent:335, abs:337, acos:339, acosh:341, asin:343, asinh:345, atan:347, atanh:349, avg_over_time:351, ceil:353, changes:355, clamp:357, clamp_max:359, clamp_min:361, cos:363, cosh:365, count_over_time:367, days_in_month:369, day_of_month:371, day_of_week:373, day_of_year:375, deg:377, delta:379, deriv:381, exp:383, floor:385, histogram_count:387, histogram_fraction:389, histogram_quantile:391, histogram_stddev:393, histogram_stdvar:395, histogram_sum:397, histogram_avg:399,
|
|
129
|
+
const spec_Identifier = {__proto__:null,absent_over_time:333, absent:335, abs:337, acos:339, acosh:341, asin:343, asinh:345, atan:347, atanh:349, avg_over_time:351, ceil:353, changes:355, clamp:357, clamp_max:359, clamp_min:361, cos:363, cosh:365, count_over_time:367, days_in_month:369, day_of_month:371, day_of_week:373, day_of_year:375, deg:377, delta:379, deriv:381, exp:383, floor:385, histogram_count:387, histogram_fraction:389, histogram_quantile:391, histogram_stddev:393, histogram_stdvar:395, histogram_sum:397, histogram_avg:399, double_exponential_smoothing:401, hour:403, idelta:405, increase:407, irate:409, label_replace:411, label_join:413, last_over_time:415, ln:417, log10:419, log2:421, mad_over_time:423, max_over_time:425, min_over_time:427, minute:429, month:431, pi:433, predict_linear:435, present_over_time:437, quantile_over_time:439, rad:441, rate:443, resets:445, round:447, scalar:449, sgn:451, sin:453, sinh:455, sort:457, sort_desc:459, sort_by_label:461, sort_by_label_desc:463, sqrt:465, stddev_over_time:467, stdvar_over_time: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PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP$m$y%V%]P%fP%v$mP&P&WPPPPPPPPPPP$m&b&nP&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n&n$m&z'T$m$m$m$m'd$m'p(P(XPPP(P$mP(`P(c(i(oPPPPP(vPPP)fe^OXY#P#o#p#q#r#s$VeROXY#P#o#p#q#r#s$VQ#QRR#j#RQ#g#OQ$Y#lR$|$rQ#bZQ$U#fU$g$Q$j$wV$x$l$z%PQ#RRQ#[UR#j#QZ#n#S#T#U#V#WY#m#S#T#U#V#WR$Z#neUOXY#P#o#p#q#r#s$VeTOXY#P#o#p#q#r#s$VQ#v#XQ#w#YR$t$cd^OXY#P#o#p#q#r#s$VR#z#ZeYOXY#P#o#p#q#r#s$Vd]OXY#P#o#p#q#r#s$VR#e[Q#dZV$h$Q$j$wQ$O#aT$P#b$gR#{#ZQ$m$UR${$mQ$W#iR$p$WS$R#b#dR$k$RQSOQ#^XQ#_YQ#i#PQ$[#oQ$]#pQ$^#qQ$_#rQ$`#sR$o$VQ#o#SQ#p#TQ#q#UQ#r#VR#s#W",
|
|
111
|
-
nodeNames: "⚠ Bool Ignoring On GroupLeft GroupRight Offset Atan2 Avg Bottomk Count CountValues Group Max Min Quantile LimitK LimitRatio Stddev Stdvar Sum Topk By Without And Or Unless Start End LineComment PromQL AggregateExpr AggregateOp AggregateModifier GroupingLabels LabelName QuotedLabelName StringLiteral FunctionCallBody BinaryExpr Pow BoolModifier MatchingModifierClause Mul Div Mod Add Sub Eql Gte Gtr Lte Lss Neq FunctionCall FunctionIdentifier AbsentOverTime Identifier Absent Abs Acos Acosh Asin Asinh Atan Atanh AvgOverTime Ceil Changes Clamp ClampMax ClampMin Cos Cosh CountOverTime DaysInMonth DayOfMonth DayOfWeek DayOfYear Deg Delta Deriv Exp Floor HistogramCount HistogramFraction HistogramQuantile HistogramStdDev HistogramStdVar HistogramSum HistogramAvg
|
|
135
|
+
nodeNames: "⚠ Bool Ignoring On GroupLeft GroupRight Offset Atan2 Avg Bottomk Count CountValues Group Max Min Quantile LimitK LimitRatio Stddev Stdvar Sum Topk By Without And Or Unless Start End LineComment PromQL AggregateExpr AggregateOp AggregateModifier GroupingLabels LabelName QuotedLabelName StringLiteral FunctionCallBody BinaryExpr Pow BoolModifier MatchingModifierClause Mul Div Mod Add Sub Eql Gte Gtr Lte Lss Neq FunctionCall FunctionIdentifier AbsentOverTime Identifier Absent Abs Acos Acosh Asin Asinh Atan Atanh AvgOverTime Ceil Changes Clamp ClampMax ClampMin Cos Cosh CountOverTime DaysInMonth DayOfMonth DayOfWeek DayOfYear Deg Delta Deriv Exp Floor HistogramCount HistogramFraction HistogramQuantile HistogramStdDev HistogramStdVar HistogramSum HistogramAvg DoubleExponentialSmoothing Hour Idelta Increase Irate LabelReplace LabelJoin LastOverTime Ln Log10 Log2 MadOverTime MaxOverTime MinOverTime Minute Month Pi PredictLinear PresentOverTime QuantileOverTime Rad Rate Resets Round Scalar Sgn Sin Sinh Sort SortDesc SortByLabel SortByLabelDesc Sqrt StddevOverTime StdvarOverTime SumOverTime Tan Tanh Timestamp Time Vector Year MatrixSelector NumberDurationLiteralInDurationContext NumberDurationLiteral OffsetExpr ParenExpr SubqueryExpr UnaryExpr UnaryOp VectorSelector LabelMatchers UnquotedLabelMatcher MatchOp EqlSingle EqlRegex NeqRegex QuotedLabelMatcher StepInvariantExpr At AtModifierPreprocessors MetricName",
|
|
112
136
|
maxTerm: 249,
|
|
113
137
|
nodeProps: [
|
|
114
138
|
["group", -12,31,37,39,54,133,135,136,137,138,139,141,149,"Expr"]
|
|
@@ -215,7 +239,7 @@ const inf = 157,
|
|
|
215
239
|
HistogramStdVar = 88,
|
|
216
240
|
HistogramSum = 89,
|
|
217
241
|
HistogramAvg = 90,
|
|
218
|
-
|
|
242
|
+
DoubleExponentialSmoothing = 91,
|
|
219
243
|
Hour = 92,
|
|
220
244
|
Idelta = 93,
|
|
221
245
|
Increase = 94,
|
|
@@ -278,4 +302,4 @@ const inf = 157,
|
|
|
278
302
|
AtModifierPreprocessors = 151,
|
|
279
303
|
MetricName = 152;
|
|
280
304
|
|
|
281
|
-
export { Abs, Absent, AbsentOverTime, Acos, Acosh, Add, AggregateExpr, AggregateModifier, AggregateOp, And, Asin, Asinh, At, AtModifierPreprocessors, Atan, Atan2, Atanh, Avg, AvgOverTime, BinaryExpr, Bool, BoolModifier, Bottomk, By, Ceil, Changes, Clamp, ClampMax, ClampMin, Cos, Cosh, Count, CountOverTime, CountValues, DayOfMonth, DayOfWeek, DayOfYear, DaysInMonth, Deg, Delta, Deriv, Div, End, Eql, EqlRegex, EqlSingle, Exp, Floor, FunctionCall, FunctionCallBody, FunctionIdentifier, Group, GroupLeft, GroupRight, GroupingLabels, Gte, Gtr, HistogramAvg, HistogramCount, HistogramFraction, HistogramQuantile, HistogramStdDev, HistogramStdVar, HistogramSum,
|
|
305
|
+
export { Abs, Absent, AbsentOverTime, Acos, Acosh, Add, AggregateExpr, AggregateModifier, AggregateOp, And, Asin, Asinh, At, AtModifierPreprocessors, Atan, Atan2, Atanh, Avg, AvgOverTime, BinaryExpr, Bool, BoolModifier, Bottomk, By, Ceil, Changes, Clamp, ClampMax, ClampMin, Cos, Cosh, Count, CountOverTime, CountValues, DayOfMonth, DayOfWeek, DayOfYear, DaysInMonth, Deg, Delta, Deriv, Div, DoubleExponentialSmoothing, End, Eql, EqlRegex, EqlSingle, Exp, Floor, FunctionCall, FunctionCallBody, FunctionIdentifier, Group, GroupLeft, GroupRight, GroupingLabels, Gte, Gtr, HistogramAvg, HistogramCount, HistogramFraction, HistogramQuantile, HistogramStdDev, HistogramStdVar, HistogramSum, Hour, Idelta, Identifier, Ignoring, Increase, Irate, LabelJoin, LabelMatchers, LabelName, LabelReplace, LastOverTime, LimitK, LimitRatio, LineComment, Ln, Log10, Log2, Lss, Lte, MadOverTime, MatchOp, MatchingModifierClause, MatrixSelector, Max, MaxOverTime, MetricName, Min, MinOverTime, Minute, Mod, Month, Mul, Neq, NeqRegex, NumberDurationLiteral, NumberDurationLiteralInDurationContext, Offset, OffsetExpr, On, Or, ParenExpr, Pi, Pow, PredictLinear, PresentOverTime, PromQL, Quantile, QuantileOverTime, QuotedLabelMatcher, QuotedLabelName, Rad, Rate, Resets, Round, Scalar, Sgn, Sin, Sinh, Sort, SortByLabel, SortByLabelDesc, SortDesc, Sqrt, Start, Stddev, StddevOverTime, Stdvar, StdvarOverTime, StepInvariantExpr, StringLiteral, Sub, SubqueryExpr, Sum, SumOverTime, Tan, Tanh, Time, Timestamp, Topk, UnaryExpr, UnaryOp, Unless, UnquotedLabelMatcher, Vector, VectorSelector, Without, Year, inf, nan, parser };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prometheus-io/lezer-promql",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.300.0-beta.1",
|
|
4
4
|
"description": "lezer-based PromQL grammar",
|
|
5
5
|
"main": "dist/index.cjs",
|
|
6
6
|
"type": "module",
|
|
@@ -32,7 +32,8 @@
|
|
|
32
32
|
"devDependencies": {
|
|
33
33
|
"@lezer/generator": "^1.7.1",
|
|
34
34
|
"@lezer/highlight": "^1.2.0",
|
|
35
|
-
"@lezer/lr": "^1.4.2"
|
|
35
|
+
"@lezer/lr": "^1.4.2",
|
|
36
|
+
"@rollup/plugin-node-resolve": "^15.2.3"
|
|
36
37
|
},
|
|
37
38
|
"peerDependencies": {
|
|
38
39
|
"@lezer/highlight": "^1.1.2",
|