gooddata 2.1.3-java → 2.1.4-java
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/.gdc-ii-config-chart.yaml +2 -0
- data/.travis.yml +47 -21
- data/CHANGELOG.md +27 -0
- data/Dockerfile +37 -22
- data/Gemfile +4 -4
- data/Jenkinsfile-chart +1 -7
- data/SDK_VERSION +1 -1
- data/VERSION +1 -1
- data/bin/help.sh +1 -1
- data/bin/provision.sh +1 -1
- data/bin/release.sh +1 -1
- data/bin/rollout.sh +1 -1
- data/bin/run_smoke_tests.sh +5 -1
- data/bin/test_projects_cleanup.rb +1 -0
- data/bin/user_filters.sh +1 -1
- data/bin/users.sh +1 -1
- data/gooddata.gemspec +3 -4
- data/k8s/charts/lcm-bricks/Chart.yaml +1 -1
- data/k8s/charts/lcm-bricks/templates/_helpers.tpl +14 -0
- data/k8s/charts/lcm-bricks/templates/prometheus/alertingRules.yaml +13 -4
- data/lib/gooddata/lcm/actions/collect_dynamic_schedule_params.rb +5 -2
- data/lib/gooddata/lcm/actions/synchronize_etls_in_segment.rb +1 -1
- data/lib/gooddata/models/process.rb +7 -8
- data/lib/gooddata/models/profile.rb +9 -2
- data/lib/gooddata/models/project.rb +8 -3
- data/lib/gooddata/models/schedule.rb +2 -1
- data/lib/gooddata/rest/client.rb +6 -2
- data/lib/gooddata/rest/connection.rb +4 -2
- metadata +4 -4
- data/bin/hello_world.sh +0 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 7fc6d23e8d5782c1029093532c6fd7fac954dfa06a0a9561f8da795994910c8c
|
|
4
|
+
data.tar.gz: aac2cf531bca16aaf63f2f82f2387ba396add858bc67a589d4bf667702143a3b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: d4045b2f4401856b1181ad93640ae09a516cae09577632b99ad3a13f532a9528767141340a6e9aecd3f6792e3f8ff709179eb51080685f9ab25c2461bb154629
|
|
7
|
+
data.tar.gz: 97107dbf36d4ad5b3becd478b39b7c2a8cd32172a44e8e74b09fcc8174d1e5a9d379dc412ff0a3d46e8b38ad6938c15c389a69c31f8a24f0000f96bbcba3a044
|
data/.travis.yml
CHANGED
|
@@ -23,14 +23,14 @@ jobs:
|
|
|
23
23
|
script: |
|
|
24
24
|
git remote add upstream https://github.com/gooddata/gooddata-ruby.git
|
|
25
25
|
git fetch upstream develop
|
|
26
|
-
|
|
26
|
+
failed=0
|
|
27
|
+
PRONTO_FLAY_MASS_THRESHOLD=50 bundle exec pronto run -c upstream/develop --exit-code lib || failed=1
|
|
28
|
+
PRONTO_FLAY_MASS_THRESHOLD=100 bundle exec pronto run -c upstream/develop --exit-code spec || failed=1
|
|
29
|
+
if [ "$failed" -ne 0 ] ; then
|
|
30
|
+
exit 1
|
|
31
|
+
fi
|
|
27
32
|
|
|
28
33
|
# UNIT TESTS ON LINUX IN ALL SUPPORTED RUBY VERSIONS
|
|
29
|
-
- name: unit tests 2.2
|
|
30
|
-
stage: before-merge
|
|
31
|
-
script: bundle exec rake test:unit
|
|
32
|
-
rvm: 2.2
|
|
33
|
-
|
|
34
34
|
- name: unit tests 2.3
|
|
35
35
|
stage: before-merge
|
|
36
36
|
script: bundle exec rake test:unit
|
|
@@ -55,6 +55,7 @@ jobs:
|
|
|
55
55
|
stage: before-merge
|
|
56
56
|
script: bundle exec rake test:unit
|
|
57
57
|
rvm: jruby-9.1.14
|
|
58
|
+
jdk: openjdk8
|
|
58
59
|
|
|
59
60
|
- name: sdk integration (vcr) tests - base
|
|
60
61
|
stage: before-merge
|
|
@@ -73,7 +74,6 @@ jobs:
|
|
|
73
74
|
script: bundle exec rspec spec/lcm/integration/lcm_end_to_end_spec.rb
|
|
74
75
|
env:
|
|
75
76
|
- VCR_RECORD_MODE=none
|
|
76
|
-
- GD_ENV=development
|
|
77
77
|
rvm: 2.3
|
|
78
78
|
|
|
79
79
|
# AFTER MERGE
|
|
@@ -89,6 +89,7 @@ jobs:
|
|
|
89
89
|
- VCR_ON=false
|
|
90
90
|
- GD_ENV=staging
|
|
91
91
|
rvm: jruby-9.1.14
|
|
92
|
+
jdk: openjdk8
|
|
92
93
|
|
|
93
94
|
- &lcm-slow-tests
|
|
94
95
|
name: staging1 - lcm slow tests
|
|
@@ -102,6 +103,7 @@ jobs:
|
|
|
102
103
|
- VCR_ON=false
|
|
103
104
|
- GD_ENV=staging
|
|
104
105
|
rvm: jruby-9.1.14
|
|
106
|
+
jdk: openjdk8
|
|
105
107
|
|
|
106
108
|
- &userprov-tests
|
|
107
109
|
name: staging1 - user provisioning tests
|
|
@@ -114,6 +116,21 @@ jobs:
|
|
|
114
116
|
- VCR_ON=false
|
|
115
117
|
- GD_ENV=staging
|
|
116
118
|
rvm: jruby-9.1.14
|
|
119
|
+
jdk: openjdk8
|
|
120
|
+
|
|
121
|
+
- &bricks-smoke-tests
|
|
122
|
+
name: staging1 - bricks smoke tests
|
|
123
|
+
stage: after-merge
|
|
124
|
+
script:
|
|
125
|
+
- sudo keytool -importcert -alias gooddata-2008 -file "./data/2008.crt" -keystore $JAVA_HOME/jre/lib/security/cacerts -trustcacerts -storepass 'changeit' -noprompt
|
|
126
|
+
- sudo keytool -importcert -alias gooddata-int -file "./data/new_ca.cer" -keystore $JAVA_HOME/jre/lib/security/cacerts -trustcacerts -storepass 'changeit' -noprompt
|
|
127
|
+
- sudo keytool -importcert -alias gooddata-prod -file "data/new_prodgdc_ca.crt" -keystore $JAVA_HOME/jre/lib/security/cacerts -trustcacerts -storepass 'changeit' -noprompt
|
|
128
|
+
- bundle exec rake -f lcm.rake test:smoke
|
|
129
|
+
env:
|
|
130
|
+
- GD_ENV=staging
|
|
131
|
+
- VCR_ON=false
|
|
132
|
+
rvm: jruby-9.1.14
|
|
133
|
+
jdk: openjdk8
|
|
117
134
|
|
|
118
135
|
- &sdk-integration-tests
|
|
119
136
|
name: staging1 - sdk integration tests - base
|
|
@@ -123,6 +140,7 @@ jobs:
|
|
|
123
140
|
- VCR_ON=false
|
|
124
141
|
- GD_ENV=staging
|
|
125
142
|
rvm: jruby-9.1.14
|
|
143
|
+
jdk: openjdk8
|
|
126
144
|
|
|
127
145
|
- &sdk-integration-tests-project
|
|
128
146
|
name: staging1 - sdk integration tests - project
|
|
@@ -132,6 +150,7 @@ jobs:
|
|
|
132
150
|
- VCR_ON=false
|
|
133
151
|
- GD_ENV=staging
|
|
134
152
|
rvm: jruby-9.1.14
|
|
153
|
+
jdk: openjdk8
|
|
135
154
|
|
|
136
155
|
# staging 2
|
|
137
156
|
- <<: *lcm-integration-tests
|
|
@@ -143,13 +162,19 @@ jobs:
|
|
|
143
162
|
- <<: *lcm-slow-tests
|
|
144
163
|
name: staging2 - lcm slow tests
|
|
145
164
|
env:
|
|
146
|
-
- GD_ENV=
|
|
165
|
+
- GD_ENV=testing
|
|
147
166
|
- VCR_ON=false
|
|
148
167
|
|
|
149
168
|
- <<: *userprov-tests
|
|
150
169
|
name: staging2 - lcm user provisioning tests
|
|
151
170
|
env:
|
|
152
|
-
- GD_ENV=
|
|
171
|
+
- GD_ENV=testing
|
|
172
|
+
- VCR_ON=false
|
|
173
|
+
|
|
174
|
+
- <<: *bricks-smoke-tests
|
|
175
|
+
name: staging2 - bricks smoke tests
|
|
176
|
+
env:
|
|
177
|
+
- GD_ENV=testing
|
|
153
178
|
- VCR_ON=false
|
|
154
179
|
|
|
155
180
|
- <<: *sdk-integration-tests
|
|
@@ -174,13 +199,20 @@ jobs:
|
|
|
174
199
|
- <<: *lcm-slow-tests
|
|
175
200
|
name: staging3 - lcm slow tests
|
|
176
201
|
env:
|
|
177
|
-
- GD_ENV=
|
|
202
|
+
- GD_ENV=development
|
|
178
203
|
- VCR_ON=false
|
|
179
204
|
|
|
180
205
|
- <<: *userprov-tests
|
|
181
206
|
name: staging3 - lcm user provisioning tests
|
|
182
207
|
env:
|
|
183
|
-
- GD_ENV=
|
|
208
|
+
- GD_ENV=development
|
|
209
|
+
- VCR_ON=false
|
|
210
|
+
|
|
211
|
+
|
|
212
|
+
- <<: *bricks-smoke-tests
|
|
213
|
+
name: staging3 - bricks smoke tests
|
|
214
|
+
env:
|
|
215
|
+
- GD_ENV=development
|
|
184
216
|
- VCR_ON=false
|
|
185
217
|
|
|
186
218
|
- <<: *sdk-integration-tests
|
|
@@ -210,7 +242,7 @@ jobs:
|
|
|
210
242
|
name: staging3 - test environment clean-up
|
|
211
243
|
env: GD_ENV=development
|
|
212
244
|
|
|
213
|
-
# AFTER MERGE UNIT TESTS ON ALTERNATIVE PLATFORM
|
|
245
|
+
# AFTER MERGE UNIT TESTS ON ALTERNATIVE PLATFORM
|
|
214
246
|
|
|
215
247
|
- name: unit tests 2.3
|
|
216
248
|
stage: after-merge
|
|
@@ -223,7 +255,7 @@ jobs:
|
|
|
223
255
|
stage: after-merge
|
|
224
256
|
script: bundle exec rake test:unit
|
|
225
257
|
os: osx
|
|
226
|
-
osx_image: xcode9.3
|
|
258
|
+
osx_image: xcode9.3
|
|
227
259
|
rvm: 2.4
|
|
228
260
|
|
|
229
261
|
- name: unit tests 2.5
|
|
@@ -246,14 +278,6 @@ jobs:
|
|
|
246
278
|
os: osx
|
|
247
279
|
rvm: jruby-9.1.14
|
|
248
280
|
|
|
249
|
-
- name: unit tests 2.2
|
|
250
|
-
stage: after-merge
|
|
251
|
-
before_install:
|
|
252
|
-
- gem install bundler -v 1.17
|
|
253
|
-
script: bundle exec rake test:unit
|
|
254
|
-
os: osx
|
|
255
|
-
rvm: 2.2
|
|
256
|
-
|
|
257
281
|
- stage: gem-release
|
|
258
282
|
name: deploy MRI gem
|
|
259
283
|
rvm: 2.3
|
|
@@ -264,6 +288,7 @@ jobs:
|
|
|
264
288
|
- stage: gem-release
|
|
265
289
|
name: deploy JRuby gem
|
|
266
290
|
rvm: jruby-9.1.14
|
|
291
|
+
jdk: openjdk8
|
|
267
292
|
script: |
|
|
268
293
|
echo -e "---\n:rubygems_api_key: $RUBYGEMS_API_KEY" > ~/.gem/credentials
|
|
269
294
|
chmod 0600 ~/.gem/credentials
|
|
@@ -278,6 +303,7 @@ jobs:
|
|
|
278
303
|
- <<: *gem-smoke-test
|
|
279
304
|
name: smoke test JRuby gem
|
|
280
305
|
rvm: jruby-9.1.14
|
|
306
|
+
jdk: openjdk8
|
|
281
307
|
|
|
282
308
|
notifications:
|
|
283
309
|
email:
|
data/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,31 @@
|
|
|
1
1
|
# GoodData Ruby SDK Changelog
|
|
2
|
+
## 2.1.4
|
|
3
|
+
- BUGFIX: TMA-906 LCM Rollout/Provisioning does not set dynamic params in case apply for all schedules on client
|
|
4
|
+
- BUGFIX: TMA-1519 Add limit param when get all projects
|
|
5
|
+
- II-448: Move configuration from Jenkinsfile
|
|
6
|
+
- TMA-1515: version bump
|
|
7
|
+
- TRIVIAL: remove obsolete hello_world brick
|
|
8
|
+
- TMA-1515: run the bricks as user apache
|
|
9
|
+
- FEATURE: TMA-1487: Delete testing snowflake data sources and fixing CR
|
|
10
|
+
- Switch end to end test to staging 2
|
|
11
|
+
- TMA-1275: Skip cloning ADDv2 process into LCM master
|
|
12
|
+
- BUGFIX: TMA-1505 import gooddata certificate when run smoke test
|
|
13
|
+
- TMA-1502: remove jdk8 from tavis config return to inocence, for unknown reason openjdk8 and default mac-osx image does not work together on travis
|
|
14
|
+
- TMA-1502: set travis to use jdk8
|
|
15
|
+
- TMA-1502: use numeric user-id for docker does not operate properly with user-name
|
|
16
|
+
- II-456 Use kubernetes recommended labels and latest chart templates
|
|
17
|
+
- TMA-1486: Alerts for job count in LCM namespace
|
|
18
|
+
- TMA-1292: more resilient k8s smoke spec
|
|
19
|
+
- Fix adding server response to error message
|
|
20
|
+
- TMA-1395 fix username in smoke test
|
|
21
|
+
- TMA-1468: add #upload_multiple spec
|
|
22
|
+
- TMA-1395 fix username in help.sh
|
|
23
|
+
- TMA-1395 fix username in docker container
|
|
24
|
+
- TRIVIAL: use forked pronto-flay with high mass thresholds setup in travis
|
|
25
|
+
- Automated base image update (gdc-docker-images, d0f5e08)
|
|
26
|
+
- TMA-1454: remove activesupport dependencies from spec
|
|
27
|
+
- Automated base image update (gdc-docker-images, d38e8ad)
|
|
28
|
+
|
|
2
29
|
## 2.1.3
|
|
3
30
|
- TMA-1394: upload_data takes mapping of gd labels to csv columns into account
|
|
4
31
|
- TMA-1292: K8s load and smoke spec
|
data/Dockerfile
CHANGED
|
@@ -1,38 +1,46 @@
|
|
|
1
|
-
FROM harbor.intgdc.com/tools/gdc-java-8-jre:
|
|
1
|
+
FROM harbor.intgdc.com/tools/gdc-java-8-jre:d0f5e08
|
|
2
2
|
|
|
3
|
-
ARG
|
|
4
|
-
ARG
|
|
3
|
+
ARG RVM_VERSION=stable
|
|
4
|
+
ARG JRUBY_VERSION=9.2.5.0
|
|
5
5
|
|
|
6
6
|
LABEL image_name="GDC LCM Bricks"
|
|
7
7
|
LABEL maintainer="LCM <lcm@gooddata.com>"
|
|
8
8
|
LABEL git_repository_url="https://github.com/gooddata/gooddata-ruby/"
|
|
9
|
-
LABEL parent_image="harbor.intgdc.com/tools/gdc-java-8-jre:
|
|
10
|
-
LABEL git_commit=$GIT_COMMIT
|
|
11
|
-
LABEL bricks_version=$BRICKS_VERSION
|
|
9
|
+
LABEL parent_image="harbor.intgdc.com/tools/gdc-java-8-jre:d0f5e08"
|
|
12
10
|
|
|
13
11
|
# which is required by RVM
|
|
14
12
|
RUN yum install -y curl which patch make git \
|
|
15
13
|
&& yum clean all \
|
|
16
14
|
&& rm -rf /var/cache/yum
|
|
17
15
|
|
|
18
|
-
#
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
16
|
+
# Install + verify RVM with gpg (https://rvm.io/rvm/security)
|
|
17
|
+
RUN gpg2 --quiet --no-tty --logger-fd 1 --keyserver hkp://keys.gnupg.net \
|
|
18
|
+
--recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 \
|
|
19
|
+
7D2BAF1CF37B13E2069D6956105BD0E739499BDB \
|
|
20
|
+
&& echo 409B6B1796C275462A1703113804BB82D39DC0E3:6: | \
|
|
21
|
+
gpg2 --quiet --no-tty --logger-fd 1 --import-ownertrust \
|
|
22
|
+
&& curl -sSO https://raw.githubusercontent.com/rvm/rvm/${RVM_VERSION}/binscripts/rvm-installer \
|
|
23
|
+
&& curl -sSO https://raw.githubusercontent.com/rvm/rvm/${RVM_VERSION}/binscripts/rvm-installer.asc \
|
|
24
|
+
&& gpg2 --quiet --no-tty --logger-fd 1 --verify rvm-installer.asc \
|
|
25
|
+
&& bash rvm-installer ${RVM_VERSION} \
|
|
26
|
+
&& rm rvm-installer rvm-installer.asc \
|
|
27
|
+
&& echo "bundler" >> /usr/local/rvm/gemsets/global.gems \
|
|
28
|
+
&& echo "rvm_silence_path_mismatch_check_flag=1" >> /etc/rvmrc \
|
|
29
|
+
&& echo "install: --no-document" > /etc/gemrc
|
|
30
|
+
|
|
31
|
+
# Switch to a bash login shell to allow simple 'rvm' in RUN commands
|
|
32
|
+
SHELL ["/bin/bash", "-l", "-c"]
|
|
33
|
+
|
|
34
|
+
RUN rvm install jruby-${JRUBY_VERSION} && gem update --system \
|
|
35
|
+
&& gem install bundler rake
|
|
27
36
|
|
|
28
|
-
|
|
29
|
-
RUN curl -sSL https://get.rvm.io | bash -s stable
|
|
37
|
+
WORKDIR /src
|
|
30
38
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
&&
|
|
39
|
+
RUN groupadd -g 48 apache \
|
|
40
|
+
&& useradd -u 48 -m --no-log-init -r -g apache -G rvm apache \
|
|
41
|
+
&& chown apache: /src
|
|
34
42
|
|
|
35
|
-
|
|
43
|
+
USER apache
|
|
36
44
|
|
|
37
45
|
ADD ./bin ./bin
|
|
38
46
|
ADD ./lib ./lib
|
|
@@ -41,6 +49,13 @@ ADD ./VERSION .
|
|
|
41
49
|
ADD ./Gemfile .
|
|
42
50
|
ADD ./gooddata.gemspec .
|
|
43
51
|
|
|
44
|
-
RUN
|
|
52
|
+
RUN bundle install
|
|
53
|
+
|
|
54
|
+
ARG GIT_COMMIT=unspecified
|
|
55
|
+
ARG BRICKS_VERSION=unspecified
|
|
56
|
+
LABEL git_commit=$GIT_COMMIT
|
|
57
|
+
LABEL bricks_version=$BRICKS_VERSION
|
|
58
|
+
|
|
59
|
+
ENV GOODDATA_RUBY_COMMIT=$GIT_COMMIT
|
|
45
60
|
|
|
46
61
|
CMD [ "./bin/help.sh" ]
|
data/Gemfile
CHANGED
|
@@ -2,12 +2,12 @@ source 'https://rubygems.org'
|
|
|
2
2
|
|
|
3
3
|
group 'development' do
|
|
4
4
|
unless RUBY_PLATFORM == 'java'
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
ref: '266805b'
|
|
5
|
+
gem 'pronto-flay',
|
|
6
|
+
git: 'https://github.com/kubamahnert/pronto-flay',
|
|
7
|
+
branch: 'flay-mass-threshold'
|
|
9
8
|
end
|
|
10
9
|
end
|
|
11
10
|
|
|
12
11
|
# Specify your gem's dependencies in gooddata.gemspec
|
|
13
12
|
gemspec
|
|
13
|
+
|
data/Jenkinsfile-chart
CHANGED
data/SDK_VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
2.1.
|
|
1
|
+
2.1.4
|
data/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
3.
|
|
1
|
+
3.7.2
|
data/bin/help.sh
CHANGED
data/bin/provision.sh
CHANGED
data/bin/release.sh
CHANGED
data/bin/rollout.sh
CHANGED
data/bin/run_smoke_tests.sh
CHANGED
|
@@ -2,4 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
export LCM_BRICKS_IMAGE_TAG=$GOODDATA_RUBY_COMMIT
|
|
4
4
|
export GD_ENV=staging
|
|
5
|
-
|
|
5
|
+
|
|
6
|
+
# WORKAROUND: temp HOME is needed since RSpec uses simplecov which requires HOME to be set to something else than '/'
|
|
7
|
+
# which is default when running container as the non existing user within the image.
|
|
8
|
+
# The core problem there is jruby's `isAbsoluteHome` method considering path of length 1 not to be absolute
|
|
9
|
+
/bin/bash -l -c "if [[ $HOME == '/' ]]; then export HOME=$(mktemp -d); fi && bundle exec rake -f lcm.rake test:smoke"
|
|
@@ -86,6 +86,7 @@ def clean_up!(client, force, days)
|
|
|
86
86
|
delete_project_by_title(/LCM spec Client With Conflicting LDM Changes/, projects, days, force)
|
|
87
87
|
delete_project_by_title(/LCM spec master project/, projects, days, force)
|
|
88
88
|
delete_project_by_title(/users brick load test/, projects, days, force)
|
|
89
|
+
delete_project_by_title(/#transfer_processes and #transfer_schedules test/, projects, days, force)
|
|
89
90
|
delete_ads_by_title(/Development ADS/, client, days, force)
|
|
90
91
|
delete_ads_by_title(/Production ADS/, client, days, force)
|
|
91
92
|
delete_ads_by_title(/TEST ADS/, client, days, force)
|
data/bin/user_filters.sh
CHANGED
data/bin/users.sh
CHANGED
data/gooddata.gemspec
CHANGED
|
@@ -46,10 +46,9 @@ Gem::Specification.new do |s|
|
|
|
46
46
|
s.add_development_dependency 'pry'
|
|
47
47
|
s.add_development_dependency 'pry-byebug', '~> 3.6' if RUBY_PLATFORM != 'java'
|
|
48
48
|
|
|
49
|
-
s.add_development_dependency 'pronto', '~> 0.
|
|
50
|
-
s.add_development_dependency 'pronto-rubocop', '~> 0.9
|
|
51
|
-
s.add_development_dependency 'pronto-reek', '~> 0.9
|
|
52
|
-
s.add_development_dependency 'pronto-flay', '~> 0.9.0' if RUBY_PLATFORM != 'java'
|
|
49
|
+
s.add_development_dependency 'pronto', '~> 0.10' if RUBY_PLATFORM != 'java'
|
|
50
|
+
s.add_development_dependency 'pronto-rubocop', '~> 0.9' if RUBY_PLATFORM != 'java'
|
|
51
|
+
s.add_development_dependency 'pronto-reek', '~> 0.9' if RUBY_PLATFORM != 'java'
|
|
53
52
|
s.add_development_dependency 'vcr'
|
|
54
53
|
|
|
55
54
|
s.add_development_dependency 'sqlite3' if RUBY_PLATFORM != 'java'
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
{{/* vim: set filetype=mustache: */}}
|
|
2
|
+
{{/*
|
|
3
|
+
Expand the name of the chart.
|
|
4
|
+
*/}}
|
|
5
|
+
{{- define "lcm-bricks.name" -}}
|
|
6
|
+
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
|
7
|
+
{{- end -}}
|
|
8
|
+
|
|
9
|
+
{{/*
|
|
10
|
+
Create chart name and version as used by the chart label.
|
|
11
|
+
*/}}
|
|
12
|
+
{{- define "lcm-bricks.chart" -}}
|
|
13
|
+
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
|
14
|
+
{{- end -}}
|
|
@@ -4,11 +4,11 @@ metadata:
|
|
|
4
4
|
name: lcm-bricks-monitoring-rules
|
|
5
5
|
namespace: monitoring
|
|
6
6
|
labels:
|
|
7
|
-
app: lcm-bricks
|
|
8
|
-
component: lcm
|
|
7
|
+
app.kubernetes.io/name: {{ include "lcm-bricks.name" . }}
|
|
9
8
|
team: lcm
|
|
10
|
-
chart: lcm-bricks
|
|
11
|
-
|
|
9
|
+
helm.sh/chart: {{ include "lcm-bricks.chart" . }}
|
|
10
|
+
app.kubernetes.io/instance: {{ .Release.Name }}
|
|
11
|
+
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
|
12
12
|
data:
|
|
13
13
|
lcm-bricks-monitoring-rules.yaml: |+
|
|
14
14
|
groups:
|
|
@@ -74,3 +74,12 @@ data:
|
|
|
74
74
|
annotations:
|
|
75
75
|
description: "{{`{{ $labels.kubernetes_pod_name }}`}} container is spending too much time in pause garbage collector. Investigate root cause and increase heap size and/or number of replicas if necessary."
|
|
76
76
|
summary: "{{`{{ $labels.kubernetes_pod_name }}`}} is doing too much pause GC"
|
|
77
|
+
- alert: "[LCM] there is more than 100 jobs on cluster={{ .Values.clusterId }}"
|
|
78
|
+
expr: count(kube_job_info{namespace="lcm"}) > 100
|
|
79
|
+
labels:
|
|
80
|
+
severity: critical
|
|
81
|
+
team: lcm # switch to msf in production
|
|
82
|
+
cluster_id: {{ .Values.clusterId }}
|
|
83
|
+
annotations:
|
|
84
|
+
description: "There is more than 100 jobs in LCM namespace. They are likely not deleted."
|
|
85
|
+
summary: "There is more than 100 jobs in LCM namespace."
|
|
@@ -57,8 +57,11 @@ module GoodData
|
|
|
57
57
|
GoodData.logger.debug("Processing row: #{safe_to_print_row}")
|
|
58
58
|
results << safe_to_print_row
|
|
59
59
|
|
|
60
|
-
|
|
61
|
-
|
|
60
|
+
client_id_column_value = row[client_id_column]
|
|
61
|
+
client_id = client_id_column_value.blank? ? :all_clients : client_id_column_value
|
|
62
|
+
|
|
63
|
+
schedule_title_column_value = row[schedule_title_column]
|
|
64
|
+
schedule_name = schedule_title_column_value.blank? ? :all_schedules : schedule_title_column_value
|
|
62
65
|
|
|
63
66
|
schedule_params[client_id] ||= {}
|
|
64
67
|
schedule_params[client_id][schedule_name] ||= {}
|
|
@@ -123,7 +123,7 @@ module GoodData
|
|
|
123
123
|
|
|
124
124
|
client_id = entry[:client_id]
|
|
125
125
|
params_for_this_client = schedule_params[client_id] || {}
|
|
126
|
-
params_for_all_schedules_in_this_client = params_for_this_client[
|
|
126
|
+
params_for_all_schedules_in_this_client = params_for_this_client[:all_schedules]
|
|
127
127
|
|
|
128
128
|
to_project.set_metadata('GOODOT_CUSTOM_PROJECT_ID', client_id) # TMA-210
|
|
129
129
|
|
|
@@ -186,14 +186,7 @@ module GoodData
|
|
|
186
186
|
client, project = GoodData.get_client_and_project(options)
|
|
187
187
|
data = { process: data } unless data[:process]
|
|
188
188
|
data[:process] = GoodData::Helpers.symbolize_keys(data[:process]).select { |k| %i[type name component].include? k }
|
|
189
|
-
data[:process][:component] = GoodData::Helpers.symbolize_keys(data[:process][:component]).select { |k| %i[name version configLocation].include? k }
|
|
190
|
-
|
|
191
|
-
# a feature flag is required to create component type processes
|
|
192
|
-
client.post "/gdc/projects/#{project.pid}/projectFeatureFlags",
|
|
193
|
-
featureFlag: {
|
|
194
|
-
key: 'enableEtlComponent',
|
|
195
|
-
value: true
|
|
196
|
-
}
|
|
189
|
+
data[:process][:component] = GoodData::Helpers.symbolize_keys(data[:process][:component]).select { |k| %i[name version configLocation config].include? k }
|
|
197
190
|
|
|
198
191
|
save(data, options)
|
|
199
192
|
end
|
|
@@ -333,6 +326,12 @@ module GoodData
|
|
|
333
326
|
process['component']
|
|
334
327
|
end
|
|
335
328
|
|
|
329
|
+
# Determines whether the process is an ADDv2 component.
|
|
330
|
+
# @return [Bool] True if the process is an ADDv2 component.
|
|
331
|
+
def add_v2_component?
|
|
332
|
+
process['component'] && process['component']['name'] == 'gdc-data-distribution'
|
|
333
|
+
end
|
|
334
|
+
|
|
336
335
|
def schedules
|
|
337
336
|
project.schedules.select { |schedule| schedule.process_id == obj_id }
|
|
338
337
|
end
|
|
@@ -326,8 +326,15 @@ module GoodData
|
|
|
326
326
|
# Gets the array of projects
|
|
327
327
|
#
|
|
328
328
|
# @return [Array<GoodData::Project>] Array of project where account settings belongs to
|
|
329
|
-
def projects
|
|
330
|
-
|
|
329
|
+
def projects(limit = nil)
|
|
330
|
+
url = @json['accountSetting']['links']['projects']
|
|
331
|
+
query_params = ''
|
|
332
|
+
if !limit.nil? && limit.is_a?(Integer) && limit > 0
|
|
333
|
+
limit = [limit, 500].min
|
|
334
|
+
query_params += "limit=#{limit}"
|
|
335
|
+
end
|
|
336
|
+
url += "?#{query_params}" unless query_params.empty?
|
|
337
|
+
projects = client.get url
|
|
331
338
|
projects['projects'].map do |project|
|
|
332
339
|
client.create(GoodData::Project, project)
|
|
333
340
|
end
|
|
@@ -67,9 +67,9 @@ module GoodData
|
|
|
67
67
|
class << self
|
|
68
68
|
# Returns an array of all projects accessible by
|
|
69
69
|
# current user
|
|
70
|
-
def all(opts = { client: GoodData.connection })
|
|
70
|
+
def all(opts = { client: GoodData.connection }, limit = nil)
|
|
71
71
|
c = GoodData.get_client(opts)
|
|
72
|
-
c.user.projects
|
|
72
|
+
c.user.projects(limit)
|
|
73
73
|
end
|
|
74
74
|
|
|
75
75
|
# Returns a Project object identified by given string
|
|
@@ -265,7 +265,8 @@ module GoodData
|
|
|
265
265
|
additional_hidden_params = options[:additional_hidden_params] || {}
|
|
266
266
|
result = from_project.processes.uniq(&:name).map do |process|
|
|
267
267
|
fail "The process name #{process.name} must be unique in transfered project #{to_project}" if to_project_processes.count { |p| p.name == process.name } > 1
|
|
268
|
-
next if process.type == :dataload
|
|
268
|
+
next if process.type == :dataload || process.add_v2_component?
|
|
269
|
+
|
|
269
270
|
to_process = to_project_processes.find { |p| p.name == process.name }
|
|
270
271
|
|
|
271
272
|
to_process = if process.path
|
|
@@ -310,6 +311,7 @@ module GoodData
|
|
|
310
311
|
res = (from_project.processes + to_project.processes).map { |p| [p, p.name, p.type] }
|
|
311
312
|
res.group_by { |x| [x[1], x[2]] }
|
|
312
313
|
.select { |_, procs| procs.length == 1 && procs[2] != :dataload }
|
|
314
|
+
.reject { |_, procs| procs.first.first.add_v2_component? }
|
|
313
315
|
.flat_map { |_, procs| procs.select { |p| p[0].project.pid == to_project.pid }.map { |p| p[0] } }
|
|
314
316
|
.peach(&:delete)
|
|
315
317
|
|
|
@@ -355,6 +357,7 @@ module GoodData
|
|
|
355
357
|
def transfer_schedules(from_project, to_project)
|
|
356
358
|
to_project_processes = to_project.processes.sort_by(&:name)
|
|
357
359
|
from_project_processes = from_project.processes.sort_by(&:name)
|
|
360
|
+
from_project_processes.reject!(&:add_v2_component?)
|
|
358
361
|
|
|
359
362
|
GoodData.logger.debug("Processes in from project #{from_project.pid}: #{from_project_processes.map(&:name).join(', ')}")
|
|
360
363
|
GoodData.logger.debug("Processes in to project #{to_project.pid}: #{to_project_processes.map(&:name).join(', ')}")
|
|
@@ -415,6 +418,8 @@ module GoodData
|
|
|
415
418
|
(schedule_spec[:process_id] == local.process_id) && (schedule.name == schedule_spec[:name])
|
|
416
419
|
end
|
|
417
420
|
|
|
421
|
+
next unless remote_process || process_spec
|
|
422
|
+
|
|
418
423
|
GoodData.logger.info("Creating schedule #{schedule_spec[:name]} for process #{remote_process.name}")
|
|
419
424
|
|
|
420
425
|
executable = nil
|
|
@@ -77,7 +77,8 @@ module GoodData
|
|
|
77
77
|
de_synchronize_all = options[:de_synchronize_all] || options['GDC_DE_SYNCHRONIZE_ALL']
|
|
78
78
|
else
|
|
79
79
|
lcm_component = process.type == :lcm
|
|
80
|
-
|
|
80
|
+
add_component = process.add_v2_component?
|
|
81
|
+
executable_missing = !lcm_component && !add_component && executable.blank?
|
|
81
82
|
fail 'Executable has to be provided' if executable_missing
|
|
82
83
|
end
|
|
83
84
|
|
data/lib/gooddata/rest/client.rb
CHANGED
|
@@ -188,8 +188,12 @@ module GoodData
|
|
|
188
188
|
end
|
|
189
189
|
end
|
|
190
190
|
|
|
191
|
-
def projects(id = :all)
|
|
192
|
-
|
|
191
|
+
def projects(id = :all, limit = nil)
|
|
192
|
+
if limit.nil?
|
|
193
|
+
GoodData::Project[id, client: self]
|
|
194
|
+
else
|
|
195
|
+
GoodData::Project.all({ client: self }, limit)
|
|
196
|
+
end
|
|
193
197
|
end
|
|
194
198
|
|
|
195
199
|
def processes(id = :all)
|
|
@@ -471,9 +471,11 @@ module GoodData
|
|
|
471
471
|
return exception unless exception.response
|
|
472
472
|
|
|
473
473
|
response = JSON.parse(exception.response.body, symbolize_names: true)
|
|
474
|
-
return exception unless exception.message && response[:error] && response[:error][:message]
|
|
474
|
+
return exception unless exception.message && response[:error] && response[:error][:message]
|
|
475
475
|
|
|
476
|
-
|
|
476
|
+
request_id = exception.response.headers[:x_gdc_request] || 'unknown'
|
|
477
|
+
|
|
478
|
+
exception.message = exception.message + ': ' + response[:error][:message] % response[:error][:parameters] + ' request_id: ' + request_id
|
|
477
479
|
rescue JSON::ParserError # rubocop:disable Lint/HandleExceptions
|
|
478
480
|
end
|
|
479
481
|
exception
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: gooddata
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.1.
|
|
4
|
+
version: 2.1.4
|
|
5
5
|
platform: java
|
|
6
6
|
authors:
|
|
7
7
|
- Pavel Kolesnikov
|
|
@@ -14,7 +14,7 @@ authors:
|
|
|
14
14
|
autorequire:
|
|
15
15
|
bindir: bin
|
|
16
16
|
cert_chain: []
|
|
17
|
-
date: 2019-
|
|
17
|
+
date: 2019-06-03 00:00:00.000000000 Z
|
|
18
18
|
dependencies:
|
|
19
19
|
- !ruby/object:Gem::Dependency
|
|
20
20
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -482,7 +482,6 @@ email: lcm@gooddata.com
|
|
|
482
482
|
executables:
|
|
483
483
|
- gitflow-init.sh
|
|
484
484
|
- gooddata
|
|
485
|
-
- hello_world.sh
|
|
486
485
|
- help.sh
|
|
487
486
|
- provision.sh
|
|
488
487
|
- release.sh
|
|
@@ -501,6 +500,7 @@ files:
|
|
|
501
500
|
- ".document"
|
|
502
501
|
- ".editorconfig"
|
|
503
502
|
- ".flayignore"
|
|
503
|
+
- ".gdc-ii-config-chart.yaml"
|
|
504
504
|
- ".gdc-ii-config.yaml"
|
|
505
505
|
- ".gitignore"
|
|
506
506
|
- ".pronto.yml"
|
|
@@ -530,7 +530,6 @@ files:
|
|
|
530
530
|
- authors.sh
|
|
531
531
|
- bin/gitflow-init.sh
|
|
532
532
|
- bin/gooddata
|
|
533
|
-
- bin/hello_world.sh
|
|
534
533
|
- bin/help.sh
|
|
535
534
|
- bin/provision.sh
|
|
536
535
|
- bin/release.sh
|
|
@@ -551,6 +550,7 @@ files:
|
|
|
551
550
|
- gooddata
|
|
552
551
|
- gooddata.gemspec
|
|
553
552
|
- k8s/charts/lcm-bricks/Chart.yaml
|
|
553
|
+
- k8s/charts/lcm-bricks/templates/_helpers.tpl
|
|
554
554
|
- k8s/charts/lcm-bricks/templates/prometheus/alertingRules.yaml
|
|
555
555
|
- lcm.rake
|
|
556
556
|
- lib/gooddata.rb
|
data/bin/hello_world.sh
DELETED