Skip to content

Partitioning compaction for Cortex #5025

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 133 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
133 commits
Select commit Hold shift + click to select a range
269cbea
Partitioning compaction for Cortex
alexqyle Dec 6, 2022
f2e60cc
Fixed lint
alexqyle Dec 7, 2022
5f37f26
Refactored thans and prometheus changes
alexqyle Jan 3, 2023
e83e079
clean up - https://github.com/cortexproject/cortex/pull/2599 (#5031)
alanprot Dec 9, 2022
15a91a6
clean up - https://github.com/cortexproject/cortex/pull/2599 (#5031)
alanprot Dec 9, 2022
1a15675
increase queue duration histogram bucket (#5029)
yeya24 Dec 10, 2022
ace5cd1
Add counter metrics for total requests going to queue (#5030)
yeya24 Dec 10, 2022
3c33a7d
Bump github.com/lib/pq from 1.3.0 to 1.10.7 (#5023)
dependabot[bot] Dec 11, 2022
ba8b3e8
Bump github.com/spf13/afero from 1.6.0 to 1.9.3 (#5022)
dependabot[bot] Dec 11, 2022
30bee47
Bump github.com/stretchr/testify from 1.8.0 to 1.8.1 (#5020)
dependabot[bot] Dec 11, 2022
35078ff
Bump github.com/mitchellh/go-wordwrap from 1.0.0 to 1.0.1 (#5019)
dependabot[bot] Dec 11, 2022
9c5445c
Bump go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc …
dependabot[bot] Dec 13, 2022
38a0b43
Bump github.com/alicebob/miniredis/v2 from 2.22.0 to 2.23.1 (#5032)
dependabot[bot] Dec 13, 2022
b271db2
Logging Vertical Sharding info on query stats (#5037)
alanprot Dec 13, 2022
7bf7669
Bump go.opentelemetry.io/contrib/propagators/aws from 1.11.1 to 1.12.…
dependabot[bot] Dec 14, 2022
e2dc0bf
Ingester: Metadata APIs should honour QueryIngestersWithin when Query…
harry671003 Dec 14, 2022
0ac83e7
Building Arm Images (#5041)
alanprot Dec 15, 2022
66e86eb
update thanos to latest main 4054531421b5fc88286b8757f86767ec41100082…
yeya24 Dec 15, 2022
06556f7
Fix tracing.NewRandomRatioBased panic (#5044)
alanprot Dec 15, 2022
6cb8a34
Remove flapping test in tracing sampling (#5047)
friedrichg Dec 16, 2022
1f060d6
Fix opsgenie validation (#5045)
friedrichg Dec 16, 2022
bcdfd6c
Bump golang.org/x/net from 0.2.0 to 0.4.0 (#5054)
dependabot[bot] Dec 19, 2022
489da37
Bump github.com/golang-migrate/migrate/v4 from 4.7.0 to 4.15.2 (#5053)
dependabot[bot] Dec 20, 2022
dac9421
Bump github.com/armon/go-metrics from 0.4.0 to 0.4.1 (#5050)
dependabot[bot] Dec 20, 2022
8dfd02b
Bump github.com/felixge/fgprof from 0.9.2 to 0.9.3 (#5051)
dependabot[bot] Dec 20, 2022
6c8befc
Test example config with filesystem backend (#5072)
friedrichg Dec 30, 2022
fce38be
Bump github.com/hashicorp/consul/api from 1.17.0 to 1.18.0 (#5066)
dependabot[bot] Dec 30, 2022
caabc49
Bump go.etcd.io/etcd/client/v3 from 3.5.4 to 3.5.6 (#5064)
dependabot[bot] Dec 30, 2022
6236cfa
Create Span for the codec MergeResponse method (#5075)
alanprot Dec 30, 2022
2ee2fe7
Bump github.com/prometheus/client_golang from 1.13.0 to 1.14.0 (#5065)
dependabot[bot] Dec 30, 2022
99b4432
switch encoding/json to json iter (#5069)
yeya24 Dec 30, 2022
d612221
Run integration tests in parallel (#5073)
friedrichg Dec 31, 2022
0fda0d1
Get second port without closing first one to prevent port clashing (#…
friedrichg Jan 3, 2023
0908c6f
Parallelize distributor tests (#5076)
friedrichg Jan 3, 2023
16b7a8f
Skip instant query round tripper if sharding is not applicable. (#5062)
yeya24 Jan 3, 2023
7d51ad9
stop using FromMetricsToLabelAdapters (#5078)
yeya24 Jan 3, 2023
350f5a4
Fixed compile error
alexqyle Jan 3, 2023
a6791f0
Revert prometheus parallelism change
alexqyle Jan 31, 2023
7000ee9
chore: Updating Prometheus to v0.40.7 and Thanos to 3327c510076a (#5048)
alanprot Jan 11, 2023
817a795
Bump github.com/minio/minio-go/v7 from 7.0.45 to 7.0.46 (#5082)
dependabot[bot] Jan 11, 2023
0176201
Bump github.com/alicebob/miniredis/v2 from 2.23.1 to 2.30.0 (#5084)
dependabot[bot] Jan 11, 2023
18df1e8
Bump golang.org/x/time from 0.1.0 to 0.3.0 (#5088)
dependabot[bot] Jan 11, 2023
b3e9aa0
Support Zstd compression for gRPC (#5092)
ssesha Jan 12, 2023
f71c349
remove go.mod replacement for weaveworks/common (#5094)
kama910 Jan 12, 2023
b56b148
Add support for new thanos promql engine (#5093)
yeya24 Jan 12, 2023
be52dd5
use labels Bytes rather than String for map key (#5095)
yeya24 Jan 17, 2023
dcc4891
frontend/transport: print Grafana specific headers in slow query log …
GiedriusS Jan 20, 2023
30c6e4c
Fix Flaky Test (#5100)
alanprot Jan 21, 2023
41becac
Update promql engine to fix stats panic (#5099)
yeya24 Jan 24, 2023
43a417d
Add dynamodb multikey kv (#5026)
danielblando Jan 24, 2023
baf9bb1
Bump github.com/dustin/go-humanize from 1.0.0 to 1.0.1 (#5098)
dependabot[bot] Jan 25, 2023
6e842ad
Bump golang.org/x/net from 0.4.0 to 0.5.0 (#5083)
dependabot[bot] Jan 25, 2023
198599c
Change log level for 4xx on Push API. Do not log on 429 (#5103)
danielblando Jan 26, 2023
bdbb8d7
include status code in query frontend query stats logs (#5104)
yeya24 Jan 27, 2023
87ca5c5
Rename oltp_endpoint to otlp_endpoint to match opentelemetry spec and…
sharkymcdongles Jan 27, 2023
80f14cb
Bump github.com/prometheus/common from 0.37.0 to 0.39.0 (#5052)
dependabot[bot] Jan 29, 2023
7d1ed3d
Bump github.com/minio/minio-go/v7 from 7.0.46 to 7.0.47 (#5096)
dependabot[bot] Jan 29, 2023
79e3017
Bump github.com/aws/aws-sdk-go from 1.44.156 to 1.44.189 (#5110)
dependabot[bot] Jan 30, 2023
705d526
Bump go.opentelemetry.io/otel/sdk from 1.11.2 to 1.12.0 (#5111)
dependabot[bot] Jan 31, 2023
a9e26b3
Update thanos and prometheus (#5114)
alanprot Jan 31, 2023
61438ce
fix response status code panic (#5117)
kama910 Feb 2, 2023
1bfd076
Bump go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc …
dependabot[bot] Feb 2, 2023
ba5a005
Support enabled_tenants and disabled_tenants in alertmanager (#5116)
friedrichg Feb 2, 2023
b167894
Bump github.com/klauspost/compress from 1.15.14 to 1.15.15 (#5108)
dependabot[bot] Feb 2, 2023
530f961
query frontend: get error from response body (#5118)
yeya24 Feb 2, 2023
35a09ee
Make TSDB max exemplars config per tenant (#5080)
sahnib Feb 2, 2023
599f8f8
Rename max exemplars limit flag to ingester.max-exemplars. (#5122)
Feb 3, 2023
64e4b16
Update Dockerfiles to use Alpine 3.17 (#5132)
alexku7 Feb 9, 2023
d2fc6c9
fix conflict schema url when initializing resources (#5140)
yeya24 Feb 10, 2023
e41a88c
Using otel tracer sampler (#5141)
alanprot Feb 11, 2023
414e965
Remove Weave cloud and Grafana Cloud Reference from docs (#5138)
friedrichg Feb 11, 2023
869b69e
initialize querier stats in QFE only if it is not enabled (#5142)
yeya24 Feb 14, 2023
c273e67
Bump go.etcd.io/etcd/client/pkg/v3 from 3.5.6 to 3.5.7 (#5125)
dependabot[bot] Feb 14, 2023
36fced7
Add redis as index cache and caching bucket backend (#5057)
yeya24 Feb 14, 2023
e138bb3
Bump go.opentelemetry.io/contrib/propagators/aws from 1.12.0 to 1.14.…
dependabot[bot] Feb 14, 2023
63424d8
Bump go.etcd.io/etcd/api/v3 from 3.5.6 to 3.5.7 (#5126)
dependabot[bot] Feb 14, 2023
012deb8
Bump go.opentelemetry.io/otel/exporters/otlp/otlptrace (#5163)
dependabot[bot] Feb 21, 2023
5bc269f
Bump github.com/minio/minio-go/v7 from 7.0.47 to 7.0.49 (#5160)
dependabot[bot] Feb 21, 2023
295ff79
Bump golang.org/x/net from 0.5.0 to 0.7.0 (#5161)
dependabot[bot] Feb 21, 2023
8bcc486
Update README.md for chunk deprecation note (#5164)
alvinlin123 Feb 21, 2023
8d6adfa
Disabling ValidateJsonRawMessage flag from json jsoniter (#5167)
alanprot Feb 22, 2023
0b21bdc
StoreGateway: Allow filtering out recent blocks during sync (#5166)
harry671003 Feb 22, 2023
76c949b
remove unnecessary sprintf (#5173)
kama910 Feb 24, 2023
77eca8a
Bump go.etcd.io/etcd/client/v3 from 3.5.6 to 3.5.7 (#5162)
dependabot[bot] Feb 24, 2023
607b748
add a trace span for merging series from ingesters (#5176)
yeya24 Feb 24, 2023
cb352bb
[chore] Update Prometheus/Thanos/Thanos engine (#5177)
alanprot Feb 24, 2023
de57ecf
Bump github.com/stretchr/testify from 1.8.1 to 1.8.2 (#5183)
dependabot[bot] Feb 27, 2023
8248399
Bump github.com/klauspost/compress from 1.15.15 to 1.16.0 (#5181)
dependabot[bot] Feb 27, 2023
fd7043b
Bump github.com/thanos-io/thanos (#5182)
dependabot[bot] Feb 27, 2023
9da5574
Bump github.com/Masterminds/squirrel (#5180)
dependabot[bot] Feb 28, 2023
1e78d22
Retry logic for S3 bucket client (#5135)
alexqyle Feb 28, 2023
0275696
Update Dockerfile (#5159)
mehrdadbn9 Mar 3, 2023
d256639
change doc generation to order reference alphanumerical (#5191)
fbegyn Mar 3, 2023
c6cc029
Decrease log level for ingester partial failure (#5192)
danielblando Mar 3, 2023
a818202
Bump golang.org/x/net from 0.7.0 to 0.8.0 (#5197)
dependabot[bot] Mar 6, 2023
69ba6d4
Bump go.opentelemetry.io/otel from 1.13.0 to 1.14.0 (#5196)
dependabot[bot] Mar 6, 2023
1f0425d
Bump github.com/prometheus/common (#5194)
dependabot[bot] Mar 6, 2023
5bbeae1
Reuse write request from distributor to Ingesters (#5193)
alanprot Mar 7, 2023
2939439
Fix read reader multiple times in QFE (#5202)
yeya24 Mar 8, 2023
7f99307
Add fetched samples and chunks count into querier stats (#5198)
yeya24 Mar 9, 2023
3407888
add query fuzz test with promqlsmith (#5200)
yeya24 Mar 9, 2023
ca18961
update promqlsmith version (#5208)
yeya24 Mar 13, 2023
e1de2a5
Bump github.com/thanos-io/thanos from 0.31.0-rc.0 to 0.31.0-rc.1 (#5212)
dependabot[bot] Mar 13, 2023
514661c
Implement grpc.Compressor.DecompressedSize for snappy to optimize mem…
damnever Mar 17, 2023
a76ebeb
Bump github.com/klauspost/compress from 1.16.0 to 1.16.3 (#5219)
dependabot[bot] Mar 20, 2023
0cc2860
Bump github.com/hashicorp/consul/api from 1.18.0 to 1.20.0 (#5218)
dependabot[bot] Mar 20, 2023
3fc5b38
Update prometheus to bring in head chunks improvement (#5220)
yeya24 Mar 20, 2023
dbc7f95
enable failures for query fuzzer test (#5225)
yeya24 Mar 22, 2023
0e356b1
remove duplicate code (#5226)
yiyang5055 Mar 22, 2023
a7afa9d
Add build info API to doc (#5227)
alvinlin123 Mar 23, 2023
5fd3d77
prepare release 1.15.0 (#5230)
yeya24 Mar 27, 2023
0484202
Update Prometheus (#5234)
alanprot Mar 27, 2023
a098908
Store Gateway: Convert metrics from summary to histograms (#5239)
friedrichg Mar 30, 2023
b625a16
Add unit test for resolveConflicts function (#5233)
dogukanteber Mar 31, 2023
c74033d
Bump google.golang.org/protobuf from 1.29.0 to 1.29.1 (#5222)
dependabot[bot] Mar 31, 2023
b9e2e97
Fix a typo and a grammar error (#5242)
dogukanteber Apr 3, 2023
d90fd98
Fix typo in architecture diagram (#5249)
alvinlin123 Apr 5, 2023
fe6bbba
Bump github.com/Masterminds/squirrel from 1.5.3 to 1.5.4 (#5247)
dependabot[bot] Apr 6, 2023
fd5b39f
Bump github.com/alicebob/miniredis/v2 from 2.30.0 to 2.30.1 (#5245)
dependabot[bot] Apr 6, 2023
525c86b
Bump github.com/minio/minio-go/v7 from 7.0.49 to 7.0.50 (#5246)
dependabot[bot] Apr 6, 2023
e66a8c8
Bump github.com/aws/aws-sdk-go from 1.44.217 to 1.44.239 (#5255)
dependabot[bot] Apr 11, 2023
18c48cb
Bump golang.org/x/net from 0.8.0 to 0.9.0 (#5256)
dependabot[bot] Apr 11, 2023
8f248dc
Bump github.com/spf13/afero from 1.9.3 to 1.9.5 (#5243)
dependabot[bot] Apr 11, 2023
9ab4512
Bump github.com/grpc-ecosystem/go-grpc-middleware from 1.3.0 to 1.4.0…
dependabot[bot] Apr 11, 2023
81f1951
Bump github.com/segmentio/fasthash (#5244)
dependabot[bot] Apr 11, 2023
257821d
Bump google.golang.org/grpc from 1.53.0 to 1.54.0 (#5271)
dependabot[bot] Apr 21, 2023
a9fb23f
Bump github.com/minio/minio-go/v7 from 7.0.50 to 7.0.52 (#5268)
dependabot[bot] Apr 24, 2023
28377bf
Bump go.etcd.io/etcd/client/pkg/v3 from 3.5.7 to 3.5.8 (#5272)
dependabot[bot] Apr 24, 2023
3ecb986
fix error log in query fuzzer testcase (#5287)
yeya24 Apr 25, 2023
6114dc7
log query response size in QFE and querier (#5288)
yeya24 Apr 25, 2023
76842a5
update 1.15 compatibility test image (#5295)
yeya24 Apr 27, 2023
d348111
Fix changelog for v1.14.0. flag ingester.chunk-encoding was removed t…
friedrichg Apr 29, 2023
c36be53
add cortex 1.15.1 to compatibility test (#5313)
yeya24 May 1, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 4 additions & 0 deletions .github/workflows/scripts/install-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,8 @@ set -x
VER="20.10.19"
curl -L -o /tmp/docker-$VER.tgz https://download.docker.com/linux/static/stable/x86_64/docker-$VER.tgz
tar -xz -C /tmp -f /tmp/docker-$VER.tgz
mkdir -vp ~/.docker/cli-plugins/
curl --silent -L "https://github.com/docker/buildx/releases/download/v0.3.0/buildx-v0.3.0.linux-amd64" > ~/.docker/cli-plugins/docker-buildx
chmod a+x ~/.docker/cli-plugins/docker-buildx
mv /tmp/docker/* /usr/bin
docker run --privileged --rm tonistiigi/binfmt --install all
90 changes: 63 additions & 27 deletions .github/workflows/test-build-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,15 @@ jobs:
lint:
runs-on: ubuntu-20.04
container:
image: quay.io/cortexproject/build-image:upgrade-to-go1.19.3-e8b98ddc0
image: quay.io/cortexproject/build-image:upgrade-to-go1.20.1-pr-5159
steps:
- name: Checkout Repo
uses: actions/checkout@v2
- name: Setup Git safe.directory
run: |
echo "this step is needed because when running in container, actions/checkout does not set safe.directory effectively."
echo "See https://github.com/actions/runner/issues/2033. We should use --system instead of --global"
git config --system --add safe.directory $GITHUB_WORKSPACE
# Commands in the Makefile are hardcoded with an assumed file structure of the CI container
# Symlink ensures paths specified in previous commands don’t break
- name: Sym Link Expected Path to Workspace
Expand All @@ -35,10 +40,15 @@ jobs:
test:
runs-on: ubuntu-20.04
container:
image: quay.io/cortexproject/build-image:upgrade-to-go1.19.3-e8b98ddc0
image: quay.io/cortexproject/build-image:upgrade-to-go1.20.1-pr-5159
steps:
- name: Checkout Repo
uses: actions/checkout@v2
- name: Setup Git safe.directory
run: |
echo "this step is needed because when running in container, actions/checkout does not set safe.directory effectively."
echo "See https://github.com/actions/runner/issues/2033. We should use --system instead of --global"
git config --system --add safe.directory $GITHUB_WORKSPACE
- name: Sym Link Expected Path to Workspace
run: |
mkdir -p /go/src/github.com/cortexproject/cortex
Expand All @@ -49,10 +59,15 @@ jobs:
build:
runs-on: ubuntu-20.04
container:
image: quay.io/cortexproject/build-image:upgrade-to-go1.19.3-e8b98ddc0
image: quay.io/cortexproject/build-image:upgrade-to-go1.20.1-pr-5159
steps:
- name: Checkout Repo
uses: actions/checkout@v2
- name: Setup Git safe.directory
run: |
echo "this step is needed because when running in container, actions/checkout does not set safe.directory effectively."
echo "See https://github.com/actions/runner/issues/2033. We should use --system instead of --global"
git config --system --add safe.directory $GITHUB_WORKSPACE
- name: Install Docker Client
run: ./.github/workflows/scripts/install-docker.sh
- name: Sym Link Expected Path to Workspace
Expand Down Expand Up @@ -88,11 +103,22 @@ jobs:
integration:
needs: build
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
tags:
- requires_docker
- integration_alertmanager
- integration_backward_compatibility
- integration_memberlist
- integration_querier
- integration_ruler
- integration_query_fuzz
steps:
- name: Upgrade golang
uses: actions/setup-go@v2
with:
go-version: 1.19.x
go-version: 1.20.1
- name: Checkout Repo
uses: actions/checkout@v2
- name: Install Docker Client
Expand All @@ -116,35 +142,35 @@ jobs:
# locally and the download time doesn't account in the test execution time, which is subject
# to a timeout
run: |
docker pull minio/minio:RELEASE.2019-12-30T05-45-39Z
docker pull amazon/dynamodb-local:1.11.477
docker pull minio/minio:RELEASE.2021-10-13T00-23-17Z
docker pull consul:1.8.4
docker pull gcr.io/etcd-development/etcd:v3.4.7
docker pull quay.io/cortexproject/cortex:v1.0.0
docker pull quay.io/cortexproject/cortex:v1.1.0
docker pull quay.io/cortexproject/cortex:v1.2.0
docker pull quay.io/cortexproject/cortex:v1.3.0
docker pull quay.io/cortexproject/cortex:v1.4.0
docker pull quay.io/cortexproject/cortex:v1.5.0
docker pull quay.io/cortexproject/cortex:v1.6.0
docker pull quay.io/cortexproject/cortex:v1.7.0
docker pull quay.io/cortexproject/cortex:v1.8.0
docker pull quay.io/cortexproject/cortex:v1.9.0
docker pull quay.io/cortexproject/cortex:v1.10.0
docker pull quay.io/cortexproject/cortex:v1.11.1
docker pull quay.io/cortexproject/cortex:v1.13.1
docker pull quay.io/cortexproject/cortex:v1.14.0
docker pull shopify/bigtable-emulator:0.1.0
if [ "$TEST_TAGS" = "integration_backward_compatibility" ]; then
docker pull quay.io/cortexproject/cortex:v1.6.0
docker pull quay.io/cortexproject/cortex:v1.7.0
docker pull quay.io/cortexproject/cortex:v1.8.0
docker pull quay.io/cortexproject/cortex:v1.9.0
docker pull quay.io/cortexproject/cortex:v1.10.0
docker pull quay.io/cortexproject/cortex:v1.11.1
docker pull quay.io/cortexproject/cortex:v1.13.1
docker pull quay.io/cortexproject/cortex:v1.13.2
docker pull quay.io/cortexproject/cortex:v1.14.0
docker pull quay.io/cortexproject/cortex:v1.14.1
docker pull quay.io/cortexproject/cortex:v1.15.0
docker pull quay.io/cortexproject/cortex:v1.15.1
fi
docker pull memcached:1.6.1
docker pull bouncestorage/swift-aio:55ba4331
docker pull redis:7.0.4-alpine
env:
TEST_TAGS: ${{ matrix.tags }}
- name: Integration Tests
run: |
export CORTEX_IMAGE_PREFIX="${IMAGE_PREFIX:-quay.io/cortexproject/}"
export IMAGE_TAG=$(make image-tag)
export CORTEX_IMAGE="${CORTEX_IMAGE_PREFIX}cortex:$IMAGE_TAG"
export CORTEX_IMAGE="${CORTEX_IMAGE_PREFIX}cortex:$IMAGE_TAG-amd64"
export CORTEX_CHECKOUT_DIR="/go/src/github.com/cortexproject/cortex"
echo "Running integration tests with image: $CORTEX_IMAGE"
go test -tags=requires_docker -timeout 2400s -v -count=1 ./integration/...
go test -tags=integration,${{ matrix.tags }} -timeout 2400s -v -count=1 ./integration/...
env:
IMAGE_PREFIX: ${{ secrets.IMAGE_PREFIX }}

Expand All @@ -167,20 +193,25 @@ jobs:
run: |
touch build-image/.uptodate
MIGRATIONS_DIR=$(pwd)/cmd/cortex/migrations
make BUILD_IMAGE=quay.io/cortexproject/build-image:upgrade-to-go1.19.3-e8b98ddc0 TTY='' configs-integration-test
make BUILD_IMAGE=quay.io/cortexproject/build-image:upgrade-to-go1.20.1-pr-5159 TTY='' configs-integration-test

deploy_website:
needs: [build, test]
if: (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/')) && github.repository == 'cortexproject/cortex'
runs-on: ubuntu-20.04
container:
image: quay.io/cortexproject/build-image:upgrade-to-go1.19.3-e8b98ddc0
image: quay.io/cortexproject/build-image:upgrade-to-go1.20.1-pr-5159
steps:
- name: Checkout Repo
uses: actions/checkout@v2
with:
# web-deploy script expects repo to be cloned with ssh for some commands to work
ssh-key: ${{ secrets.WEBSITE_DEPLOY_SSH_PRIVATE_KEY }}
- name: Setup Git safe.directory
run: |
echo "this step is needed because when running in container, actions/checkout does not set safe.directory effectively."
echo "See https://github.com/actions/runner/issues/2033. We should use --system instead of --global"
git config --system --add safe.directory $GITHUB_WORKSPACE
- name: Sym Link Expected Path to Workspace
run: |
mkdir -p /go/src/github.com/cortexproject/cortex
Expand Down Expand Up @@ -211,10 +242,15 @@ jobs:
if: (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/')) && github.repository == 'cortexproject/cortex'
runs-on: ubuntu-20.04
container:
image: quay.io/cortexproject/build-image:upgrade-to-go1.19.3-e8b98ddc0
image: quay.io/cortexproject/build-image:upgrade-to-go1.20.1-pr-5159
steps:
- name: Checkout Repo
uses: actions/checkout@v2
- name: Setup Git safe.directory
run: |
echo "this step is needed because when running in container, actions/checkout does not set safe.directory effectively."
echo "See https://github.com/actions/runner/issues/2033. We should use --system instead of --global"
git config --system --add safe.directory $GITHUB_WORKSPACE
- name: Install Docker Client
run: ./.github/workflows/scripts/install-docker.sh
- name: Sym link Expected Path to Workspace
Expand Down
7 changes: 7 additions & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,10 @@ run:
build-tags:
- netgo
- requires_docker
- integration
- integration_alertmanager
- integration_backward_compatibility
- integration_memberlist
- integration_querier
- integration_ruler
- integration_query_fuzz
34 changes: 34 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,49 @@
# Changelog

## master / unreleased
* [CHANGE] Store gateways summary metrics have been converted to histograms `cortex_bucket_store_series_blocks_queried`, `cortex_bucket_store_series_data_fetched`, `cortex_bucket_store_series_data_size_touched_bytes`, `cortex_bucket_store_series_data_size_fetched_bytes`, `cortex_bucket_store_series_data_touched`, `cortex_bucket_store_series_result_series` #5239

## 1.15.0 in progress

* [CHANGE] Storage: Make Max exemplars config per tenant instead of global configuration. #5016
* [CHANGE] Alertmanager: Local file disclosure vulnerability in OpsGenie configuration has been fixed. #5045
* [CHANGE] Rename oltp_endpoint to otlp_endpoint to match opentelemetry spec and lib name. #5067
* [CHANGE] Distributor/Ingester: Log warn level on push requests when they have status code 4xx. Do not log if status is 429. #5103
* [CHANGE] Tracing: Use the default OTEL trace sampler when `-tracing.otel.exporter-type` is set to `awsxray`. #5141
* [CHANGE] Ingester partial error log line to debug level. #5192
* [CHANGE] Change HTTP status code from 503/422 to 499 if a request is canceled. #5220
* [ENHANCEMENT] Update Go version to 1.19.3. #4988
* [ENHANCEMENT] Querier: limit series query to only ingesters if `start` param is not specified. #4976
* [ENHANCEMENT] Query-frontend/scheduler: add a new limit `frontend.max-outstanding-requests-per-tenant` for configuring queue size per tenant. Started deprecating two flags `-query-scheduler.max-outstanding-requests-per-tenant` and `-querier.max-outstanding-requests-per-tenant`, and change their value default to 0. Now if both the old flag and new flag are specified, the old flag's queue size will be picked. #5005
* [ENHANCEMENT] Query-tee: Add `/api/v1/query_exemplars` API endpoint support. #5010
* [ENHANCEMENT] Query Frontend/Query Scheduler: Increase upper bound to 60s for queue duration histogram metric. #5029
* [ENHANCEMENT] Query Frontend: Log Vertical sharding information when `query_stats_enabled` is enabled. #5037
* [ENHANCEMENT] Ingester: The metadata APIs should honour `querier.query-ingesters-within` when `querier.query-store-for-labels-enabled` is true. #5027
* [ENHANCEMENT] Query Frontend: Skip instant query roundtripper if sharding is not applicable. #5062
* [ENHANCEMENT] Push reduce one hash operation of Labels. #4945 #5114
* [ENHANCEMENT] Alertmanager: Added `-alertmanager.enabled-tenants` and `-alertmanager.disabled-tenants` to explicitly enable or disable alertmanager for specific tenants. #5116
* [ENHANCEMENT] Upgraded Docker base images to `alpine:3.17`. #5132
* [ENHANCEMENT] Add retry logic to S3 bucket client. #5135
* [ENHANCEMENT] Update Go version to 1.20.1. #5159
* [ENHANCEMENT] Distributor: Reuse byte slices when serializing requests from distributors to ingesters. #5193
* [ENHANCEMENT] Query Frontend: Add number of chunks and samples fetched in query stats. #5198
* [ENHANCEMENT] Implement grpc.Compressor.DecompressedSize for snappy to optimize memory allocations. #5213
* [FEATURE] Querier/Query Frontend: support Prometheus /api/v1/status/buildinfo API. #4978
* [FEATURE] Ingester: Add active series to all_user_stats page. #4972
* [FEATURE] Ingester: Added `-blocks-storage.tsdb.head-chunks-write-queue-size` allowing to configure the size of the in-memory queue used before flushing chunks to the disk . #5000
* [FEATURE] Query Frontend: Log query params in query frontend even if error happens. #5005
* [FEATURE] Ingester: Enable snapshotting of In-memory TSDB on disk during shutdown via `-blocks-storage.tsdb.memory-snapshot-on-shutdown`. #5011
* [FEATURE] Query Frontend/Scheduler: Add a new counter metric `cortex_request_queue_requests_total` for total requests going to queue. #5030
* [FEATURE] Build ARM docker images. #5041
* [FEATURE] Query-frontend/Querier: Create spans to measure time to merge promql responses. #5041
* [FEATURE] Querier/Ruler: Support the new thanos promql engine. This is an experimental feature and might change in the future. #5093
* [FEATURE] Added zstd as an option for grpc compression #5092
* [FEATURE] Ring: Add new kv store option `dynamodb`. #5026
* [FEATURE] Cache: Support redis as backend for caching bucket and index cache. #5057
* [FEATURE] Querier/Store-Gateway: Added `-blocks-storage.bucket-store.ignore-blocks-within` allowing to filter out the recently created blocks from being synced by queriers and store-gateways. #5166
* [FEATURE] AlertManager/Ruler: Added support for `keep_firing_for` on alerting rulers.
* [BUGFIX] Updated `golang.org/x/net` dependency to fix CVE-2022-27664. #5008
* [BUGFIX] Fix panic when otel and xray tracing is enabled. #5044

## 1.14.0 2022-12-02

Expand Down Expand Up @@ -44,6 +77,7 @@
- `-ingester.chunk-age-jitter`
- `-ingester.concurrent-flushes`
- `-ingester.spread-flushes`
- `-ingester.chunk-encoding`
- `-store.*` except `-store.engine` and `-store.max-query-length`
- `-store.query-chunk-limit` was deprecated and replaced by `-querier.max-fetched-chunks-per-query`
- `-deletes.*`
Expand Down
30 changes: 21 additions & 9 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
VERSION=$(shell cat "./VERSION" 2> /dev/null)
GOPROXY_VALUE=$(shell go env GOPROXY)

# ARCHS
ARCHS = amd64 arm64

# Boiler plate for building Docker containers.
# All this must go at top of file I'm afraid.
IMAGE_PREFIX ?= quay.io/cortexproject/
Expand Down Expand Up @@ -37,8 +40,9 @@ SED ?= $(shell which gsed 2>/dev/null || which sed)
# Dependencies (i.e. things that go in the image) still need to be explicitly
# declared.
%/$(UPTODATE): %/Dockerfile
@echo
$(SUDO) docker build --build-arg=revision=$(GIT_REVISION) --build-arg=goproxyValue=$(GOPROXY_VALUE) -t $(IMAGE_PREFIX)$(shell basename $(@D)) -t $(IMAGE_PREFIX)$(shell basename $(@D)):$(IMAGE_TAG) $(@D)/
for arch in $(ARCHS); do \
$(SUDO) docker buildx build --platform linux/$$arch --build-arg=revision=$(GIT_REVISION) --build-arg=goproxyValue=$(GOPROXY_VALUE) -t $(IMAGE_PREFIX)$(shell basename $(@D)) -t $(IMAGE_PREFIX)$(shell basename $(@D)):$(IMAGE_TAG)-$$arch $(@D)/ ; \
done
@echo
@echo Please use push-multiarch-build-image to build and push build image for all supported architectures.
touch $@
Expand Down Expand Up @@ -118,7 +122,7 @@ build-image/$(UPTODATE): build-image/*
SUDO := $(shell docker info >/dev/null 2>&1 || echo "sudo -E")
BUILD_IN_CONTAINER := true
BUILD_IMAGE ?= $(IMAGE_PREFIX)build-image
LATEST_BUILD_IMAGE_TAG ?= upgrade-to-go1.19.3-e8b98ddc0
LATEST_BUILD_IMAGE_TAG ?= upgrade-to-go1.20.1-e6945e022

# TTY is parameterized to allow Google Cloud Builder to run builds,
# as it currently disallows TTY devices. This value needs to be overridden
Expand Down Expand Up @@ -160,7 +164,11 @@ else
exes: $(EXES)

$(EXES):
CGO_ENABLED=0 go build $(GO_FLAGS) -o $@ ./$(@D)
@for arch in $(ARCHS); do \
echo "Building $@ for $$arch";\
CGO_ENABLED=0 GOARCH=$$arch GOOS=linux go build $(GO_FLAGS) -o $@-$$arch ./$(@D); \
done


protos: $(PROTO_GOS)

Expand All @@ -176,7 +184,7 @@ lint:
golangci-lint run

# Ensure no blocklisted package is imported.
GOFLAGS="-tags=requires_docker" faillint -paths "github.com/bmizerany/assert=github.com/stretchr/testify/assert,\
GOFLAGS="-tags=requires_docker,integration,integration_alertmanager,integration_backward_compatibility,integration_memberlist,integration_querier,integration_ruler,integration_query_fuzz" faillint -paths "github.com/bmizerany/assert=github.com/stretchr/testify/assert,\
golang.org/x/net/context=context,\
sync/atomic=go.uber.org/atomic,\
github.com/prometheus/client_golang/prometheus.{MultiError}=github.com/prometheus/prometheus/tsdb/errors.{NewMulti},\
Expand Down Expand Up @@ -272,16 +280,20 @@ clean-protos:

save-images:
@mkdir -p docker-images
for image_name in $(IMAGE_NAMES); do \
@for image_name in $(IMAGE_NAMES); do \
if ! echo $$image_name | grep build; then \
docker save $$image_name:$(IMAGE_TAG) -o docker-images/$$(echo $$image_name | tr "/" _):$(IMAGE_TAG); \
for arch in $(ARCHS); do \
docker save $$image_name:$(IMAGE_TAG)-$$arch -o docker-images/$$(echo $$image_name | tr "/" _):$(IMAGE_TAG)-$$arch; \
done;\
fi \
done

load-images:
for image_name in $(IMAGE_NAMES); do \
@for image_name in $(IMAGE_NAMES); do \
if ! echo $$image_name | grep build; then \
docker load -i docker-images/$$(echo $$image_name | tr "/" _):$(IMAGE_TAG); \
for arch in $(ARCHS); do \
docker load -i docker-images/$$(echo $$image_name | tr "/" _):$(IMAGE_TAG)-$$arch; \
done;\
fi \
done

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Cortex is primarily used as a [remote write](https://prometheus.io/docs/operatin

The chunks storage is deprecated since v1.10.0. You're encouraged to use the [blocks storage](docs/blocks-storage/_index.md).

Chunks storage is scheduled to be removed in release 1.14.0
Chunks storage was removed in release 1.14.0

## Documentation

Expand Down
1 change: 1 addition & 0 deletions RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ Our goal is to provide a new minor release every 6 weeks. This is a new process
| v1.12.0 | 2022-02-17 | _Abandoned_ |
| v1.13.0 | 2022-06-23 | Alvin Lin (@alvinlin123) |
| v1.14.0 | 2022-11-15 | Alan Protasio (@alanprot) |
| v1.15.0 | 2023-03-27 | Ben Ye (@yeya24) |

## Release shepherd responsibilities

Expand Down
4 changes: 2 additions & 2 deletions build-image/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.19.3-buster
FROM golang:1.20.1-buster
ARG goproxyValue
ENV GOPROXY=${goproxyValue}
RUN apt-get update && apt-get install -y curl python-requests python-yaml file jq unzip protobuf-compiler libprotobuf-dev && \
Expand All @@ -23,7 +23,7 @@ RUN GOARCH=$(go env GOARCH) && \
chmod +x shfmt && \
mv shfmt /usr/bin

RUN curl -sfL https://github.com/raw/golangci/golangci-lint/master/install.sh| sh -s -- -b /usr/bin v1.48.0
RUN curl -sfL https://github.com/raw/golangci/golangci-lint/master/install.sh| sh -s -- -b /usr/bin v1.51.2

ENV HUGO_VERSION=v0.101.0
RUN go install github.com/client9/misspell/cmd/[email protected] &&\
Expand Down
6 changes: 4 additions & 2 deletions cmd/cortex/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
FROM alpine:3.14
FROM alpine:3.17
ARG TARGETARCH

RUN apk add --no-cache ca-certificates
COPY migrations /migrations/
COPY cortex /bin/cortex
COPY cortex-$TARGETARCH /bin/cortex
EXPOSE 80
ENTRYPOINT [ "/bin/cortex" ]

Expand Down
6 changes: 4 additions & 2 deletions cmd/query-tee/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
FROM alpine:3.14
FROM alpine:3.17
ARG TARGETARCH

RUN apk add --no-cache ca-certificates
COPY query-tee /
COPY query-tee-$TARGETARCH /query-tee
ENTRYPOINT ["/query-tee"]

ARG revision
Expand Down
5 changes: 3 additions & 2 deletions cmd/test-exporter/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
FROM alpine:3.14
FROM alpine:3.17
ARG TARGETARCH
RUN apk add --no-cache ca-certificates
COPY test-exporter /
COPY test-exporter-$TARGETARCH /test-exporter
ENTRYPOINT ["/test-exporter"]

ARG revision
Expand Down
Loading