gitlab-exporter 7.0.1 → 7.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2c062d3df29ab27b462fab49affc7bf091a79485c7d6f09f6210d7484f379c9a
4
- data.tar.gz: cff7645b256b132bcfd9bf34ba1541dcd3d117ff1419bb2c5d2f90b5e4259496
3
+ metadata.gz: bd49abef867540a7fcfb667672ddef699d7bf883ddf4a3fc3856b1097959386b
4
+ data.tar.gz: e959328537cd1b32003a9d1d7f006dc4812bf52bf82e71dab9a972f4ee86e4d5
5
5
  SHA512:
6
- metadata.gz: 50f37bdbfd6bed68b11e0e1527e9e6cbde1afc30aed339495194ab311c9d52d879d7a1728ae6528fe69f63918f1921b3079977aab426b24b65c0ed49bb49815c
7
- data.tar.gz: 73cd73cb2de026b3737a488374fffa3066350b48a700b2742a002c52d5e650741d1dade7472d380031f0c175a3de3b66d1c0b561c1286e24fd752402c8777b15
6
+ metadata.gz: 6c6a2a358ae1f30483f35cad1e26e5d074772d30522cb9bfea85436481f59f160170c90a309012f8def286808ebc334d3b0f1c451045a99fc7a7048505b7efc9
7
+ data.tar.gz: 2df79f4b275b371846160f3d552a14254a21dcad1ba2e3650c92383384d17671b325d4e5daf7235b89f83c16eb7a825ca60b38be8a5f145df1c0ca8be73bdeaa
data/.gitlab-ci.yml CHANGED
@@ -1,13 +1,23 @@
1
- image: "ruby:2.3"
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
- 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
-
8
- cache:
9
- paths:
10
- - vendor
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
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- gitlab-exporter (7.0.1)
4
+ gitlab-exporter (7.0.2)
5
5
  connection_pool (~> 2.2.1)
6
6
  pg (~> 1.1)
7
7
  quantile (~> 0.2.0)
@@ -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 = {
@@ -1,5 +1,5 @@
1
1
  module GitLab
2
2
  module Exporter
3
- VERSION = "7.0.1".freeze
3
+ VERSION = "7.0.2".freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gitlab-exporter
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.0.1
4
+ version: 7.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pablo Carranza