Skip to content

Commit f5fd029

Browse files
committed
Updating changelog, release notes and references to the previous release version.
1 parent 2dc7226 commit f5fd029

File tree

7 files changed

+409
-36
lines changed

7 files changed

+409
-36
lines changed

CHANGELOG.md

+293-6
Large diffs are not rendered by default.

README.md

+2-8
Original file line numberDiff line numberDiff line change
@@ -40,14 +40,8 @@ Loki differs from Prometheus by focusing on logs instead of metrics, and deliver
4040

4141
### Documentation
4242

43-
* [master](https://grafana.com/docs/loki/latest/)
44-
* [v1.5.0](https://github.com/grafana/loki/tree/v1.5.0/docs/README.md)
45-
* [v1.4.1](https://github.com/grafana/loki/tree/v1.4.1/docs/README.md)
46-
* [v1.4.0](https://github.com/grafana/loki/tree/v1.4.0/docs/README.md)
47-
* [v1.3.0](https://github.com/grafana/loki/tree/v1.3.0/docs/README.md)
48-
* [v1.2.0](https://github.com/grafana/loki/tree/v1.2.0/docs/README.md)
49-
* [v1.1.0](https://github.com/grafana/loki/tree/v1.1.0/docs/README.md)
50-
* [v1.0.0](https://github.com/grafana/loki/tree/v1.0.0/docs/README.md)
43+
* [Most Recent Release](https://grafana.com/docs/loki/latest/)
44+
* [Unreleased](https://grafana.com/docs/loki/next/)
5145

5246
Commonly used sections:
5347

docs/sources/installation/docker.md

+9-9
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@ For production, we recommend installing with Tanka or Helm.
1818
Copy and paste the commands below into your command line.
1919

2020
```bash
21-
wget https://raw.githubusercontent.com/grafana/loki/v2.2.1/cmd/loki/loki-local-config.yaml -O loki-config.yaml
22-
docker run -v $(pwd):/mnt/config -p 3100:3100 grafana/loki:2.2.1 -config.file=/mnt/config/loki-config.yaml
23-
wget https://raw.githubusercontent.com/grafana/loki/v2.2.1/cmd/promtail/promtail-docker-config.yaml -O promtail-config.yaml
24-
docker run -v $(pwd):/mnt/config -v /var/log:/var/log grafana/promtail:2.2.1 -config.file=/mnt/config/promtail-config.yaml
21+
wget https://raw.githubusercontent.com/grafana/loki/v2.3.0/cmd/loki/loki-local-config.yaml -O loki-config.yaml
22+
docker run -v $(pwd):/mnt/config -p 3100:3100 grafana/loki:2.3.0 -config.file=/mnt/config/loki-config.yaml
23+
wget https://raw.githubusercontent.com/grafana/loki/v2.3.0/cmd/promtail/promtail-docker-config.yaml -O promtail-config.yaml
24+
docker run -v $(pwd):/mnt/config -v /var/log:/var/log grafana/promtail:2.3.0 -config.file=/mnt/config/promtail-config.yaml
2525
```
2626

2727
When finished, `loki-config.yaml` and `promtail-config.yaml` are downloaded in the directory you chose. Docker containers are running Loki and Promtail using those config files.
@@ -36,10 +36,10 @@ Copy and paste the commands below into your terminal. Note that you will need to
3636

3737
```bash
3838
cd "<local-path>"
39-
wget https://raw.githubusercontent.com/grafana/loki/v2.2.1/cmd/loki/loki-local-config.yaml -O loki-config.yaml
40-
docker run -v <local-path>:/mnt/config -p 3100:3100 grafana/loki:2.2.1 --config.file=/mnt/config/loki-config.yaml
41-
wget https://raw.githubusercontent.com/grafana/loki/v2.2.1/cmd/promtail/promtail-docker-config.yaml -O promtail-config.yaml
42-
docker run -v <local-path>:/mnt/config -v /var/log:/var/log grafana/promtail:2.2.1 --config.file=/mnt/config/promtail-config.yaml
39+
wget https://raw.githubusercontent.com/grafana/loki/v2.3.0/cmd/loki/loki-local-config.yaml -O loki-config.yaml
40+
docker run -v <local-path>:/mnt/config -p 3100:3100 grafana/loki:2.3.0 --config.file=/mnt/config/loki-config.yaml
41+
wget https://raw.githubusercontent.com/grafana/loki/v2.3.0/cmd/promtail/promtail-docker-config.yaml -O promtail-config.yaml
42+
docker run -v <local-path>:/mnt/config -v /var/log:/var/log grafana/promtail:2.3.0 --config.file=/mnt/config/promtail-config.yaml
4343
```
4444

4545
When finished, `loki-config.yaml` and `promtail-config.yaml` are downloaded in the directory you chose. Docker containers are running Loki and Promtail using those config files.
@@ -51,6 +51,6 @@ Navigate to http://localhost:3100/metrics to view the output.
5151
Run the following commands in your command line. They work for Windows or Linux systems.
5252

5353
```bash
54-
wget https://raw.githubusercontent.com/grafana/loki/v2.2.1/production/docker-compose.yaml -O docker-compose.yaml
54+
wget https://raw.githubusercontent.com/grafana/loki/v2.3.0/production/docker-compose.yaml -O docker-compose.yaml
5555
docker-compose -f docker-compose.yaml up
5656
```

docs/sources/maintaining/release.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ Loki docs are versioned. Follow the below steps to version Loki docs for this re
107107
>NOTE: Here $LOCAL_LOKI_PATH is your local path where Loki is checked out with correct $VERSION
108108

109109
1. Clone Grafana website [repo](https://github.com/grafana/website)
110-
1. Create new branch `git checkout -b $VERSION` (replace `$VERSION` with current release version. e.g: `v2.2.1`)
110+
1. Create new branch `git checkout -b $VERSION` (replace `$VERSION` with current release version. e.g: `v2.3.0`)
111111
1. Run `mv content/docs/loki/next content/docs/loki/next.main`
112112
1. Run `mkdir content/docs/loki/next`
113113
1. Run `cp -R $LOCAL_LOKI_PATH/docs/sources/* content/docs/loki/next`

docs/sources/release-notes/v2-3.md

+75-10
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,86 @@ title: V2.3
44

55
# Version 2.3 release notes
66

7-
Prose here about 2.3.
7+
The Loki team is excited to announce the release of Loki 2.3!
8+
9+
It's been nearly 6 months since 2.2 was released and we have made good use of that time to bring forward several significant improvements and requested features.
10+
11+
2.3 is also the first version of Loki released under the AGPLv3 license. You can [read more about our licensing here](https://grafana.com/licensing/).
12+
13+
Some parts of the Loki repo will remain Apache-2.0 licensed (mainly clients and some tooling), for more details please read [LICENSING.md](https://github.com/grafana/loki/blob/main/LICENSING.md).
814

915
## Features and enhancements
1016

11-
List of features here.
17+
* Loki now has the ability to apply [custom retention](../../operations/storage/retention/) based on stream selectors! This will allow much finer control over log retention all of which is now handled by Loki, no longer requiring the use of object store configs for retention.
18+
* Coming along hand in hand with storing logs for longer durations is the ability to [delete log streams](../../operations/storage/logs-deletion/). The initial implementation lets you submit delete request jobs which will be processed after 24 hours.
19+
* A very exciting new LogQL parser has been introduced: the [pattern parser](../../logql/#parser-expression). Much simpler and faster than regexp for log lines that have a little bit of structure to them such as the [Common Log Format](https://en.wikipedia.org/wiki/Common_Log_Format). This is now Loki's fastest parser so try it out on any of your log lines!
20+
* Extending on the work of Alerting Rules, Loki now accepts [recording rules](../../rules/#recording-rules). This lets you turn your logs into metrics and push them to Prometheus or any Prometheus compatible remote_write endpoint.
21+
* LogQL can understand [IP addresses](../../logql/ip/)! This enables filtering on IP addresses and subnet ranges.
22+
23+
For those of you running Loki as microservices, the following features will improve performance operations significantly for many operations.
24+
25+
* We created an [index gateway](../../operations/storage/boltdb-shipper/#index-gateway) which takes on the task of downloading the boltdb-shipper index files allowing you to run your queriers without any local disk requirements, this is really helpful in Kubernetes environments where you can return your queriers from Statefulsets back to Deployments and save a lot of PVC costs and operational headaches.
26+
* Ingester queriers [are now shardable](https://github.com/grafana/loki/pull/3852), this is a significant performance boost for high volume log streams when querying recent data.
27+
* Instant queries can now be [split and sharded](https://github.com/grafana/loki/pull/3984) making them just as fast as range queries.
28+
29+
A very common feature requested has also been included in 2.3:
30+
31+
* [3919](https://github.com/grafana/loki/pull/3919) **github-vincent-miszczak**: Add ingester.autoforget-unhealthy-timeout opt-in feature
32+
33+
Without revisiting the decisions and discussions around the somewhat controversial behavior of _unhealthy_ ingesters, you can now decided how you would like them to be handled: manually or automatically.
34+
35+
Lastly several useful additions to the LogQL query language have been included:
36+
37+
* More text/template functions are included for `label_format` and `line_format` with PR [3515](https://github.com/grafana/loki/pull/3515), please check out the [documentation for template functions](https://grafana.com/docs/loki/latest/logql/template_functions/).
38+
* Also support for math functions withing `label_format` and `line_format` was included with [3434](https://github.com/grafana/loki/pull/3434).
39+
* Two additional metric functions with some interesting use cases `first_over_time` and `last_over_time` were added in PR [3050](https://github.com/grafana/loki/pull/3050). These can be useful for some down sampling approaches where instead of taking an average, max, or min of samples over a range in a metrics query, you can select the first or last log line to use from that range.
40+
41+
## Upgrade considerations
42+
43+
The path from 2.2.1 to 2.3.0 should be smooth, as always, please check out the [Upgrade Guide](https://github.com/grafana/loki/blob/master/docs/sources/upgrading/_index.md#230) for important upgrade guidance.
44+
45+
One change we consider noteworthy however is:
46+
47+
* [3216](https://github.com/grafana/loki/pull/3216) **sandeepsukhani**: check for stream selectors to have at least one equality matcher.
48+
49+
This change now rejects any query which does not contain at least one equality matcher, an example may better illustrate:
50+
51+
`{namespace=~".*"}`
52+
53+
This query will now be rejected, however there are several ways to modify it for it to succeed:
54+
55+
Add at least one equals label matcher:
56+
57+
`{cluster="us-east-1",namespace=~".*"}`
58+
59+
Use `.+` instead of `.*`
60+
61+
`{namespace=~".+"}`
62+
63+
This difference may seem subtle but if we break it down `.` matches any character, `*` matches zero or more of the preceding character and `+` matches one or more of the preceding character. The `.*` case will match empty values where `.+` will not, this is the important difference. `{namespace=""}` is an invalid request (unless you add another equals label matcher like the example above).
64+
65+
The reasoning for this change has to do with how index lookups work in Loki, if you don't have at least one equality matcher Loki has to perform a complete index table scan which is an expensive and slow operation.
66+
67+
68+
69+
## Security fixes
70+
71+
List of security fixes for 2.3.x.
72+
73+
### 2.3.0 security fixes
74+
75+
2.3.0 contains an important security fix:
76+
77+
* [4020](https://github.com/grafana/loki/pull/4020) **simonswine**: Restrict path segments in TenantIDs (CVE-2021-36156 CVE-2021-36157).
78+
79+
**Note** Exploitation of this vulnerability requires the ability for an attacker to craft and send directly to Loki an `X-Scope-OrgID` header, end users should not have the ability to create and send this header directly to Loki as it controls access to tenants and is important to control setting of this header for proper tenant isolation and security. We always recommend having a proxy or gateway be responsible for setting the `X-Scope-OrgID`.
1280

13-
- Pattern parser. [poor docs link to Parser expression](../../logql/#parser-expression)
14-
- Windows event log scraping. [docs link](../../clients/promtail/scraping/#windows-event-log)
15-
- Recording rules.
16-
- Index Gateway.
17-
- Retention.
18-
- `promtail_instance` label.
1981

2082
## Bug fixes
2183

22-
Lists of bug fixes for v2.3.x.
84+
Lists of bug fixes for 2.3.x.
85+
86+
### 2.3.0 bug fixes
2387

24-
### V2.3.0 bug fixes
88+
* An important fix for leaking resources was patched with [3733](https://github.com/grafana/loki/pull/3733), when queries were canceled a goroutine was left running which would hold memory resources creating a memory leak.
89+
* [3686](https://github.com/grafana/loki/pull/3686) fixes a panic with the frontend when use with downstream URL. **Note** we recommend using the [GRPC Pull Model](https://grafana.com/docs/loki/latest/configuration/query-frontend/#grpc-mode-pull-model), better performance and fair scheduling between tenants can be obtained with the GPRC Pull Model.

docs/sources/upgrading/_index.md

+27
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,33 @@ If possible try to stay current and do sequential updates. If you want to skip v
1919

2020
-_add changes here which are unreleased_
2121

22+
## 2.3.0
23+
24+
### Loki
25+
26+
#### Query restriction introduced for queries which do not have at least one equality matcher
27+
28+
PR [3216](https://github.com/grafana/loki/pull/3216) **sandeepsukhani**: check for stream selectors to have at least one equality matcher
29+
30+
This change now rejects any query which does not contain at least one equality matcher, an example may better illustrate:
31+
32+
`{namespace=~".*"}`
33+
34+
This query will now be rejected, however there are several ways to modify it for it to succeed:
35+
36+
Add at least one equals label matcher:
37+
38+
`{cluster="us-east-1",namespace=~".*"}`
39+
40+
Use `.+` instead of `.*`
41+
42+
`{namespace=~".+"}`
43+
44+
This difference may seem subtle but if we break it down `.` matches any character, `*` matches zero or more of the preceding character and `+` matches one or more of the preceding character. The `.*` case will match empty values where `.+` will not, this is the important difference. `{namespace=""}` is an invalid request (unless you add another equals label matcher like the example above)
45+
46+
The reasoning for this change has to do with how index lookups work in Loki, if you don't have at least one equality matcher Loki has to perform a complete index table scan which is an expensive and slow operation.
47+
48+
2249
## 2.2.0
2350

2451
### Loki

production/docker-compose.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ networks:
55

66
services:
77
loki:
8-
image: grafana/loki:2.2.1
8+
image: grafana/loki:2.3.0
99
ports:
1010
- "3100:3100"
1111
command: -config.file=/etc/loki/local-config.yaml
1212
networks:
1313
- loki
1414

1515
promtail:
16-
image: grafana/promtail:2.2.1
16+
image: grafana/promtail:2.3.0
1717
volumes:
1818
- /var/log:/var/log
1919
command: -config.file=/etc/promtail/config.yml

0 commit comments

Comments
 (0)