Skip to content

Commit 13bed14

Browse files
authored
Merge branch 'main' into pmm-7-enable-tests
2 parents b6b38be + 2ae068c commit 13bed14

File tree

894 files changed

+8152
-2380
lines changed

Some content is hidden

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

894 files changed

+8152
-2380
lines changed

.github/CODEOWNERS

-5
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,11 @@
11
* @percona/pmm-review-be
2-
/build/ @atymchuk @percona/pmm-review-be
3-
/admin/ @percona/pmm-review-be
42
/agent/agents/postgres/ @JiriCtvrtka @percona/pmm-review-be
53
/agent/runner/ @artemgavrilov @percona/pmm-review-be
64
/api/ @BupycHuk @percona/pmm-review-be
7-
/docs/api/ @atymchuk @percona/pmm-review-be
85
/managed/services/checks/ @idoqo @percona/pmm-review-be
9-
/managed/ @percona/pmm-review-be
106
/managed/services/dbaas @gen1us2k @recharte @percona/pmm-review-be
117
/managed/services/management/dbaas @gen1us2k @recharte @percona/pmm-review-be
128
/update/ @BupycHuk @talhabinrizwan @percona/pmm-review-be
13-
/api-tests/ @percona/pmm-review-be
149
**/go.mod @percona/pmm-review-dependency @percona/pmm-review-be
1510
**/Dockerfile @percona/pmm-review-dependency @percona/pmm-review-be
1611
/cli-tests/package.json @percona/pmm-review-dependency @yurkovychv

.github/workflows/admin.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ jobs:
3131

3232
steps:
3333
- name: Check out code
34-
uses: actions/checkout@v3
34+
uses: actions/checkout@v4
3535

3636
- name: Set up Go release
3737
uses: actions/setup-go@v4
@@ -95,7 +95,7 @@ jobs:
9595

9696
steps:
9797
- name: Check out code
98-
uses: actions/checkout@v3
98+
uses: actions/checkout@v4
9999

100100
- name: Set up Go release
101101
uses: actions/setup-go@v4

.github/workflows/agent.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ jobs:
6363

6464
steps:
6565
- name: Check out code
66-
uses: actions/checkout@v3
66+
uses: actions/checkout@v4
6767

6868
- name: Set up Go release
6969
uses: actions/setup-go@v4

.github/workflows/clean.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
fail-fast: false
1414
matrix:
1515
go:
16-
- version: 1.20.x
16+
- version: 1.21.x
1717
may-fail: false
1818
- version: tip
1919
may-fail: true
@@ -52,7 +52,7 @@ jobs:
5252
echo "GOROOT=$HOME/gotip" >> $GITHUB_ENV
5353
echo "$HOME/gotip/bin" >> $GITHUB_PATH
5454
- name: Check out code into the Go module directory
55-
uses: actions/checkout@v3
55+
uses: actions/checkout@v4
5656
with:
5757
lfs: true
5858

.github/workflows/devcontainer.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -31,29 +31,29 @@ jobs:
3131

3232
steps:
3333
- name: Check out code
34-
uses: actions/checkout@v3
34+
uses: actions/checkout@v4
3535
with:
3636
ref: ${{ github.event.inputs.branch }}
3737

3838
- name: Set up Docker Buildx
39-
uses: docker/setup-buildx-action@v2
39+
uses: docker/setup-buildx-action@v3
4040

4141
- name: Login to ghcr.io registry
42-
uses: docker/login-action@v2
42+
uses: docker/login-action@v3
4343
with:
4444
registry: ghcr.io
4545
username: ${{ github.repository_owner }}
4646
password: ${{ secrets.GITHUB_TOKEN }}
4747

4848
- name: Login to docker.io registry
49-
uses: docker/login-action@v2
49+
uses: docker/login-action@v3
5050
with:
5151
registry: docker.io
5252
username: ${{ secrets.DOCKERHUB_USERNAME }}
5353
password: ${{ secrets.DOCKERHUB_PASSWORD }}
5454

5555
- name: Build and push to registries
56-
uses: docker/build-push-action@v4
56+
uses: docker/build-push-action@v5
5757
with:
5858
file: ./devcontainer.Dockerfile
5959
push: true

.github/workflows/doc.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ on:
66
paths:
77
- "api/**"
88
- "docs/api/**"
9+
910
workflow_dispatch:
1011
inputs:
1112
version:
@@ -19,7 +20,7 @@ jobs:
1920
runs-on: ubuntu-22.04
2021
steps:
2122
- name: Check out code
22-
uses: actions/checkout@v3
23+
uses: actions/checkout@v4
2324

2425
- name: API
2526
uses: readmeio/rdme@v8

.github/workflows/dockerhub-readme.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
runs-on: ubuntu-latest
1313
environment: Production
1414
steps:
15-
- uses: actions/checkout@v3
15+
- uses: actions/checkout@v4
1616

1717
- name: Update Docker Hub Readme for perconalab/pmm-server
1818
uses: peter-evans/dockerhub-description@v3

.github/workflows/main.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919

2020
steps:
2121
- name: Check out code
22-
uses: actions/checkout@v3
22+
uses: actions/checkout@v4
2323

2424
- name: Set up Go release
2525
uses: actions/setup-go@v4

.github/workflows/managed.yml

+3-6
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ jobs:
3636

3737
steps:
3838
- name: Check out code
39-
uses: actions/checkout@v3
39+
uses: actions/checkout@v4
4040

4141
- name: Enable Go build cache
4242
if: ${{ fromJSON(env.DEVCONTAINER_CACHE_ENABLED) }}
@@ -107,9 +107,6 @@ jobs:
107107
- name: Run debug commands on failure
108108
if: ${{ failure() }}
109109
run: |
110-
env
111-
go version
112-
go env
113-
pwd
110+
env | sort
111+
go env | sort
114112
git status
115-
kubectl version --short --output json

.github/workflows/qan-api2.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232

3333
steps:
3434
- name: Checkout code
35-
uses: actions/checkout@v3
35+
uses: actions/checkout@v4
3636

3737
- name: Set up Go release
3838
uses: actions/setup-go@v4

.github/workflows/sbom.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
runs-on: ubuntu-22.04
1111
steps:
1212
- name: Check out code
13-
uses: actions/checkout@v3
13+
uses: actions/checkout@v4
1414

1515
- name: Create SBOM for PMM
1616
uses: anchore/sbom-action@v0
@@ -27,7 +27,7 @@ jobs:
2727
runs-on: ubuntu-22.04
2828
steps:
2929
- name: Check out code
30-
uses: actions/checkout@v3
30+
uses: actions/checkout@v4
3131

3232
- name: Create SBOM for vmproxy
3333
uses: anchore/sbom-action@v0

.github/workflows/update.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ jobs:
4242

4343
steps:
4444
- name: Check out code
45-
uses: actions/checkout@v3
45+
uses: actions/checkout@v4
4646

4747
- name: Docker Up
4848
run: docker compose up -d

.github/workflows/vmproxy.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232

3333
steps:
3434
- name: Check out code
35-
uses: actions/checkout@v3
35+
uses: actions/checkout@v4
3636

3737
- name: Set up Go release
3838
uses: actions/setup-go@v4

.golangci.yml

+17-13
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,19 @@ linters-settings:
77
max-complexity: 30
88

99
depguard:
10-
list-type: blacklist
11-
include-go-root: true
12-
packages:
13-
# use "github.com/pkg/errors" instead
14-
- errors
15-
# use "github.com/golang/protobuf/proto" instead
16-
- github.com/gogo/protobuf/proto
17-
# use only forked parser
18-
- github.com/percona/go-mysql/log/slow
19-
# use "github.com/percona-platform/saas" instead
20-
- github.com/percona-platform/platform
21-
# use "gopkg.in/yaml.v3" instead
22-
- gopkg.in/yaml.v2
10+
rules:
11+
main:
12+
deny:
13+
- pkg: "errors"
14+
desc: use "github.com/pkg/errors" instead
15+
- pkg: "github.com/gogo/protobuf/proto"
16+
desc: use "github.com/golang/protobuf/proto" instead
17+
- pkg: "github.com/percona/go-mysql/log/slow"
18+
desc: only use the forked parser
19+
- pkg: "github.com/percona-platform/platform"
20+
desc: use "github.com/percona-platform/saas" instead
21+
- pkg: "gopkg.in/yaml.v2"
22+
desc: use "gopkg.in/yaml.v3" instead
2323

2424
gci:
2525
sections:
@@ -103,8 +103,12 @@ linters:
103103
- maligned # deprecated
104104
- nlreturn # too annoying
105105
- nosnakecase # deprecated
106+
- rowserrcheck # disabled because of generics
106107
- scopelint # too many false positives
108+
- structcheck # replaced by unused
109+
- varcheck # replaced by unused
107110
- varnamelen # useless
111+
- wastedassign # disabled because of generics
108112
- wrapcheck # we do not use wrapping everywhere
109113
- wsl # too annoying
110114

.licenserc.yaml

+11-50
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ header:
22
- paths:
33
- "**/*.go"
44
paths-ignore:
5-
- "**/agent/**"
6-
- "**/admin/**"
5+
- "agent/**"
6+
- "admin/**"
77
- "**/mock_*"
88
- "**/*.pb.go"
99
- "**/*.pb.gw.go"
@@ -12,62 +12,23 @@ header:
1212
- "**/json/client/**"
1313
- "**/amclient/**"
1414
- "**/ammodels/**"
15-
- "qan-api2/migrations/"
15+
- "qan-api2/migrations/**"
1616
- "managed/services/dbaas/kubernetes/client/kubeclient_interface.go"
1717
- "managed/services/dbaas/olm/operator_service_interface.go"
1818
- "managed/services/dbaas/kubernetes/operator_service_interface.go"
1919
license:
20-
spdx-id: AGPL-3.0
21-
content: |
22-
// Copyright (C) 2019 Percona LLC
23-
//
24-
// This program is free software: you can redistribute it and/or modify
25-
// it under the terms of the GNU Affero General Public License as published by
26-
// the Free Software Foundation, either version 3 of the License, or
27-
// (at your option) any later version.
28-
//
29-
// This program is distributed in the hope that it will be useful,
30-
// but WITHOUT ANY WARRANTY; without even the implied warranty of
31-
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
32-
// GNU Affero General Public License for more details.
33-
//
34-
// You should have received a copy of the GNU Affero General Public License
35-
// along with this program. If not, see <https://www.gnu.org/licenses/>.
20+
spdx-id: AGPL-3.0-or-later
21+
copyright-owner: Percona LLC
22+
copyright-year: 2023
3623

3724
- paths:
38-
- "./agent/**/*.go"
39-
- "./admin/**/.go"
25+
- "agent/**/*.go"
26+
- "admin/**/*.go"
4027
paths-ignore:
4128
- "**/*_reform.go"
4229
- "**/mock_*"
4330
- "**/json/client/**"
4431
license:
45-
content: |
46-
// Copyright (C) 2019 Percona LLC
47-
//
48-
// Licensed under the Apache License, Version 2.0 (the "License");
49-
// you may not use this file except in compliance with the License.
50-
// You may obtain a copy of the License at
51-
//
52-
// http://www.apache.org/licenses/LICENSE-2.0
53-
//
54-
// Unless required by applicable law or agreed to in writing, software
55-
// distributed under the License is distributed on an "AS IS" BASIS,
56-
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
57-
// See the License for the specific language governing permissions and
58-
// limitations under the License.
59-
60-
pattern: |
61-
// Copyright \(C\) 20\d{2} Percona LLC
62-
//
63-
// Licensed under the Apache License, Version 2.0 \(the "License"\);
64-
// you may not use this file except in compliance with the License.
65-
// You may obtain a copy of the License at
66-
//
67-
// http://www.apache.org/licenses/LICENSE-2.0
68-
//
69-
// Unless required by applicable law or agreed to in writing, software
70-
// distributed under the License is distributed on an "AS IS" BASIS,
71-
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
72-
// See the License for the specific language governing permissions and
73-
// limitations under the License.
32+
spdx-id: Apache-2.0
33+
copyright-owner: Percona LLC
34+
copyright-year: 2023

admin/agentlocal/agentlocal.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2019 Percona LLC
1+
// Copyright (C) 2023 Percona LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

admin/cli/cli.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2019 Percona LLC
1+
// Copyright (C) 2023 Percona LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

admin/cli/flags/global.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2019 Percona LLC
1+
// Copyright (C) 2023 Percona LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

admin/cmd/bootstrap.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2019 Percona LLC
1+
// Copyright (C) 2023 Percona LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

admin/cmd/pmm-admin/main.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2019 Percona LLC
1+
// Copyright (C) 2023 Percona LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

admin/cmd/pmm-admin/main_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2019 Percona LLC
1+
// Copyright (C) 2023 Percona LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

admin/cmd/pmm/main.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2019 Percona LLC
1+
// Copyright (C) 2023 Percona LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

admin/commands/annotation.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2019 Percona LLC
1+
// Copyright (C) 2023 Percona LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

admin/commands/base.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2019 Percona LLC
1+
// Copyright (C) 2023 Percona LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

admin/commands/base/setup.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2019 Percona LLC
1+
// Copyright (C) 2023 Percona LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

admin/commands/base_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2019 Percona LLC
1+
// Copyright (C) 2023 Percona LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

admin/commands/completion.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2019 Percona LLC
1+
// Copyright (C) 2023 Percona LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

0 commit comments

Comments
 (0)