gitlab-exporter 7.0.1 → 7.0.2
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.
- checksums.yaml +4 -4
- data/.gitlab-ci.yml +19 -9
- data/Gemfile.lock +1 -1
- data/lib/gitlab_exporter/database/row_count.rb +6 -0
- data/lib/gitlab_exporter/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: bd49abef867540a7fcfb667672ddef699d7bf883ddf4a3fc3856b1097959386b
|
|
4
|
+
data.tar.gz: e959328537cd1b32003a9d1d7f006dc4812bf52bf82e71dab9a972f4ee86e4d5
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 6c6a2a358ae1f30483f35cad1e26e5d074772d30522cb9bfea85436481f59f160170c90a309012f8def286808ebc334d3b0f1c451045a99fc7a7048505b7efc9
|
|
7
|
+
data.tar.gz: 2df79f4b275b371846160f3d552a14254a21dcad1ba2e3650c92383384d17671b325d4e5daf7235b89f83c16eb7a825ca60b38be8a5f145df1c0ca8be73bdeaa
|
data/.gitlab-ci.yml
CHANGED
|
@@ -1,13 +1,23 @@
|
|
|
1
|
-
|
|
1
|
+
default:
|
|
2
|
+
image: "ruby:2.3"
|
|
3
|
+
before_script:
|
|
4
|
+
- git config --global user.email "bot@gitlab.com"
|
|
5
|
+
- git config --global user.name "Bot User"
|
|
6
|
+
- bundle install -j $(nproc) --path vendor
|
|
7
|
+
cache:
|
|
8
|
+
paths:
|
|
9
|
+
- vendor
|
|
10
|
+
tags:
|
|
11
|
+
- gitlab-org
|
|
2
12
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
-
|
|
13
|
+
workflow:
|
|
14
|
+
rules:
|
|
15
|
+
# For merge requests, create a pipeline.
|
|
16
|
+
- if: '$CI_MERGE_REQUEST_IID'
|
|
17
|
+
# For `master` branch, create a pipeline (this includes on schedules, pushes, merges, etc.).
|
|
18
|
+
- if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH'
|
|
19
|
+
# For tags, create a pipeline.
|
|
20
|
+
- if: '$CI_COMMIT_TAG'
|
|
11
21
|
|
|
12
22
|
rspec:
|
|
13
23
|
script:
|
data/Gemfile.lock
CHANGED
|
@@ -10,6 +10,11 @@ module GitLab
|
|
|
10
10
|
# #construct_query
|
|
11
11
|
# rubocop:disable Metrics/ClassLength
|
|
12
12
|
class RowCountCollector < Base
|
|
13
|
+
# We ignore mirrors with a next_execution_timestamp before
|
|
14
|
+
# 2020-03-28 because this is when we stopped processing mirrors
|
|
15
|
+
# for private projects on the free plan. Skipping those can
|
|
16
|
+
# significantly improve query performance:
|
|
17
|
+
# https://gitlab.com/gitlab-org/gitlab/-/issues/216252#note_334514544
|
|
13
18
|
WHERE_MIRROR_ENABLED = <<~SQL.freeze
|
|
14
19
|
projects.mirror = true
|
|
15
20
|
AND projects.archived = false
|
|
@@ -19,6 +24,7 @@ module GitLab
|
|
|
19
24
|
OR
|
|
20
25
|
plans.name IN ('early_adopter', 'bronze', 'silver', 'gold')
|
|
21
26
|
)
|
|
27
|
+
AND project_mirror_data.next_execution_timestamp > '2020-03-28'
|
|
22
28
|
SQL
|
|
23
29
|
|
|
24
30
|
MIRROR_QUERY = {
|