Skip to content

Commit 0dc6d06

Browse files
authored
Upgrade loki and related dependencies (#277)
1 parent 96f4336 commit 0dc6d06

File tree

5,902 files changed

+1043521
-328307
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

5,902 files changed

+1043521
-328307
lines changed

.github/workflows/validate_pr.yml

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -9,30 +9,34 @@ jobs:
99
name: Lint
1010
runs-on: ubuntu-latest
1111
steps:
12-
- uses: actions/checkout@v2
12+
- uses: actions/checkout@v3
13+
- uses: actions/setup-go@v4
14+
with:
15+
go-version: '1.21'
16+
cache: false
1317
- name: golangci-lint
14-
uses: golangci/golangci-lint-action@v2
18+
uses: golangci/golangci-lint-action@v3.7.0
1519
with:
16-
version: v1.31
20+
version: v1.54.2
1721
unit_tests:
1822
name: Unit-Tests
1923
runs-on: ubuntu-latest
2024
steps:
21-
- uses: actions/checkout@v2
22-
- name: Set up Go 1.16
23-
uses: actions/setup-go@v1
25+
- uses: actions/checkout@v3
26+
- name: Set up Go 1.21
27+
uses: actions/setup-go@v4
2428
with:
25-
go-version: 1.16
29+
go-version: 1.21
2630
- name: Unit Tests
2731
run: make test
2832
build:
2933
name: Build Binaries
3034
runs-on: ubuntu-latest
3135
steps:
32-
- uses: actions/checkout@v2
33-
- name: Set up Go 1.16
34-
uses: actions/setup-go@v1
36+
- uses: actions/checkout@v3
37+
- name: Set up Go 1.21
38+
uses: actions/setup-go@v4
3539
with:
36-
go-version: 1.16
40+
go-version: 1.21
3741
- name: Build All
3842
run: make all

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,4 @@ dist/
1313
/metrics-in-grafana.json
1414
/prometheus-metrics.json
1515
/metrics-in-ruler.json
16+
.idea

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ Order should be `CHANGE`, `FEATURE`, `ENHANCEMENT`, and `BUGFIX`
66

77
* [FEATURE] Support Arm64 on Darwin for all binaries (benchtool etc). #215
88
* [BUGFIX] Fix `cortextool rules` legends displaying wrong symbols for updates and deletions. #226
9+
* [CHANGE] Upgrade modules to latest versions
910

1011
## v0.10.7
1112

Makefile

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,10 @@ GIT_REVISION := $(shell git rev-parse --short HEAD)
77
GIT_BRANCH := $(shell git rev-parse --abbrev-ref HEAD)
88
GO_FLAGS := -mod=vendor -ldflags "-extldflags \"-static\" -s -w -X $(VPREFIX).Branch=$(GIT_BRANCH) -X $(VPREFIX).Version=$(IMAGE_TAG) -X $(VPREFIX).Revision=$(GIT_REVISION)" -tags netgo
99

10-
all: cortextool chunktool logtool
11-
images: cortextool-image chunktool-image logtool-image benchtool-image
10+
all: cortextool logtool
11+
images: cortextool-image logtool-image benchtool-image
1212
benchtool: cmd/benchtool/benchtool
1313
cortextool: cmd/cortextool/cortextool
14-
chunktool: cmd/chunktool/chunktool
1514
logtool: cmd/logtool/logtool
1615
e2ealerting: cmd/e2ealerting/e2ealerting
1716
blockscopy: cmd/blockscopy/blockscopy
@@ -24,10 +23,6 @@ cortextool-image:
2423
$(SUDO) docker build -t $(IMAGE_PREFIX)/cortextool -f cmd/cortextool/Dockerfile .
2524
$(SUDO) docker tag $(IMAGE_PREFIX)/cortextool $(IMAGE_PREFIX)/cortextool:$(IMAGE_TAG)
2625

27-
chunktool-image:
28-
$(SUDO) docker build -t $(IMAGE_PREFIX)/chunktool -f cmd/chunktool/Dockerfile .
29-
$(SUDO) docker tag $(IMAGE_PREFIX)/chunktool $(IMAGE_PREFIX)/chunktool:$(IMAGE_TAG)
30-
3126
logtool-image:
3227
$(SUDO) docker build -t $(IMAGE_PREFIX)/logtool -f cmd/logtool/Dockerfile .
3328
$(SUDO) docker tag $(IMAGE_PREFIX)/logtool $(IMAGE_PREFIX)/logtool:$(IMAGE_TAG)
@@ -48,9 +43,6 @@ cmd/benchtool/benchtool: $(APP_GO_FILES) cmd/benchtool/main.go
4843
cmd/cortextool/cortextool: $(APP_GO_FILES) cmd/cortextool/main.go
4944
CGO_ENABLED=0 go build $(GO_FLAGS) -o $@ ./$(@D)
5045

51-
cmd/chunktool/chunktool: $(APP_GO_FILES) cmd/chunktool/main.go
52-
CGO_ENABLED=0 go build $(GO_FLAGS) -o $@ ./$(@D)
53-
5446
cmd/logtool/logtool: $(APP_GO_FILES) cmd/logtool/main.go
5547
CGO_ENABLED=0 go build $(GO_FLAGS) -o $@ ./$(@D)
5648

@@ -70,7 +62,6 @@ cross:
7062
CGO_ENABLED=0 gox -output="dist/{{.Dir}}-{{.OS}}-{{.Arch}}" -ldflags=${LDFLAGS} -arch="amd64" -os="linux windows darwin" -osarch="darwin/arm64" ./cmd/benchtool
7163
CGO_ENABLED=0 gox -output="dist/{{.Dir}}-{{.OS}}-{{.Arch}}" -ldflags=${LDFLAGS} -arch="amd64" -os="linux windows darwin" -osarch="darwin/arm64" ./cmd/blockgen
7264
CGO_ENABLED=0 gox -output="dist/{{.Dir}}-{{.OS}}-{{.Arch}}" -ldflags=${LDFLAGS} -arch="amd64" -os="linux windows darwin" -osarch="darwin/arm64" ./cmd/blockscopy
73-
CGO_ENABLED=0 gox -output="dist/{{.Dir}}-{{.OS}}-{{.Arch}}" -ldflags=${LDFLAGS} -arch="amd64" -os="linux windows darwin" -osarch="darwin/arm64" ./cmd/chunktool
7465
CGO_ENABLED=0 gox -output="dist/{{.Dir}}-{{.OS}}-{{.Arch}}" -ldflags=${LDFLAGS} -arch="amd64" -os="linux windows darwin" -osarch="darwin/arm64" ./cmd/cortextool
7566
CGO_ENABLED=0 gox -output="dist/{{.Dir}}-{{.OS}}-{{.Arch}}" -ldflags=${LDFLAGS} -arch="amd64" -os="linux windows darwin" -osarch="darwin/arm64" ./cmd/e2ealerting
7667
CGO_ENABLED=0 gox -output="dist/{{.Dir}}-{{.OS}}-{{.Arch}}" -ldflags=${LDFLAGS} -arch="amd64" -os="linux windows darwin" -osarch="darwin/arm64" ./cmd/logtool
@@ -83,7 +74,6 @@ test:
8374
clean:
8475
rm -rf cmd/benchtool/benchtool
8576
rm -rf cmd/cortextool/cortextool
86-
rm -rf cmd/chunktool/chunktool
8777
rm -rf cmd/logtool/logtool
8878
rm -rf cmd/e2ealerting/e2ealerting
8979
rm -rf cmd/blockscopy/blockscopy

README.md

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ This repo contains tools used for interacting with [Cortex](https://github.com/c
1414
* [benchtool](docs/benchtool.md): A powerful YAML driven tool for benchmarking
1515
Cortex write and query API.
1616
* [cortextool](#cortextool): Interacts with user-facing Cortex APIs and backend storage components.
17-
* [chunktool](#chunktool): Interacts with chunks stored and indexed in Cortex storage backends.
1817
* [logtool](#logtool): Tool which parses Cortex query-frontend logs and formats them for easy analysis.
1918
* [e2ealerting](docs/e2ealerting.md): Tool that helps measure how long an alert takes from scrape of sample to Alertmanager notification delivery.
2019

@@ -386,25 +385,6 @@ This command accepts Prometheus rule YAML files as input and extracts Prometheus
386385
cortextool analyse rule-file ./rule_file_one.yaml ./rule_file_two.yaml ...
387386
```
388387

389-
## chunktool
390-
391-
This repo also contains the `chunktool`. A client meant to interact with chunks stored and indexed in cortex backends.
392-
393-
##### Chunk Delete
394-
395-
The delete command currently cleans all index entries pointing to chunks in the specified index. Only bigtable and the v10 schema are currently fully supported. This will not delete the entire index entry, only the corresponding chunk entries within the index row.
396-
397-
##### Chunk Migrate
398-
399-
The migrate command helps with migrating chunks across cortex clusters. It also takes care of setting right index in the new cluster as per the specified schema config.
400-
401-
As of now it only supports `Bigtable` or `GCS` as a source to read chunks from for migration. For writing it supports all the storages that Cortex supports.
402-
More details about it [here](./pkg/chunk/migrate/README.md)
403-
404-
##### Chunk Validate/Clean-Index
405-
406-
The `chunk validate-index` and `chunk clean-index` command allows users to scan their index and chunk backends for invalid entries. The `validate-index` command will find invalid entries and ouput them to a CSV file. The `clean-index` command will take that CSV file as input and delete the invalid entries.
407-
408388
## logtool
409389

410390
A CLI tool to parse Cortex query-frontend logs and formats them for easy analysis.

cmd/benchtool/main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import (
99
"os/signal"
1010

1111
logutil "github.com/cortexproject/cortex/pkg/util/log"
12-
"github.com/go-kit/kit/log/level"
12+
"github.com/go-kit/log/level"
1313
"github.com/grafana/dskit/flagext"
1414
"github.com/prometheus/client_golang/prometheus"
1515
"github.com/prometheus/client_golang/prometheus/promhttp"

cmd/chunktool/Dockerfile

Lines changed: 0 additions & 12 deletions
This file was deleted.

cmd/chunktool/main.go

Lines changed: 0 additions & 25 deletions
This file was deleted.

cmd/e2ealerting/main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import (
44
"flag"
55
"os"
66

7-
"github.com/go-kit/kit/log/level"
7+
"github.com/go-kit/log/level"
88
"github.com/grafana/cortex-tools/pkg/alerting"
99

1010
util_log "github.com/cortexproject/cortex/pkg/util/log"

cmd/rules-migrator/main.go

Lines changed: 0 additions & 116 deletions
This file was deleted.

0 commit comments

Comments
 (0)