Pull request event #3839 passed

  • Ran for
  • New branch build
AMD64
Ruby: 3.2.2
Git
Raw log
Scroll to End of Log
0.00s0.22s0.12s0.06s0.00s
worker_info
1Worker information
2hostname: d0a23df6-7d63-47e8-a6a9-814614a8c919@1.worker-n2-com-f8c4bb956-cnsdw.gce-production-1
3version: deploy_2024.10.02-2-gc32b553 https://github.com/travis-ci/worker/tree/c32b553e81363378d09787f52103ea9bcadf253c
4instance: travis-job-cd235b8d-cacf-413d-86f1-c138338f72e0 travis-ci-ubuntu-2004-1726220016-655c8cb5 (via amqp)
5startup: 5.828413398s
60.22s0.00s0.01s0.00s0.01s
system_info
7Build system information
8Build language: ruby
9Build dist: focal
10Build id: 273865569
11Job id: 629755145
12Runtime kernel version: 5.15.0-1068-gcp
13VM: default
14travis-build version: 6b157a1c
15Build image provisioning date and time
16Fri 13 Sep 2024 09:58:48 AM UTC
17Operating System Details
18Distributor ID: Ubuntu
19Description: Ubuntu 20.04.6 LTS
20Release: 20.04
21Codename: focal
22Systemd Version
23systemd 245 (245.4-4ubuntu3.23)
24Cookbooks Version
2539734fe https://github.com/travis-ci/travis-cookbooks/tree/39734fe
26git version
27git version 2.46.0
28bash version
29GNU bash, version 5.0.17(1)-release (x86_64-pc-linux-gnu)
30gcc version
31gcc (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0
32docker version
33Client:
34 Version: 24.0.7
35 API version: 1.43
36 Go version: go1.21.1
37 Git commit: 24.0.7-0ubuntu2~20.04.1
38 Built: Wed Mar 13 20:29:24 2024
39 OS/Arch: linux/amd64
40 Context: default
42Server:
43 Engine:
44 Version: 24.0.7
45 API version: 1.43 (minimum version 1.12)
46 Go version: go1.21.1
47 Git commit: 24.0.7-0ubuntu2~20.04.1
48 Built: Wed Mar 13 20:29:24 2024
49 OS/Arch: linux/amd64
50 Experimental: false
51 containerd:
52 Version: 1.7.12
53 GitCommit:
54 runc:
55 Version: 1.1.12-0ubuntu2~20.04.1
56 GitCommit:
57 docker-init:
58 Version: 0.19.0
59 GitCommit:
60clang version
61clang version 18.1.8
62jq version
63jq-1.7.1
64bats version
65Bats 1.11.0
66shellcheck version
670.10.0
68shfmt version
69v3.8.0
70ccache version
713.7.7
72cmake version
73cmake version 3.29.0
74heroku version
75heroku/9.2.1 linux-x64 node-v16.20.2
76imagemagick version
77Version: ImageMagick 6.9.10-23 Q16 x86_64 20190101 https://imagemagick.org
78md5deep version
794.4
80mercurial version
81version 6.5.2
82mysql version
83mysql Ver 8.0.39-0ubuntu0.20.04.1 for Linux on x86_64 ((Ubuntu))
84openssl version
85OpenSSL 1.1.1f 31 Mar 2020
86packer version
87Packer v1.11.2
88postgresql client version
89psql (PostgreSQL) 13.16 (Ubuntu 13.16-1.pgdg20.04+1)
90ragel version
91Ragel State Machine Compiler version 6.10 March 2017
92sudo version
931.8.31
94gzip version
95gzip 1.10
96zip version
97Zip 3.0
98vim version
99VIM - Vi IMproved 8.1 (2018 May 18, compiled Sep 04 2024 03:11:27)
100iptables version
101iptables v1.8.4 (legacy)
102curl version
103curl 7.68.0 (x86_64-pc-linux-gnu) libcurl/7.68.0 OpenSSL/1.1.1f zlib/1.2.11 brotli/1.0.7 libidn2/2.2.0 libpsl/0.21.0 (+libidn2/2.2.0) libssh/0.9.3/openssl/zlib nghttp2/1.40.0 librtmp/2.3
104wget version
105GNU Wget 1.20.3 built on linux-gnu.
106rsync version
107rsync version 3.1.3 protocol version 31
108gimme version
109v1.5.4
110nvm version
1110.40.1
112perlbrew version
113/home/travis/perl5/perlbrew/bin/perlbrew - App::perlbrew/0.95
114phpenv version
115rbenv 1.3.0
116rvm version
117rvm 1.29.12 (latest) by Michal Papis, Piotr Kuczynski, Wayne E. Seguin [https://rvm.io]
118default ruby version
119ruby 3.3.5 (2024-09-03 revision ef084cc8f4) [x86_64-linux]
120default python version
121Python 3.7.17
122ElasticSearch version
1237.16.3
124Installed Firefox version
125firefox 99.0
126MongoDB version
127MongoDB 4.4.29
128PhantomJS version
1292.1.1
130Redis version
131redis-server 7.4.0
132Pre-installed Go versions
1331.23.0
134mvn version
135Apache Maven 3.9.4 (dfbb324ad4a7c8fb0bf182e6d91b0ae20e3d2dd9)
136gradle version
137Gradle 8.3!
138lein version
139Leiningen 2.11.2 on Java 11.0.21 OpenJDK 64-Bit Server VM
140Pre-installed Node.js versions
141v10.24.1
142v12.22.12
143v14.21.3
144v16.15
145v16.20.2
146v18.20.3
147v18.20.4
148v20.17.0
149v4.9.1
150v6.17.1
151v8.17.0
152phpenv versions
153 system
154 7.4
155* 7.4.6 (set by /home/travis/.phpenv/version)
156 hhvm-stable
157 hhvm
158composer --version
159Composer version 1.10.6 2020-05-06 10:28:10
160Pre-installed Ruby versions
161ruby-2.7.6
162ruby-3.3.5
1640.02s0.01s0.79s0.30s0.05s0.01s0.04s0.00s0.03s0.01s0.01s0.01s0.01s0.00s0.44sOK
1650.00s0.05s0.00s0.02s0.18s0.00s0.01s0.00s0.01s0.00s0.17s0.00s1.02s0.00s0.12s6.04s0.00s4.08s0.00s2.35s
docker_mtu_and_registry_mirrors
Docker
resolvconf
apt
166Adding APT Sources
1670.37s$ curl -sSL "https://www.postgresql.org/media/keys/ACCC4CF8.asc" | sudo -E apt-key add -
168OK
1690.04s$ echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" | sudo tee -a ${TRAVIS_ROOT}/etc/apt/sources.list >/dev/null
17015.47s$ travis_apt_get_update
171Installing APT Packages
172PostgreSQL package is detected. Stopping postgresql service. See https://github.com/travis-ci/travis-ci/issues/5737 for more information.
173$ sudo systemctl stop postgresql
17415.64s$ sudo -E apt-get -yq --no-install-suggests --no-install-recommends $(travis_apt_get_options) install postgresql-11 postgresql-client-11
175Reading package lists...
176Building dependency tree...
177Reading state information...
178The following packages were automatically installed and are no longer required:
179 amd64-microcode intel-microcode iucode-tool libglu1-mesa
180 libjs-jquery-metadata libjs-jquery-tablesorter libnotify4 libwxbase3.0-0v5
181 libwxgtk3.0-gtk3-0v5 linux-modules-5.4.0-195-generic postgresql-client-12
182Use 'sudo apt autoremove' to remove them.
183Suggested packages:
184 postgresql-doc-11
185Recommended packages:
186 sysstat
187The following NEW packages will be installed:
188 postgresql-11 postgresql-client-11
1890 upgraded, 2 newly installed, 0 to remove and 128 not upgraded.
190Need to get 15.8 MB of archives.
191After this operation, 54.1 MB of additional disk space will be used.
192Get:1 http://apt.postgresql.org/pub/repos/apt focal-pgdg/main amd64 postgresql-client-11 amd64 11.22-8.pgdg20.04+1 [1,494 kB]
193Get:2 http://apt.postgresql.org/pub/repos/apt focal-pgdg/main amd64 postgresql-11 amd64 11.22-8.pgdg20.04+1 [14.3 MB]
194Preconfiguring packages ...
195Fetched 15.8 MB in 3s (5,422 kB/s)
196Selecting previously unselected package postgresql-client-11.
197(Reading database ... 154608 files and directories currently installed.)
198Preparing to unpack .../postgresql-client-11_11.22-8.pgdg20.04+1_amd64.deb ...
199Unpacking postgresql-client-11 (11.22-8.pgdg20.04+1) ...
200Selecting previously unselected package postgresql-11.
201Preparing to unpack .../postgresql-11_11.22-8.pgdg20.04+1_amd64.deb ...
202Unpacking postgresql-11 (11.22-8.pgdg20.04+1) ...
203Setting up postgresql-client-11 (11.22-8.pgdg20.04+1) ...
204Setting up postgresql-11 (11.22-8.pgdg20.04+1) ...
205Creating new PostgreSQL cluster 11/main ...
206/usr/lib/postgresql/11/bin/initdb -D /var/lib/postgresql/11/main --auth-local peer --auth-host md5
207The files belonging to this database system will be owned by user "postgres".
208This user must also own the server process.
210The database cluster will be initialized with locale "en_US.UTF-8".
211The default database encoding has accordingly been set to "UTF8".
212The default text search configuration will be set to "english".
214Data page checksums are disabled.
216fixing permissions on existing directory /var/lib/postgresql/11/main ... ok
217creating subdirectories ... ok
218selecting default max_connections ... 100
219selecting default shared_buffers ... 128MB
220selecting default timezone ... UTC
221selecting dynamic shared memory implementation ... posix
222creating configuration files ... ok
223running bootstrap script ... ok
224performing post-bootstrap initialization ... ok
225syncing data to disk ... ok
227Success. You can now start the database server using:
229 pg_ctlcluster 11 main start
231Processing triggers for postgresql-common (262.pgdg20.04+1) ...
232Building PostgreSQL dictionaries from installed myspell/hunspell packages...
233Removing obsolete dictionary files:
2343.01s
services
postgresql
2352.79s$ travis_setup_postgresql 11
236Starting PostgreSQL v11
237sudo systemctl start postgresql@11-main
git.checkout
2390.01s0.52s$ git clone --depth=50 https://github.com/travis-ci/travis-migrations.git travis-ci/travis-migrations
240Cloning into 'travis-ci/travis-migrations'...
241$ cd travis-ci/travis-migrations
2420.31s$ git fetch origin +refs/pull/300/merge: --depth=50
243From https://github.com/travis-ci/travis-migrations
244 * branch refs/pull/300/merge -> FETCH_HEAD
245$ git checkout -qf FETCH_HEAD
2470.00s
248Setting environment variables from repository settings
249$ export QUAY_ROBOT_HANDLE=[secure]
250$ export QUAY_ROBOT_TOKEN=[secure]
251$ export ARTIFACTS_BUCKET=travis-migrations-structure-dumps
252$ export ARTIFACTS_SECRET=[secure]
253$ export ARTIFACTS_KEY=[secure]
rvm
2553.03s$ rvm get head
256Downloading https://get.rvm.io
257Downloading https://raw.githubusercontent.com/rvm/rvm/master/binscripts/rvm-installer.asc
258Verifying /home/travis/.rvm/archives/rvm-installer.asc
259gpg: Signature made Tue 21 Feb 2023 11:35:16 PM UTC
260gpg: using RSA key 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
261gpg: Good signature from "Piotr Kuczynski <piotr.kuczynski@gmail.com>" [unknown]
262gpg: WARNING: This key is not certified with a trusted signature!
263gpg: There is no indication that the signature belongs to the owner.
264Primary key fingerprint: 7D2B AF1C F37B 13E2 069D 6956 105B D0E7 3949 9BDB
265GPG verified '/home/travis/.rvm/archives/rvm-installer'
266Downloading https://github.com/rvm/rvm/archive/master.tar.gz
267Upgrading the RVM installation in /home/travis/.rvm/
268 RVM PATH line found in /home/travis/.mkshrc /home/travis/.profile /home/travis/.zshrc.
269 RVM PATH line not found for Bash, rerun this command with '--auto-dotfiles' flag to fix it.
270 RVM sourcing line found in /home/travis/.profile /home/travis/.bashrc /home/travis/.zlogin.
271Upgrade of RVM in /home/travis/.rvm/ is complete.
273<warn>Thanks for installing RVM 🙏</warn>
274Please consider donating to our open collective to help us maintain RVM.
276👉 Donate: <code>https://opencollective.com/rvm/donate</code>
279RVM reloaded!
28019.86s$ rvm use 3.2.2 --install --binary --fuzzy
281curl: (22) The requested URL returned error: 404
282Required ruby-3.2.2 is not installed - installing.
283curl: (22) The requested URL returned error: 404
284Searching for binary rubies, this might take some time.
285Found remote file https://rubies.travis-ci.org/ubuntu/20.04/x86_64/ruby-3.2.2.tar.bz2
286Checking requirements for ubuntu.
287Requirements installation successful.
288ruby-3.2.2 - #configure
289ruby-3.2.2 - #download
290 % Total % Received % Xferd Average Speed Time Time Time Current
291 Dload Upload Total Spent Left Speed
292 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
293100 32.0M 100 32.0M 0 0 20.9M 0 0:00:01 0:00:01 --:--:-- 113M
294No checksum for downloaded archive, recording checksum in user configuration.
295ruby-3.2.2 - #validate archive
296ruby-3.2.2 - #extract
297ruby-3.2.2 - #validate binary
298ruby-3.2.2 - #setup
299ruby-3.2.2 - #gemset created /home/travis/.rvm/gems/ruby-3.2.2@global
300ruby-3.2.2 - #importing gemset /home/travis/.rvm/gemsets/global.gems..................................
301ruby-3.2.2 - #generating global wrappers........
302ruby-3.2.2 - #uninstalling gem rubygems-bundler-1.4.5.
303ruby-3.2.2 - #gemset created /home/travis/.rvm/gems/ruby-3.2.2
304ruby-3.2.2 - #importing gemset /home/travis/.rvm/gemsets/default.gems..............
305ruby-3.2.2 - #generating default wrappers........
306Using /home/travis/.rvm/gems/ruby-3.2.2
308$ export BUNDLE_GEMFILE=$PWD/Gemfile
cache.1
309Setting up build cache
310$ export CASHER_DIR=${TRAVIS_HOME}/.casher
3110.18s$ Installing caching utilities
3120.00s1.83sattempting to download cache archive
313fetching PR.300/cache--linux-focal-e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855--rvm-3.2.2--gemfile-Gemfile.tgz
314fetching PR.300/cache-linux-focal-e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855--rvm-3.2.2--gemfile-Gemfile.tgz
315fetching PR.300/cache--rvm-3.2.2--gemfile-Gemfile.tgz
316fetching master/cache--linux-focal-e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855--rvm-3.2.2--gemfile-Gemfile.tgz
317found cache
3180.00s2.05sadding /home/travis/build/travis-ci/travis-migrations/vendor/bundle to cache
319creating directory /home/travis/build/travis-ci/travis-migrations/vendor/bundle
ruby.versions
322$ ruby --version
323ruby 3.2.2 (2023-03-30 revision e51014f9c0) [x86_64-linux]
324$ rvm --version
325rvm 1.29.12-next (master) by Michal Papis, Piotr Kuczynski, Wayne E. Seguin [https://rvm.io]
326$ bundle --version
327Bundler version 2.4.10
328$ gem --version
3293.4.10
before_install.1
3314.22s$ gem update --system
332Updating rubygems-update
333Successfully installed rubygems-update-3.6.2
334Installing RubyGems 3.6.2
335 Successfully built RubyGem
336 Name: bundler
337 Version: 2.6.2
338 File: bundler-2.6.2.gem
339Bundler 2.6.2 installed
340RubyGems 3.6.2 installed
341Regenerating binstubs
342Regenerating plugins
344# 3.6.2 / 2024-12-23
346## Security:
348* Fix Gem::SafeMarshal buffer overrun when given lengths larger than fit
349 into a byte. Pull request
350 [#8305](https://github.com/rubygems/rubygems/pull/8305) by segiddins
351* Improve type checking in marshal_load methods. Pull request
352 [#8306](https://github.com/rubygems/rubygems/pull/8306) by segiddins
354## Enhancements:
356* Skip rdoc hooks and their tests on newer rdoc versions. Pull request
357 [#8340](https://github.com/rubygems/rubygems/pull/8340) by
358 deivid-rodriguez
359* Installs bundler 2.6.2 as a default gem.
361## Bug fixes:
363* Fix serialized metadata including an empty `@original_platform`
364 attribute. Pull request
365 [#8355](https://github.com/rubygems/rubygems/pull/8355) by
366 deivid-rodriguez
368# 3.6.1 / 2024-12-17
370## Enhancements:
372* Installs bundler 2.6.1 as a default gem.
374## Bug fixes:
376* Fix `gem info` tagging some non default gems as default. Pull request
377 [#8321](https://github.com/rubygems/rubygems/pull/8321) by
378 deivid-rodriguez
380## Documentation:
382* Fix broken links. Pull request
383 [#8327](https://github.com/rubygems/rubygems/pull/8327) by st0012
385# 3.6.0 / 2024-12-16
387## Security:
389* Stop storing executable names in ivars. Pull request
390 [#8307](https://github.com/rubygems/rubygems/pull/8307) by segiddins
392## Breaking changes:
394* Drop ruby 3.0 support. Pull request
395 [#8091](https://github.com/rubygems/rubygems/pull/8091) by segiddins
397## Features:
399* Add --attestation option to gem push. Pull request
400 [#8239](https://github.com/rubygems/rubygems/pull/8239) by segiddins
402## Enhancements:
404* Skip unresolved deps warning on `Gem::Specification.reset` on benign
405 cases. Pull request
406 [#8309](https://github.com/rubygems/rubygems/pull/8309) by
407 deivid-rodriguez
408* Let `gem install <name>` suggest `<name>-ruby` and `ruby-<name>` when
409 providing "did you mean" suggestions. Pull request
410 [#8197](https://github.com/rubygems/rubygems/pull/8197) by duckinator
411* Update SPDX license list as of 2024-08-19. Pull request
412 [#8233](https://github.com/rubygems/rubygems/pull/8233) by
413 github-actions[bot]
414* Add `--target-rbconfig` option to `gem install` and `gem update`
415 commands. Pull request
416 [#7628](https://github.com/rubygems/rubygems/pull/7628) by kateinoigakukun
417* Skip nil-value keys to make metadata reproducible. Pull request
418 [#7129](https://github.com/rubygems/rubygems/pull/7129) by nobu
419* Allow disabling installation of compiled extensions into lib through
420 `Gem.configuration.install_extension_in_lib`. Pull request
421 [#6463](https://github.com/rubygems/rubygems/pull/6463) by hsbt
422* Installs bundler 2.6.0 as a default gem.
424## Bug fixes:
426* Set $0 to exe when running `gem exec` to fix name in CLI output. Pull
427 request [#8267](https://github.com/rubygems/rubygems/pull/8267) by adam12
428* Fix manifest in gem package using incorrect platform sometimes. Pull
429 request [#8202](https://github.com/rubygems/rubygems/pull/8202) by
430 deivid-rodriguez
432## Documentation:
434* Fix missing single quote in git source example. Pull request
435 [#8303](https://github.com/rubygems/rubygems/pull/8303) by nobu
436* Update the `gem install` demo in REAME to use a gem that just works on
437 Windows. Pull request
438 [#8262](https://github.com/rubygems/rubygems/pull/8262) by soda92
439* Unify rubygems and bundler docs directory. Pull request
440 [#8159](https://github.com/rubygems/rubygems/pull/8159) by hsbt
442# 3.5.23 / 2024-11-05
444## Enhancements:
446* Validate user input encoding of `gem` CLI arguments. Pull request
447 [#6471](https://github.com/rubygems/rubygems/pull/6471) by
448 deivid-rodriguez
449* Fix `gem update --system` leaving old default bundler executables
450 around. Pull request
451 [#8172](https://github.com/rubygems/rubygems/pull/8172) by
452 deivid-rodriguez
453* Installs bundler 2.5.23 as a default gem.
455## Bug fixes:
457* Fix commands with 2 MFA requests when webauthn is enabled. Pull request
458 [#8174](https://github.com/rubygems/rubygems/pull/8174) by
459 deivid-rodriguez
460* Make `--enable-load-relative` binstubs prolog work when Ruby is not
461 installed in the same directory as the binstub. Pull request
462 [#7872](https://github.com/rubygems/rubygems/pull/7872) by
463 deivid-rodriguez
465## Performance:
467* Speed up `gem install <nonexistent-gem>` by finding alternative name
468 suggestions faster. Pull request
469 [#8084](https://github.com/rubygems/rubygems/pull/8084) by duckinator
471## Documentation:
473* Add missing comma in documentation. Pull request
474 [#8152](https://github.com/rubygems/rubygems/pull/8152) by leoarnold
476# 3.5.22 / 2024-10-16
478## Enhancements:
480* Prevent `._*` files in packages generated from macOS. Pull request
481 [#8150](https://github.com/rubygems/rubygems/pull/8150) by
482 deivid-rodriguez
483* Fix `gem pristine etc` resetting gem twice sometimes. Pull request
484 [#8117](https://github.com/rubygems/rubygems/pull/8117) by
485 deivid-rodriguez
486* Allow `gem pristine` to reset default gems too. Pull request
487 [#8118](https://github.com/rubygems/rubygems/pull/8118) by
488 deivid-rodriguez
489* Update vendored `uri` and `net-http`. Pull request
490 [#8112](https://github.com/rubygems/rubygems/pull/8112) by segiddins
491* Installs bundler 2.5.22 as a default gem.
493## Bug fixes:
495* Fix `gem contents` for default gems. Pull request
496 [#8132](https://github.com/rubygems/rubygems/pull/8132) by
497 deivid-rodriguez
498* Fix duplicated specs when they have been previously activated. Pull
499 request [#8131](https://github.com/rubygems/rubygems/pull/8131) by
500 deivid-rodriguez
501* Fix `gem install` on NFS shares. Pull request
502 [#8123](https://github.com/rubygems/rubygems/pull/8123) by
503 deivid-rodriguez
504* Fix a `gem install` crash during "done installing" hooks. Pull request
505 [#8113](https://github.com/rubygems/rubygems/pull/8113) by
506 deivid-rodriguez
507* Fix plugin command loading. Pull request
508 [#8121](https://github.com/rubygems/rubygems/pull/8121) by
509 deivid-rodriguez
511# 3.5.21 / 2024-10-03
513## Enhancements:
515* Fix `Gem::MissingSpecVersionError#to_s` not showing exception message.
516 Pull request [#8074](https://github.com/rubygems/rubygems/pull/8074) by
517 deivid-rodriguez
518* Remove code that makes suggest_gems_from_name give worse results. Pull
519 request [#8083](https://github.com/rubygems/rubygems/pull/8083) by
520 duckinator
521* Warning about PATH in `--user-install` mode is only necessary for gems
522 with executables. Pull request
523 [#8071](https://github.com/rubygems/rubygems/pull/8071) by
524 deivid-rodriguez
525* Installs bundler 2.5.21 as a default gem.
527## Bug fixes:
529* Fix error in one source when fetching dependency APIs clearing results
530 from all sources. Pull request
531 [#8080](https://github.com/rubygems/rubygems/pull/8080) by
532 deivid-rodriguez
533* Fix `gem cleanup` warning when two versions of psych installed. Pull
534 request [#8072](https://github.com/rubygems/rubygems/pull/8072) by
535 deivid-rodriguez
537# 3.5.20 / 2024-09-24
539## Enhancements:
541* Installs bundler 2.5.20 as a default gem.
543# 3.5.19 / 2024-09-18
545## Enhancements:
547* Standardize pretty-print output for `Gem::Source` and subclasses. Pull
548 request [#7994](https://github.com/rubygems/rubygems/pull/7994) by
549 djberube
550* Update vendored `molinillo` to master and vendored `resolv` to 0.4.0.
551 Pull request [#7521](https://github.com/rubygems/rubygems/pull/7521) by
552 hsbt
553* Installs bundler 2.5.19 as a default gem.
555## Bug fixes:
557* Fix `bundle exec rake install` failing when local gem has extensions.
558 Pull request [#7977](https://github.com/rubygems/rubygems/pull/7977) by
559 deivid-rodriguez
560* Make `gem exec` use the standard GEM_HOME. Pull request
561 [#7982](https://github.com/rubygems/rubygems/pull/7982) by
562 deivid-rodriguez
563* Fix `gem fetch` always exiting with zero status code. Pull request
564 [#8007](https://github.com/rubygems/rubygems/pull/8007) by
565 deivid-rodriguez
566* Remove temporary `.lock` files unintentionally left around by gem
567 installer. Pull request
568 [#7939](https://github.com/rubygems/rubygems/pull/7939) by nobu
569* Removed unused stringio. Pull request
570 [#8001](https://github.com/rubygems/rubygems/pull/8001) by hsbt
571* Avoid another race condition of open mode. Pull request
572 [#7931](https://github.com/rubygems/rubygems/pull/7931) by nobu
573* Fix `@license` typo preventing licenses from being correctly
574 unmarshalled. Pull request
575 [#7975](https://github.com/rubygems/rubygems/pull/7975) by djberube
577## Performance:
579* Fix `gem install does-not-exist` being super slow. Pull request
580 [#8006](https://github.com/rubygems/rubygems/pull/8006) by
581 deivid-rodriguez
583# 3.5.18 / 2024-08-26
585## Enhancements:
587* Installs bundler 2.5.18 as a default gem.
589## Bug fixes:
591* Fix `gem uninstall <name>:<version>` failing on shadowed default gems.
592 Pull request [#7949](https://github.com/rubygems/rubygems/pull/7949) by
593 deivid-rodriguez
595# 3.5.17 / 2024-08-01
597## Enhancements:
599* Explicitly encode `Gem::Dependency` to yaml. Pull request
600 [#7867](https://github.com/rubygems/rubygems/pull/7867) by segiddins
601* Installs bundler 2.5.17 as a default gem.
603## Bug fixes:
605* Fix `gem list` regression when a regular gem shadows a default one. Pull
606 request [#7892](https://github.com/rubygems/rubygems/pull/7892) by
607 deivid-rodriguez
608* Always leave default gem executables around. Pull request
609 [#7879](https://github.com/rubygems/rubygems/pull/7879) by
610 deivid-rodriguez
611* Fix line comment issue for hash when loading gemrc. Pull request
612 [#7857](https://github.com/rubygems/rubygems/pull/7857) by leetking
614# 3.5.16 / 2024-07-18
616## Enhancements:
618* Installs bundler 2.5.16 as a default gem.
620## Bug fixes:
622* Fix gemspec `require_paths` validation. Pull request
623 [#7866](https://github.com/rubygems/rubygems/pull/7866) by
624 deivid-rodriguez
625* Fix loading of nested `gemrc` config keys when specified as symbols.
626 Pull request [#7851](https://github.com/rubygems/rubygems/pull/7851) by
627 moofkit
629## Performance:
631* Use `caller_locations` instead of splitting `caller`. Pull request
632 [#7708](https://github.com/rubygems/rubygems/pull/7708) by nobu
634# 3.5.15 / 2024-07-09
636## Enhancements:
638* Installs bundler 2.5.15 as a default gem.
640## Bug fixes:
642* Restrict generic `arm` to only match 32-bit arm. Pull request
643 [#7830](https://github.com/rubygems/rubygems/pull/7830) by ntkme
644* Protect creating binstubs with a file lock. Pull request
645 [#7806](https://github.com/rubygems/rubygems/pull/7806) by
646 deivid-rodriguez
648## Documentation:
650* Make it clearer that `add_dependency` is the main way to add
651 non-development dependencies. Pull request
652 [#7800](https://github.com/rubygems/rubygems/pull/7800) by jeromedalbert
654# 3.5.14 / 2024-06-21
656## Enhancements:
658* Installs bundler 2.5.14 as a default gem.
660## Bug fixes:
662* Make "bundler? update --bundler" behave identically. Pull request
663 [#7778](https://github.com/rubygems/rubygems/pull/7778) by x-yuri
665# 3.5.13 / 2024-06-14
667## Enhancements:
669* Installs bundler 2.5.13 as a default gem.
671## Bug fixes:
673* Never remove executables that may belong to a default gem. Pull request
674 [#7747](https://github.com/rubygems/rubygems/pull/7747) by
675 deivid-rodriguez
677# 3.5.12 / 2024-06-13
679## Enhancements:
681* Installs bundler 2.5.12 as a default gem.
683## Bug fixes:
685* Fix `gem uninstall` unresolved specifications warning. Pull request
686 [#7667](https://github.com/rubygems/rubygems/pull/7667) by
687 deivid-rodriguez
688* Fix `gem pristine` sometimes failing to pristine user installed gems.
689 Pull request [#7664](https://github.com/rubygems/rubygems/pull/7664) by
690 deivid-rodriguez
692# 3.5.11 / 2024-05-28
694## Enhancements:
696* Update SPDX license list as of 2024-05-22. Pull request
697 [#7689](https://github.com/rubygems/rubygems/pull/7689) by
698 github-actions[bot]
699* Fix the update_rubygems inconsistency (--disable-gems). Pull request
700 [#7658](https://github.com/rubygems/rubygems/pull/7658) by x-yuri
701* Accept WASI as an OS name in Gem::Platform. Pull request
702 [#7629](https://github.com/rubygems/rubygems/pull/7629) by kateinoigakukun
703* Warn if RubyGems version explicitly set in gemspec does not match
704 running version. Pull request
705 [#7460](https://github.com/rubygems/rubygems/pull/7460) by
706 deivid-rodriguez
707* Installs bundler 2.5.11 as a default gem.
709## Bug fixes:
711* Fix binstubs sometimes not getting regenerated when `--destdir` is
712 given. Pull request
713 [#7660](https://github.com/rubygems/rubygems/pull/7660) by
714 deivid-rodriguez
715* Fix `gem uninstall --user-install` for symlinked HOME. Pull request
716 [#7645](https://github.com/rubygems/rubygems/pull/7645) by
717 deivid-rodriguez
718* Fix issue when plugin stubs would sometimes not be properly removed by
719 `gem uninstall`. Pull request
720 [#7631](https://github.com/rubygems/rubygems/pull/7631) by
721 deivid-rodriguez
722* Fix plugins uninstallation for user installed gems. Pull request
723 [#6456](https://github.com/rubygems/rubygems/pull/6456) by voxik
725## Performance:
727* Use a constant empty tar header to avoid extra allocations. Pull request
728 [#7484](https://github.com/rubygems/rubygems/pull/7484) by segiddins
730## Documentation:
732* Recommend `bin/rake` over `rake` in contributing docs. Pull request
733 [#7648](https://github.com/rubygems/rubygems/pull/7648) by
734 deivid-rodriguez
736# 3.5.10 / 2024-05-03
738## Security:
740* Add a limit to the size of the metadata and checksums files in a gem
741 package. Pull request
742 [#7568](https://github.com/rubygems/rubygems/pull/7568) by segiddins
744## Enhancements:
746* Don't fully require `rubygems` from `rubygems/package` to prevent some
747 circular require warnings when using Bundler. Pull request
748 [#7612](https://github.com/rubygems/rubygems/pull/7612) by
749 deivid-rodriguez
750* Installs bundler 2.5.10 as a default gem.
752## Bug fixes:
754* Rename credential email to identifier in WebAuthn poller. Pull request
755 [#7623](https://github.com/rubygems/rubygems/pull/7623) by jenshenny
757# 3.5.9 / 2024-04-12
759## Enhancements:
761* Installs bundler 2.5.9 as a default gem.
763# 3.5.8 / 2024-04-11
765## Security:
767* Respect global umask when writing regular files. Pull request
768 [#7518](https://github.com/rubygems/rubygems/pull/7518) by
769 deivid-rodriguez
771## Enhancements:
773* Allow string keys with gemrc. Pull request
774 [#7543](https://github.com/rubygems/rubygems/pull/7543) by hsbt
775* [Experimental] Add "gem rebuild" command. Pull request
776 [#4913](https://github.com/rubygems/rubygems/pull/4913) by duckinator
777* Installs bundler 2.5.8 as a default gem.
779## Bug fixes:
781* Fix NoMethodError crash when building errors about corrupt package
782 files. Pull request
783 [#7539](https://github.com/rubygems/rubygems/pull/7539) by jez
784* Fix resolver to properly intersect Arrays of `Gem::Resolver::Activation`
785 objects. Pull request
786 [#7537](https://github.com/rubygems/rubygems/pull/7537) by
787 deivid-rodriguez
789# 3.5.7 / 2024-03-22
791## Enhancements:
793* Warn on empty or open required_ruby_version specification attribute.
794 Pull request [#5010](https://github.com/rubygems/rubygems/pull/5010) by
795 simi
796* Control whether YAML aliases are enabled in Gem::SafeYAML.safe_load via
797 attribute. Pull request
798 [#7464](https://github.com/rubygems/rubygems/pull/7464) by segiddins
799* Update SPDX license list as of 2024-02-08. Pull request
800 [#7468](https://github.com/rubygems/rubygems/pull/7468) by
801 github-actions[bot]
802* Installs bundler 2.5.7 as a default gem.
804## Bug fixes:
806* Allow prerelease activation (even if requirement is not explicit about
807 it) when it's the only possibility. Pull request
808 [#7428](https://github.com/rubygems/rubygems/pull/7428) by kimesf
810## Documentation:
812* Fix a typo. Pull request
813 [#7505](https://github.com/rubygems/rubygems/pull/7505) by hsbt
814* Use https instead of http in documentation links. Pull request
815 [#7481](https://github.com/rubygems/rubygems/pull/7481) by hsbt
817# 3.5.6 / 2024-02-06
819## Enhancements:
821* Deep copy requirements in `Gem::Specification` and `Gem::Requirement`.
822 Pull request [#7439](https://github.com/rubygems/rubygems/pull/7439) by
823 flavorjones
824* Change gem login message to clear up that username can be also used.
825 Pull request [#7422](https://github.com/rubygems/rubygems/pull/7422) by
826 VitaliySerov
827* Add metadata for rubygems.org. Pull request
828 [#7435](https://github.com/rubygems/rubygems/pull/7435) by m-nakamura145
829* Improve gem login scope selection. Pull request
830 [#7342](https://github.com/rubygems/rubygems/pull/7342) by williantenfen
831* Vendor uri in RubyGems. Pull request
832 [#7386](https://github.com/rubygems/rubygems/pull/7386) by
833 deivid-rodriguez
834* Installs bundler 2.5.6 as a default gem.
836## Bug fixes:
838* Skip to load commented out words. Pull request
839 [#7413](https://github.com/rubygems/rubygems/pull/7413) by hsbt
840* Fix rake runtime dependency warning for rake based extension. Pull
841 request [#7395](https://github.com/rubygems/rubygems/pull/7395) by ntkme
843# 3.5.5 / 2024-01-18
845## Enhancements:
847* Installs bundler 2.5.5 as a default gem.
849## Bug fixes:
851* Fix `require` activation conflicts when requiring default gems under
852 some situations. Pull request
853 [#7379](https://github.com/rubygems/rubygems/pull/7379) by
854 deivid-rodriguez
855* Use cache_home instead of data_home in default_spec_cache_dir. Pull
856 request [#7331](https://github.com/rubygems/rubygems/pull/7331) by mrkn
858## Documentation:
860* Use squiggly heredocs in `Gem::Specification#description` documentation,
861 so it doesn't add leading whitespace. Pull request
862 [#7373](https://github.com/rubygems/rubygems/pull/7373) by bravehager
864# 3.5.4 / 2024-01-04
866## Enhancements:
868* Always avoid "Updating rubygems-update" message. Pull request
869 [#7335](https://github.com/rubygems/rubygems/pull/7335) by
870 deivid-rodriguez
871* Installs bundler 2.5.4 as a default gem.
873## Bug fixes:
875* Make `gem update --system` respect ruby version constraints. Pull
876 request [#7334](https://github.com/rubygems/rubygems/pull/7334) by
877 deivid-rodriguez
879# 3.5.3 / 2023-12-22
881## Enhancements:
883* Installs bundler 2.5.3 as a default gem.
885# 3.5.2 / 2023-12-21
887## Enhancements:
889* Support dynamic library loading with extension .so or .o. Pull request
890 [#7241](https://github.com/rubygems/rubygems/pull/7241) by hogelog
891* Installs bundler 2.5.2 as a default gem.
893## Performance:
895* Replace `object_id` comparison with identity Hash. Pull request
896 [#7303](https://github.com/rubygems/rubygems/pull/7303) by amomchilov
897* Use IO.copy_stream when reading, writing. Pull request
898 [#6958](https://github.com/rubygems/rubygems/pull/6958) by martinemde
900# 3.5.1 / 2023-12-15
902## Enhancements:
904* Installs bundler 2.5.1 as a default gem.
906# 3.5.0 / 2023-12-15
908## Security:
910* Replace `Marshal.load` with a fully-checked safe gemspec loader. Pull
911 request [#6896](https://github.com/rubygems/rubygems/pull/6896) by
912 segiddins
914## Breaking changes:
916* Drop ruby 2.6 and 2.7 support. Pull request
917 [#7116](https://github.com/rubygems/rubygems/pull/7116) by
918 deivid-rodriguez
919* Release package no longer includes test files. Pull request
920 [#6781](https://github.com/rubygems/rubygems/pull/6781) by hsbt
921* Hide `Gem::MockGemUi` from users. Pull request
922 [#6623](https://github.com/rubygems/rubygems/pull/6623) by hsbt
923* Deprecated `Gem.datadir` has been removed. Pull request
924 [#6469](https://github.com/rubygems/rubygems/pull/6469) by hsbt
926## Deprecations:
928* Deprecate `Gem::Platform.match?`. Pull request
929 [#6783](https://github.com/rubygems/rubygems/pull/6783) by hsbt
930* Deprecate `Gem::List`. Pull request
931 [#6311](https://github.com/rubygems/rubygems/pull/6311) by segiddins
933## Features:
935* The `generate_index` command can now generate compact index files and
936 lives as an external `rubygems-generate_index` gem. Pull request
937 [#7085](https://github.com/rubygems/rubygems/pull/7085) by segiddins
938* Make `gem install` fallback to user installation directory if default
939 gem home is not writable. Pull request
940 [#5327](https://github.com/rubygems/rubygems/pull/5327) by duckinator
941* Leverage ruby feature to warn when requiring default gems from stdlib
942 that will be turned into bundled gems in the future. Pull request
943 [#6840](https://github.com/rubygems/rubygems/pull/6840) by hsbt
945## Performance:
947* Use match? when regexp match data is unused. Pull request
948 [#7263](https://github.com/rubygems/rubygems/pull/7263) by segiddins
949* Fewer allocations in gem installation. Pull request
950 [#6975](https://github.com/rubygems/rubygems/pull/6975) by segiddins
951* Optimize allocations in `Gem::Version`. Pull request
952 [#6970](https://github.com/rubygems/rubygems/pull/6970) by segiddins
954## Enhancements:
956* Warn for duplicate meta data links when building gems. Pull request
957 [#7213](https://github.com/rubygems/rubygems/pull/7213) by etherbob
958* Vendor `net-http`, `net-protocol`, `resolv`, and `timeout` to reduce
959 conflicts between Gemfile gems and internal dependencies. Pull request
960 [#6793](https://github.com/rubygems/rubygems/pull/6793) by
961 deivid-rodriguez
962* Remove non-transparent requirement added to prerelease gems. Pull
963 request [#7226](https://github.com/rubygems/rubygems/pull/7226) by
964 deivid-rodriguez
965* Stream output from ext builds when --verbose. Pull request
966 [#7240](https://github.com/rubygems/rubygems/pull/7240) by osyoyu
967* Add missing services to CI detection and make it consistent between
968 RubyGems and Bundler. Pull request
969 [#7205](https://github.com/rubygems/rubygems/pull/7205) by nevinera
970* Update generate licenses template to not freeze regexps. Pull request
971 [#7154](https://github.com/rubygems/rubygems/pull/7154) by
972 github-actions[bot]
973* Don't check `LIBRUBY_RELATIVE` in truffleruby to signal a bash prelude
974 in rubygems binstubs. Pull request
975 [#7156](https://github.com/rubygems/rubygems/pull/7156) by
976 deivid-rodriguez
977* Update SPDX list and warn on deprecated identifiers. Pull request
978 [#6926](https://github.com/rubygems/rubygems/pull/6926) by simi
979* Simplify extended `require` to potentially fix some deadlocks. Pull
980 request [#6827](https://github.com/rubygems/rubygems/pull/6827) by nobu
981* Small refactors for `Gem::Resolver`. Pull request
982 [#6766](https://github.com/rubygems/rubygems/pull/6766) by hsbt
983* Use double-quotes instead of single-quotes consistently in warnings.
984 Pull request [#6550](https://github.com/rubygems/rubygems/pull/6550) by
985 hsbt
986* Add debug message for `nil` version gemspec. Pull request
987 [#6436](https://github.com/rubygems/rubygems/pull/6436) by hsbt
988* Installs bundler 2.5.0 as a default gem.
990## Bug fixes:
992* Fix installing from source with same default bundler version already
993 installed. Pull request
994 [#7244](https://github.com/rubygems/rubygems/pull/7244) by
995 deivid-rodriguez
997## Documentation:
999* Improve comment explaining the necessity of `write_default_spec` method.
1000 Pull request [#6563](https://github.com/rubygems/rubygems/pull/6563) by
1001 voxik
1003# 3.4.22 / 2023-11-09
1005## Enhancements:
1007* Update SPDX license list as of 2023-10-05. Pull request
1008 [#7040](https://github.com/rubygems/rubygems/pull/7040) by
1009 github-actions[bot]
1010* Remove unnecessary rescue. Pull request
1011 [#7109](https://github.com/rubygems/rubygems/pull/7109) by
1012 deivid-rodriguez
1013* Installs bundler 2.4.22 as a default gem.
1015## Bug fixes:
1017* Handle empty array at built-in YAML serializer. Pull request
1018 [#7099](https://github.com/rubygems/rubygems/pull/7099) by hsbt
1019* Ignore non-tar format `.gem` files during search. Pull request
1020 [#7095](https://github.com/rubygems/rubygems/pull/7095) by dearblue
1021* Allow explicitly uninstalling multiple versions of same gem. Pull
1022 request [#7063](https://github.com/rubygems/rubygems/pull/7063) by
1023 kstevens715
1025## Performance:
1027* Avoid regexp match on every call to `Gem::Platform.local`. Pull request
1028 [#7104](https://github.com/rubygems/rubygems/pull/7104) by segiddins
1030## Documentation:
1032* Get `Gem::Specification#extensions_dir` documented. Pull request
1033 [#6218](https://github.com/rubygems/rubygems/pull/6218) by
1034 deivid-rodriguez
1036# 3.4.21 / 2023-10-17
1038## Enhancements:
1040* Abort `setup.rb` if Ruby is too old. Pull request
1041 [#7011](https://github.com/rubygems/rubygems/pull/7011) by
1042 deivid-rodriguez
1043* Remove usage of Dir.chdir that only execute a subprocess. Pull request
1044 [#6930](https://github.com/rubygems/rubygems/pull/6930) by segiddins
1045* Freeze more strings in generated gemspecs. Pull request
1046 [#6974](https://github.com/rubygems/rubygems/pull/6974) by segiddins
1047* Use pure-ruby YAML parser for loading configuration at RubyGems. Pull
1048 request [#6615](https://github.com/rubygems/rubygems/pull/6615) by hsbt
1049* Installs bundler 2.4.21 as a default gem.
1051## Documentation:
1053* Update suggested variable for bindir. Pull request
1054 [#7028](https://github.com/rubygems/rubygems/pull/7028) by hsbt
1055* Fix invalid links in documentation. Pull request
1056 [#7008](https://github.com/rubygems/rubygems/pull/7008) by simi
1058# 3.4.20 / 2023-09-27
1060## Enhancements:
1062* Raise `Gem::Package::FormatError` when gem encounters corrupt EOF.
1063 Pull request [#6882](https://github.com/rubygems/rubygems/pull/6882)
1064 by martinemde
1065* Allow skipping empty license `gem build` warning by setting license to
1066 `nil`. Pull request
1067 [#6879](https://github.com/rubygems/rubygems/pull/6879) by jhong97
1068* Update SPDX license list as of 2023-06-18. Pull request
1069 [#6891](https://github.com/rubygems/rubygems/pull/6891) by
1070 github-actions[bot]
1071* Update SPDX license list as of 2023-04-28. Pull request
1072 [#6642](https://github.com/rubygems/rubygems/pull/6642) by segiddins
1073* Update SPDX license list as of 2023-01-26. Pull request
1074 [#6310](https://github.com/rubygems/rubygems/pull/6310) by segiddins
1075* Installs bundler 2.4.20 as a default gem.
1077## Bug fixes:
1079* Fixed false positive SymlinkError in symbolic link directory. Pull
1080 request [#6947](https://github.com/rubygems/rubygems/pull/6947) by
1081 negi0109
1082* Ensure that loading multiple gemspecs with legacy YAML class references
1083 does not warn. Pull request
1084 [#6889](https://github.com/rubygems/rubygems/pull/6889) by segiddins
1085* Fix NoMethodError when choosing a too big number from `gem uni` list.
1086 Pull request [#6901](https://github.com/rubygems/rubygems/pull/6901) by
1087 amatsuda
1089## Performance:
1091* Reduce allocations for stub specifications. Pull request
1092 [#6972](https://github.com/rubygems/rubygems/pull/6972) by segiddins
1094# 3.4.19 / 2023-08-17
1096## Enhancements:
1098* Installs bundler 2.4.19 as a default gem.
1100## Performance:
1102* Speedup building docs when updating rubygems. Pull request
1103 [#6864](https://github.com/rubygems/rubygems/pull/6864) by
1104 deivid-rodriguez
1106# 3.4.18 / 2023-08-02
1108## Enhancements:
1110* Add poller to fetch WebAuthn OTP. Pull request
1111 [#6774](https://github.com/rubygems/rubygems/pull/6774) by jenshenny
1112* Remove side effects when unmarshaling old `Gem::Specification`. Pull
1113 request [#6825](https://github.com/rubygems/rubygems/pull/6825) by nobu
1114* Ship rubygems executables in `exe` folder. Pull request
1115 [#6704](https://github.com/rubygems/rubygems/pull/6704) by hsbt
1116* Installs bundler 2.4.18 as a default gem.
1118# 3.4.17 / 2023-07-14
1120## Enhancements:
1122* Installs bundler 2.4.17 as a default gem.
1124## Performance:
1126* Avoid unnecessary work for private local gem installation. Pull request
1127 [#6810](https://github.com/rubygems/rubygems/pull/6810) by
1128 deivid-rodriguez
1130# 3.4.16 / 2023-07-10
1132## Enhancements:
1134* Installs bundler 2.4.16 as a default gem.
1136# 3.4.15 / 2023-06-29
1138## Enhancements:
1140* Installs bundler 2.4.15 as a default gem.
1142## Bug fixes:
1144* Autoload shellwords when it's needed. Pull request
1145 [#6734](https://github.com/rubygems/rubygems/pull/6734) by ioquatix
1147## Documentation:
1149* Update command to test local gem command changes. Pull request
1150 [#6761](https://github.com/rubygems/rubygems/pull/6761) by jenshenny
1152# 3.4.14 / 2023-06-12
1154## Enhancements:
1156* Load plugin immediately. Pull request
1157 [#6673](https://github.com/rubygems/rubygems/pull/6673) by kou
1158* Installs bundler 2.4.14 as a default gem.
1160## Documentation:
1162* Clarify what the `rubygems-update` gem is for, and link to source code
1163 and guides. Pull request
1164 [#6710](https://github.com/rubygems/rubygems/pull/6710) by davetron5000
1166# 3.4.13 / 2023-05-09
1168## Enhancements:
1170* Installs bundler 2.4.13 as a default gem.
1172# 3.4.12 / 2023-04-11
1174## Enhancements:
1176* [Experimental] Add WebAuthn Support to the CLI. Pull request
1177 [#6560](https://github.com/rubygems/rubygems/pull/6560) by jenshenny
1178* Installs bundler 2.4.12 as a default gem.
1180# 3.4.11 / 2023-04-10
1182## Enhancements:
1184* Installs bundler 2.4.11 as a default gem.
1187------------------------------------------------------------------------------
1189RubyGems installed the following executables:
1190 /home/travis/.rvm/rubies/ruby-3.2.2/bin/gem
1191 /home/travis/.rvm/rubies/ruby-3.2.2/bin/bundle
1192 /home/travis/.rvm/rubies/ruby-3.2.2/bin/bundler
1194RubyGems system software updated
before_install.2
11950.02s$ sudo sed -i -e '/local.*peer/s/postgres/all/' -e 's/peer\|md5/trust/g' /etc/postgresql/11/main/pg_hba.conf
before_install.3
11960.02s$ sudo sed -i -e 's/^port = 5433/port = 5432/' /etc/postgresql/11/main/postgresql.conf
before_install.4
11972.42s$ sudo systemctl restart postgresql@11-main
install.bundler
11981.63s$ bundle install --jobs=3 --retry=3 --deployment
1199[DEPRECATED] The `--deployment` flag is deprecated because it relies on being remembered across bundler invocations, which bundler will no longer do in future versions. Instead please use `bundle config set deployment true`, and stop using this flag
1200Bundler 2.6.2 is running, but your lockfile was generated with 2.4.14. Installing Bundler 2.4.14 and restarting using that version.
1201Fetching gem metadata from https://rubygems.org/.
1202Fetching bundler 2.4.14
1203Installing bundler 2.4.14
1204[DEPRECATED] The `--deployment` flag is deprecated because it relies on being remembered across bundler invocations, which bundler will no longer do in future versions. Instead please use `bundle config set --local deployment 'true'`, and stop using this flag
1205Using rake 13.0.6
1206Using concurrent-ruby 1.2.2
1207Using i18n 1.14.1
1208Using minitest 5.18.1
1209Using tzinfo 2.0.6
1210Using activesupport 7.0.6
1211Using builder 3.2.4
1212Using erubi 1.12.0
1213Using racc 1.7.1
1214Using nokogiri 1.15.2 (x86_64-linux)
1215Using rails-dom-testing 2.1.1
1216Using crass 1.0.6
1217Using loofah 2.21.3
1218Using rails-html-sanitizer 1.6.0
1219Using actionview 7.0.6
1220Using rack 2.2.7
1221Using rack-test 2.1.0
1222Using actionpack 7.0.6
1223Using nio4r 2.5.9
1224Using websocket-extensions 0.1.5
1225Using websocket-driver 0.7.5
1226Using actioncable 7.0.6
1227Using globalid 1.1.0
1228Using activejob 7.0.6
1229Using activemodel 7.0.6
1230Using activerecord 7.0.6
1231Using marcel 1.0.2
1232Using mini_mime 1.1.2
1233Using activestorage 7.0.6
1234Using date 3.3.3
1235Using timeout 0.4.0
1236Using net-protocol 0.2.1
1237Using net-imap 0.3.6
1238Using net-pop 0.1.2
1239Using net-smtp 0.3.3
1240Using mail 2.8.1
1241Using actionmailbox 7.0.6
1242Using actionmailer 7.0.6
1243Using actiontext 7.0.6
1244Using ansi 1.5.0
1245Using ast 2.4.2
1246Using aws-eventstream 1.2.0
1247Using aws-partitions 1.783.0
1248Using aws-sigv4 1.6.0
1249Using jmespath 1.6.2
1250Using aws-sdk-core 3.176.1
1251Using aws-sdk-kms 1.68.0
1252Using aws-sdk-s3 1.127.0
1253Using bundler 2.4.14
1254Using colored 1.2
1255Using diff-lcs 1.5.0
1256Using docile 1.4.0
1257Using json 2.6.3
1258Using language_server-protocol 3.17.0.3
1259Using method_source 1.0.0
1260Using parallel 1.23.0
1261Using parser 3.2.2.3
1262Using pg 1.5.3
1263Using thor 1.2.2
1264Using zeitwerk 2.6.8
1265Using railties 7.0.6
1266Using rails 7.0.6
1267Using rainbow 3.1.1
1268Using rake-notes 0.2.2
1269Using regexp_parser 2.8.1
1270Using rexml 3.2.5
1271Using routes 0.2.0
1272Using rspec-support 3.12.1
1273Using rspec-core 3.12.2
1274Using rspec-expectations 3.12.3
1275Using rspec-mocks 3.12.5
1276Using rspec 3.12.0
1277Using rubocop-ast 1.29.0
1278Using ruby-progressbar 1.13.0
1279Using unicode-display_width 2.4.2
1280Using rubocop 1.54.1
1281Using rubocop-capybara 2.18.0
1282Using rubocop-factory_bot 2.23.1
1283Using rubocop-performance 1.18.0
1284Using rubocop-rspec 2.22.0
1285Using simplecov-html 0.12.3
1286Using simplecov_json_formatter 0.1.4
1287Using simplecov 0.22.0
1288Using terminal-table 3.0.2
1289Using simplecov-console 0.9.1
1290Bundle complete! 12 Gemfile dependencies, 85 gems now installed.
1291Bundled gems are installed into `./vendor/bundle`
before_script.1
12930.01s$ psql --version
1294psql (PostgreSQL) 11.22 (Ubuntu 11.22-8.pgdg20.04+1)
before_script.2
12950.25s$ psql -c 'CREATE DATABASE travis_test;'
1296CREATE DATABASE
before_script.3
12971.22s$ curl -fs https://raw.githubusercontent.com/travis-ci/travis-migrations/master/db/main/structure.sql | psql -v ON_ERROR_STOP=1 travis_test
1298SET
1299SET
1300SET
1301SET
1302SET
1303 set_config
1304------------
1306(1 row)
1308SET
1309SET
1310SET
1311SET
1312CREATE EXTENSION
1313COMMENT
1314CREATE EXTENSION
1315COMMENT
1316CREATE TYPE
1317CREATE FUNCTION
1318CREATE FUNCTION
1319CREATE FUNCTION
1320CREATE FUNCTION
1321CREATE FUNCTION
1322CREATE FUNCTION
1323CREATE FUNCTION
1324CREATE FUNCTION
1325CREATE FUNCTION
1326CREATE FUNCTION
1327CREATE FUNCTION
1328CREATE FUNCTION
1329CREATE FUNCTION
1330CREATE FUNCTION
1331CREATE FUNCTION
1332CREATE FUNCTION
1333CREATE FUNCTION
1334CREATE FUNCTION
1335CREATE FUNCTION
1336CREATE FUNCTION
1337CREATE FUNCTION
1338CREATE FUNCTION
1339CREATE FUNCTION
1340CREATE FUNCTION
1341CREATE FUNCTION
1342CREATE FUNCTION
1343CREATE FUNCTION
1344CREATE FUNCTION
1345CREATE FUNCTION
1346CREATE FUNCTION
1347SET
1348CREATE TABLE
1349CREATE SEQUENCE
1350ALTER SEQUENCE
1351CREATE TABLE
1352CREATE TABLE
1353CREATE SEQUENCE
1354ALTER SEQUENCE
1355CREATE TABLE
1356CREATE SEQUENCE
1357ALTER SEQUENCE
1358CREATE TABLE
1359CREATE SEQUENCE
1360ALTER SEQUENCE
1361CREATE TABLE
1362CREATE SEQUENCE
1363ALTER SEQUENCE
1364CREATE TABLE
1365CREATE SEQUENCE
1366ALTER SEQUENCE
1367CREATE TABLE
1368CREATE SEQUENCE
1369ALTER SEQUENCE
1370CREATE TABLE
1371CREATE SEQUENCE
1372ALTER SEQUENCE
1373CREATE SEQUENCE
1374CREATE TABLE
1375CREATE SEQUENCE
1376ALTER SEQUENCE
1377CREATE TABLE
1378CREATE SEQUENCE
1379ALTER SEQUENCE
1380CREATE TABLE
1381CREATE SEQUENCE
1382ALTER SEQUENCE
1383CREATE TABLE
1384CREATE SEQUENCE
1385ALTER SEQUENCE
1386CREATE TABLE
1387CREATE SEQUENCE
1388ALTER SEQUENCE
1389CREATE TABLE
1390CREATE SEQUENCE
1391ALTER SEQUENCE
1392CREATE TABLE
1393CREATE TABLE
1394CREATE TABLE
1395CREATE TABLE
1396CREATE TABLE
1397CREATE TABLE
1398CREATE TABLE
1399CREATE TABLE
1400CREATE TABLE
1401CREATE TABLE
1402CREATE TABLE
1403CREATE TABLE
1404CREATE TABLE
1405CREATE TABLE
1406CREATE TABLE
1407CREATE TABLE
1408CREATE SEQUENCE
1409ALTER SEQUENCE
1410CREATE TABLE
1411CREATE SEQUENCE
1412ALTER SEQUENCE
1413CREATE TABLE
1414CREATE TABLE
1415CREATE SEQUENCE
1416ALTER SEQUENCE
1417CREATE TABLE
1418CREATE SEQUENCE
1419ALTER SEQUENCE
1420CREATE TABLE
1421CREATE SEQUENCE
1422ALTER SEQUENCE
1423CREATE TABLE
1424CREATE SEQUENCE
1425ALTER SEQUENCE
1426CREATE TABLE
1427CREATE SEQUENCE
1428ALTER SEQUENCE
1429CREATE TABLE
1430CREATE SEQUENCE
1431ALTER SEQUENCE
1432CREATE TABLE
1433CREATE SEQUENCE
1434ALTER SEQUENCE
1435CREATE TABLE
1436CREATE SEQUENCE
1437ALTER SEQUENCE
1438CREATE TABLE
1439CREATE SEQUENCE
1440ALTER SEQUENCE
1441CREATE TABLE
1442CREATE SEQUENCE
1443ALTER SEQUENCE
1444CREATE TABLE
1445CREATE SEQUENCE
1446ALTER SEQUENCE
1447CREATE TABLE
1448CREATE SEQUENCE
1449ALTER SEQUENCE
1450CREATE TABLE
1451CREATE SEQUENCE
1452ALTER SEQUENCE
1453CREATE TABLE
1454CREATE SEQUENCE
1455ALTER SEQUENCE
1456CREATE TABLE
1457CREATE SEQUENCE
1458ALTER SEQUENCE
1459CREATE TABLE
1460CREATE TABLE
1461CREATE SEQUENCE
1462ALTER SEQUENCE
1463CREATE TABLE
1464CREATE SEQUENCE
1465ALTER SEQUENCE
1466CREATE TABLE
1467CREATE SEQUENCE
1468ALTER SEQUENCE
1469CREATE TABLE
1470CREATE SEQUENCE
1471ALTER SEQUENCE
1472CREATE TABLE
1473CREATE SEQUENCE
1474ALTER SEQUENCE
1475CREATE TABLE
1476CREATE SEQUENCE
1477ALTER SEQUENCE
1478CREATE TABLE
1479CREATE SEQUENCE
1480ALTER SEQUENCE
1481CREATE TABLE
1482CREATE SEQUENCE
1483ALTER SEQUENCE
1484CREATE TABLE
1485CREATE TABLE
1486CREATE SEQUENCE
1487ALTER SEQUENCE
1488CREATE TABLE
1489CREATE TABLE
1490CREATE SEQUENCE
1491ALTER SEQUENCE
1492CREATE TABLE
1493CREATE SEQUENCE
1494ALTER SEQUENCE
1495CREATE TABLE
1496CREATE SEQUENCE
1497ALTER SEQUENCE
1498CREATE TABLE
1499CREATE SEQUENCE
1500ALTER SEQUENCE
1501CREATE TABLE
1502CREATE SEQUENCE
1503ALTER SEQUENCE
1504CREATE TABLE
1505CREATE SEQUENCE
1506ALTER SEQUENCE
1507CREATE TABLE
1508CREATE SEQUENCE
1509ALTER SEQUENCE
1510CREATE TABLE
1511CREATE SEQUENCE
1512ALTER SEQUENCE
1513CREATE TABLE
1514CREATE SEQUENCE
1515ALTER SEQUENCE
1516CREATE TABLE
1517CREATE SEQUENCE
1518ALTER SEQUENCE
1519CREATE TABLE
1520CREATE SEQUENCE
1521ALTER SEQUENCE
1522CREATE TABLE
1523CREATE SEQUENCE
1524ALTER SEQUENCE
1525CREATE TABLE
1526CREATE SEQUENCE
1527ALTER SEQUENCE
1528CREATE TABLE
1529ALTER TABLE
1530ALTER TABLE
1531ALTER TABLE
1532ALTER TABLE
1533ALTER TABLE
1534ALTER TABLE
1535ALTER TABLE
1536ALTER TABLE
1537ALTER TABLE
1538ALTER TABLE
1539ALTER TABLE
1540ALTER TABLE
1541ALTER TABLE
1542ALTER TABLE
1543ALTER TABLE
1544ALTER TABLE
1545ALTER TABLE
1546ALTER TABLE
1547ALTER TABLE
1548ALTER TABLE
1549ALTER TABLE
1550ALTER TABLE
1551ALTER TABLE
1552ALTER TABLE
1553ALTER TABLE
1554ALTER TABLE
1555ALTER TABLE
1556ALTER TABLE
1557ALTER TABLE
1558ALTER TABLE
1559ALTER TABLE
1560ALTER TABLE
1561ALTER TABLE
1562ALTER TABLE
1563ALTER TABLE
1564ALTER TABLE
1565ALTER TABLE
1566ALTER TABLE
1567ALTER TABLE
1568ALTER TABLE
1569ALTER TABLE
1570ALTER TABLE
1571ALTER TABLE
1572ALTER TABLE
1573ALTER TABLE
1574ALTER TABLE
1575ALTER TABLE
1576ALTER TABLE
1577ALTER TABLE
1578ALTER TABLE
1579ALTER TABLE
1580ALTER TABLE
1581ALTER TABLE
1582ALTER TABLE
1583ALTER TABLE
1584ALTER TABLE
1585ALTER TABLE
1586ALTER TABLE
1587ALTER TABLE
1588ALTER TABLE
1589ALTER TABLE
1590ALTER TABLE
1591ALTER TABLE
1592ALTER TABLE
1593ALTER TABLE
1594ALTER TABLE
1595ALTER TABLE
1596ALTER TABLE
1597ALTER TABLE
1598ALTER TABLE
1599ALTER TABLE
1600ALTER TABLE
1601ALTER TABLE
1602ALTER TABLE
1603ALTER TABLE
1604ALTER TABLE
1605ALTER TABLE
1606ALTER TABLE
1607ALTER TABLE
1608ALTER TABLE
1609ALTER TABLE
1610ALTER TABLE
1611ALTER TABLE
1612ALTER TABLE
1613ALTER TABLE
1614ALTER TABLE
1615ALTER TABLE
1616ALTER TABLE
1617ALTER TABLE
1618ALTER TABLE
1619ALTER TABLE
1620ALTER TABLE
1621ALTER TABLE
1622ALTER TABLE
1623ALTER TABLE
1624ALTER TABLE
1625ALTER TABLE
1626ALTER TABLE
1627ALTER TABLE
1628ALTER TABLE
1629ALTER TABLE
1630ALTER TABLE
1631ALTER TABLE
1632ALTER TABLE
1633ALTER TABLE
1634ALTER TABLE
1635CREATE INDEX
1636CREATE INDEX
1637CREATE INDEX
1638CREATE INDEX
1639CREATE INDEX
1640CREATE INDEX
1641CREATE INDEX
1642CREATE INDEX
1643CREATE INDEX
1644CREATE INDEX
1645CREATE INDEX
1646CREATE INDEX
1647CREATE INDEX
1648CREATE INDEX
1649CREATE INDEX
1650CREATE INDEX
1651CREATE INDEX
1652CREATE INDEX
1653CREATE INDEX
1654CREATE INDEX
1655CREATE INDEX
1656CREATE INDEX
1657CREATE INDEX
1658CREATE INDEX
1659CREATE INDEX
1660CREATE INDEX
1661CREATE INDEX
1662CREATE INDEX
1663CREATE INDEX
1664CREATE INDEX
1665CREATE INDEX
1666CREATE INDEX
1667CREATE INDEX
1668CREATE INDEX
1669CREATE INDEX
1670CREATE INDEX
1671CREATE INDEX
1672CREATE INDEX
1673CREATE INDEX
1674CREATE INDEX
1675CREATE INDEX
1676CREATE INDEX
1677CREATE INDEX
1678CREATE INDEX
1679CREATE INDEX
1680CREATE INDEX
1681CREATE INDEX
1682CREATE INDEX
1683CREATE INDEX
1684CREATE INDEX
1685CREATE INDEX
1686CREATE INDEX
1687CREATE INDEX
1688CREATE INDEX
1689CREATE INDEX
1690CREATE INDEX
1691CREATE INDEX
1692CREATE INDEX
1693CREATE INDEX
1694CREATE INDEX
1695CREATE INDEX
1696CREATE INDEX
1697CREATE INDEX
1698CREATE INDEX
1699CREATE INDEX
1700CREATE INDEX
1701CREATE INDEX
1702CREATE INDEX
1703CREATE INDEX
1704CREATE INDEX
1705CREATE INDEX
1706CREATE INDEX
1707CREATE INDEX
1708CREATE INDEX
1709CREATE INDEX
1710CREATE INDEX
1711CREATE INDEX
1712CREATE INDEX
1713CREATE INDEX
1714CREATE INDEX
1715CREATE INDEX
1716CREATE INDEX
1717CREATE INDEX
1718CREATE INDEX
1719CREATE INDEX
1720CREATE INDEX
1721CREATE INDEX
1722CREATE INDEX
1723CREATE INDEX
1724CREATE INDEX
1725CREATE INDEX
1726CREATE INDEX
1727CREATE INDEX
1728CREATE INDEX
1729CREATE INDEX
1730CREATE INDEX
1731CREATE INDEX
1732CREATE INDEX
1733CREATE INDEX
1734CREATE INDEX
1735CREATE INDEX
1736CREATE INDEX
1737CREATE INDEX
1738CREATE INDEX
1739CREATE INDEX
1740CREATE INDEX
1741CREATE INDEX
1742CREATE INDEX
1743CREATE INDEX
1744CREATE INDEX
1745CREATE INDEX
1746CREATE INDEX
1747CREATE INDEX
1748CREATE INDEX
1749CREATE INDEX
1750CREATE INDEX
1751CREATE INDEX
1752CREATE INDEX
1753CREATE INDEX
1754CREATE INDEX
1755CREATE INDEX
1756CREATE INDEX
1757CREATE INDEX
1758CREATE INDEX
1759CREATE INDEX
1760CREATE INDEX
1761CREATE INDEX
1762CREATE INDEX
1763CREATE INDEX
1764CREATE INDEX
1765CREATE INDEX
1766CREATE INDEX
1767CREATE INDEX
1768CREATE INDEX
1769CREATE INDEX
1770CREATE INDEX
1771CREATE INDEX
1772CREATE INDEX
1773CREATE INDEX
1774CREATE INDEX
1775CREATE INDEX
1776CREATE INDEX
1777CREATE INDEX
1778CREATE INDEX
1779CREATE INDEX
1780CREATE INDEX
1781CREATE INDEX
1782CREATE INDEX
1783CREATE INDEX
1784CREATE INDEX
1785CREATE INDEX
1786CREATE INDEX
1787CREATE INDEX
1788CREATE INDEX
1789CREATE INDEX
1790CREATE INDEX
1791CREATE INDEX
1792CREATE INDEX
1793CREATE INDEX
1794CREATE INDEX
1795CREATE INDEX
1796CREATE INDEX
1797CREATE INDEX
1798CREATE INDEX
1799CREATE INDEX
1800CREATE INDEX
1801CREATE INDEX
1802CREATE INDEX
1803CREATE INDEX
1804CREATE INDEX
1805CREATE INDEX
1806CREATE INDEX
1807CREATE INDEX
1808CREATE INDEX
1809CREATE INDEX
1810CREATE INDEX
1811CREATE INDEX
1812CREATE INDEX
1813CREATE INDEX
1814CREATE INDEX
1815CREATE INDEX
1816CREATE INDEX
1817CREATE INDEX
1818CREATE INDEX
1819CREATE INDEX
1820CREATE INDEX
1821CREATE INDEX
1822CREATE INDEX
1823CREATE INDEX
1824CREATE INDEX
1825CREATE INDEX
1826CREATE INDEX
1827CREATE INDEX
1828CREATE INDEX
1829CREATE INDEX
1830CREATE INDEX
1831CREATE INDEX
1832CREATE INDEX
1833CREATE INDEX
1834CREATE INDEX
1835CREATE INDEX
1836CREATE INDEX
1837CREATE INDEX
1838CREATE INDEX
1839CREATE INDEX
1840CREATE INDEX
1841CREATE INDEX
1842CREATE INDEX
1843CREATE INDEX
1844CREATE INDEX
1845CREATE TRIGGER
1846CREATE TRIGGER
1847CREATE TRIGGER
1848CREATE TRIGGER
1849CREATE TRIGGER
1850CREATE TRIGGER
1851CREATE TRIGGER
1852CREATE TRIGGER
1853CREATE TRIGGER
1854CREATE TRIGGER
1855CREATE TRIGGER
1856CREATE TRIGGER
1857CREATE TRIGGER
1858CREATE TRIGGER
1859CREATE TRIGGER
1860CREATE TRIGGER
1861CREATE TRIGGER
1862ALTER TABLE
1863ALTER TABLE
1864ALTER TABLE
1865ALTER TABLE
1866ALTER TABLE
1867ALTER TABLE
1868ALTER TABLE
1869ALTER TABLE
1870ALTER TABLE
1871ALTER TABLE
1872ALTER TABLE
1873ALTER TABLE
1874ALTER TABLE
1875ALTER TABLE
1876ALTER TABLE
1877ALTER TABLE
1878ALTER TABLE
1879ALTER TABLE
1880ALTER TABLE
1881ALTER TABLE
1882ALTER TABLE
1883ALTER TABLE
1884ALTER TABLE
1885ALTER TABLE
1886ALTER TABLE
1887ALTER TABLE
1888ALTER TABLE
1889ALTER TABLE
1890ALTER TABLE
1891ALTER TABLE
1892ALTER TABLE
1893ALTER TABLE
1894ALTER TABLE
1895SET
1896INSERT 0 394
189742.01s$ bundle exec rspec spec
1899Repo counts
1900 before aggregation
1901 after aggregating per repo
1902 after aggregating all counts
1903 does not raise if repos are missing
1904 does not raise if builds are deleted before stages
1906set_updated_at trigger
1907Dropped database 'travis_test'
1908Created database 'travis_test'
1909== 201207261749 CreatePlans: migrating ========================================
1910-- create_table(:plans, {:id=>:integer})
1911 -> 0.0058s
1912== 201207261749 CreatePlans: migrated (0.0059s) ===============================
1914== 20101126174706 CreateRepositories: migrating ===============================
1915-- create_table(:repositories, {:id=>:integer})
1916 -> 0.0053s
1917== 20101126174706 CreateRepositories: migrated (0.0054s) ======================
1919== 20101126174715 CreateBuilds: migrating =====================================
1920-- create_table(:builds, {:id=>:integer})
1921 -> 0.0056s
1922== 20101126174715 CreateBuilds: migrated (0.0057s) ============================
1924== 20110109130532 DeviseCreateUsers: migrating ================================
1925-- create_table(:users, {:id=>:integer})
1926 -> 0.0048s
1927-- add_index(:users, :login, {:unique=>true})
1928 -> 0.0023s
1929== 20110109130532 DeviseCreateUsers: migrated (0.0072s) =======================
1931== 20110116155100 RepositoriesAddUsername: migrating ==========================
1932-- change_table(:repositories)
1933 -> 0.0007s
1934== 20110116155100 RepositoriesAddUsername: migrated (0.0008s) =================
1936== 20110130102621 CreateTokens: migrating =====================================
1937-- create_table(:tokens, {:id=>:integer})
1938 -> 0.0051s
1939== 20110130102621 CreateTokens: migrated (0.0051s) ============================
1941== 20110301071656 AddBuildParentIdAndConfiguration: migrating =================
1942-- change_table(:builds)
1943 -> 0.0011s
1944-- change_column(:builds, :number, :string)
1945 -> 0.0050s
1946-- add_index(:builds, :repository_id)
1947 -> 0.0021s
1948-- add_index(:builds, :parent_id)
1949 -> 0.0021s
1950== 20110301071656 AddBuildParentIdAndConfiguration: migrated (0.0105s) ========
1952== 20110316174721 RepositoriesDenormalizeLastBuildAttributes: migrating =======
1953-- change_table(:repositories)
1954 -> 0.0024s
1955== 20110316174721 RepositoriesDenormalizeLastBuildAttributes: migrated (0.0024s)
1957== 20110321075539 RepositoriesAddOwnerNameAndOwnerEmail: migrating ============
1958-- change_table(:repositories)
1959 -> 0.0019s
1960-- remove_column(:repositories, :username)
1961 -> 0.0005s
1962== 20110321075539 RepositoriesAddOwnerNameAndOwnerEmail: migrated (0.0025s) ===
1964== 20110411171936 CreateHistoriesTable: migrating =============================
1965-- create_table(:histories, {:id=>:integer})
1966 -> 0.0051s
1967-- add_index(:histories, [:item, :table, :month, :year])
1968 -> 0.0020s
1969== 20110411171936 CreateHistoriesTable: migrated (0.0072s) ====================
1971== 20110411171937 RenameHistoriesToRailsAdminHistories: migrating =============
1972-- remove_index(:histories, nil, {:name=>:index_histories_on_item_and_table_and_month_and_year})
1973 -> 0.0004s
1974-- rename_table(:histories, :rails_admin_histories)
1975 -> 0.0032s
1976-- add_index("rails_admin_histories", ["item", "table", "month", "year"], {:name=>"index_histories_on_item_and_table_and_month_and_year"})
1977 -> 0.0022s
1978== 20110411171937 RenameHistoriesToRailsAdminHistories: migrated (0.0071s) ====
1980== 20110411172518 AddAdminFlagToUser: migrating ===============================
1981-- change_table(:users)
1982 -> 0.0011s
1983== 20110411172518 AddAdminFlagToUser: migrated (0.0011s) ======================
1985== 20110413101057 BuildsAddRef: migrating =====================================
1986-- change_table(:builds)
1987 -> 0.0011s
1988== 20110413101057 BuildsAddRef: migrated (0.0011s) ============================
1990== 20110414131100 BuildsAddGithubPayload: migrating ===========================
1991-- change_table(:builds)
1992 -> 0.0007s
1993== 20110414131100 BuildsAddGithubPayload: migrated (0.0007s) ==================
1995== 20110503150504 AddGithubIdToUsersTable: migrating ==========================
1996-- add_column(:users, :github_id, :integer)
1997 -> 0.0006s
1998-- add_index(:users, :github_id)
1999 -> 0.0021s
2000== 20110503150504 AddGithubIdToUsersTable: migrated (0.0028s) =================
2002== 20110523012243 RepositoriesChangeOwnerEmailType: migrating =================
2003-- change_column(:repositories, :owner_email, :text)
2004 -> 0.0006s
2005== 20110523012243 RepositoriesChangeOwnerEmailType: migrated (0.0007s) ========
2007== 20110611203537 AddGithubOauthTokenToUser: migrating ========================
2008-- add_column(:users, :github_oauth_token, :string)
2009 -> 0.0006s
2010-- add_index(:users, :github_oauth_token)
2011 -> 0.0020s
2012== 20110611203537 AddGithubOauthTokenToUser: migrated (0.0027s) ===============
2014== 20110613210252 AddCompareUrlToBuild: migrating =============================
2015-- add_column(:builds, :compare_url, :string)
2016 -> 0.0006s
2017== 20110613210252 AddCompareUrlToBuild: migrated (0.0006s) ====================
2019== 20110615152003 BuildsRemoveJobId: migrating ================================
2020-- change_table(:builds)
2021 -> 0.0006s
2022== 20110615152003 BuildsRemoveJobId: migrated (0.0007s) =======================
2024== 20110616211744 BuildRemoveLastBuiltAt: migrating ===========================
2025-- change_table(:repositories)
2026 -> 0.0006s
2027== 20110616211744 BuildRemoveLastBuiltAt: migrated (0.0006s) ==================
2029== 20110617114728 AddMissingIndexes: migrating ================================
2030-- add_index(:repositories, :last_build_started_at)
2031 -> 0.0026s
2032-- add_index(:repositories, [:owner_name, :name])
2033 -> 0.0020s
2034-- add_index(:builds, [:repository_id, :parent_id, :started_at])
2035 -> 0.0023s
2036== 20110617114728 AddMissingIndexes: migrated (0.0073s) =======================
2038== 20110619100906 AddActiveToRepositories: migrating ==========================
2039-- add_column(:repositories, :is_active, :boolean)
2040 -> 0.0007s
2041== 20110619100906 AddActiveToRepositories: migrated (0.0007s) =================
2043== 20110729094426 StoreTokenInBuild: migrating ================================
2044-- add_column(:builds, :token, :string)
2045 -> 0.0006s
2046== 20110729094426 StoreTokenInBuild: migrated (0.0007s) =======================
2048== 20110801161819 CreateRequestsCommitsAndTasks: migrating ====================
2049-- change_table(:builds)
2050 -> 0.0015s
2051-- create_table(:commits, {:force=>true, :id=>:integer})
2052 -> 0.0057s
2053-- create_table(:requests, {:force=>true, :id=>:integer})
2054 -> 0.0055s
2055-- create_table(:tasks, {:force=>true, :id=>:integer})
2056 -> 0.0056s
2057-- add_index(:commits, :commit)
2058 -> 0.0021s
2059-- add_index(:builds, :commit)
2060 -> 0.0022s
2061-- add_index(:requests, :commit)
2062 -> 0.0023s
2063-- add_index(:tasks, :commit)
2064 -> 0.0020s
2065-- execute("UPDATE requests SET commit_id = (SELECT commits.id FROM commits WHERE commits.commit = requests.commit LIMIT 1)")
2066 -> 0.0006s
2067-- execute("UPDATE tasks SET commit_id = (SELECT commits.id FROM commits WHERE commits.commit = tasks.commit LIMIT 1)")
2068 -> 0.0004s
2069-- execute("DELETE FROM builds WHERE parent_id IS NOT NULL")
2070 -> 0.0005s
2071-- execute("UPDATE builds SET request_id = (SELECT requests.id FROM requests WHERE requests.commit = builds.commit LIMIT 1)")
2072 -> 0.0004s
2073-- execute("UPDATE builds SET commit_id = (SELECT commits.id FROM commits WHERE commits.commit = builds.commit LIMIT 1)")
2074 -> 0.0004s
2075-- execute("CREATE SEQUENCE shared_builds_tasks_seq CACHE 30")
2076 -> 0.0005s
2077-- execute("ALTER TABLE builds ALTER COLUMN id TYPE BIGINT")
2078 -> 0.0133s
2079-- execute("ALTER TABLE builds ALTER COLUMN id SET DEFAULT nextval('shared_builds_tasks_seq')")
2080 -> 0.0006s
2081-- execute("ALTER TABLE tasks ALTER COLUMN id TYPE BIGINT")
2082 -> 0.0071s
2083-- execute("ALTER TABLE tasks ALTER COLUMN id SET DEFAULT nextval('shared_builds_tasks_seq')")
2084 -> 0.0005s
2085-- select_value("SELECT max(id) FROM commits")
2086 -> 0.0006s
2087-- execute("SELECT setval('commits_id_seq', 1)")
2088 -> 0.0004s
2089-- select_value("SELECT max(id) FROM requests")
2090 -> 0.0004s
2091-- execute("SELECT setval('requests_id_seq', 1)")
2092 -> 0.0003s
2093-- select_value("SELECT max(id) FROM tasks")
2094 -> 0.0005s
2095-- execute("SELECT setval('tasks_id_seq', 1)")
2096 -> 0.0003s
2097-- remove_column(:builds, :parent_id)
2098 -> 0.0005s
2099-- remove_column(:builds, :commit)
2100 -> 0.0004s
2101-- remove_column(:requests, :commit)
2102 -> 0.0004s
2103-- remove_column(:tasks, :commit)
2104 -> 0.0004s
2105== 20110801161819 CreateRequestsCommitsAndTasks: migrated (0.0561s) ===========
2107== 20110805030147 RepositoryRenameIsActiveToActive: migrating =================
2108-- rename_column(:repositories, :is_active, :active)
2109 -> 0.0093s
2110== 20110805030147 RepositoryRenameIsActiveToActive: migrated (0.0094s) ========
2112== 20110819232908 TasksAddTags: migrating =====================================
2113-- add_column(:tasks, :tags, :text)
2114 -> 0.0016s
2115== 20110819232908 TasksAddTags: migrated (0.0016s) ============================
2117== 20110911204538 CacheOneNumberForSharedBuildsTasksSequence: migrating =======
2118-- execute("ALTER SEQUENCE shared_builds_tasks_seq CACHE 1 NO MAXVALUE NO CYCLE")
2119 -> 0.0014s
2120== 20110911204538 CacheOneNumberForSharedBuildsTasksSequence: migrated (0.0015s)
2122== 20111107134436 RenameTasksToJobs: migrating ================================
2123-- rename_table(:tasks, :jobs)
2124 -> 0.0059s
2125-- execute("UPDATE jobs SET type = 'Job::Test' WHERE type = 'Task::Test'")
2126 -> 0.0006s
2127-- execute("UPDATE jobs SET type = 'Job::Configure' WHERE type = 'Task::Configure'")
2128 -> 0.0004s
2129== 20111107134436 RenameTasksToJobs: migrated (0.0070s) =======================
2131== 20111107134437 CreateArtifacts: migrating ==================================
2132-- create_table(:artifacts, {:id=>:integer})
2133 -> 0.0070s
2134-- execute("UPDATE artifacts SET job_id = id")
2135 -> 0.0007s
2136-- execute("select setval('artifacts_id_seq', (select max(id) + 1 from artifacts));")
2137 -> 0.0007s
2138-- add_index(:artifacts, [:type, :job_id])
2139 -> 0.0028s
2140== 20111107134437 CreateArtifacts: migrated (0.0116s) =========================
2142== 20111107134438 CreateWorkers: migrating ====================================
2143-- create_table(:workers, {:id=>:integer})
2144 -> 0.0069s
2145-- add_index(:workers, [:name, :host])
2146 -> 0.0027s
2147== 20111107134438 CreateWorkers: migrated (0.0098s) ===========================
2149== 20111107134439 JobsAddRetries: migrating ===================================
2150-- change_table(:jobs)
2151 -> 0.0022s
2152== 20111107134439 JobsAddRetries: migrated (0.0023s) ==========================
2154== 20111107134440 RemoveRailsAdmin: migrating =================================
2155-- drop_table(:rails_admin_histories)
2156 -> 0.0034s
2157== 20111107134440 RemoveRailsAdmin: migrated (0.0035s) ========================
2159== 20111128235043 AddIndexesToJobs: migrating =================================
2160-- add_index(:jobs, [:queue, :state])
2161 -> 0.0031s
2162== 20111128235043 AddIndexesToJobs: migrated (0.0032s) ========================
2164== 20111129014329 AddRepositoryIdIndexToJobs: migrating =======================
2165-- add_index(:jobs, :repository_id)
2166 -> 0.0031s
2167== 20111129014329 AddRepositoryIdIndexToJobs: migrated (0.0032s) ==============
2169== 20111129022625 AddOwnerAndTypeIndexToJobs: migrating =======================
2170-- add_index(:jobs, [:type, :owner_id, :owner_type])
2171 -> 0.0033s
2172== 20111129022625 AddOwnerAndTypeIndexToJobs: migrated (0.0034s) ==============
2174== 20111201113500 WorkersAddPayloadAndLastError: migrating ====================
2175-- change_table(:workers)
2176 -> 0.0017s
2177== 20111201113500 WorkersAddPayloadAndLastError: migrated (0.0017s) ===========
2179== 20111203002341 RepositoriesAddDescriptionAndLastLanguage: migrating ========
2180-- change_table(:repositories)
2181 -> 0.0017s
2182-- change_table(:builds)
2183 -> 0.0009s
2184== 20111203002341 RepositoriesAddDescriptionAndLastLanguage: migrated (0.0027s)
2186== 20111203221720 BuildsAddArchivedAt: migrating ==============================
2187-- change_table(:builds)
2188 -> 0.0020s
2189== 20111203221720 BuildsAddArchivedAt: migrated (0.0020s) =====================
2191== 20111207093700 MimicProductionDb: migrating ================================
2192-- column_exists?(:users, :oauth2_uid, :integer)
2193 -> 0.0040s
2194-- column_exists?(:users, :oauth2_token, :string)
2195 -> 0.0029s
2196-- column_exists?(:repositories, :user_id, :integer)
2197 -> 0.0033s
2198== 20111207093700 MimicProductionDb: migrated (0.0104s) =======================
2200== 20111212103859 BuildsAddDuration: migrating ================================
2201-- change_table(:builds)
2202 -> 0.0013s
2203== 20111212103859 BuildsAddDuration: migrated (0.0014s) =======================
2205== 20111212112411 RepositoriesAddLastBuildDuration: migrating =================
2206-- change_table(:repositories)
2207 -> 0.0011s
2208== 20111212112411 RepositoriesAddLastBuildDuration: migrated (0.0012s) ========
2210== 20111214173922 CreateSslKeys: migrating ====================================
2211-- create_table(:ssl_keys, {:id=>:integer})
2212 -> 0.0061s
2213-- add_index("ssl_keys", ["repository_id"], {:name=>"index_ssl_key_on_repository_id"})
2214 -> 0.0021s
2215== 20111214173922 CreateSslKeys: migrated (0.0083s) ===========================
2217== 20120114125404 AddAllowFailureToJobs: migrating ============================
2218-- add_column(:jobs, :allow_failure, :boolean, {:default=>false})
2219 -> 0.0011s
2220== 20120114125404 AddAllowFailureToJobs: migrated (0.0011s) ===================
2222== 20120216133223 AddPullRequestFieldsToRequest: migrating ====================
2223-- add_column(:requests, :event_type, :string)
2224 -> 0.0007s
2225-- add_column(:requests, :comments_url, :string)
2226 -> 0.0004s
2227-- add_column(:requests, :base_commit, :string)
2228 -> 0.0004s
2229-- add_column(:requests, :head_commit, :string)
2230 -> 0.0003s
2231== 20120216133223 AddPullRequestFieldsToRequest: migrated (0.0019s) ===========
2233== 20120222082522 AddGravatarIdToUsers: migrating =============================
2234-- add_column(:users, :gravatar_id, :string)
2235 -> 0.0006s
2236== 20120222082522 AddGravatarIdToUsers: migrated (0.0006s) ====================
2238== 20120301131209 OrganizationsCreate: migrating ==============================
2239-- create_table(:organizations, {:id=>:integer})
2240 -> 0.0051s
2241== 20120301131209 OrganizationsCreate: migrated (0.0052s) =====================
2243== 20120304000502 JobsRenameOwnerToSource: migrating ==========================
2244-- change_table(:jobs)
2245 -> 0.0056s
2246== 20120304000502 JobsRenameOwnerToSource: migrated (0.0056s) =================
2248== 20120304000503 RepositoriesAddOwner: migrating =============================
2249-- change_table(:repositories)
2250 -> 0.0011s
2251== 20120304000503 RepositoriesAddOwner: migrated (0.0011s) ====================
2253== 20120304000504 BuildsAddOwner: migrating ===================================
2254-- change_table(:builds)
2255 -> 0.0011s
2256== 20120304000504 BuildsAddOwner: migrated (0.0011s) ==========================
2258== 20120304000505 JobsAddOwner: migrating =====================================
2259-- change_table(:jobs)
2260 -> 0.0010s
2261== 20120304000505 JobsAddOwner: migrated (0.0011s) ============================
2263== 20120304000506 RequestsAddOwner: migrating =================================
2264-- change_table(:requests)
2265 -> 0.0011s
2266== 20120304000506 RequestsAddOwner: migrated (0.0011s) ========================
2268== 20120311234933 AddLocaleToUser: migrating ==================================
2269-- add_column(:users, :locale, :string)
2270 -> 0.0006s
2271== 20120311234933 AddLocaleToUser: migrated (0.0007s) =========================
2273== 20120316123726 CreateMemberships: migrating ================================
2274-- create_table(:memberships, {:id=>:integer})
2275 -> 0.0041s
2276== 20120316123726 CreateMemberships: migrated (0.0041s) =======================
2278== 20120319170001 RepositoriesAddPrivate: migrating ===========================
2279-- change_table(:repositories)
2280 -> 0.0011s
2281== 20120319170001 RepositoriesAddPrivate: migrated (0.0012s) ==================
2283== 20120324104051 CreateUrls: migrating =======================================
2284-- create_table(:urls, {:id=>:integer})
2285 -> 0.0053s
2286== 20120324104051 CreateUrls: migrated (0.0053s) ==============================
2288== 20120505165100 CopyStatusToResult: migrating ===============================
2289-- add_column(:builds, :result, :integer)
2290 -> 0.0007s
2291-- add_column(:jobs, :result, :integer)
2292 -> 0.0004s
2293-- add_column(:repositories, :last_build_result, :integer)
2294 -> 0.0004s
2295Executing: UPDATE builds SET result = status;
2296Executing: UPDATE jobs SET result = status;
2297Executing: UPDATE repositories SET last_build_result = last_build_status;
2298== 20120505165100 CopyStatusToResult: migrated (0.0029s) ======================
2300== 20120511171900 RequestsAddIndexOnHeadCommit: migrating =====================
2301-- add_index(:requests, :head_commit)
2302 -> 0.0027s
2303== 20120511171900 RequestsAddIndexOnHeadCommit: migrated (0.0027s) ============
2305== 20120521174400 CreatePermissions: migrating ================================
2306-- create_table(:permissions, {:id=>:integer})
2307 -> 0.0037s
2308-- add_index(:permissions, :user_id)
2309 -> 0.0027s
2310-- add_index(:permissions, :repository_id)
2311 -> 0.0081s
2312== 20120521174400 CreatePermissions: migrated (0.0147s) =======================
2314== 20120527235800 BuildsAddPreviousResult: migrating ==========================
2315-- change_table(:builds)
2316 -> 0.0026s
2317== 20120527235800 BuildsAddPreviousResult: migrated (0.0027s) =================
2319== 20120702111126 CreateSubscriptions: migrating ==============================
2320-- create_table(:subscriptions, {:id=>:integer})
2321 -> 0.0099s
2322== 20120702111126 CreateSubscriptions: migrated (0.0100s) =====================
2324== 20120703114226 AddBillingEmailCreditCardDataToSubscriptions: migrating =====
2325-- change_table(:subscriptions)
2326 -> 0.0058s
2327== 20120703114226 AddBillingEmailCreditCardDataToSubscriptions: migrated (0.0060s)
2329== 20120713140816 AddSyncInfoToUser: migrating ================================
2330-- add_column(:users, :in_sync, :boolean)
2331 -> 0.0018s
2332-- add_column(:users, :synced_at, :timestamp)
2333 -> 0.0014s
2334== 20120713140816 AddSyncInfoToUser: migrated (0.0036s) =======================
2336== 20120713153215 RenameInSyncToIsSyncing: migrating ==========================
2337-- rename_column(:users, :in_sync, :is_syncing)
2338 -> 0.0059s
2339== 20120713153215 RenameInSyncToIsSyncing: migrated (0.0061s) =================
2341== 20120725005300 AddQueueToWorkers: migrating ================================
2342-- add_column(:workers, :queue, :string)
2343 -> 0.0021s
2344== 20120725005300 AddQueueToWorkers: migrated (0.0023s) =======================
2346== 20120727151900 AddJobsIndexOnStateOwnerTypeOwnerId: migrating ==============
2347-- add_index(:jobs, ["state", "owner_id", "owner_type"], {:name=>"index_jobs_on_state_owner_type_owner_id"})
2348 -> 0.0037s
2349== 20120727151900 AddJobsIndexOnStateOwnerTypeOwnerId: migrated (0.0038s) =====
2351== 20120731005301 AddQueuedAtToJobs: migrating ================================
2352-- add_column(:jobs, :queued_at, :timestamp, {:precision=>nil})
2353 -> 0.0021s
2354== 20120731005301 AddQueuedAtToJobs: migrated (0.0024s) =======================
2356== 20120731074000 AddAmountToPlans: migrating =================================
2357-- change_table(:plans)
2358 -> 0.0022s
2359== 20120731074000 AddAmountToPlans: migrated (0.0023s) ========================
2361== 20120802001001 AddPushAndPullToPermissions: migrating ======================
2362-- add_column(:permissions, :push, :boolean, {:default=>false})
2363 -> 0.0011s
2364-- add_column(:permissions, :pull, :boolean, {:default=>false})
2365 -> 0.0008s
2366-- change_column_default(:permissions, :admin, false)
2367 -> 0.0016s
2368== 20120802001001 AddPushAndPullToPermissions: migrated (0.0036s) =============
2370== 20120803164000 CreateInvoices: migrating ===================================
2371-- create_table(:invoices, {:id=>:integer})
2372 -> 0.0055s
2373== 20120803164000 CreateInvoices: migrated (0.0055s) ==========================
2375== 20120803182300 AddInvoiceIdToInvoices: migrating ===========================
2376-- change_table(:invoices)
2377 -> 0.0007s
2378== 20120803182300 AddInvoiceIdToInvoices: migrated (0.0008s) ==================
2380== 20120804122700 AddStripeInvoiceIdToInvoices: migrating =====================
2381-- change_table(:invoices)
2382 -> 0.0007s
2383-- add_index(:invoices, :stripe_id)
2384 -> 0.0023s
2385== 20120804122700 AddStripeInvoiceIdToInvoices: migrated (0.0030s) ============
2387== 20120806120400 AddPlanToSubscriptions: migrating ===========================
2388-- change_table(:subscriptions)
2389 -> 0.0007s
2390== 20120806120400 AddPlanToSubscriptions: migrated (0.0008s) ==================
2392== 20120820164000 RenamePlanOnSubscriptions: migrating ========================
2393-- change_table(:subscriptions)
2394 -> 0.0014s
2395== 20120820164000 RenamePlanOnSubscriptions: migrated (0.0014s) ===============
2397== 20120905093300 CreateStripeEvents: migrating ===============================
2398-- create_table(:stripe_events, {:id=>:integer})
2399 -> 0.0049s
2400-- add_index(:stripe_events, :event_type)
2401 -> 0.0019s
2402-- add_index(:stripe_events, :date)
2403 -> 0.0019s
2404== 20120905093300 CreateStripeEvents: migrated (0.0089s) ======================
2406== 20120905171300 AddEventIdToStripeEvents: migrating =========================
2407-- change_table(:stripe_events)
2408 -> 0.0007s
2409-- add_index(:stripe_events, :event_id)
2410 -> 0.0021s
2411== 20120905171300 AddEventIdToStripeEvents: migrated (0.0029s) ================
2413== 20120911160000 AddBuildsIndexOnRepositoryIdAndState: migrating =============
2414-- remove_index("builds", nil, {:column=>"repository_id", :name=>"index_builds_on_repository_id"})
2415 -> 0.0017s
2416-- add_index("builds", ["repository_id", "state"])
2417 -> 0.0022s
2418== 20120911160000 AddBuildsIndexOnRepositoryIdAndState: migrated (0.0049s) ====
2420== 20120911230000 ArtifactsAddAggregatedAt: migrating =========================
2421-- add_column(:artifacts, :aggregated_at, :timestamp, {:precision=>nil})
2422 -> 0.0007s
2423== 20120911230000 ArtifactsAddAggregatedAt: migrated (0.0007s) ================
2425== 20120911230001 AddArtifactParts: migrating =================================
2426-- create_table(:artifact_parts, {:id=>:integer})
2427 -> 0.0054s
2428-- add_index(:artifact_parts, [:artifact_id, :number])
2429 -> 0.0023s
2430== 20120911230001 AddArtifactParts: migrated (0.0078s) ========================
2432== 20120913143800 AddSubscriptionsCoupon: migrating ===========================
2433-- change_table(:subscriptions)
2434 -> 0.0008s
2435== 20120913143800 AddSubscriptionsCoupon: migrated (0.0009s) ==================
2437== 20120915012000 BuildsAddIndexOnFinishedAt: migrating =======================
2438-- add_index("builds", "finished_at")
2439 -> 0.0027s
2440== 20120915012000 BuildsAddIndexOnFinishedAt: migrated (0.0027s) ==============
2442== 20120915012001 CommitsAddIndexOnBranch: migrating ==========================
2443-- add_index("commits", "branch")
2444 -> 0.0024s
2445== 20120915012001 CommitsAddIndexOnBranch: migrated (0.0025s) =================
2447== 20120915150000 JobsAddIndexOnCreatedAt: migrating ==========================
2448-- add_index("jobs", "created_at")
2449 -> 0.0025s
2450== 20120915150000 JobsAddIndexOnCreatedAt: migrated (0.0025s) =================
2452== 20121015002500 CreateEvents: migrating =====================================
2453-- create_table(:events, {:id=>:integer})
2454 -> 0.0053s
2455== 20121015002500 CreateEvents: migrated (0.0054s) ============================
2457== 20121015002501 RequestsAddResultAndMessage: migrating ======================
2458-- add_column(:requests, :result, :string)
2459 -> 0.0007s
2460-- add_column(:requests, :message, :string)
2461 -> 0.0004s
2462== 20121015002501 RequestsAddResultAndMessage: migrated (0.0012s) =============
2464== 20121017040100 CreateBroadcasts: migrating =================================
2465-- create_table(:broadcasts, {:id=>:integer})
2466 -> 0.0056s
2467== 20121017040100 CreateBroadcasts: migrated (0.0056s) ========================
2469== 20121017040200 EventsChangeDataToText: migrating ===========================
2470-- change_column(:events, :data, :text)
2471 -> 0.0007s
2472== 20121017040200 EventsChangeDataToText: migrated (0.0007s) ==================
2474== 20121018201301 AddEventTypeToBuilds: migrating =============================
2475-- add_column(:builds, :event_type, :string)
2476 -> 0.0007s
2477== 20121018201301 AddEventTypeToBuilds: migrated (0.0007s) ====================
2479== 20121018203728 UpdateEventTypeOnBuilds: migrating ==========================
2480-- execute(" UPDATE builds\n SET event_type = requests.event_type\n FROM requests\n WHERE builds.request_id = requests.id\n")
2481 -> 0.0010s
2482== 20121018203728 UpdateEventTypeOnBuilds: migrated (0.0010s) =================
2484== 20121018210156 AddIndexOnRepositoryIdAndEventTypeToBuilds: migrating =======
2485-- add_index(:builds, [:repository_id, :event_type])
2486 -> 0.0025s
2487== 20121018210156 AddIndexOnRepositoryIdAndEventTypeToBuilds: migrated (0.0026s)
2489== 20121125122700 RepositoriesAddLastBuildState: migrating ====================
2490-- add_column(:repositories, :last_build_state, :string)
2491 -> 0.0007s
2492== 20121125122700 RepositoriesAddLastBuildState: migrated (0.0007s) ===========
2494== 20121125122701 BuildsAddPreviousState: migrating ===========================
2495-- add_column(:builds, :previous_state, :string)
2496 -> 0.0007s
2497== 20121125122701 BuildsAddPreviousState: migrated (0.0008s) ==================
2499== 20121222125200 ArtifactPartsAddFinal: migrating ============================
2500-- add_column(:artifact_parts, :final, :boolean)
2501 -> 0.0012s
2502-- add_column(:artifact_parts, :created_at, :timestamp)
2503 -> 0.0007s
2504== 20121222125200 ArtifactPartsAddFinal: migrated (0.0020s) ===================
2506== 20121222125300 ArtifactPartsChangeContentToText: migrating =================
2507-- change_column(:artifact_parts, :content, :text)
2508 -> 0.0009s
2509== 20121222125300 ArtifactPartsChangeContentToText: migrated (0.0010s) ========
2511== 20121222140200 ArtifactPartsAddIndexOnArtifactId: migrating ================
2512-- add_index(:artifact_parts, :artifact_id)
2513 -> 0.0030s
2514== 20121222140200 ArtifactPartsAddIndexOnArtifactId: migrated (0.0031s) =======
2516== 20121223162300 ArtifactPartsRemoveIndexOnArtifactId: migrating =============
2517-- remove_index(:artifact_parts, :artifact_id, {:name=>"index_artifact_parts_on_artifact_id"})
2518 -> 0.0035s
2519== 20121223162300 ArtifactPartsRemoveIndexOnArtifactId: migrated (0.0056s) ====
2521== 20130107165057 AddGithubScopesToUser: migrating ============================
2522-- add_column(:users, :github_scopes, :text)
2523 -> 0.0010s
2524== 20130107165057 AddGithubScopesToUser: migrated (0.0011s) ===================
2526== 20130115125836 AddIndexOnLastSeenAtToWorkers: migrating ====================
2527-- add_index(:workers, :last_seen_at)
2528 -> 0.0031s
2529== 20130115125836 AddIndexOnLastSeenAtToWorkers: migrated (0.0032s) ===========
2531== 20130115145728 CacheFullNameInWorkers: migrating ===========================
2532-- add_column(:workers, :full_name, :string)
2533 -> 0.0009s
2534-- add_index(:workers, :full_name)
2535 -> 0.0026s
2536== 20130115145728 CacheFullNameInWorkers: migrated (0.0037s) ==================
2538== 20130125002600 ArtifactsAddArchivedAt: migrating ===========================
2539-- add_column(:artifacts, :archived_at, :timestamp, {:precision=>nil})
2540 -> 0.0012s
2541-- add_index(:artifacts, :archived_at)
2542 -> 0.0025s
2543== 20130125002600 ArtifactsAddArchivedAt: migrated (0.0040s) ==================
2545== 20130125171100 ArtifactsAddArchivingAndVerified: migrating =================
2546-- add_column(:artifacts, :archiving, :boolean)
2547 -> 0.0009s
2548-- add_column(:artifacts, :archive_verified, :boolean)
2549 -> 0.0006s
2550-- add_index(:artifacts, :archiving)
2551 -> 0.0026s
2552-- add_index(:artifacts, :archive_verified)
2553 -> 0.0025s
2554== 20130125171100 ArtifactsAddArchivingAndVerified: migrated (0.0069s) ========
2556== 20130129142703 CreateEmails: migrating =====================================
2557-- create_table(:emails, {:id=>:integer})
2558 -> 0.0071s
2559-- add_index(:emails, :user_id)
2560 -> 0.0026s
2561-- add_index(:emails, :email)
2562 -> 0.0025s
2563== 20130129142703 CreateEmails: migrated (0.0126s) ============================
2565== 20130208135800 RenameArtifacts: migrating ==================================
2566-- rename_table(:artifacts, :artifacts_backup)
2567 -> 0.0093s
2568-- rename_table(:artifact_parts, :artifact_parts_backup)
2569 -> 0.0074s
2570== 20130208135800 RenameArtifacts: migrated (0.0168s) =========================
2572== 20130208135801 DropArtifacts: migrating ====================================
2573-- drop_table(:artifacts_backup)
2574 -> 0.0031s
2575-- drop_table(:artifact_parts_backup)
2576 -> 0.0035s
2577== 20130208135801 DropArtifacts: migrated (0.0066s) ===========================
2579== 20130306154311 CreatePgcryptoExtension: migrating ==========================
2580-- execute("create extension if not exists pgcrypto")
2581 -> 0.0051s
2582== 20130306154311 CreatePgcryptoExtension: migrated (0.0053s) =================
2584== 20130311211101 AddPullRequestTitleToBuilds: migrating ======================
2585-- add_column(:builds, :pull_request_title, :text)
2586 -> 0.0009s
2587== 20130311211101 AddPullRequestTitleToBuilds: migrated (0.0009s) =============
2589== 20130327100801 AddPullRequestNumberToBuilds: migrating =====================
2590-- add_column(:builds, :pull_request_number, :integer)
2591 -> 0.0043s
2592== 20130327100801 AddPullRequestNumberToBuilds: migrated (0.0044s) ============
2594== 20130418101437 AddIndexToBuildsRequestId: migrating ========================
2595-- execute("CREATE INDEX CONCURRENTLY index_builds_on_request_id ON builds(request_id)")
2596 -> 0.0045s
2597== 20130418101437 AddIndexToBuildsRequestId: migrated (0.0046s) ===============
2599== 20130418103306 AddIndexToJobsOnOwnerIdOwnerTypeAndState: migrating =========
2600-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_owner_id_and_owner_type_and_state ON jobs(owner_id, owner_type, state)")
2601 -> 0.0042s
2602== 20130418103306 AddIndexToJobsOnOwnerIdOwnerTypeAndState: migrated (0.0043s)
2604== 20130505023259 AddMoreIndexesToBuilds: migrating ===========================
2605-- execute(" CREATE INDEX CONCURRENTLY index_builds_on_repository_id_and_event_type_and_state_and_branch\n ON builds(repository_id, event_type, state, branch);\n")
2606 -> 0.0041s
2607== 20130505023259 AddMoreIndexesToBuilds: migrated (0.0041s) ==================
2609== 20130521115725 AddIndexOnBuildState: migrating =============================
2610-- execute(" CREATE INDEX CONCURRENTLY index_builds_on_state\n ON builds(state);\n")
2611 -> 0.0039s
2612== 20130521115725 AddIndexOnBuildState: migrated (0.0039s) ====================
2614== 20130521133050 UpdateFinishedJobs: migrating ===============================
2615-- execute("UPDATE jobs SET state = 'passed' WHERE state = 'finished' AND result = 0 AND type = 'Job::Test'")
2616 -> 0.0008s
2617-- execute("UPDATE jobs SET state = 'failed' WHERE state = 'finished' AND result = 1 AND type = 'Job::Test'")
2618 -> 0.0004s
2619-- execute("UPDATE jobs SET state = 'errored' WHERE state = 'finished' AND result IS NULL AND type = 'Job::Test'")
2620 -> 0.0004s
2621-- execute("SELECT COUNT(*) FROM jobs WHERE state = 'finished' AND type = 'Job::Test'")
2622 -> 0.0004s
2623== 20130521133050 UpdateFinishedJobs: migrated (0.0020s) ======================
2625== 20130521134224 UpdateFinishedBuilds: migrating =============================
2626-- execute("UPDATE builds SET state = 'passed' WHERE state = 'finished' AND result = 0")
2627 -> 0.0007s
2628-- execute("UPDATE builds SET state = 'failed' WHERE state = 'finished' AND result = 1")
2629 -> 0.0003s
2630-- execute("UPDATE builds SET state = 'errored' WHERE state = 'finished' AND result IS NULL")
2631 -> 0.0003s
2632-- execute("SELECT COUNT(*) FROM builds WHERE state = 'finished'")
2633 -> 0.0003s
2634== 20130521134224 UpdateFinishedBuilds: migrated (0.0019s) ====================
2636== 20130521134800 RemoveUnusedBuildColumns: migrating =========================
2637-- remove_column(:builds, :result)
2638 -> 0.0007s
2639-- remove_column(:builds, :status)
2640 -> 0.0004s
2641-- remove_column(:builds, :previous_result)
2642 -> 0.0003s
2643-- remove_column(:builds, :agent)
2644 -> 0.0003s
2645-- remove_column(:builds, :language)
2646 -> 0.0003s
2647-- remove_column(:builds, :archived_at)
2648 -> 0.0003s
2649== 20130521134800 RemoveUnusedBuildColumns: migrated (0.0025s) ================
2651== 20130521141357 RemoveUnusedJobColumns: migrating ===========================
2652-- remove_column(:jobs, :status)
2653 -> 0.0007s
2654-- remove_column(:jobs, :job_id)
2655 -> 0.0003s
2656-- remove_column(:jobs, :retries)
2657 -> 0.0004s
2658== 20130521141357 RemoveUnusedJobColumns: migrated (0.0015s) ==================
2660== 20130618084205 AddCoupons: migrating =======================================
2661-- create_table(:coupons, {:id=>:integer})
2662 -> 0.0053s
2663== 20130618084205 AddCoupons: migrated (0.0054s) ==============================
2665== 20130629122945 AddGithubIdToUsers: migrating ===============================
2666-- add_column(:repositories, :github_id, :integer)
2667 -> 0.0007s
2668-- add_index(:repositories, :github_id)
2669 -> 0.0022s
2670== 20130629122945 AddGithubIdToUsers: migrated (0.0029s) ======================
2672== 20130629133531 AddDefaultBranchToRepositories: migrating ===================
2673-- add_column(:repositories, :default_branch, :string)
2674 -> 0.0007s
2675== 20130629133531 AddDefaultBranchToRepositories: migrated (0.0007s) ==========
2677== 20130629174449 AddGithubLanguageToRepositories: migrating ==================
2678-- add_column(:repositories, :github_language, :string)
2679 -> 0.0006s
2680== 20130629174449 AddGithubLanguageToRepositories: migrated (0.0007s) =========
2682== 20130701175200 AddContactIdToSubscriptions: migrating ======================
2683-- change_table(:subscriptions)
2684 -> 0.0008s
2685== 20130701175200 AddContactIdToSubscriptions: migrated (0.0009s) =============
2687== 20130702123456 RemoveUnusedRepositoryColumns: migrating ====================
2688-- remove_column(:repositories, :last_duration)
2689 -> 0.0019s
2690-- remove_column(:repositories, :last_build_status)
2691 -> 0.0009s
2692-- remove_column(:repositories, :last_build_result)
2693 -> 0.0012s
2694-- remove_column(:repositories, :last_build_language)
2695 -> 0.0006s
2696== 20130702123456 RemoveUnusedRepositoryColumns: migrated (0.0051s) ===========
2698== 20130702144325 AddUniqueIndexOnUsersGithubIdAndRemoveUniqueIndexOnUsersLogin: migrating
2699-- execute("DROP INDEX index_users_on_login")
2700 -> 0.0017s
2701-- execute("CREATE INDEX CONCURRENTLY index_users_on_login ON users(login)")
2702 -> 0.0044s
2703-- execute("DROP INDEX index_users_on_github_id")
2704 -> 0.0013s
2705-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_users_on_github_id ON users(github_id)")
2706 -> 0.0040s
2707== 20130702144325 AddUniqueIndexOnUsersGithubIdAndRemoveUniqueIndexOnUsersLogin: migrated (0.0117s)
2709== 20130705123456 AddExtraColumnsToOrganizations: migrating ===================
2710-- add_column(:organizations, :avatar_url, :string)
2711 -> 0.0010s
2712-- add_column(:organizations, :location, :string)
2713 -> 0.0011s
2714-- add_column(:organizations, :email, :string)
2715 -> 0.0013s
2716-- add_column(:organizations, :company, :string)
2717 -> 0.0010s
2718-- add_column(:organizations, :homepage, :string)
2719 -> 0.0009s
2720== 20130705123456 AddExtraColumnsToOrganizations: migrated (0.0058s) ==========
2722== 20130707164854 AddIndexOnGithubIdToOrganizations: migrating ================
2723-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_organizations_on_github_id ON organizations(github_id)")
2724 -> 0.0044s
2725== 20130707164854 AddIndexOnGithubIdToOrganizations: migrated (0.0045s) =======
2727== 20130709185200 CreateAnnotations: migrating ================================
2728-- create_table(:annotations, {:id=>:integer})
2729 -> 0.0086s
2730== 20130709185200 CreateAnnotations: migrated (0.0092s) =======================
2732== 20130709233500 CreateAnnotationProviders: migrating ========================
2733-- create_table(:annotation_providers, {:id=>:integer})
2734 -> 0.0128s
2735== 20130709233500 CreateAnnotationProviders: migrated (0.0131s) ===============
2737== 20130710000745 AddAnnotationProviderIdToAnnotations: migrating =============
2738-- add_column(:annotations, :annotation_provider_id, :integer, {:null=>false})
2739 -> 0.0009s
2740== 20130710000745 AddAnnotationProviderIdToAnnotations: migrated (0.0009s) ====
2742== 20130726101124 AddCanceledAtToJobsAndBuilds: migrating =====================
2743-- add_column(:builds, :canceled_at, :timestamp, {:precision=>nil})
2744 -> 0.0008s
2745-- add_column(:jobs, :canceled_at, :timestamp, {:precision=>nil})
2746 -> 0.0005s
2747== 20130726101124 AddCanceledAtToJobsAndBuilds: migrated (0.0014s) ============
2749== 20130901183019 AddIndexOnRepositoryGithubId: migrating =====================
2750-- execute("DROP INDEX index_repositories_on_github_id")
2751 -> 0.0012s
2752-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_github_id ON repositories(github_id)")
2753 -> 0.0032s
2754== 20130901183019 AddIndexOnRepositoryGithubId: migrated (0.0044s) ============
2756== 20130909203321 AddCachedMatrixIdsToBuilds: migrating =======================
2757-- execute("ALTER TABLE builds ADD COLUMN cached_matrix_ids integer[]")
2758 -> 0.0053s
2759== 20130909203321 AddCachedMatrixIdsToBuilds: migrated (0.0053s) ==============
2761== 20130910184823 CreateIndexOnBuildsIdDescAndRepositoryIdAndEventType: migrating
2762-- execute("CREATE INDEX CONCURRENTLY index_builds_on_id_repository_id_and_event_type_desc ON builds (id DESC, repository_id, event_type);")
2763 -> 0.0036s
2764== 20130910184823 CreateIndexOnBuildsIdDescAndRepositoryIdAndEventType: migrated (0.0036s)
2766== 20130916101056 AddUniqueIndexOnRepositoryGithubId: migrating ===============
2767-- execute("DROP INDEX index_repositories_on_github_id")
2768 -> 0.0010s
2769-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_repositories_on_github_id ON repositories(github_id)")
2770 -> 0.0036s
2771== 20130916101056 AddUniqueIndexOnRepositoryGithubId: migrated (0.0047s) ======
2773== 20130920135744 AddSettingsToRepositories: migrating ========================
2774-- add_column(:repositories, :settings, :json)
2775 -> 0.0006s
2776== 20130920135744 AddSettingsToRepositories: migrated (0.0007s) ===============
2778== 20131104101056 RemoveWorkersTableAndIndexes: migrating =====================
2779-- drop_table(:workers)
2780 -> 0.0010s
2781== 20131104101056 RemoveWorkersTableAndIndexes: migrated (0.0011s) ============
2783== 20131109101056 RemoveEventsTable: migrating ================================
2784-- drop_table(:events)
2785 -> 0.0009s
2786== 20131109101056 RemoveEventsTable: migrated (0.0009s) =======================
2788== 20140120225125 RemoveAnnotationImageInfo: migrating ========================
2789-- remove_column(:annotations, :image_url)
2790 -> 0.0006s
2791-- remove_column(:annotations, :image_alt)
2792 -> 0.0003s
2793== 20140120225125 RemoveAnnotationImageInfo: migrated (0.0010s) ===============
2795== 20140121003026 AddStatusToAnnotations: migrating ===========================
2796-- add_column(:annotations, :status, :string)
2797 -> 0.0011s
2798== 20140121003026 AddStatusToAnnotations: migrated (0.0012s) ==================
2800== 20140204220926 AddIndicesToRequests: migrating =============================
2801-- execute("CREATE INDEX CONCURRENTLY index_requests_on_repository_id ON requests(repository_id)")
2802 -> 0.0035s
2803-- execute("CREATE INDEX CONCURRENTLY index_requests_on_commit_id ON requests(commit_id)")
2804 -> 0.0034s
2805== 20140204220926 AddIndicesToRequests: migrated (0.0070s) ====================
2807== 20140210003014 AddIndicesToMemberships: migrating ==========================
2808-- execute("CREATE INDEX CONCURRENTLY index_memberships_on_user_id ON memberships(user_id)")
2809 -> 0.0034s
2810== 20140210003014 AddIndicesToMemberships: migrated (0.0035s) =================
2812== 20140210012509 RemoveUnusedIndices: migrating ==============================
2813-- execute("DROP INDEX CONCURRENTLY index_commits_on_commit")
2814 -> 0.0021s
2815-- execute("DROP INDEX CONCURRENTLY index_builds_on_state")
2816 -> 0.0020s
2817-- execute("DROP INDEX CONCURRENTLY index_commits_on_branch")
2818 -> 0.0022s
2819-- execute("DROP INDEX CONCURRENTLY index_users_on_github_oauth_token")
2820 -> 0.0023s
2821-- execute("DROP INDEX CONCURRENTLY index_builds_on_finished_at")
2822 -> 0.0023s
2823-- execute("DROP INDEX CONCURRENTLY index_jobs_on_queue_and_state")
2824 -> 0.0020s
2825-- execute("DROP INDEX CONCURRENTLY index_jobs_on_created_at")
2826 -> 0.0020s
2827== 20140210012509 RemoveUnusedIndices: migrated (0.0151s) =====================
2829== 20140612131826 AddRemovedInfoToLogs: migrating =============================
2830== 20140612131826 AddRemovedInfoToLogs: migrated (0.0007s) ====================
2832== 20140827121945 AddEducationFieldToUser: migrating ==========================
2833-- add_column(:users, :education, :boolean)
2834 -> 0.0007s
2835== 20140827121945 AddEducationFieldToUser: migrated (0.0008s) =================
2837== 20150121135400 JobsAddReceivedAt: migrating ================================
2838-- add_column(:jobs, :received_at, :timestamp, {:precision=>nil})
2839 -> 0.0012s
2840== 20150121135400 JobsAddReceivedAt: migrated (0.0012s) =======================
2842== 20150121135401 BuildsAddReceivedAt: migrating ==============================
2843-- add_column(:builds, :received_at, :timestamp, {:precision=>nil})
2844 -> 0.0007s
2845== 20150121135401 BuildsAddReceivedAt: migrated (0.0008s) =====================
2847== 20150204144312 AddIndexOnRepositoryIdToCommits: migrating ==================
2848-- execute("DROP INDEX IF EXISTS index_commits_on_repository_id")
2849 -> 0.0003s
2850-- execute("CREATE INDEX CONCURRENTLY index_commits_on_repository_id ON commits(repository_id)")
2851 -> 0.0038s
2852== 20150204144312 AddIndexOnRepositoryIdToCommits: migrated (0.0042s) =========
2854== 20150210170900 IndexRequestsOnCreatedAt: migrating =========================
2855-- execute("DROP INDEX IF EXISTS index_requests_on_created_at")
2856 -> 0.0003s
2857-- execute("CREATE INDEX CONCURRENTLY index_requests_on_created_at ON requests(created_at)")
2858 -> 0.0041s
2859== 20150210170900 IndexRequestsOnCreatedAt: migrated (0.0044s) ================
2861== 20150223125700 CreateBranches: migrating ===================================
2862-- create_table(:branches, {:id=>:integer})
2863 -> 0.0161s
2864-- add_index(:branches, [:repository_id, :name], {:unique=>true})
2865 -> 0.0034s
2866== 20150223125700 CreateBranches: migrated (0.0196s) ==========================
2868== 20150311020321 AddNextBuildNumberToRepository: migrating ===================
2869-- add_column(:repositories, :next_build_number, :integer)
2870 -> 0.0010s
2871== 20150311020321 AddNextBuildNumberToRepository: migrated (0.0011s) ==========
2873== 20150316020321 AddActiveIndexToRepository: migrating =======================
2874-- execute("DROP INDEX IF EXISTS index_repositories_on_active")
2875 -> 0.0004s
2876-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_active ON repositories(active)")
2877 -> 0.0042s
2878== 20150316020321 AddActiveIndexToRepository: migrated (0.0048s) ==============
2880== 20150316080321 AddOwnerTypeAndOwnerIdIndexesToBuilds: migrating ============
2881-- execute("DROP INDEX IF EXISTS index_builds_on_owner_type")
2882 -> 0.0004s
2883-- execute("DROP INDEX IF EXISTS index_builds_on_owner_id")
2884 -> 0.0002s
2885-- execute("CREATE INDEX CONCURRENTLY index_builds_on_owner_type ON builds(owner_type)")
2886 -> 0.0046s
2887-- execute("CREATE INDEX CONCURRENTLY index_builds_on_owner_id ON builds(owner_id)")
2888 -> 0.0043s
2889== 20150316080321 AddOwnerTypeAndOwnerIdIndexesToBuilds: migrated (0.0098s) ===
2891== 20150316100321 AddOwnerTypeAndOwnerIdIndexesToRepositories: migrating ======
2892-- execute("DROP INDEX IF EXISTS index_repositories_on_owner_type")
2893 -> 0.0003s
2894-- execute("DROP INDEX IF EXISTS index_repositories_on_owner_id")
2895 -> 0.0004s
2896-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_owner_type ON repositories(owner_type)")
2897 -> 0.0044s
2898-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_owner_id ON repositories(owner_id)")
2899 -> 0.0037s
2900== 20150316100321 AddOwnerTypeAndOwnerIdIndexesToRepositories: migrated (0.0090s)
2902== 20150317004600 AddSlugIndexToRepositories: migrating =======================
2903-- execute("CREATE EXTENSION IF NOT EXISTS pg_trgm")
2904 -> 0.0158s
2905-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_slug ON repositories USING gin((owner_name || '/' || name) gin_trgm_ops)")
2906 -> 0.0044s
2907== 20150317004600 AddSlugIndexToRepositories: migrated (0.0203s) ==============
2909== 20150317020321 AddTokenIndexToTokens: migrating ============================
2910-- execute("DROP INDEX IF EXISTS index_tokens_on_token")
2911 -> 0.0006s
2912-- execute("CREATE INDEX CONCURRENTLY index_tokens_on_token ON tokens(token)")
2913 -> 0.0047s
2914== 20150317020321 AddTokenIndexToTokens: migrated (0.0054s) ===================
2916== 20150317080321 AddLoginIndexToOrganizations: migrating =====================
2917-- execute("DROP INDEX IF EXISTS index_organizations_on_login")
2918 -> 0.0005s
2919-- execute("CREATE INDEX CONCURRENTLY index_organizations_on_login ON organizations(login)")
2920 -> 0.0037s
2921== 20150317080321 AddLoginIndexToOrganizations: migrated (0.0043s) ============
2923== 20150414001337 AddLowerCaseIndices: migrating ==============================
2924-- execute("DROP INDEX IF EXISTS index_organizations_on_lower_login")
2925 -> 0.0005s
2926-- execute("CREATE INDEX CONCURRENTLY index_organizations_on_lower_login ON organizations USING btree(lower(login))")
2927 -> 0.0054s
2928-- execute("DROP INDEX IF EXISTS index_users_on_lower_login")
2929 -> 0.0016s
2930-- execute("CREATE INDEX CONCURRENTLY index_users_on_lower_login ON users USING btree(lower(login))")
2931 -> 0.0043s
2932-- execute("DROP INDEX IF EXISTS index_repositories_on_lower_name")
2933 -> 0.0004s
2934-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_lower_name ON repositories USING btree(lower(name))")
2935 -> 0.0037s
2936-- execute("DROP INDEX IF EXISTS index_repositories_on_lower_owner_name")
2937 -> 0.0004s
2938-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_lower_owner_name ON repositories USING btree(lower(owner_name))")
2939 -> 0.0040s
2940== 20150414001337 AddLowerCaseIndices: migrated (0.0210s) =====================
2942== 20150528101600 RepositoriesAddIndexOwnerName: migrating ====================
2943-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_owner_name ON repositories(owner_name)")
2944 -> 0.0038s
2945== 20150528101600 RepositoriesAddIndexOwnerName: migrated (0.0038s) ===========
2947== 20150528101601 RepositoriesAddIndexName: migrating =========================
2948-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_name ON repositories(name)")
2949 -> 0.0038s
2950== 20150528101601 RepositoriesAddIndexName: migrated (0.0039s) ================
2952== 20150528101602 RepositoriesDropIndexOwnerNameName: migrating ===============
2953-- execute("DROP INDEX CONCURRENTLY index_repositories_on_owner_name_and_name")
2954 -> 0.0020s
2955== 20150528101602 RepositoriesDropIndexOwnerNameName: migrated (0.0021s) ======
2957== 20150528101603 BuildsAddIndexEventType: migrating ==========================
2958-- execute("CREATE INDEX CONCURRENTLY index_builds_on_event_type ON builds (event_type)")
2959 -> 0.0036s
2960== 20150528101603 BuildsAddIndexEventType: migrated (0.0037s) =================
2962== 20150528101604 BuildsAddIndexRepositoryId: migrating =======================
2963-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id ON builds (repository_id)")
2964 -> 0.0036s
2965== 20150528101604 BuildsAddIndexRepositoryId: migrated (0.0036s) ==============
2967== 20150528101605 BuildsAddIndexState: migrating ==============================
2968-- execute("CREATE INDEX CONCURRENTLY index_builds_on_state ON builds (state)")
2969 -> 0.0037s
2970== 20150528101605 BuildsAddIndexState: migrated (0.0037s) =====================
2972== 20150528101607 BuildsAddIndexBranch: migrating =============================
2973-- execute("CREATE INDEX CONCURRENTLY index_builds_on_branch ON builds (branch)")
2974 -> 0.0033s
2975== 20150528101607 BuildsAddIndexBranch: migrated (0.0033s) ====================
2977== 20150528101608 BuildsDropIndexRepositoryIdAndState: migrating ==============
2978-- execute("DROP INDEX CONCURRENTLY index_builds_on_repository_id_and_state")
2979 -> 0.0020s
2980== 20150528101608 BuildsDropIndexRepositoryIdAndState: migrated (0.0020s) =====
2982== 20150528101609 BuildsDropIndexRepositoryIdAndEventType: migrating ==========
2983-- execute("DROP INDEX CONCURRENTLY index_builds_on_repository_id_and_event_type")
2984 -> 0.0022s
2985== 20150528101609 BuildsDropIndexRepositoryIdAndEventType: migrated (0.0022s) =
2987== 20150528101610 BuildsDropIndexIdRepositoryIdAndEventTypeDesc: migrating ====
2988-- execute("DROP INDEX CONCURRENTLY index_builds_on_id_repository_id_and_event_type_desc")
2989 -> 0.0023s
2990== 20150528101610 BuildsDropIndexIdRepositoryIdAndEventTypeDesc: migrated (0.0023s)
2992== 20150528101611 BuildsDropIndexRepositoryIdAndEventTypeAndStateAndBranch: migrating
2993-- execute("DROP INDEX CONCURRENTLY index_builds_on_repository_id_and_event_type_and_state_and_bran")
2994 -> 0.0021s
2995== 20150528101611 BuildsDropIndexRepositoryIdAndEventTypeAndStateAndBranch: migrated (0.0021s)
2997== 20150609175200 AddCancelationColumnsToSubscriptions: migrating =============
2998-- change_table(:subscriptions)
2999 -> 0.0012s
3000== 20150609175200 AddCancelationColumnsToSubscriptions: migrated (0.0012s) ====
3002== 20150610143500 JobsAddIndexOwnerId: migrating ==============================
3003-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_owner_id ON jobs (owner_id)")
3004 -> 0.0039s
3005== 20150610143500 JobsAddIndexOwnerId: migrated (0.0039s) =====================
3007== 20150610143501 JobsAddIndexOwnerType: migrating ============================
3008-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_owner_type ON jobs (owner_type)")
3009 -> 0.0037s
3010== 20150610143501 JobsAddIndexOwnerType: migrated (0.0037s) ===================
3012== 20150610143502 JobsAddIndexSourceId: migrating =============================
3013-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_source_id ON jobs (source_id)")
3014 -> 0.0035s
3015== 20150610143502 JobsAddIndexSourceId: migrated (0.0036s) ====================
3017== 20150610143503 JobsAddIndexSourceType: migrating ===========================
3018-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_source_type ON jobs (source_type)")
3019 -> 0.0033s
3020== 20150610143503 JobsAddIndexSourceType: migrated (0.0033s) ==================
3022== 20150610143504 JobsAddIndexType: migrating =================================
3023-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_type ON jobs (type)")
3024 -> 0.0175s
3025== 20150610143504 JobsAddIndexType: migrated (0.0176s) ========================
3027== 20150610143505 JobsDropIndexOwnerIdAndOwnerTypeAndState: migrating =========
3028-- execute("DROP INDEX CONCURRENTLY index_jobs_on_owner_id_and_owner_type_and_state")
3029 -> 0.0025s
3030== 20150610143505 JobsDropIndexOwnerIdAndOwnerTypeAndState: migrated (0.0025s)
3032== 20150610143506 JobsDropIndexStateOwnerTypeOwnerId: migrating ===============
3033-- execute("DROP INDEX CONCURRENTLY index_jobs_on_state_owner_type_owner_id")
3034 -> 0.0025s
3035== 20150610143506 JobsDropIndexStateOwnerTypeOwnerId: migrated (0.0026s) ======
3037== 20150610143507 JobsDropIndexTypeAndSourceIdAndSourceType: migrating ========
3038-- index_exists?(:jobs, :index_jobs_on_type_and_owner_id_and_owner_type, {:name=>"index_jobs_on_index_jobs_on_type_and_owner_id_and_owner_type"})
3039 -> 0.0056s
3040== 20150610143507 JobsDropIndexTypeAndSourceIdAndSourceType: migrated (0.0056s)
3042== 20150610143508 JobsAddIndexState: migrating ================================
3043-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_state ON jobs (state)")
3044 -> 0.0047s
3045== 20150610143508 JobsAddIndexState: migrated (0.0047s) =======================
3047== 20150610143509 JobsAddIndexQueue: migrating ================================
3048-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_queue ON jobs (queue)")
3049 -> 0.0043s
3050== 20150610143509 JobsAddIndexQueue: migrated (0.0043s) =======================
3052== 20150610143510 TokensAddIndexUserId: migrating =============================
3053-- execute("CREATE INDEX CONCURRENTLY index_tokens_on_user_id ON tokens (user_id)")
3054 -> 0.0038s
3055== 20150610143510 TokensAddIndexUserId: migrated (0.0039s) ====================
3057== 20150615103059 AddStatusToSubscriptions: migrating =========================
3058-- add_column(:subscriptions, :status, :string)
3059 -> 0.0011s
3060== 20150615103059 AddStatusToSubscriptions: migrated (0.0012s) ================
3062== 20150629231300 ReposAddInvalidatedAt: migrating ============================
3063-- add_column(:repositories, :invalidated_at, :timestamp, {:precision=>nil})
3064 -> 0.0011s
3065== 20150629231300 ReposAddInvalidatedAt: migrated (0.0012s) ===================
3067== 20150923131400 BroadcastsAddCategory: migrating ============================
3068-- add_column(:broadcasts, :category, :string)
3069 -> 0.0009s
3070== 20150923131400 BroadcastsAddCategory: migrated (0.0010s) ===================
3072== 20151112153500 CreateStars: migrating ======================================
3073-- create_table(:stars, {:id=>:integer})
3074 -> 0.0105s
3075-- add_index(:stars, :user_id)
3076 -> 0.0025s
3077== 20151112153500 CreateStars: migrated (0.0134s) =============================
3079== 20151113111400 StarsAddIndexUserIdAndRepositoryId: migrating ===============
3080-- execute("CREATE UNIQUE INDEX index_stars_on_user_id_and_repository_id ON stars (user_id, repository_id)")
3081 -> 0.0030s
3082== 20151113111400 StarsAddIndexUserIdAndRepositoryId: migrated (0.0032s) ======
3084== 20151127153500 UsersAddIndexGithubOauthToken: migrating ====================
3085-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_users_on_github_oauth_token ON users (github_oauth_token)")
3086 -> 0.0042s
3087== 20151127153500 UsersAddIndexGithubOauthToken: migrated (0.0044s) ===========
3089== 20151127154200 AnnotationsAddIndexJobId: migrating =========================
3090-- execute("CREATE INDEX CONCURRENTLY index_annotations_on_job_id ON annotations (job_id)")
3091 -> 0.0038s
3092== 20151127154200 AnnotationsAddIndexJobId: migrated (0.0040s) ================
3094== 20151127154600 BroadcastsAddIndexRecipientIdAndRecipientType: migrating ====
3095-- execute("CREATE INDEX CONCURRENTLY index_broadcasts_on_recipient_id_and_recipient_type ON broadcasts (recipient_id, recipient_type)")
3096 -> 0.0037s
3097== 20151127154600 BroadcastsAddIndexRecipientIdAndRecipientType: migrated (0.0037s)
3099== 20151202122200 UsersAddFirstLoggedInAt: migrating ==========================
3100-- add_column(:users, :first_logged_in_at, :timestamp, {:precision=>nil})
3101 -> 0.0007s
3102== 20151202122200 UsersAddFirstLoggedInAt: migrated (0.0007s) =================
3104== 20160107120927 AddCronTable: migrating =====================================
3105-- create_table(:crons, {:id=>:integer})
3106 -> 0.0063s
3107== 20160107120927 AddCronTable: migrated (0.0065s) ============================
3109== 20160303165750 AddDebugOptionsToJobs: migrating ============================
3110-- add_column(:jobs, :debug_options, :text)
3111 -> 0.0008s
3112== 20160303165750 AddDebugOptionsToJobs: migrated (0.0008s) ===================
3114== 20160412113020 BuildsDropIndexOwnerType: migrating =========================
3115-- execute("DROP INDEX CONCURRENTLY index_builds_on_owner_type")
3116 -> 0.0020s
3117== 20160412113020 BuildsDropIndexOwnerType: migrated (0.0021s) ================
3119== 20160412113070 RepositoriesDropIndexLastBuildStartedAt: migrating ==========
3120-- execute("DROP INDEX CONCURRENTLY index_repositories_on_last_build_started_at")
3121 -> 0.0028s
3122== 20160412113070 RepositoriesDropIndexLastBuildStartedAt: migrated (0.0028s) =
3124== 20160412121405 JobsDropIndexType: migrating ================================
3125-- execute("DROP INDEX CONCURRENTLY index_jobs_on_type")
3126 -> 0.0021s
3127== 20160412121405 JobsDropIndexType: migrated (0.0022s) =======================
3129== 20160412123900 JobsDropIndexSourceType: migrating ==========================
3130-- execute("DROP INDEX CONCURRENTLY index_jobs_on_source_type")
3131 -> 0.0020s
3132== 20160412123900 JobsDropIndexSourceType: migrated (0.0021s) =================
3134== 20160414214442 JobsAddIndexQueuedAt: migrating =============================
3135-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_queued_at ON jobs (queued_at)")
3136 -> 0.0037s
3137== 20160414214442 JobsAddIndexQueuedAt: migrated (0.0038s) ====================
3139== 20160422104300 BuildsAddIndexNumber: migrating =============================
3140-- execute("CREATE INDEX CONCURRENTLY index_builds_on_number ON builds (number)")
3141 -> 0.0036s
3142== 20160422104300 BuildsAddIndexNumber: migrated (0.0037s) ====================
3144== 20160422121400 BuildsAddIndexRepositoryIdAndNumberAndEventType: migrating ==
3145-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id_and_number_and_event_type ON builds (repository_id, number, event_type)")
3146 -> 0.0038s
3147== 20160422121400 BuildsAddIndexRepositoryIdAndNumberAndEventType: migrated (0.0038s)
3149== 20160510142700 JobsAddIndexCreatedAt: migrating ============================
3150-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_created_at ON jobs (created_at)")
3151 -> 0.0041s
3152== 20160510142700 JobsAddIndexCreatedAt: migrated (0.0041s) ===================
3154== 20160510144200 BuildsAddPrivate: migrating =================================
3155-- change_table(:builds)
3156 -> 0.0007s
3157== 20160510144200 BuildsAddPrivate: migrated (0.0008s) ========================
3159== 20160510150300 JobsAddPrivate: migrating ===================================
3160-- change_table(:jobs)
3161 -> 0.0008s
3162== 20160510150300 JobsAddPrivate: migrated (0.0009s) ==========================
3164== 20160510150400 RequestsAddPrivate: migrating ===============================
3165-- change_table(:requests)
3166 -> 0.0007s
3167== 20160510150400 RequestsAddPrivate: migrated (0.0007s) ======================
3169== 20160513074300 AddCurrentBuildIdToRepositories: migrating ==================
3170-- add_column(:repositories, :current_build_id, :bigint)
3171 -> 0.0007s
3172-- execute("ALTER TABLE repositories ADD CONSTRAINT fk_repositories_current_build_id FOREIGN KEY (current_build_id) REFERENCES builds (id);")
3173 -> 0.0015s
3174== 20160513074300 AddCurrentBuildIdToRepositories: migrated (0.0023s) =========
3176== 20160609163600 PermissionsAddIndexUserIdAndRepositoryId: migrating =========
3177-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_permissions_on_user_id_and_repository_id ON permissions (user_id, repository_id)")
3178 -> 0.0043s
3179== 20160609163600 PermissionsAddIndexUserIdAndRepositoryId: migrated (0.0044s)
3181== 20160623133900 CreatePreviousJobStates: migrating ==========================
3182-- create_table(:previous_job_states, {:id=>:integer})
3183 -> 0.0054s
3184-- add_column(:jobs, :previous_job_state_id, :bigint)
3185 -> 0.0005s
3186== 20160623133900 CreatePreviousJobStates: migrated (0.0060s) =================
3188== 20160623133901 AddPreviousStatesTriggers: migrating ========================
3189-- execute(" CREATE FUNCTION save_state_change() RETURNS trigger AS $$\n DECLARE\n previous_job_state_id BIGINT;\n BEGIN\n if TG_OP='UPDATE' then\n UPDATE previous_job_states SET ended_at = NOW() WHERE id = OLD.previous_job_state_id;\n end if;\n\n INSERT INTO previous_job_states (job_id, set_at, state) VALUES(NEW.id, NOW(), NEW.state)\n RETURNING id INTO previous_job_state_id;\n NEW.previous_job_state_id = previous_job_state_id;\n\n RETURN NEW;\n END;\n $$ LANGUAGE plpgsql;\n\n CREATE TRIGGER save_state_change_on_update\n BEFORE UPDATE on jobs\n FOR EACH ROW\n WHEN (OLD.state IS DISTINCT FROM NEW.state)\n EXECUTE PROCEDURE save_state_change();\n\n CREATE TRIGGER save_state_change_on_insert\n BEFORE INSERT on jobs\n FOR EACH ROW\n EXECUTE PROCEDURE save_state_change();\n")
3190 -> 0.0131s
3191== 20160623133901 AddPreviousStatesTriggers: migrated (0.0133s) ===============
3193== 20160712125400 RevertPreviousJobStates: migrating ==========================
3194-- execute(" DROP TRIGGER IF EXISTS save_state_change_on_update on jobs;\n DROP TRIGGER IF EXISTS save_state_change_on_insert on jobs;\n DROP FUNCTION IF EXISTS save_state_change();\n")
3195 -> 0.0017s
3196-- remove_column(:jobs, :previous_job_state_id)
3197 -> 0.0006s
3198-- drop_table(:previous_job_states)
3199 -> 0.0013s
3200== 20160712125400 RevertPreviousJobStates: migrated (0.0040s) =================
3202== 20160819103700 AddAvatarUrlToUsers: migrating ==============================
3203-- add_column(:users, :avatar_url, :string)
3204 -> 0.0011s
3205== 20160819103700 AddAvatarUrlToUsers: migrated (0.0011s) =====================
3207== 20160920220400 AddRoleToMemberships: migrating =============================
3208-- add_column(:memberships, :role, :string)
3209 -> 0.0035s
3210== 20160920220400 AddRoleToMemberships: migrated (0.0036s) ====================
3212== 20161028154600 RemoveTypeIndices: migrating ================================
3213-- execute("DROP INDEX CONCURRENTLY IF EXISTS index_requests_on_event_type")
3214 -> 0.0003s
3215-- execute("DROP INDEX CONCURRENTLY IF EXISTS index_jobs_on_owner_type")
3216 -> 0.0024s
3217== 20161028154600 RemoveTypeIndices: migrated (0.0028s) =======================
3219== 20161101000000 AddNextRunLastRunToCrons: migrating =========================
3220-- column_exists?(:crons, :next_run)
3221 -> 0.0075s
3222-- add_column(:crons, :next_run, :timestamp, {:precision=>nil})
3223 -> 0.0005s
3224-- column_exists?(:crons, :last_run)
3225 -> 0.0019s
3226-- add_column(:crons, :last_run, :timestamp, {:precision=>nil})
3227 -> 0.0005s
3228== 20161101000000 AddNextRunLastRunToCrons: migrated (0.0106s) ================
3230== 20161101000001 AddDontRunIfRecentBuildExists: migrating ====================
3231-- column_exists?(:crons, :dont_run_if_recent_build_exists)
3232 -> 0.0018s
3233-- add_column(:crons, :dont_run_if_recent_build_exists, :boolean, {:default=>false})
3234 -> 0.0009s
3235== 20161101000001 AddDontRunIfRecentBuildExists: migrated (0.0028s) ===========
3237== 20161201112200 CreateBetaFeatures: migrating ===============================
3238-- create_table(:beta_features, {:id=>:integer})
3239 -> 0.0070s
3240== 20161201112200 CreateBetaFeatures: migrated (0.0071s) ======================
3242== 20161201112600 CreateUserBetaFeatures: migrating ===========================
3243-- create_table(:user_beta_features, {:id=>:integer})
3244 -> 0.0047s
3245-- add_index(:user_beta_features, [:user_id, :beta_feature_id])
3246 -> 0.0027s
3247== 20161201112600 CreateUserBetaFeatures: migrated (0.0076s) ==================
3249== 20161202000000 RemoveDisableByBuildFromCrons: migrating ====================
3250-- remove_column(:crons, :disable_by_build)
3251 -> 0.0012s
3252== 20161202000000 RemoveDisableByBuildFromCrons: migrated (0.0013s) ===========
3254== 20161206155800 AddBillingAdminOnlyToOrganizations: migrating ===============
3255-- add_column(:organizations, :billing_admin_only, :boolean)
3256 -> 0.0021s
3257== 20161206155800 AddBillingAdminOnlyToOrganizations: migrated (0.0025s) ======
3259== 20161221171300 BuildsAddIndexRepositoryIdAndNumber: migrating ==============
3260-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id_and_number ON builds(repository_id, (number::integer))")
3261 -> 0.0042s
3262== 20161221171300 BuildsAddIndexRepositoryIdAndNumber: migrated (0.0042s) =====
3264== 20170211000000 JobsAddStageNumber: migrating ===============================
3265-- add_column(:jobs, :stage_number, :string)
3266 -> 0.0021s
3267== 20170211000000 JobsAddStageNumber: migrated (0.0024s) ======================
3269== 20170211000001 JobsAddStageId: migrating ===================================
3270-- change_table(:jobs)
3271 -> 0.0008s
3272== 20170211000001 JobsAddStageId: migrated (0.0008s) ==========================
3274== 20170211000002 StagesCreate: migrating =====================================
3275-- create_table(:stages, {:id=>:integer})
3276 -> 0.0053s
3277== 20170211000002 StagesCreate: migrated (0.0054s) ============================
3279== 20170211000003 StagesAddStateAndTimestamps: migrating ======================
3280-- change_table(:stages)
3281 -> 0.0016s
3282== 20170211000003 StagesAddStateAndTimestamps: migrated (0.0016s) =============
3284== 20170213124000 AddConstraintForOwnerIdToSubscriptions: migrating ===========
3285-- execute("CREATE UNIQUE INDEX subscriptions_owner ON subscriptions (owner_id, owner_type) WHERE (status = 'subscribed');")
3286 -> 0.0025s
3287== 20170213124000 AddConstraintForOwnerIdToSubscriptions: migrated (0.0025s) ==
3289== 20170316000000 QueueableJobsCreate: migrating ==============================
3290-- create_table(:queueable_jobs, {:id=>:integer})
3291 -> 0.0031s
3292== 20170316000000 QueueableJobsCreate: migrated (0.0031s) =====================
3294== 20170316000001 QueueableJobsIndexJobId: migrating ==========================
3295-- add_index(:queueable_jobs, :job_id, {:algorithm=>:concurrently})
3296 -> 0.0035s
3297== 20170316000001 QueueableJobsIndexJobId: migrated (0.0035s) =================
3299== 20170318000000 PullRequestsCreate: migrating ===============================
3300-- create_table(:pull_requests, {:id=>:integer})
3301 -> 0.0050s
3302== 20170318000000 PullRequestsCreate: migrated (0.0051s) ======================
3304== 20170318000001 RequestsAddPullRequestId: migrating =========================
3305-- change_table(:requests)
3306 -> 0.0008s
3307== 20170318000001 RequestsAddPullRequestId: migrated (0.0008s) ================
3309== 20170318000002 BuildsAddPullRequestId: migrating ===========================
3310-- change_table(:builds)
3311 -> 0.0007s
3312== 20170318000002 BuildsAddPullRequestId: migrated (0.0007s) ==================
3314== 20170322000000 AddIndexOnRequestsRepositoryIdAndIdDesc: migrating ==========
3315-- execute("CREATE INDEX CONCURRENTLY index_requests_on_repository_id_and_id_desc ON requests (repository_id, id DESC);")
3316 -> 0.0039s
3317== 20170322000000 AddIndexOnRequestsRepositoryIdAndIdDesc: migrated (0.0040s) =
3319== 20170331000000 AddIndexRepositoryIdOnPullRequests: migrating ===============
3320-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_pull_requests_on_repository_id_and_number ON pull_requests (repository_id, (number::integer));")
3321 -> 0.0038s
3322== 20170331000000 AddIndexRepositoryIdOnPullRequests: migrated (0.0038s) ======
3324== 20170401000000 OwnerGroupsCreate: migrating ================================
3325-- create_table(:owner_groups, {:id=>:integer})
3326 -> 0.0051s
3327== 20170401000000 OwnerGroupsCreate: migrated (0.0051s) =======================
3329== 20170401000001 OwnerGroupsIndexOwnerIdOwnerType: migrating =================
3330-- execute("CREATE INDEX CONCURRENTLY index_owner_groups_on_owner_type_and_owner_id ON owner_groups (owner_type, owner_id);")
3331 -> 0.0038s
3332== 20170401000001 OwnerGroupsIndexOwnerIdOwnerType: migrated (0.0038s) ========
3334== 20170401000002 OwnerGroupsIndexUuid: migrating =============================
3335-- execute("CREATE INDEX CONCURRENTLY index_owner_groups_on_uuid ON owner_groups (uuid);")
3336 -> 0.0039s
3337== 20170401000002 OwnerGroupsIndexUuid: migrated (0.0040s) ====================
3339== 20170405000000 TagsCreate: migrating =======================================
3340-- create_table(:tags, {:id=>:integer})
3341 -> 0.0050s
3342== 20170405000000 TagsCreate: migrated (0.0050s) ==============================
3344== 20170405000001 RequestsAddBranchIdAndTagId: migrating ======================
3345-- change_table(:requests)
3346 -> 0.0136s
3347== 20170405000001 RequestsAddBranchIdAndTagId: migrated (0.0138s) =============
3349== 20170405000002 CommitsAddBranchIdAndTagId: migrating =======================
3350-- change_table(:commits)
3351 -> 0.0024s
3352== 20170405000002 CommitsAddBranchIdAndTagId: migrated (0.0025s) ==============
3354== 20170405000003 BuildsAddBranchIdAndTagId: migrating ========================
3355-- change_table(:builds)
3356 -> 0.0018s
3357== 20170405000003 BuildsAddBranchIdAndTagId: migrated (0.0019s) ===============
3359== 20170408000000 RequestsAddSenderId: migrating ==============================
3360-- change_table(:requests)
3361 -> 0.0016s
3362== 20170408000000 RequestsAddSenderId: migrated (0.0017s) =====================
3364== 20170408000001 BuildsAddSenderId: migrating ================================
3365-- change_table(:builds)
3366 -> 0.0016s
3367== 20170408000001 BuildsAddSenderId: migrated (0.0017s) =======================
3369== 20170410000000 JobsIndexStageId: migrating =================================
3370-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_stage_id ON jobs (stage_id);")
3371 -> 0.0044s
3372== 20170410000000 JobsIndexStageId: migrated (0.0045s) ========================
3374== 20170411000000 TagsIndexRepoIdAndName: migrating ===========================
3375-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_tags_on_repository_id_and_name ON tags (repository_id, name);")
3376 -> 0.0041s
3377== 20170411000000 TagsIndexRepoIdAndName: migrated (0.0041s) ==================
3379== 20170419093249 AddSourceToSubscriptions: migrating =========================
3380-- execute(" CREATE TYPE source_type AS ENUM ('manual', 'stripe', 'github', 'unknown');\n")
3381 -> 0.0011s
3382-- add_column(:subscriptions, :source, :source_type, {:default=>"unknown", :null=>false})
3383 -> 0.0011s
3384== 20170419093249 AddSourceToSubscriptions: migrated (0.0024s) ================
3386== 20170531125700 AddIndexOnBuildsSenderTypeAndSenderId: migrating ============
3387-- execute("CREATE INDEX CONCURRENTLY index_builds_on_sender_type_and_sender_id ON builds (sender_type, sender_id);")
3388 -> 0.0045s
3389== 20170531125700 AddIndexOnBuildsSenderTypeAndSenderId: migrated (0.0046s) ===
3391== 20170601163700 DropIndexOnRepositoriesBuildsAndCommits: migrating ==========
3392-- execute("DROP INDEX CONCURRENTLY index_repositories_on_lower_owner_name")
3393 -> 0.0022s
3394-- execute("DROP INDEX CONCURRENTLY index_repositories_on_owner_type")
3395 -> 0.0022s
3396-- execute("DROP INDEX CONCURRENTLY index_commits_on_repository_id")
3397 -> 0.0018s
3398-- execute("DROP INDEX CONCURRENTLY index_builds_on_number")
3399 -> 0.0018s
3400== 20170601163700 DropIndexOnRepositoriesBuildsAndCommits: migrated (0.0082s) =
3402== 20170601164400 AddIndexOnBuildsAndStages: migrating ========================
3403-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id_and_branch_and_event_type_and_id ON builds (repository_id, branch, event_type, id)")
3404 -> 0.0043s
3405-- execute("CREATE INDEX CONCURRENTLY index_stages_on_build_id ON stages (build_id)")
3406 -> 0.0033s
3407== 20170601164400 AddIndexOnBuildsAndStages: migrated (0.0078s) ===============
3409== 20170609174400 DropUnusedIndexesOnJobsAndBuilds: migrating =================
3410-- execute("DROP INDEX CONCURRENTLY index_jobs_on_repository_id")
3411 -> 0.0022s
3412-- execute("DROP INDEX CONCURRENTLY index_jobs_on_queued_at")
3413 -> 0.0022s
3414-- execute("DROP INDEX CONCURRENTLY index_jobs_on_queue")
3415 -> 0.0022s
3416-- execute("DROP INDEX CONCURRENTLY index_jobs_on_owner_id")
3417 -> 0.0021s
3418-- execute("DROP INDEX CONCURRENTLY index_builds_on_branch")
3419 -> 0.0025s
3420-- execute("DROP INDEX CONCURRENTLY index_builds_on_event_type")
3421 -> 0.0023s
3422-- execute("DROP INDEX CONCURRENTLY index_builds_on_owner_id")
3423 -> 0.0023s
3424== 20170609174400 DropUnusedIndexesOnJobsAndBuilds: migrated (0.0160s) ========
3426== 20170613000000 CreateTrials: migrating =====================================
3427-- create_table(:trials, {:id=>:integer})
3428 -> 0.0076s
3429-- execute("CREATE INDEX CONCURRENTLY index_trials_on_owner ON trials(owner_id, owner_type)")
3430 -> 0.0035s
3431== 20170613000000 CreateTrials: migrated (0.0112s) ============================
3433== 20170620144500 AddIndexesOnBuildsAndJobsAndBranches: migrating =============
3434-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id_and_branch_and_id_desc ON builds (repository_id, branch, id DESC)")
3435 -> 0.0037s
3436-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_owner_id_and_owner_type_and_state ON jobs (owner_id, owner_type, state)")
3437 -> 0.0034s
3438-- execute("CREATE INDEX CONCURRENTLY index_branches_on_repository_id ON branches (repository_id)")
3439 -> 0.0033s
3440== 20170620144500 AddIndexesOnBuildsAndJobsAndBranches: migrated (0.0105s) ====
3442== 20170621142300 RemovePlansTable: migrating =================================
3443-- drop_table(:plans)
3444 -> 0.0014s
3445== 20170621142300 RemovePlansTable: migrated (0.0014s) ========================
3447== 20170713162000 AddCcLastDigitsToInvoices: migrating ========================
3448-- change_table(:invoices)
3449 -> 0.0010s
3450== 20170713162000 AddCcLastDigitsToInvoices: migrated (0.0011s) ===============
3452== 20170822171600 CreateMessages: migrating ===================================
3453-- create_table("messages", {:force=>:cascade, :id=>:integer})
3454 -> 0.0066s
3455-- execute("CREATE INDEX CONCURRENTLY index_messages_on_subject_type_and_subject_id ON messages(subject_type, subject_id)")
3456 -> 0.0037s
3457== 20170822171600 CreateMessages: migrated (0.0103s) ==========================
3459== 20170831000000 CreateTrialAllowances: migrating ============================
3460-- create_table(:trial_allowances, {:id=>:integer})
3461 -> 0.0079s
3462-- add_index(:trial_allowances, :trial_id)
3463 -> 0.0020s
3464-- add_index(:trial_allowances, [:creator_id, :creator_type])
3465 -> 0.0021s
3466== 20170831000000 CreateTrialAllowances: migrated (0.0121s) ===================
3468== 20170911172800 AddIndexOnJobsUpdatedAt: migrating ==========================
3469-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_updated_at ON jobs (updated_at)")
3470 -> 0.0034s
3471== 20170911172800 AddIndexOnJobsUpdatedAt: migrated (0.0034s) =================
3473== 20171017104500 AddConcurrencyToSubscriptions: migrating ====================
3474-- change_table(:subscriptions)
3475 -> 0.0007s
3476== 20171017104500 AddConcurrencyToSubscriptions: migrated (0.0007s) ===========
3478== 20171024000000 AddAbuseTable: migrating ====================================
3479-- create_table(:abuses, {:id=>:integer})
3480 -> 0.0058s
3481-- execute("CREATE INDEX CONCURRENTLY index_abuses_on_owner ON abuses(owner_id)")
3482 -> 0.0033s
3483== 20171024000000 AddAbuseTable: migrated (0.0092s) ===========================
3485== 20171025000000 AddUpdatedAtTriggerToBuildsAndJobs: migrating ===============
3486-- execute(" CREATE FUNCTION set_updated_at() RETURNS trigger AS $$\n BEGIN\n IF TG_OP = 'INSERT' OR\n (TG_OP = 'UPDATE' AND NEW.* IS DISTINCT FROM OLD.*) THEN\n NEW.updated_at := statement_timestamp();\n END IF;\n RETURN NEW;\n END;\n $$ LANGUAGE plpgsql;\n\n CREATE TRIGGER set_updated_at_on_builds\n BEFORE INSERT OR UPDATE ON builds\n FOR EACH ROW\n EXECUTE PROCEDURE set_updated_at();\n\n CREATE TRIGGER set_updated_at_on_jobs\n BEFORE INSERT OR UPDATE ON jobs\n FOR EACH ROW\n EXECUTE PROCEDURE set_updated_at();\n")
3487 -> 0.0008s
3488== 20171025000000 AddUpdatedAtTriggerToBuildsAndJobs: migrated (0.0009s) ======
3490== 20171103000000 UpdateIndexOnAbuses: migrating ==============================
3491-- index_exists?(:abuses, :owner, {:name=>"index_abuses_on_owner"})
3492 -> 0.0015s
3493-- index_exists?(:abuses, [:owner_id, :owner_type, :level], {:name=>"index_abuses_on_owner_id_and_owner_type_and_level"})
3494 -> 0.0012s
3495-- add_index(:abuses, [:owner_id, :owner_type, :level], {:unique=>true, :algorithm=>:concurrently})
3496 -> 0.0047s
3497== 20171103000000 UpdateIndexOnAbuses: migrated (0.0075s) =====================
3499== 20171211000000 AddRepositoryIdBranchEventTypeIndexOnBuilds: migrating ======
3500-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id_and_branch_and_event_type ON builds (repository_id, branch, event_type) WHERE state IN ('created', 'queued', 'received')")
3501 -> 0.0042s
3502== 20171211000000 AddRepositoryIdBranchEventTypeIndexOnBuilds: migrated (0.0043s)
3504== 20180212000000 UsersAddSuspended: migrating ================================
3505-- add_column(:users, :suspended, :boolean, {:default=>false})
3506 -> 0.0015s
3507== 20180212000000 UsersAddSuspended: migrated (0.0015s) =======================
3509== 20180213000000 UsersAddSuspendedAt: migrating ==============================
3510-- add_column(:users, :suspended_at, :timestamp, {:precision=>nil})
3511 -> 0.0008s
3512== 20180213000000 UsersAddSuspendedAt: migrated (0.0009s) =====================
3514== 20180222000000 AddComIdAndOrgId: migrating =================================
3515-- add_column(:branches, :org_id, :integer)
3516 -> 0.0008s
3517-- add_column(:builds, :org_id, :integer)
3518 -> 0.0005s
3519-- add_column(:commits, :org_id, :integer)
3520 -> 0.0005s
3521-- add_column(:crons, :org_id, :integer)
3522 -> 0.0005s
3523-- add_column(:jobs, :org_id, :integer)
3524 -> 0.0005s
3525-- add_column(:organizations, :org_id, :integer)
3526 -> 0.0005s
3527-- add_column(:permissions, :org_id, :integer)
3528 -> 0.0005s
3529-- add_column(:pull_requests, :org_id, :integer)
3530 -> 0.0004s
3531-- add_column(:repositories, :org_id, :integer)
3532 -> 0.0005s
3533-- add_column(:requests, :org_id, :integer)
3534 -> 0.0004s
3535-- add_column(:ssl_keys, :org_id, :integer)
3536 -> 0.0006s
3537-- add_column(:stages, :org_id, :integer)
3538 -> 0.0006s
3539-- add_column(:tags, :org_id, :integer)
3540 -> 0.0005s
3541-- add_column(:users, :org_id, :integer)
3542 -> 0.0006s
3543-- add_column(:branches, :com_id, :integer)
3544 -> 0.0005s
3545-- add_column(:builds, :com_id, :integer)
3546 -> 0.0006s
3547-- add_column(:commits, :com_id, :integer)
3548 -> 0.0005s
3549-- add_column(:crons, :com_id, :integer)
3550 -> 0.0005s
3551-- add_column(:jobs, :com_id, :integer)
3552 -> 0.0005s
3553-- add_column(:organizations, :com_id, :integer)
3554 -> 0.0005s
3555-- add_column(:permissions, :com_id, :integer)
3556 -> 0.0005s
3557-- add_column(:pull_requests, :com_id, :integer)
3558 -> 0.0005s
3559-- add_column(:repositories, :com_id, :integer)
3560 -> 0.0006s
3561-- add_column(:requests, :com_id, :integer)
3562 -> 0.0006s
3563-- add_column(:ssl_keys, :com_id, :integer)
3564 -> 0.0005s
3565-- add_column(:stages, :com_id, :integer)
3566 -> 0.0004s
3567-- add_column(:tags, :com_id, :integer)
3568 -> 0.0004s
3569-- add_column(:users, :com_id, :integer)
3570 -> 0.0004s
3571== 20180222000000 AddComIdAndOrgId: migrated (0.0151s) ========================
3573== 20180222000001 AddComIdAndOrgIdIndices: migrating ==========================
3574-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_branches_on_org_id ON branches USING btree (org_id)")
3575 -> 0.0044s
3576-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_builds_on_org_id ON builds USING btree (org_id)")
3577 -> 0.0040s
3578-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_jobs_on_org_id ON jobs USING btree (org_id)")
3579 -> 0.0046s
3580-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_commits_on_org_id ON commits USING btree (org_id)")
3581 -> 0.0039s
3582-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_crons_on_org_id ON crons USING btree (org_id)")
3583 -> 0.0038s
3584-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_organizations_on_org_id ON organizations USING btree (org_id)")
3585 -> 0.0040s
3586-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_permissions_on_org_id ON permissions USING btree (org_id)")
3587 -> 0.0037s
3588-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_pull_requests_on_org_id ON pull_requests USING btree (org_id)")
3589 -> 0.0037s
3590-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_repositories_on_org_id ON repositories USING btree (org_id)")
3591 -> 0.0038s
3592-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_requests_on_org_id ON requests USING btree (org_id)")
3593 -> 0.0041s
3594-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_ssl_keys_on_org_id ON ssl_keys USING btree (org_id)")
3595 -> 0.0038s
3596-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_stages_on_org_id ON stages USING btree (org_id)")
3597 -> 0.0036s
3598-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_tags_on_org_id ON tags USING btree (org_id)")
3599 -> 0.0035s
3600-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_users_on_org_id ON users USING btree (org_id)")
3601 -> 0.0041s
3602-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_branches_on_com_id ON branches USING btree (com_id)")
3603 -> 0.0033s
3604-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_builds_on_com_id ON builds USING btree (com_id)")
3605 -> 0.0037s
3606-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_jobs_on_com_id ON jobs USING btree (com_id)")
3607 -> 0.0037s
3608-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_commits_on_com_id ON commits USING btree (com_id)")
3609 -> 0.0038s
3610-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_crons_on_com_id ON crons USING btree (com_id)")
3611 -> 0.0034s
3612-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_organizations_on_com_id ON organizations USING btree (com_id)")
3613 -> 0.0034s
3614-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_permissions_on_com_id ON permissions USING btree (com_id)")
3615 -> 0.0034s
3616-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_pull_requests_on_com_id ON pull_requests USING btree (com_id)")
3617 -> 0.0030s
3618-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_repositories_on_com_id ON repositories USING btree (com_id)")
3619 -> 0.0033s
3620-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_requests_on_com_id ON requests USING btree (com_id)")
3621 -> 0.0034s
3622-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_ssl_keys_on_com_id ON ssl_keys USING btree (com_id)")
3623 -> 0.0034s
3624-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_stages_on_com_id ON stages USING btree (com_id)")
3625 -> 0.0034s
3626-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_tags_on_com_id ON tags USING btree (com_id)")
3627 -> 0.0033s
3628-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_users_on_com_id ON users USING btree (com_id)")
3629 -> 0.0038s
3630== 20180222000001 AddComIdAndOrgIdIndices: migrated (0.1048s) =================
3632== 20180222000002 AddMigrating: migrating =====================================
3633-- add_column(:repositories, :migrating, :boolean)
3634 -> 0.0007s
3635-- add_column(:repositories, :migrated_at, :timestamp, {:precision=>nil})
3636 -> 0.0004s
3637-- add_column(:organizations, :migrating, :boolean)
3638 -> 0.0004s
3639-- add_column(:organizations, :migrated_at, :timestamp, {:precision=>nil})
3640 -> 0.0004s
3641-- add_column(:users, :migrating, :boolean)
3642 -> 0.0004s
3643-- add_column(:users, :migrated_at, :timestamp, {:precision=>nil})
3644 -> 0.0004s
3645== 20180222000002 AddMigrating: migrated (0.0027s) ============================
3647== 20180222000003 DropFkRepositoriesCurrentBuildId: migrating =================
3648-- execute("ALTER TABLE repositories DROP CONSTRAINT fk_repositories_current_build_id")
3649 -> 0.0008s
3650== 20180222000003 DropFkRepositoriesCurrentBuildId: migrated (0.0008s) ========
3652== 20180222000009 CreateRepoCounts: migrating =================================
3653-- create_table(:repo_counts, {:id=>false})
3654 -> 0.0031s
3655-- add_index(:repo_counts, :repository_id)
3656 -> 0.0019s
3657== 20180222000009 CreateRepoCounts: migrated (0.0051s) ========================
3659== 20180222000012 CreateRepoCountsTriggers: migrating =========================
3660-- execute("create or replace function count_requests() returns trigger as $$\ndeclare\n c text;\n r record;\nbegin\n if tg_argv[0]::int > 0 then r := new; else r := old; end if;\n if r.repository_id is not null then\n insert into repo_counts(repository_id, requests)\n values(r.repository_id, tg_argv[0]::int);\n end if;\n return r;\nexception when others then\n get stacked diagnostics c = pg_exception_context;\n raise warning '% context: %s', sqlerrm, c;\n return r;\nend;\n$$\nlanguage plpgsql;\ndrop trigger if exists trg_count_request_inserted on requests;\ncreate trigger trg_count_request_inserted after insert on requests\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_requests(1);\ndrop trigger if exists trg_count_request_deleted on requests;\ncreate trigger trg_count_request_deleted after delete on requests\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_requests('-1');\n\ncreate or replace function count_commits() returns trigger as $$\ndeclare\n c text;\n r record;\nbegin\n if tg_argv[0]::int > 0 then r := new; else r := old; end if;\n if r.repository_id is not null then\n insert into repo_counts(repository_id, commits)\n values(r.repository_id, tg_argv[0]::int);\n end if;\n return r;\nexception when others then\n get stacked diagnostics c = pg_exception_context;\n raise warning '% context: %s', sqlerrm, c;\n return r;\nend;\n$$\nlanguage plpgsql;\ndrop trigger if exists trg_count_commit_inserted on commits;\ncreate trigger trg_count_commit_inserted after insert on commits\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_commits(1);\ndrop trigger if exists trg_count_commit_deleted on commits;\ncreate trigger trg_count_commit_deleted after delete on commits\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_commits('-1');\n\ncreate or replace function count_branches() returns trigger as $$\ndeclare\n c text;\n r record;\nbegin\n if tg_argv[0]::int > 0 then r := new; else r := old; end if;\n if r.repository_id is not null then\n insert into repo_counts(repository_id, branches)\n values(r.repository_id, tg_argv[0]::int);\n end if;\n return r;\nexception when others then\n get stacked diagnostics c = pg_exception_context;\n raise warning '% context: %s', sqlerrm, c;\n return r;\nend;\n$$\nlanguage plpgsql;\ndrop trigger if exists trg_count_branch_inserted on branches;\ncreate trigger trg_count_branch_inserted after insert on branches\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_branches(1);\ndrop trigger if exists trg_count_branch_deleted on branches;\ncreate trigger trg_count_branch_deleted after delete on branches\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_branches('-1');\n\ncreate or replace function count_pull_requests() returns trigger as $$\ndeclare\n c text;\n r record;\nbegin\n if tg_argv[0]::int > 0 then r := new; else r := old; end if;\n if r.repository_id is not null then\n insert into repo_counts(repository_id, pull_requests)\n values(r.repository_id, tg_argv[0]::int);\n end if;\n return r;\nexception when others then\n get stacked diagnostics c = pg_exception_context;\n raise warning '% context: %s', sqlerrm, c;\n return r;\nend;\n$$\nlanguage plpgsql;\ndrop trigger if exists trg_count_pull_request_inserted on pull_requests;\ncreate trigger trg_count_pull_request_inserted after insert on pull_requests\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_pull_requests(1);\ndrop trigger if exists trg_count_pull_request_deleted on pull_requests;\ncreate trigger trg_count_pull_request_deleted after delete on pull_requests\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_pull_requests('-1');\n\ncreate or replace function count_tags() returns trigger as $$\ndeclare\n c text;\n r record;\nbegin\n if tg_argv[0]::int > 0 then r := new; else r := old; end if;\n if r.repository_id is not null is not null then\n insert into repo_counts(repository_id, tags)\n values(r.repository_id, tg_argv[0]::int);\n end if;\n return r;\nexception when others then\n get stacked diagnostics c = pg_exception_context;\n raise warning '% context: %s', sqlerrm, c;\n return r;\nend;\n$$\nlanguage plpgsql;\ndrop trigger if exists trg_count_tag_inserted on tags;\ncreate trigger trg_count_tag_inserted after insert on tags\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_tags(1);\ndrop trigger if exists trg_count_tag_deleted on tags;\ncreate trigger trg_count_tag_deleted after delete on tags\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_tags('-1');\n\ncreate or replace function count_builds() returns trigger as $$\ndeclare\n c text;\n r record;\nbegin\n if tg_argv[0]::int > 0 then r := new; else r := old; end if;\n if r.repository_id is not null then\n insert into repo_counts(repository_id, builds)\n values(r.repository_id, tg_argv[0]::int);\n end if;\n return r;\nexception when others then\n get stacked diagnostics c = pg_exception_context;\n raise warning '% context: %s', sqlerrm, c;\n return r;\nend;\n$$\nlanguage plpgsql;\ndrop trigger if exists trg_count_build_inserted on builds;\ncreate trigger trg_count_build_inserted after insert on builds\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_builds(1);\ndrop trigger if exists trg_count_build_deleted on builds;\ncreate trigger trg_count_build_deleted after delete on builds\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_builds('-1');\n\n-- -- todo stages really should have a repository_id\n-- create or replace function count_stages() returns trigger as $$\n-- declare\n-- c text;\n-- r record;\n-- build record;\n-- begin\n-- if tg_argv[0]::int > 0 then r := new; else r := old; end if;\n-- select repository_id from builds as b where b.id = r.build_id into build;\n-- if build.repository_id is not null then\n-- insert into repo_counts(repository_id, stages)\n-- values(build.repository_id, tg_argv[0]::int);\n-- end if;\n-- return r;\n-- exception when others then\n-- get stacked diagnostics c = pg_exception_context;\n-- raise warning '% context: %s', sqlerrm, c;\n-- return r;\n-- end;\n-- $$\n-- language plpgsql;\n-- drop trigger if exists trg_count_stage_inserted on stages;\n-- create trigger trg_count_stage_inserted after insert on stages\n-- for each row when (now() > '2018-01-01 00:00:00') execute procedure count_stages(1);\n-- drop trigger if exists trg_count_stage_deleted on stages;\n-- create trigger trg_count_stage_deleted after delete on stages\n-- for each row when (now() > '2018-01-01 00:00:00') execute procedure count_stages('-1');\n\ncreate or replace function count_jobs() returns trigger as $$\ndeclare\n c text;\n r record;\nbegin\n if tg_argv[0]::int > 0 then r := new; else r := old; end if;\n if r.repository_id is not null then\n insert into repo_counts(repository_id, jobs)\n values(r.repository_id, tg_argv[0]::int);\n end if;\n return r;\nexception when others then\n get stacked diagnostics c = pg_exception_context;\n raise warning '% context: %s', sqlerrm, c;\n return r;\nend;\n$$\nlanguage plpgsql;\ndrop trigger if exists trg_count_job_inserted on jobs;\ncreate trigger trg_count_job_inserted after insert on jobs\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_jobs(1);\ndrop trigger if exists trg_count_job_deleted on jobs;\ncreate trigger trg_count_job_deleted after delete on jobs\nfor each row when (now() > '2018-01-01 00:00:00') execute procedure count_jobs('-1');\n\ndrop function if exists count_requests(_start int, _end int);\ncreate or replace function count_requests(_start int, _end int)\nreturns table (repository_id int, requests bigint, range varchar) as $$\nbegin\n return query select t.repository_id, count(id) as requests, ('requests' || ':' || _start || ':' || _end)::varchar as range\n from requests as t\n where t.id between _start and _end and t.created_at <= '2018-01-01 00:00:00' and t.repository_id is not null\n group by t.repository_id;\nend;\n$$\nlanguage plpgsql;\n\ndrop function if exists count_commits(_start int, _end int);\ncreate or replace function count_commits(_start int, _end int)\nreturns table (repository_id int, commits bigint, range varchar) as $$\nbegin\n return query select r.id, count(t.id) as commits, ('commits' || ':' || _start || ':' || _end)::varchar as range\n from commits as t\n join repositories as r on t.repository_id = r.id\n where t.id between _start and _end and t.created_at <= '2018-01-01 00:00:00' and t.repository_id is not null\n group by r.id;\nend;\n$$\nlanguage plpgsql;\n\ndrop function if exists count_branches(_start int, _end int);\ncreate or replace function count_branches(_start int, _end int)\nreturns table (repository_id int, branches bigint, range varchar) as $$\nbegin\n return query select r.id, count(t.id) as branches, ('branches' || ':' || _start || ':' || _end)::varchar as range\n from branches as t\n join repositories as r on t.repository_id = r.id\n where t.id between _start and _end and t.created_at <= '2018-01-01 00:00:00' and t.repository_id is not null\n group by r.id;\nend;\n$$\nlanguage plpgsql;\n\ndrop function if exists count_pull_requests(_start int, _end int);\ncreate or replace function count_pull_requests(_start int, _end int)\nreturns table (repository_id int, pull_requests bigint, range varchar) as $$\nbegin\n return query select r.id, count(t.id) as pull_requests, ('pull_requests' || ':' || _start || ':' || _end)::varchar as range\n from pull_requests as t\n join repositories as r on t.repository_id = r.id\n where t.id between _start and _end and t.created_at <= '2018-01-01 00:00:00' and t.repository_id is not null\n group by r.id;\nend;\n$$\nlanguage plpgsql;\n\ndrop function if exists count_tags(_start int, _end int);\ncreate or replace function count_tags(_start int, _end int)\nreturns table (repository_id int, tags bigint, range varchar) as $$\nbegin\n return query select r.id, count(t.id) as tags, ('tags' || ':' || _start || ':' || _end)::varchar as range\n from tags as t\n join repositories as r on t.repository_id = r.id\n where t.id between _start and _end and t.created_at <= '2018-01-01 00:00:00' and t.repository_id is not null\n group by r.id;\nend;\n$$\nlanguage plpgsql;\n\ndrop function if exists count_builds(_start int, _end int);\ncreate or replace function count_builds(_start int, _end int)\nreturns table (repository_id int, builds bigint, range varchar) as $$\nbegin\n return query select t.repository_id, count(id) as builds, ('builds' || ':' || _start || ':' || _end)::varchar as range\n from builds as t\n where t.id between _start and _end and t.created_at <= '2018-01-01 00:00:00' and t.repository_id is not null\n group by t.repository_id;\nend;\n$$\nlanguage plpgsql;\n\n-- drop function if exists count_stages(_start int, _end int);\n-- create or replace function count_stages(_start int, _end int)\n-- returns table (repository_id int, stages bigint, range varchar) as $$\n-- begin\n-- return query select b.repository_id, count(t.id) as stages, ('stages' || ':' || _start || ':' || _end)::varchar as range\n-- from stages as t\n-- join builds as b on t.build_id = b.id\n-- where t.id between _start and _end and b.created_at <= '2018-01-01 00:00:00' and b.repository_id is not null\n-- group by b.repository_id;\n-- end;\n-- $$\n-- language plpgsql;\n\ndrop function if exists count_jobs(_start int, _end int);\ncreate or replace function count_jobs(_start int, _end int)\nreturns table (repository_id int, jobs bigint, range varchar) as $$\nbegin\n return query select t.repository_id, count(id) as jobs, ('jobs' || ':' || _start || ':' || _end)::varchar as range\n from jobs as t\n where t.id between _start and _end and t.created_at <= '2018-01-01 00:00:00' and t.repository_id is not null\n group by t.repository_id;\nend;\n$$\nlanguage plpgsql;\n\ndrop function if exists count_all_requests(_count int, _start int, _end int);\ncreate or replace function count_all_requests(_count int, _start int, _end int) returns boolean as $$\ndeclare max int;\nbegin\n select id + _count from requests order by id desc limit 1 into max;\n for i in _start.._end by _count loop\n if i > max then exit; end if;\n begin\n raise notice 'counting requests %', i;\n insert into repo_counts(repository_id, requests, range)\n select * from count_requests(i, i + _count - 1);\n exception when unique_violation then end;\n end loop;\n\n return true;\nend\n$$\nlanguage plpgsql;\n\ndrop function if exists count_all_commits(_count int, _start int, _end int);\ncreate or replace function count_all_commits(_count int, _start int, _end int) returns boolean as $$\ndeclare max int;\nbegin\n select id + _count from commits order by id desc limit 1 into max;\n\n for i in _start.._end by _count loop\n if i > max then exit; end if;\n begin\n raise notice 'counting commits %', i;\n insert into repo_counts(repository_id, commits, range)\n select * from count_commits(i, i + _count - 1);\n exception when unique_violation then end;\n end loop;\n\n return true;\nend\n$$\nlanguage plpgsql;\n\ndrop function if exists count_all_branches(_count int, _start int, _end int);\ncreate or replace function count_all_branches(_count int, _start int, _end int) returns boolean as $$\ndeclare max int;\nbegin\n select id + _count from branches order by id desc limit 1 into max;\n\n for i in _start.._end by _count loop\n if i > max then exit; end if;\n begin\n raise notice 'counting branches %', i;\n insert into repo_counts(repository_id, branches, range)\n select * from count_branches(i, i + _count - 1);\n exception when unique_violation then end;\n end loop;\n\n return true;\nend\n$$\nlanguage plpgsql;\n\ndrop function if exists count_all_pull_requests(_count int, _start int, _end int);\ncreate or replace function count_all_pull_requests(_count int, _start int, _end int) returns boolean as $$\ndeclare max int;\nbegin\n select id + _count from pull_requests order by id desc limit 1 into max;\n\n for i in _start.._end by _count loop\n if i > max then exit; end if;\n begin\n raise notice 'counting pull_requests %', i;\n insert into repo_counts(repository_id, pull_requests, range)\n select * from count_pull_requests(i, i + _count - 1);\n exception when unique_violation then end;\n end loop;\n\n return true;\nend\n$$\nlanguage plpgsql;\n\ndrop function if exists count_all_tags(_count int, _start int, _end int);\ncreate or replace function count_all_tags(_count int, _start int, _end int) returns boolean as $$\ndeclare max int;\nbegin\n select id + _count from tags order by id desc limit 1 into max;\n\n for i in _start.._end by _count loop\n if i > max then exit; end if;\n begin\n raise notice 'counting tags %', i;\n insert into repo_counts(repository_id, tags, range)\n select * from count_tags(i, i + _count - 1);\n exception when unique_violation then end;\n end loop;\n\n return true;\nend\n$$\nlanguage plpgsql;\n\ndrop function if exists count_all_builds(_count int, _start int, _end int);\ncreate or replace function count_all_builds(_count int, _start int, _end int) returns boolean as $$\ndeclare max int;\nbegin\n select id + _count from builds order by id desc limit 1 into max;\n\n for i in _start.._end by _count loop\n if i > max then exit; end if;\n begin\n raise notice 'counting builds %', i;\n insert into repo_counts(repository_id, builds, range)\n select * from count_builds(i, i + _count - 1);\n exception when unique_violation then end;\n end loop;\n\n return true;\nend\n$$\nlanguage plpgsql;\n\n-- drop function if exists count_all_stages(_count int, _start int, _end int);\n-- create or replace function count_all_stages(_count int, _start int, _end int) returns boolean as $$\n-- declare max int;\n-- begin\n-- select id + _count from stages order by id desc limit 1 into max;\n--\n-- for i in _start.._end by _count loop\n-- if i > max then exit; end if;\n-- begin\n-- raise notice 'counting stages %', i;\n-- insert into repo_counts(repository_id, stages, range)\n-- select * from count_stages(i, i + _count - 1);\n-- exception when unique_violation then end;\n-- end loop;\n--\n-- return true;\n-- end\n-- $$\n-- language plpgsql;\n\ndrop function if exists count_all_jobs(_count int, _start int, _end int);\ncreate or replace function count_all_jobs(_count int, _start int, _end int) returns boolean as $$\ndeclare max int;\nbegin\n select id + _count from jobs order by id desc limit 1 into max;\n\n for i in _start.._end by _count loop\n if i > max then exit; end if;\n begin\n raise notice 'counting jobs %', i;\n insert into repo_counts(repository_id, jobs, range)\n select * from count_jobs(i, i + _count - 1);\n exception when unique_violation then end;\n end loop;\n\n return true;\nend\n$$\nlanguage plpgsql;\n\n\ncreate or replace function agg_all_repo_counts()\nreturns boolean as $$\nbegin\n with src as (\n select cnt.repository_id\n from repo_counts cnt\n group by cnt.repository_id\n having count(1) > 1\n ),\n del as (\n delete from repo_counts cnt\n using src\n where cnt.repository_id = src.repository_id\n returning cnt.*\n ),\n agg as (\n select\n del.repository_id,\n sum(del.requests)::integer as requests,\n sum(del.commits)::integer as commits,\n sum(del.branches)::integer as branches,\n sum(del.pull_requests)::integer as pull_requests,\n sum(del.tags)::integer as tags,\n sum(del.builds)::integer as builds,\n -- sum(del.stages)::integer as stages,\n sum(del.jobs)::integer as jobs\n from del\n group by del.repository_id\n )\n insert into repo_counts(\n repository_id,\n requests,\n commits,\n branches,\n pull_requests,\n tags,\n builds,\n -- stages,\n jobs\n )\n select\n agg.repository_id,\n agg.requests,\n agg.commits,\n agg.branches,\n agg.pull_requests,\n agg.tags,\n agg.builds,\n -- agg.stages,\n agg.jobs\n from agg;\n\n return true;\nend;\n$$\nlanguage plpgsql;\n\ncreate or replace function agg_repo_counts(_repo_id int)\nreturns boolean as $$\nbegin\n with src as (\n select cnt.repository_id\n from repo_counts cnt\n where cnt.repository_id = _repo_id\n group by cnt.repository_id\n having count(1) > 1\n ),\n del as (\n delete from repo_counts cnt\n using src\n where cnt.repository_id = src.repository_id\n returning cnt.*\n ),\n agg as (\n select\n del.repository_id,\n sum(del.requests)::integer as requests,\n sum(del.commits)::integer as commits,\n sum(del.branches)::integer as branches,\n sum(del.pull_requests)::integer as pull_requests,\n sum(del.tags)::integer as tags,\n sum(del.builds)::integer as builds,\n -- sum(del.stages)::integer as stages,\n sum(del.jobs)::integer as jobs\n from del\n group by del.repository_id\n )\n insert into repo_counts(\n repository_id,\n requests,\n commits,\n branches,\n pull_requests,\n tags,\n builds,\n -- stages,\n jobs\n )\n select\n agg.repository_id,\n agg.requests,\n agg.commits,\n agg.branches,\n agg.pull_requests,\n agg.tags,\n agg.builds,\n -- agg.stages,\n agg.jobs\n from agg\n where agg.requests > 0 or agg.builds > 0 or agg.jobs > 0;\n\n return true;\nend;\n$$\nlanguage plpgsql;\n")
3661 -> 0.0247s
3662== 20180222000012 CreateRepoCountsTriggers: migrated (0.0252s) ================
3664== 20180222164100 DropAnnotations: migrating ==================================
3665-- drop_table(:annotations)
3666 -> 0.0027s
3667-- drop_table(:annotation_providers)
3668 -> 0.0029s
3669== 20180222164100 DropAnnotations: migrated (0.0060s) =========================
3671== 20180305143800 IndexBuildsOnRepositoryIdWhereStateNotFinished: migrating ===
3672-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id_where_state_not_finished ON builds (repository_id) WHERE state IN ('created', 'queued', 'received', 'started');")
3673 -> 0.0054s
3674== 20180305143800 IndexBuildsOnRepositoryIdWhereStateNotFinished: migrated (0.0056s)
3676== 20180321102400 IndexJobsOnRepositoryIdWhereStateRunning: migrating =========
3677-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_repository_id_where_state_running ON jobs (repository_id) WHERE state IN ('queued', 'received', 'started')")
3678 -> 0.0042s
3679== 20180321102400 IndexJobsOnRepositoryIdWhereStateRunning: migrated (0.0044s)
3681== 20180330000000 CreateRequestPayloads: migrating ============================
3682-- create_table(:request_payloads, {:id=>:integer})
3683 -> 0.0092s
3684-- add_index(:request_payloads, :request_id)
3685 -> 0.0022s
3686-- add_index(:request_payloads, [:created_at, :archived])
3687 -> 0.0020s
3688== 20180330000000 CreateRequestPayloads: migrated (0.0137s) ===================
3690== 20180331000000 CreateConfigs: migrating ====================================
3691-- create_table(:request_configs, {:id=>:integer})
3692 -> 0.0072s
3693-- create_table(:build_configs, {:id=>:integer})
3694 -> 0.0055s
3695-- create_table(:job_configs, {:id=>:integer})
3696 -> 0.0060s
3697-- add_index(:request_configs, [:repository_id, :key])
3698 -> 0.0024s
3699-- add_index(:build_configs, [:repository_id, :key])
3700 -> 0.0025s
3701-- add_index(:job_configs, [:repository_id, :key])
3702 -> 0.0026s
3703-- add_column(:requests, :config_id, :integer)
3704 -> 0.0009s
3705-- add_column(:builds, :config_id, :integer)
3706 -> 0.0008s
3707-- add_column(:jobs, :config_id, :integer)
3708 -> 0.0009s
3709== 20180331000000 CreateConfigs: migrated (0.0295s) ===========================
3711== 20180404000001 CreateInstallations: migrating ==============================
3712-- create_table(:installations, {:id=>:integer})
3713 -> 0.0146s
3714-- change_table(:repositories)
3715 -> 0.0020s
3716== 20180404000001 CreateInstallations: migrated (0.0168s) =====================
3718== 20180410000000 RequestsDropPayload: migrating ==============================
3719-- remove_column(:requests, :payload, :text)
3720 -> 0.0011s
3721== 20180410000000 RequestsDropPayload: migrated (0.0013s) =====================
3723== 20180413000000 IndexBranchesOnRepositoryIdAndNameAndId: migrating ==========
3724-- execute("CREATE INDEX CONCURRENTLY index_branches_on_repository_id_and_name_and_id ON branches (repository_id, name, id)")
3725 -> 0.0044s
3726-- execute("DROP INDEX CONCURRENTLY index_branches_on_repository_id_and_name")
3727 -> 0.0023s
3728== 20180413000000 IndexBranchesOnRepositoryIdAndNameAndId: migrated (0.0069s) =
3730== 20180417000000 IndexBuildsOrganizationsUsersOnUpdatedAt: migrating =========
3731-- execute("CREATE INDEX CONCURRENTLY index_builds_on_updated_at ON builds (updated_at)")
3732 -> 0.0049s
3733-- execute("CREATE INDEX CONCURRENTLY index_users_on_updated_at ON users (updated_at)")
3734 -> 0.0043s
3735-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_updated_at ON repositories (updated_at)")
3736 -> 0.0044s
3737-- execute("CREATE INDEX CONCURRENTLY index_organizations_on_updated_at ON organizations (updated_at)")
3738 -> 0.0043s
3739== 20180417000000 IndexBuildsOrganizationsUsersOnUpdatedAt: migrated (0.0182s)
3741== 20180420000000 ConstraintsAndIndexesForGhApps: migrating ===================
3742-- execute("CREATE UNIQUE INDEX CONCURRENTLY github_id_installations_idx ON installations (github_id)")
3743 -> 0.0048s
3744-- execute("CREATE INDEX CONCURRENTLY managed_repositories_idx ON repositories (managed_by_installation_at)")
3745 -> 0.0045s
3746-- execute("CREATE UNIQUE INDEX CONCURRENTLY owner_installations_idx ON installations (owner_id, owner_type) WHERE removed_by_id IS NULL")
3747 -> 0.0046s
3748== 20180420000000 ConstraintsAndIndexesForGhApps: migrated (0.0143s) ==========
3750== 20180425000000 IndexActiveOnOrg: migrating =================================
3751-- execute("CREATE INDEX CONCURRENTLY index_active_on_org ON repositories (active_on_org)")
3752 -> 0.0044s
3753== 20180425000000 IndexActiveOnOrg: migrated (0.0045s) ========================
3755== 20180425100000 AddRemovedAtOnInstallations: migrating ======================
3756-- add_column(:installations, :removed_at, :timestamp, {:precision=>nil})
3757 -> 0.0011s
3758== 20180425100000 AddRemovedAtOnInstallations: migrated (0.0013s) =============
3760== 20180429000000 IndexRepositoriesOnOwnerNameAndName: migrating ==============
3761-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_owner_name_and_name ON repositories (owner_name, name) WHERE invalidated_at IS NULL")
3762 -> 0.0050s
3763== 20180429000000 IndexRepositoriesOnOwnerNameAndName: migrated (0.0051s) =====
3765== 20180501000000 IndexJobsOnOwnerWhereStateRunning: migrating ================
3766-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_owner_where_state_running ON jobs (owner_id, owner_type) WHERE state IN ('queued', 'received', 'started')")
3767 -> 0.0047s
3768== 20180501000000 IndexJobsOnOwnerWhereStateRunning: migrated (0.0049s) =======
3770== 20180517000000 IndexRequestsConfigId: migrating ============================
3771-- execute("CREATE INDEX CONCURRENTLY index_requests_on_config_id ON requests (config_id)")
3772 -> 0.0042s
3773== 20180517000000 IndexRequestsConfigId: migrated (0.0043s) ===================
3775== 20180517000001 IndexBuildsConfigId: migrating ==============================
3776-- execute("CREATE INDEX CONCURRENTLY index_builds_on_config_id ON requests (config_id)")
3777 -> 0.0040s
3778== 20180517000001 IndexBuildsConfigId: migrated (0.0041s) =====================
3780== 20180517000002 IndexJobsConfigId: migrating ================================
3781-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_config_id ON requests (config_id)")
3782 -> 0.0044s
3783== 20180517000002 IndexJobsConfigId: migrated (0.0045s) =======================
3785== 20180518000000 IndexBuildsOnMultiple: migrating ============================
3786-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_builds_on_repo_branch_event_type_and_private ON builds (repository_id, branch, event_type, private)")
3787 -> 0.0050s
3788== 20180518000000 IndexBuildsOnMultiple: migrated (0.0051s) ===================
3790== 20180522000000 AddActiveFlagToCrons: migrating =============================
3791-- change_table(:crons)
3792 -> 0.0021s
3793-- add_index(:crons, :next_run, {:where=>"(active IS TRUE)", :algorithm=>:concurrently})
3794 -> 0.0044s
3795== 20180522000000 AddActiveFlagToCrons: migrated (0.0067s) ====================
3797== 20180531000000 CreateRequestYamlConfigs: migrating =========================
3798-- create_table(:request_yaml_configs, {:id=>:integer})
3799 -> 0.0077s
3800-- add_index(:request_yaml_configs, [:repository_id, :key])
3801 -> 0.0034s
3802-- add_column(:requests, :yaml_config_id, :integer)
3803 -> 0.0017s
3804== 20180531000000 CreateRequestYamlConfigs: migrated (0.0132s) ================
3806== 20180606000000 IndexCommitsOnRepositoryId: migrating =======================
3807-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_commits_on_repository_id ON commits (repository_id)")
3808 -> 0.0044s
3809== 20180606000000 IndexCommitsOnRepositoryId: migrated (0.0045s) ==============
3811== 20180606000001 IndexJobsOnRepositoryId: migrating ==========================
3812-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_jobs_on_repository_id ON jobs (repository_id)")
3813 -> 0.0049s
3814== 20180606000001 IndexJobsOnRepositoryId: migrated (0.0050s) =================
3816== 20180614000000 DropRequestsConfig: migrating ===============================
3817-- remove_column(:requests, :config)
3818 -> 0.0012s
3819== 20180614000000 DropRequestsConfig: migrated (0.0013s) ======================
3821== 20180614000001 DropBuildsConfig: migrating =================================
3822-- remove_column(:builds, :config)
3823 -> 0.0012s
3824== 20180614000001 DropBuildsConfig: migrated (0.0013s) ========================
3826== 20180614000002 DropJobsConfig: migrating ===================================
3827-- remove_column(:jobs, :config)
3828 -> 0.0012s
3829== 20180614000002 DropJobsConfig: migrated (0.0025s) ==========================
3831== 20180620000000 IndexBuildsOnRepositoryIdEventTypeId: migrating =============
3832-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_builds_on_repository_id_event_type_id ON builds (repository_id, event_type, id DESC)")
3833 -> 0.0048s
3834== 20180620000000 IndexBuildsOnRepositoryIdEventTypeId: migrated (0.0049s) ====
3836== 20180725000000 CreateCancellations: migrating ==============================
3837-- create_table(:cancellations, {:id=>:integer})
3838 -> 0.0097s
3839== 20180725000000 CreateCancellations: migrated (0.0099s) =====================
3841== 20180726000000 CommitsIndexAuthorEmail: migrating ==========================
3842-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_commits_on_author_email ON commits (author_email)")
3843 -> 0.0039s
3844== 20180726000000 CommitsIndexAuthorEmail: migrated (0.0040s) =================
3846== 20180726000001 CommitsIndexCommitterEmail: migrating =======================
3847-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_commits_on_committer_email ON commits (committer_email)")
3848 -> 0.0041s
3849== 20180726000001 CommitsIndexCommitterEmail: migrated (0.0042s) ==============
3851== 20180801000001 UsersAddRedactedAt: migrating ===============================
3852-- change_table(:users)
3853 -> 0.0008s
3854== 20180801000001 UsersAddRedactedAt: migrated (0.0009s) ======================
3856== 20180822000000 CreateEmailUnsubscribes: migrating ==========================
3857-- create_table(:email_unsubscribes, {:id=>:integer})
3858 -> 0.0278s
3859== 20180822000000 CreateEmailUnsubscribes: migrated (0.0284s) =================
3861== 20180823000000 AddPreferences: migrating ===================================
3862-- change_table(:users)
3863 -> 0.0014s
3864== 20180823000000 AddPreferences: migrated (0.0014s) ==========================
3866== 20180828000000 ChangePreferencesDefault: migrating =========================
3867-- change_column_default(:users, :preferences, {})
3868 -> 0.0035s
3869== 20180828000000 ChangePreferencesDefault: migrated (0.0035s) ================
3871== 20180829000000 MakeEmailUnsubscribesIdBigint: migrating ====================
3872-- change_column(:email_unsubscribes, :id, :bigint)
3873 -> 0.0085s
3874== 20180829000000 MakeEmailUnsubscribesIdBigint: migrated (0.0086s) ===========
3876== 20180830000001 JobsAddRestartedAt: migrating ===============================
3877-- change_table(:jobs)
3878 -> 0.0012s
3879== 20180830000001 JobsAddRestartedAt: migrated (0.0012s) ======================
3881== 20180830000002 BuildsAddRestartedAt: migrating =============================
3882-- change_table(:builds)
3883 -> 0.0008s
3884== 20180830000002 BuildsAddRestartedAt: migrated (0.0008s) ====================
3886== 20180830000003 JobVersionsCreate: migrating ================================
3887-- create_table(:job_versions, {:id=>:integer})
3888 -> 0.0058s
3889== 20180830000003 JobVersionsCreate: migrated (0.0059s) =======================
3891== 20180903000000 JobConfigsIndexConfigResourcesGpu: migrating ================
3892-- execute("CREATE OR REPLACE FUNCTION is_json(text) RETURNS boolean LANGUAGE plpgsql immutable AS $$\n BEGIN\n perform $1::json;\n return true;\n EXCEPTION WHEN invalid_text_representation THEN\n return false;\n END\n$$;\n")
3893 -> 0.0011s
3894-- execute("CREATE INDEX CONCURRENTLY index_job_configs_on_config_resources_gpu ON job_configs (((config ->> 'resources')::jsonb ->> 'gpu')) WHERE is_json((config ->> 'resources')::text) AND ((config ->> 'resources')::jsonb ->> 'gpu') IS NOT NULL;\n")
3895 -> 0.0042s
3896== 20180903000000 JobConfigsIndexConfigResourcesGpu: migrated (0.0053s) =======
3898== 20180903000001 FixIndexesOnBuildsAndJobsConfigId: migrating ================
3899-- execute("DROP INDEX index_builds_on_config_id")
3900 -> 0.0011s
3901-- execute("CREATE INDEX CONCURRENTLY index_builds_on_config_id ON builds (config_id)")
3902 -> 0.0042s
3903-- execute("DROP INDEX index_jobs_on_config_id")
3904 -> 0.0013s
3905-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_config_id ON jobs (config_id)")
3906 -> 0.0041s
3907== 20180903000001 FixIndexesOnBuildsAndJobsConfigId: migrated (0.0108s) =======
3909== 20180904000001 CreateJobConfigsGpu: migrating ==============================
3910-- execute("CREATE MATERIALIZED VIEW job_configs_gpu AS\nSELECT id FROM job_configs WHERE\n is_json((config ->> 'resources')::text) AND\n ((config ->> 'resources')::jsonb ->> 'gpu') IS NOT NULL;\n")
3911 -> 0.0025s
3912== 20180904000001 CreateJobConfigsGpu: migrated (0.0025s) =====================
3914== 20180906000000 AddIndexUsersPreferencesBuildEmails: migrating ==============
3915-- execute("CREATE INDEX CONCURRENTLY user_preferences_build_emails_false ON users (id) WHERE preferences->>'build_emails' = 'false';\n")
3916 -> 0.0045s
3917== 20180906000000 AddIndexUsersPreferencesBuildEmails: migrated (0.0046s) =====
3919== 20181002115306 DeleteDuplicateRecordsFromMemberships: migrating ============
3920-- execute("DELETE FROM memberships WHERE id in (\n\tSELECT a.id FROM\n\t\t(SELECT m.id, row_number() OVER (ORDER BY m.id) as rnum\n FROM (SELECT user_id, organization_id\n FROM memberships\n GROUP BY (user_id, organization_id)\n HAVING count(*) > 1) t\n INNER JOIN memberships m ON m.user_id = t.user_id AND m.organization_id = t.organization_id) AS a\n WHERE mod(a.rnum, 2) = 0);\n")
3921 -> 0.0016s
3922== 20181002115306 DeleteDuplicateRecordsFromMemberships: migrated (0.0017s) ===
3924== 20181002115307 AddConstraintOnOrganizationAndUserToMemberships: migrating ==
3925-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_organization_id_and_user_id_on_memberships ON memberships USING btree (organization_id, user_id);\n")
3926 -> 0.0039s
3927== 20181002115307 AddConstraintOnOrganizationAndUserToMemberships: migrated (0.0040s)
3929== 20181018000000 IndexBuildsOnCreatedAt: migrating ===========================
3930-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_builds_on_created_at ON builds (created_at)")
3931 -> 0.0043s
3932== 20181018000000 IndexBuildsOnCreatedAt: migrated (0.0044s) ==================
3934== 20181029120000 AddMigrationStatusColumnToRepositories: migrating ===========
3935-- add_column(:repositories, :migration_status, :string)
3936 -> 0.0011s
3937== 20181029120000 AddMigrationStatusColumnToRepositories: migrated (0.0012s) ==
3939== 20181113120000 AddGithubGuidColumnToRequests: migrating ====================
3940-- add_column(:requests, :github_guid, :text)
3941 -> 0.0013s
3942-- add_index(:requests, :github_guid, {:algorithm=>:concurrently, :unique=>true})
3943 -> 0.0043s
3944== 20181113120000 AddGithubGuidColumnToRequests: migrated (0.0058s) ===========
3946== 20181116800000 AddConstraintsToMultipleTables: migrating ===================
3947-- execute("ALTER TABLE repositories ADD CONSTRAINT fk_repositories_on_current_build_id FOREIGN KEY (current_build_id) REFERENCES builds(id) ON DELETE SET NULL NOT VALID")
3948 -> 0.0016s
3949-- execute("ALTER TABLE repositories ADD CONSTRAINT fk_repositories_on_last_build_id FOREIGN KEY (last_build_id) REFERENCES builds(id) ON DELETE SET NULL NOT VALID")
3950 -> 0.0006s
3951-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3952 -> 0.0005s
3953-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_commit_id FOREIGN KEY (commit_id) REFERENCES commits(id) NOT VALID")
3954 -> 0.0005s
3955-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_request_id FOREIGN KEY (request_id) REFERENCES requests(id) NOT VALID")
3956 -> 0.0005s
3957-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_pull_request_id FOREIGN KEY (pull_request_id) REFERENCES pull_requests(id) NOT VALID")
3958 -> 0.0006s
3959-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) NOT VALID")
3960 -> 0.0005s
3961-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_tag_id FOREIGN KEY (tag_id) REFERENCES tags(id) NOT VALID")
3962 -> 0.0006s
3963-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_config_id FOREIGN KEY (config_id) REFERENCES build_configs(id) NOT VALID")
3964 -> 0.0005s
3965-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_jobs_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3966 -> 0.0005s
3967-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_jobs_on_commit_id FOREIGN KEY (commit_id) REFERENCES commits(id) NOT VALID")
3968 -> 0.0014s
3969-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_jobs_on_stage_id FOREIGN KEY (stage_id) REFERENCES stages(id) NOT VALID")
3970 -> 0.0032s
3971-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_jobs_on_config_id FOREIGN KEY (config_id) REFERENCES job_configs(id) NOT VALID")
3972 -> 0.0010s
3973-- execute("ALTER TABLE branches ADD CONSTRAINT fk_branches_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3974 -> 0.0010s
3975-- execute("ALTER TABLE branches ADD CONSTRAINT fk_branches_on_last_build_id FOREIGN KEY (last_build_id) REFERENCES builds(id) ON DELETE SET NULL NOT VALID")
3976 -> 0.0010s
3977-- execute("ALTER TABLE tags ADD CONSTRAINT fk_tags_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3978 -> 0.0010s
3979-- execute("ALTER TABLE tags ADD CONSTRAINT fk_tags_on_last_build_id FOREIGN KEY (last_build_id) REFERENCES builds(id) ON DELETE SET NULL NOT VALID")
3980 -> 0.0010s
3981-- execute("ALTER TABLE commits ADD CONSTRAINT fk_commits_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3982 -> 0.0005s
3983-- execute("ALTER TABLE commits ADD CONSTRAINT fk_commits_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) NOT VALID")
3984 -> 0.0005s
3985-- execute("ALTER TABLE commits ADD CONSTRAINT fk_commits_on_tag_id FOREIGN KEY (tag_id) REFERENCES tags(id) NOT VALID")
3986 -> 0.0015s
3987-- execute("ALTER TABLE crons ADD CONSTRAINT fk_crons_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) NOT VALID")
3988 -> 0.0011s
3989-- execute("ALTER TABLE job_configs ADD CONSTRAINT fk_job_configs_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3990 -> 0.0010s
3991-- execute("ALTER TABLE build_configs ADD CONSTRAINT fk_build_configs_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3992 -> 0.0009s
3993-- execute("ALTER TABLE pull_requests ADD CONSTRAINT fk_pull_requests_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3994 -> 0.0008s
3995-- execute("ALTER TABLE ssl_keys ADD CONSTRAINT fk_ssl_keys_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3996 -> 0.0010s
3997-- execute("ALTER TABLE requests ADD CONSTRAINT fk_requests_on_commit_id FOREIGN KEY (commit_id) REFERENCES commits(id) NOT VALID")
3998 -> 0.0010s
3999-- execute("ALTER TABLE requests ADD CONSTRAINT fk_requests_on_pull_request_id FOREIGN KEY (pull_request_id) REFERENCES pull_requests(id) NOT VALID")
4000 -> 0.0009s
4001-- execute("ALTER TABLE requests ADD CONSTRAINT fk_requests_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) NOT VALID")
4002 -> 0.0010s
4003-- execute("ALTER TABLE requests ADD CONSTRAINT fk_requests_on_tag_id FOREIGN KEY (tag_id) REFERENCES tags(id) NOT VALID")
4004 -> 0.0010s
4005-- execute("ALTER TABLE requests ADD CONSTRAINT fk_requests_on_config_id FOREIGN KEY (config_id) REFERENCES request_configs(id) NOT VALID")
4006 -> 0.0011s
4007-- execute("ALTER TABLE stages ADD CONSTRAINT fk_stages_on_build_id FOREIGN KEY (build_id) REFERENCES builds(id) NOT VALID")
4008 -> 0.0010s
4009== 20181116800000 AddConstraintsToMultipleTables: migrated (0.0319s) ==========
4011== 20181116800001 ValidateConstraints: migrating ==============================
4012-- execute("ALTER TABLE repositories VALIDATE CONSTRAINT fk_repositories_on_current_build_id")
4013 -> 0.0028s
4014-- execute("ALTER TABLE repositories VALIDATE CONSTRAINT fk_repositories_on_last_build_id")
4015 -> 0.0019s
4016-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_repository_id")
4017 -> 0.0012s
4018-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_commit_id")
4019 -> 0.0020s
4020-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_request_id")
4021 -> 0.0023s
4022-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_pull_request_id")
4023 -> 0.0015s
4024-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_branch_id")
4025 -> 0.0022s
4026-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_tag_id")
4027 -> 0.0018s
4028-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_config_id")
4029 -> 0.0018s
4030-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_jobs_on_repository_id")
4031 -> 0.0024s
4032-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_jobs_on_commit_id")
4033 -> 0.0012s
4034-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_jobs_on_stage_id")
4035 -> 0.0018s
4036-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_jobs_on_config_id")
4037 -> 0.0015s
4038-- execute("ALTER TABLE branches VALIDATE CONSTRAINT fk_branches_on_repository_id")
4039 -> 0.0016s
4040-- execute("ALTER TABLE branches VALIDATE CONSTRAINT fk_branches_on_last_build_id")
4041 -> 0.0016s
4042-- execute("ALTER TABLE tags VALIDATE CONSTRAINT fk_tags_on_repository_id")
4043 -> 0.0015s
4044-- execute("ALTER TABLE tags VALIDATE CONSTRAINT fk_tags_on_last_build_id")
4045 -> 0.0012s
4046-- execute("ALTER TABLE commits VALIDATE CONSTRAINT fk_commits_on_repository_id")
4047 -> 0.0016s
4048-- execute("ALTER TABLE commits VALIDATE CONSTRAINT fk_commits_on_branch_id")
4049 -> 0.0011s
4050-- execute("ALTER TABLE commits VALIDATE CONSTRAINT fk_commits_on_tag_id")
4051 -> 0.0011s
4052-- execute("ALTER TABLE crons VALIDATE CONSTRAINT fk_crons_on_branch_id")
4053 -> 0.0013s
4054-- execute("ALTER TABLE job_configs VALIDATE CONSTRAINT fk_job_configs_on_repository_id")
4055 -> 0.0011s
4056-- execute("ALTER TABLE build_configs VALIDATE CONSTRAINT fk_build_configs_on_repository_id")
4057 -> 0.0012s
4058-- execute("ALTER TABLE pull_requests VALIDATE CONSTRAINT fk_pull_requests_on_repository_id")
4059 -> 0.0012s
4060-- execute("ALTER TABLE ssl_keys VALIDATE CONSTRAINT fk_ssl_keys_on_repository_id")
4061 -> 0.0013s
4062-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_requests_on_commit_id")
4063 -> 0.0012s
4064-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_requests_on_pull_request_id")
4065 -> 0.0012s
4066-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_requests_on_branch_id")
4067 -> 0.0010s
4068-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_requests_on_tag_id")
4069 -> 0.0012s
4070-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_requests_on_config_id")
4071 -> 0.0014s
4072-- execute("ALTER TABLE stages VALIDATE CONSTRAINT fk_stages_on_build_id")
4073 -> 0.0013s
4074== 20181116800001 ValidateConstraints: migrated (0.0505s) =====================
4076== 20181126080000 AddIndexesForForeignKeys: migrating =========================
4077-- index_exists?(:builds, :branch_id)
4078 -> 0.0114s
4079-- add_index(:builds, :branch_id, {:algorithm=>:concurrently})
4080 -> 0.0046s
4081-- index_exists?(:builds, :commit_id)
4082 -> 0.0084s
4083-- add_index(:builds, :commit_id, {:algorithm=>:concurrently})
4084 -> 0.0039s
4085-- index_exists?(:builds, :pull_request_id)
4086 -> 0.0058s
4087-- add_index(:builds, :pull_request_id, {:algorithm=>:concurrently})
4088 -> 0.0040s
4089-- index_exists?(:builds, :tag_id)
4090 -> 0.0077s
4091-- add_index(:builds, :tag_id, {:algorithm=>:concurrently})
4092 -> 0.0053s
4093-- index_exists?(:jobs, :commit_id)
4094 -> 0.0057s
4095-- add_index(:jobs, :commit_id, {:algorithm=>:concurrently})
4096 -> 0.0043s
4097-- index_exists?(:branches, :last_build_id)
4098 -> 0.0025s
4099-- add_index(:branches, :last_build_id, {:algorithm=>:concurrently})
4100 -> 0.0039s
4101-- index_exists?(:tags, :repository_id)
4102 -> 0.0020s
4103-- add_index(:tags, :repository_id, {:algorithm=>:concurrently})
4104 -> 0.0037s
4105-- index_exists?(:tags, :last_build_id)
4106 -> 0.0023s
4107-- add_index(:tags, :last_build_id, {:algorithm=>:concurrently})
4108 -> 0.0036s
4109-- index_exists?(:commits, :tag_id)
4110 -> 0.0026s
4111-- add_index(:commits, :tag_id, {:algorithm=>:concurrently})
4112 -> 0.0040s
4113-- index_exists?(:commits, :branch_id)
4114 -> 0.0029s
4115-- add_index(:commits, :branch_id, {:algorithm=>:concurrently})
4116 -> 0.0035s
4117-- index_exists?(:job_configs, :repository_id)
4118 -> 0.0016s
4119-- add_index(:job_configs, :repository_id, {:algorithm=>:concurrently})
4120 -> 0.0036s
4121-- index_exists?(:build_configs, :repository_id)
4122 -> 0.0013s
4123-- add_index(:build_configs, :repository_id, {:algorithm=>:concurrently})
4124 -> 0.0034s
4125-- index_exists?(:pull_requests, :repository_id)
4126 -> 0.0019s
4127-- add_index(:pull_requests, :repository_id, {:algorithm=>:concurrently})
4128 -> 0.0035s
4129-- index_exists?(:requests, :pull_request_id)
4130 -> 0.0136s
4131-- add_index(:requests, :pull_request_id, {:algorithm=>:concurrently})
4132 -> 0.0055s
4133-- index_exists?(:requests, :tag_id)
4134 -> 0.0082s
4135-- add_index(:requests, :tag_id, {:algorithm=>:concurrently})
4136 -> 0.0045s
4137-- index_exists?(:requests, :branch_id)
4138 -> 0.0075s
4139-- add_index(:requests, :branch_id, {:algorithm=>:concurrently})
4140 -> 0.0122s
4141-- index_exists?(:repositories, :current_build_id)
4142 -> 0.0093s
4143-- add_index(:repositories, :current_build_id, {:algorithm=>:concurrently})
4144 -> 0.0044s
4145-- index_exists?(:repositories, :last_build_id)
4146 -> 0.0088s
4147-- add_index(:repositories, :last_build_id, {:algorithm=>:concurrently})
4148 -> 0.0055s
4149-- index_exists?(:crons, :branch_id)
4150 -> 0.0040s
4151-- add_index(:crons, :branch_id, {:algorithm=>:concurrently})
4152 -> 0.0048s
4153== 20181126080000 AddIndexesForForeignKeys: migrated (0.1977s) ================
4155== 20181128120000 AddUniqueIndexToBranchesOnRepositoryIdAndName: migrating ====
4156-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_branches_on_repository_id_and_name ON branches(repository_id, name)")
4157 -> 0.0045s
4158== 20181128120000 AddUniqueIndexToBranchesOnRepositoryIdAndName: migrated (0.0046s)
4160== 20181203075818 AddUniqueNameColumnToBranches: migrating ====================
4161-- add_column(:branches, :unique_name, :text)
4162 -> 0.0009s
4163== 20181203075818 AddUniqueNameColumnToBranches: migrated (0.0009s) ===========
4165== 20181203075819 AddSetUniqueNameTriggerToBranches: migrating ================
4166-- execute("DROP TRIGGER IF EXISTS set_unique_name_on_branches ON branches;\nDROP FUNCTION IF EXISTS set_unique_name();\nCREATE FUNCTION set_unique_name() RETURNS trigger AS $$\nDECLARE\n disable boolean;\nBEGIN\n disable := 'f';\n IF TG_OP = 'INSERT' OR TG_OP = 'UPDATE' THEN\n BEGIN\n disable := current_setting('set_unique_name_on_branches.disable');\n EXCEPTION\n WHEN others THEN\n set set_unique_name_on_branches.disable = 'f';\n END;\n\n IF NOT disable THEN\n NEW.unique_name := NEW.name;\n END IF;\n END IF;\n RETURN NEW;\nEND;\n$$ LANGUAGE plpgsql;\n\nCREATE TRIGGER set_unique_name_on_branches\nBEFORE INSERT OR UPDATE ON branches\nFOR EACH ROW\nEXECUTE PROCEDURE set_unique_name();\n")
4167 -> 0.0012s
4168== 20181203075819 AddSetUniqueNameTriggerToBranches: migrated (0.0014s) =======
4170== 20181203080356 CreateIndexOnBranchesUniqueNameAndRepositoryId: migrating ===
4171-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_branches_repository_id_unique_name ON branches(repository_id, unique_name) WHERE unique_name IS NOT NULL")
4172 -> 0.0041s
4173== 20181203080356 CreateIndexOnBranchesUniqueNameAndRepositoryId: migrated (0.0046s)
4175== 20181205152712 AddUniqueIndexToCronsOnBranchId: migrating ==================
4176-- execute("DROP INDEX CONCURRENTLY index_crons_on_branch_id")
4177 -> 0.0022s
4178-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_crons_on_branch_id ON crons(branch_id)")
4179 -> 0.0035s
4180== 20181205152712 AddUniqueIndexToCronsOnBranchId: migrated (0.0058s) =========
4182== 20190102000000 AddOrganizationPreferences: migrating =======================
4183-- change_table(:organizations)
4184 -> 0.0009s
4185== 20190102000000 AddOrganizationPreferences: migrated (0.0010s) ==============
4187== 20190102000001 ChangeOrganizationPreferencesDefault: migrating =============
4188-- change_column_default(:organizations, :preferences, {})
4189 -> 0.0034s
4190== 20190102000001 ChangeOrganizationPreferencesDefault: migrated (0.0034s) ====
4192== 20190109000000 CreateBetaMigrationRequestTable: migrating ==================
4193-- create_table(:beta_migration_requests, {:id=>:integer})
4194 -> 0.0063s
4195-- add_index(:beta_migration_requests, [:owner_type, :owner_id])
4196 -> 0.0022s
4197== 20190109000000 CreateBetaMigrationRequestTable: migrated (0.0087s) =========
4199== 20190118000000 AddBetaMigrationRequestColumnToOrganizations: migrating =====
4200-- add_column(:organizations, :beta_migration_request_id, :integer)
4201 -> 0.0011s
4202== 20190118000000 AddBetaMigrationRequestColumnToOrganizations: migrated (0.0011s)
4204== 20190204000000 MakeSubscriptionOwnerNotNullable: migrating =================
4205-- change_column_null(:subscriptions, :owner_type, false)
4206 -> 0.0009s
4207-- change_column_null(:subscriptions, :owner_id, false)
4208 -> 0.0005s
4209== 20190204000000 MakeSubscriptionOwnerNotNullable: migrated (0.0014s) ========
4211== 20190313000000 RequestRawConfigsCreate: migrating ==========================
4212-- create_table(:request_raw_configs, {:id=>:integer})
4213 -> 0.0059s
4214-- add_index(:request_raw_configs, [:repository_id, :key])
4215 -> 0.0021s
4216-- create_table(:request_raw_configurations, {:id=>:integer})
4217 -> 0.0046s
4218-- add_index(:request_raw_configurations, :request_id)
4219 -> 0.0018s
4220-- add_index(:request_raw_configurations, :request_raw_config_id)
4221 -> 0.0016s
4222== 20190313000000 RequestRawConfigsCreate: migrated (0.0162s) =================
4224== 20190329093854 CreateGatekeeperWorkers: migrating ==========================
4225-- create_table(:gatekeeper_workers)
4226 -> 0.0029s
4227-- execute("INSERT INTO gatekeeper_workers(id) SELECT generate_series(1,200) as id;")
4228 -> 0.0007s
4229== 20190329093854 CreateGatekeeperWorkers: migrated (0.0037s) =================
4231== 20190409133118 AddUniqueNumberColumnToBuilds: migrating ====================
4232-- add_column(:builds, :unique_number, :int)
4233 -> 0.0007s
4234== 20190409133118 AddUniqueNumberColumnToBuilds: migrated (0.0008s) ===========
4236== 20190409133320 AddSetUniqueNumberTriggerToBuilds: migrating ================
4237-- execute("DROP TRIGGER IF EXISTS set_unique_number_on_builds ON builds;\nDROP FUNCTION IF EXISTS set_unique_number();\nCREATE FUNCTION set_unique_number() RETURNS trigger AS $$\nDECLARE\n disable boolean;\nBEGIN\n disable := 'f';\n IF TG_OP = 'INSERT' OR TG_OP = 'UPDATE' THEN\n BEGIN\n disable := current_setting('set_unique_number_on_builds.disable');\n EXCEPTION\n WHEN others THEN\n set set_unique_number_on_builds.disable = 'f';\n END;\n\n IF NOT disable THEN\n IF NEW.unique_number IS NULL OR NEW.unique_number > 0 THEN\n NEW.unique_number := NEW.number;\n END IF;\n END IF;\n END IF;\n RETURN NEW;\nEND;\n$$ LANGUAGE plpgsql;\n\nCREATE TRIGGER set_unique_number_on_builds\nBEFORE INSERT OR UPDATE ON builds\nFOR EACH ROW\nEXECUTE PROCEDURE set_unique_number();\n")
4238 -> 0.0009s
4239== 20190409133320 AddSetUniqueNumberTriggerToBuilds: migrated (0.0010s) =======
4241== 20190409133444 CreateUniqueIndexOnRepositoryIdAndNumberOnBuilds: migrating =
4242-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_builds_repository_id_unique_number ON builds(repository_id, unique_number) WHERE unique_number IS NOT NULL")
4243 -> 0.0035s
4244== 20190409133444 CreateUniqueIndexOnRepositoryIdAndNumberOnBuilds: migrated (0.0036s)
4246== 20190410121039 MakeSetUniqueNumberTriggerRunOnlyOnInsert: migrating ========
4247-- execute(" DROP TRIGGER set_unique_number_on_builds ON builds;\n CREATE TRIGGER set_unique_number_on_builds\n BEFORE INSERT ON builds\n FOR EACH ROW\n EXECUTE PROCEDURE set_unique_number();\n")
4248 -> 0.0007s
4249== 20190410121039 MakeSetUniqueNumberTriggerRunOnlyOnInsert: migrated (0.0008s)
4251== 20190416071629 RemoveUniqueNameFromBranches: migrating =====================
4252-- execute("drop index concurrently index_branches_repository_id_unique_name;")
4253 -> 0.0024s
4254-- execute("DROP TRIGGER IF EXISTS set_unique_name_on_branches ON branches;\nDROP FUNCTION IF EXISTS set_unique_name();\n\n")
4255 -> 0.0011s
4256-- remove_column(:branches, :unique_name)
4257 -> 0.0011s
4258== 20190416071629 RemoveUniqueNameFromBranches: migrated (0.0048s) ============
4260== 20190417072423 AlterBuildsUniqueNumberIndex: migrating =====================
4261-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_builds_repository_id_unique_number_new ON builds(repository_id, unique_number) WHERE unique_number IS NOT NULL AND unique_number > 0")
4262 -> 0.0042s
4263-- execute("DROP INDEX CONCURRENTLY index_builds_repository_id_unique_number")
4264 -> 0.0022s
4265-- execute("ALTER INDEX index_builds_repository_id_unique_number_new RENAME TO index_builds_repository_id_unique_number")
4266 -> 0.0008s
4267== 20190417072423 AlterBuildsUniqueNumberIndex: migrated (0.0073s) ============
4269== 20190417072838 ReinstallSetUniqueNumberTrigger: migrating ==================
4270-- execute("DROP TRIGGER IF EXISTS set_unique_number_on_builds ON builds;\nDROP FUNCTION IF EXISTS set_unique_number();\n")
4271 -> 0.0067s
4272-- execute("DROP TRIGGER IF EXISTS set_unique_number_on_builds ON builds;\nDROP FUNCTION IF EXISTS set_unique_number();\nCREATE FUNCTION set_unique_number() RETURNS trigger AS $$\nDECLARE\n disable boolean;\nBEGIN\n disable := 'f';\n IF TG_OP = 'INSERT' OR TG_OP = 'UPDATE' THEN\n BEGIN\n disable := current_setting('set_unique_number_on_builds.disable');\n EXCEPTION\n WHEN others THEN\n set set_unique_number_on_builds.disable = 'f';\n END;\n\n IF NOT disable THEN\n IF NEW.unique_number IS NULL OR NEW.unique_number > 0 THEN\n NEW.unique_number := NEW.number;\n END IF;\n END IF;\n END IF;\n RETURN NEW;\nEND;\n$$ LANGUAGE plpgsql;\n\nCREATE TRIGGER set_unique_number_on_builds\nBEFORE INSERT OR UPDATE ON builds\nFOR EACH ROW\nEXECUTE PROCEDURE set_unique_number();\n")
4273 -> 0.0021s
4274== 20190417072838 ReinstallSetUniqueNumberTrigger: migrated (0.0141s) =========
4276== 20190502175059 AddMergeableStateToPullRequests: migrating ==================
4277-- add_column(:pull_requests, :mergeable_state, :string)
4278 -> 0.0008s
4279== 20190502175059 AddMergeableStateToPullRequests: migrated (0.0009s) =========
4281== 20190510121000 AddReposIndexOnLowerOwnerNameAndName: migrating =============
4282-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_repositories_on_lower_owner_name_and_name ON repositories (LOWER(owner_name), LOWER(name)) WHERE invalidated_at IS NULL")
4283 -> 0.0049s
4284== 20190510121000 AddReposIndexOnLowerOwnerNameAndName: migrated (0.0049s) ====
4286== 20190605121000 AddHistoryMigrationStatusToRepositories: migrating ==========
4287-- add_column(:repositories, :history_migration_status, :string)
4288 -> 0.0010s
4289== 20190605121000 AddHistoryMigrationStatusToRepositories: migrated (0.0010s) =
4291== 20190605155459 AddPullRequestMergeableToRequests: migrating ================
4292-- add_column(:requests, :pull_request_mergeable, :string)
4293 -> 0.0008s
4294== 20190605155459 AddPullRequestMergeableToRequests: migrated (0.0009s) =======
4296== 20190613120000 SoftDeleteRepositoryAlongWithItsData: migrating =============
4297-- execute("create table if not exists deleted_builds (like builds)")
4298 -> 0.0036s
4299-- execute("create table if not exists deleted_stages (like stages)")
4300 -> 0.0069s
4301-- execute("create table if not exists deleted_jobs (like jobs)")
4302 -> 0.0040s
4303-- execute("create table if not exists deleted_requests (like requests)")
4304 -> 0.0042s
4305-- execute("create table if not exists deleted_commits (like commits)")
4306 -> 0.0037s
4307-- execute("create table if not exists deleted_pull_requests (like pull_requests)")
4308 -> 0.0039s
4309-- execute("create table if not exists deleted_job_configs (like job_configs)")
4310 -> 0.0032s
4311-- execute("create table if not exists deleted_build_configs (like build_configs)")
4312 -> 0.0035s
4313-- execute("create table if not exists deleted_request_configs (like request_configs)")
4314 -> 0.0032s
4315-- execute("create table if not exists deleted_request_payloads (like request_payloads)")
4316 -> 0.0030s
4317-- execute("create table if not exists deleted_ssl_keys (like ssl_keys)")
4318 -> 0.0032s
4319-- execute("create table if not exists deleted_tags (like tags)")
4320 -> 0.0033s
4321-- execute("DROP FUNCTION IF EXISTS soft_delete_repo_data(bigint);\nCREATE FUNCTION soft_delete_repo_data(r_id bigint) RETURNS void AS $$\nDECLARE\n request_raw_config_ids bigint[];\n request_raw_configuration_ids bigint[];\n request_yaml_config_ids bigint[];\n request_config_ids bigint[];\n tag_ids bigint[];\n ssl_key_ids bigint[];\n build_config_ids bigint[];\n job_config_ids bigint[];\n build_ids bigint[];\n pull_request_ids bigint[];\n commit_ids bigint[];\n request_ids bigint[];\n request_payload_ids bigint[];\n stage_ids bigint[];\n job_ids bigint[];\nBEGIN\n SELECT INTO job_ids array_agg(id) FROM jobs WHERE repository_id = r_id;\n SELECT INTO stage_ids array_agg(id) FROM stages WHERE build_id IN (SELECT id FROM builds WHERE repository_id = r_id);\n SELECT INTO request_payload_ids array_agg(id) FROM request_payloads WHERE request_id IN (SELECT id FROM requests WHERE repository_id = r_id);\n SELECT INTO request_ids array_agg(id) FROM requests WHERE repository_id = r_id;\n SELECT INTO commit_ids array_agg(id) FROM commits WHERE repository_id = r_id;\n SELECT INTO pull_request_ids array_agg(id) FROM pull_requests WHERE repository_id = r_id;\n SELECT INTO build_ids array_agg(id) FROM builds WHERE repository_id = r_id;\n SELECT INTO job_config_ids array_agg(id) FROM job_configs WHERE repository_id = r_id;\n SELECT INTO build_config_ids array_agg(id) FROM build_configs WHERE repository_id = r_id;\n SELECT INTO ssl_key_ids array_agg(id) FROM ssl_keys WHERE repository_id = r_id;\n SELECT INTO tag_ids array_agg(id) FROM tags WHERE repository_id = r_id;\n SELECT INTO request_config_ids array_agg(id) FROM request_configs WHERE repository_id = r_id;\n SELECT INTO request_yaml_config_ids array_agg(id) FROM request_yaml_configs WHERE repository_id = r_id;\n SELECT INTO request_raw_configuration_ids array_agg(id) FROM request_raw_configurations WHERE request_id = ANY(request_ids);\n SELECT INTO request_raw_config_ids array_agg(id) FROM request_raw_configs WHERE id IN (SELECT request_raw_config_id FROM request_raw_configurations WHERE request_id = ANY(request_ids));\n\n INSERT INTO deleted_jobs SELECT * FROM jobs WHERE id = ANY(job_ids);\n INSERT INTO deleted_stages SELECT * FROM stages WHERE id = ANY(stage_ids);\n INSERT INTO deleted_request_payloads SELECT * FROM request_payloads WHERE id = ANY(request_payload_ids);\n INSERT INTO deleted_requests SELECT * FROM requests WHERE id = ANY(request_ids);\n INSERT INTO deleted_commits SELECT * FROM commits WHERE id = ANY(commit_ids);\n INSERT INTO deleted_pull_requests SELECT * FROM pull_requests WHERE id = ANY(pull_request_ids);\n INSERT INTO deleted_builds SELECT * FROM builds WHERE id = ANY(build_ids);\n INSERT INTO deleted_job_configs SELECT * FROM job_configs WHERE id = ANY(job_config_ids);\n INSERT INTO deleted_build_configs SELECT * FROM build_configs WHERE id = ANY(build_config_ids);\n INSERT INTO deleted_ssl_keys SELECT * FROM ssl_keys WHERE id = ANY(ssl_key_ids);\n INSERT INTO deleted_tags SELECT * FROM tags WHERE id = ANY(tag_ids);\n INSERT INTO deleted_request_configs SELECT * FROM request_configs WHERE id = ANY(request_config_ids);\n INSERT INTO deleted_request_yaml_configs SELECT * FROM request_yaml_configs WHERE id = ANY(request_yaml_config_ids);\n INSERT INTO deleted_request_raw_configurations SELECT * FROM request_raw_configurations WHERE id = ANY(request_raw_configuration_ids);\n INSERT INTO deleted_request_raw_configs SELECT * FROM request_raw_configs WHERE id = ANY(request_raw_config_ids);\n\n DELETE FROM jobs WHERE id = ANY(job_ids);\n DELETE FROM stages WHERE id = ANY(stage_ids);\n DELETE FROM request_payloads WHERE id = ANY(request_payload_ids);\n DELETE FROM requests WHERE id = ANY(request_ids);\n DELETE FROM commits WHERE id = ANY(commit_ids);\n DELETE FROM pull_requests WHERE id = ANY(pull_request_ids);\n DELETE FROM builds WHERE id = ANY(build_ids);\n DELETE FROM job_configs WHERE id = ANY(job_config_ids);\n DELETE FROM build_configs WHERE id = ANY(build_config_ids);\n DELETE FROM ssl_keys WHERE id = ANY(ssl_key_ids);\n DELETE FROM tags WHERE id = ANY(tag_ids);\n DELETE FROM request_configs WHERE id = ANY(request_config_ids);\n DELETE FROM request_yaml_configs WHERE id = ANY(request_yaml_config_ids);\n DELETE FROM request_raw_configurations WHERE id = ANY(request_raw_configuration_ids);\n DELETE FROM request_raw_configs WHERE id = ANY(request_raw_config_ids);\nEND;\n$$ LANGUAGE plpgsql;\n")
4322 -> 0.0020s
4323== 20190613120000 SoftDeleteRepositoryAlongWithItsData: migrated (0.0483s) ====
4325== 20190618082559 AddVcsTypeToUser: migrating =================================
4326-- add_column(:users, :vcs_type, :string, {:default=>nil})
4327 -> 0.0016s
4328-- execute("ALTER TABLE users ALTER COLUMN vcs_type SET DEFAULT 'GithubUser'")
4329 -> 0.0006s
4330-- select_value("SELECT id FROM users ORDER BY id DESC LIMIT 1")
4331 -> 0.0013s
4332-- execute("UPDATE users SET vcs_type = 'GithubUser' WHERE id BETWEEN 0 AND 5000")
4333 -> 0.0010s
4334== 20190618082559 AddVcsTypeToUser: migrated (0.0059s) ========================
4336== 20190701082559 AddVcsTypeToRepository: migrating ===========================
4337-- add_column(:repositories, :vcs_type, :string, {:default=>nil})
4338 -> 0.0014s
4339-- execute("ALTER TABLE repositories ALTER COLUMN vcs_type SET DEFAULT 'GithubRepository'")
4340 -> 0.0005s
4341-- select_value("SELECT id FROM repositories ORDER BY id DESC LIMIT 1")
4342 -> 0.0012s
4343-- execute("UPDATE repositories SET vcs_type = 'GithubRepository' WHERE id BETWEEN 0 AND 5000")
4344 -> 0.0010s
4345== 20190701082559 AddVcsTypeToRepository: migrated (0.0052s) ==================
4347== 20190704082559 AddVcsTypeToOrganization: migrating =========================
4348-- add_column(:organizations, :vcs_type, :string, {:default=>nil})
4349 -> 0.0012s
4350-- execute("ALTER TABLE organizations ALTER COLUMN vcs_type SET DEFAULT 'GithubOrganization'")
4351 -> 0.0005s
4352-- select_value("SELECT id FROM organizations ORDER BY id DESC LIMIT 1")
4353 -> 0.0011s
4354-- execute("UPDATE organizations SET vcs_type = 'GithubOrganization' WHERE id BETWEEN 0 AND 5000")
4355 -> 0.0008s
4356== 20190704082559 AddVcsTypeToOrganization: migrated (0.0048s) ================
4358== 20190718092750 AddDeleteCascadeToForeignKeys: migrating ====================
4359-- execute("ALTER TABLE builds ADD CONSTRAINT fk_new_builds_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4360 -> 0.0019s
4361-- execute("ALTER TABLE builds ADD CONSTRAINT fk_new_builds_on_commit_id FOREIGN KEY (commit_id) REFERENCES commits(id) ON DELETE CASCADE NOT VALID")
4362 -> 0.0009s
4363-- execute("ALTER TABLE builds ADD CONSTRAINT fk_new_builds_on_request_id FOREIGN KEY (request_id) REFERENCES requests(id) ON DELETE CASCADE NOT VALID")
4364 -> 0.0014s
4365-- execute("ALTER TABLE builds ADD CONSTRAINT fk_new_builds_on_pull_request_id FOREIGN KEY (pull_request_id) REFERENCES pull_requests(id) ON DELETE CASCADE NOT VALID")
4366 -> 0.0012s
4367-- execute("ALTER TABLE builds ADD CONSTRAINT fk_new_builds_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) ON DELETE CASCADE NOT VALID")
4368 -> 0.0014s
4369-- execute("ALTER TABLE builds ADD CONSTRAINT fk_new_builds_on_tag_id FOREIGN KEY (tag_id) REFERENCES tags(id) ON DELETE CASCADE NOT VALID")
4370 -> 0.0024s
4371-- execute("ALTER TABLE builds ADD CONSTRAINT fk_new_builds_on_config_id FOREIGN KEY (config_id) REFERENCES build_configs(id) ON DELETE CASCADE NOT VALID")
4372 -> 0.0019s
4373-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_new_jobs_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4374 -> 0.0016s
4375-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_new_jobs_on_commit_id FOREIGN KEY (commit_id) REFERENCES commits(id) ON DELETE CASCADE NOT VALID")
4376 -> 0.0020s
4377-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_new_jobs_on_stage_id FOREIGN KEY (stage_id) REFERENCES stages(id) ON DELETE CASCADE NOT VALID")
4378 -> 0.0016s
4379-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_new_jobs_on_config_id FOREIGN KEY (config_id) REFERENCES job_configs(id) ON DELETE CASCADE NOT VALID")
4380 -> 0.0017s
4381-- execute("ALTER TABLE branches ADD CONSTRAINT fk_new_branches_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4382 -> 0.0017s
4383-- execute("ALTER TABLE tags ADD CONSTRAINT fk_new_tags_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4384 -> 0.0020s
4385-- execute("ALTER TABLE commits ADD CONSTRAINT fk_new_commits_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4386 -> 0.0012s
4387-- execute("ALTER TABLE commits ADD CONSTRAINT fk_new_commits_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) ON DELETE CASCADE NOT VALID")
4388 -> 0.0021s
4389-- execute("ALTER TABLE commits ADD CONSTRAINT fk_new_commits_on_tag_id FOREIGN KEY (tag_id) REFERENCES tags(id) ON DELETE CASCADE NOT VALID")
4390 -> 0.0016s
4391-- execute("ALTER TABLE crons ADD CONSTRAINT fk_new_crons_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) ON DELETE CASCADE NOT VALID")
4392 -> 0.0017s
4393-- execute("ALTER TABLE job_configs ADD CONSTRAINT fk_new_job_configs_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4394 -> 0.0020s
4395-- execute("ALTER TABLE build_configs ADD CONSTRAINT fk_new_build_configs_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4396 -> 0.0017s
4397-- execute("ALTER TABLE pull_requests ADD CONSTRAINT fk_new_pull_requests_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4398 -> 0.0010s
4399-- execute("ALTER TABLE ssl_keys ADD CONSTRAINT fk_new_ssl_keys_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4400 -> 0.0018s
4401-- execute("ALTER TABLE requests ADD CONSTRAINT fk_new_requests_on_commit_id FOREIGN KEY (commit_id) REFERENCES commits(id) ON DELETE CASCADE NOT VALID")
4402 -> 0.0016s
4403-- execute("ALTER TABLE requests ADD CONSTRAINT fk_new_requests_on_pull_request_id FOREIGN KEY (pull_request_id) REFERENCES pull_requests(id) ON DELETE CASCADE NOT VALID")
4404 -> 0.0014s
4405-- execute("ALTER TABLE requests ADD CONSTRAINT fk_new_requests_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) ON DELETE CASCADE NOT VALID")
4406 -> 0.0018s
4407-- execute("ALTER TABLE requests ADD CONSTRAINT fk_new_requests_on_tag_id FOREIGN KEY (tag_id) REFERENCES tags(id) ON DELETE CASCADE NOT VALID")
4408 -> 0.0018s
4409-- execute("ALTER TABLE requests ADD CONSTRAINT fk_new_requests_on_config_id FOREIGN KEY (config_id) REFERENCES request_configs(id) ON DELETE CASCADE NOT VALID")
4410 -> 0.0015s
4411-- execute("ALTER TABLE stages ADD CONSTRAINT fk_new_stages_on_build_id FOREIGN KEY (build_id) REFERENCES builds(id) ON DELETE CASCADE NOT VALID")
4412 -> 0.0020s
4413-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_repository_id")
4414 -> 0.0035s
4415-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_commit_id")
4416 -> 0.0023s
4417-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_request_id")
4418 -> 0.0022s
4419-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_pull_request_id")
4420 -> 0.0022s
4421-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_branch_id")
4422 -> 0.0025s
4423-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_tag_id")
4424 -> 0.0024s
4425-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_config_id")
4426 -> 0.0018s
4427-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_new_jobs_on_repository_id")
4428 -> 0.0022s
4429-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_new_jobs_on_commit_id")
4430 -> 0.0015s
4431-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_new_jobs_on_stage_id")
4432 -> 0.0019s
4433-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_new_jobs_on_config_id")
4434 -> 0.0021s
4435-- execute("ALTER TABLE branches VALIDATE CONSTRAINT fk_new_branches_on_repository_id")
4436 -> 0.0017s
4437-- execute("ALTER TABLE tags VALIDATE CONSTRAINT fk_new_tags_on_repository_id")
4438 -> 0.0014s
4439-- execute("ALTER TABLE commits VALIDATE CONSTRAINT fk_new_commits_on_repository_id")
4440 -> 0.0018s
4441-- execute("ALTER TABLE commits VALIDATE CONSTRAINT fk_new_commits_on_branch_id")
4442 -> 0.0017s
4443-- execute("ALTER TABLE commits VALIDATE CONSTRAINT fk_new_commits_on_tag_id")
4444 -> 0.0017s
4445-- execute("ALTER TABLE crons VALIDATE CONSTRAINT fk_new_crons_on_branch_id")
4446 -> 0.0015s
4447-- execute("ALTER TABLE job_configs VALIDATE CONSTRAINT fk_new_job_configs_on_repository_id")
4448 -> 0.0019s
4449-- execute("ALTER TABLE build_configs VALIDATE CONSTRAINT fk_new_build_configs_on_repository_id")
4450 -> 0.0011s
4451-- execute("ALTER TABLE pull_requests VALIDATE CONSTRAINT fk_new_pull_requests_on_repository_id")
4452 -> 0.0017s
4453-- execute("ALTER TABLE ssl_keys VALIDATE CONSTRAINT fk_new_ssl_keys_on_repository_id")
4454 -> 0.0015s
4455-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_new_requests_on_commit_id")
4456 -> 0.0020s
4457-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_new_requests_on_pull_request_id")
4458 -> 0.0008s
4459-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_new_requests_on_branch_id")
4460 -> 0.0007s
4461-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_new_requests_on_tag_id")
4462 -> 0.0007s
4463-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_new_requests_on_config_id")
4464 -> 0.0007s
4465-- execute("ALTER TABLE stages VALIDATE CONSTRAINT fk_new_stages_on_build_id")
4466 -> 0.0009s
4467-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_repository_id")
4468 -> 0.0009s
4469-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_commit_id")
4470 -> 0.0008s
4471-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_request_id")
4472 -> 0.0008s
4473-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_pull_request_id")
4474 -> 0.0008s
4475-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_branch_id")
4476 -> 0.0007s
4477-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_tag_id")
4478 -> 0.0007s
4479-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_config_id")
4480 -> 0.0007s
4481-- execute("ALTER TABLE jobs DROP CONSTRAINT fk_jobs_on_repository_id")
4482 -> 0.0008s
4483-- execute("ALTER TABLE jobs DROP CONSTRAINT fk_jobs_on_commit_id")
4484 -> 0.0007s
4485-- execute("ALTER TABLE jobs DROP CONSTRAINT fk_jobs_on_stage_id")
4486 -> 0.0007s
4487-- execute("ALTER TABLE jobs DROP CONSTRAINT fk_jobs_on_config_id")
4488 -> 0.0007s
4489-- execute("ALTER TABLE branches DROP CONSTRAINT fk_branches_on_repository_id")
4490 -> 0.0008s
4491-- execute("ALTER TABLE tags DROP CONSTRAINT fk_tags_on_repository_id")
4492 -> 0.0007s
4493-- execute("ALTER TABLE commits DROP CONSTRAINT fk_commits_on_repository_id")
4494 -> 0.0007s
4495-- execute("ALTER TABLE commits DROP CONSTRAINT fk_commits_on_branch_id")
4496 -> 0.0006s
4497-- execute("ALTER TABLE commits DROP CONSTRAINT fk_commits_on_tag_id")
4498 -> 0.0006s
4499-- execute("ALTER TABLE crons DROP CONSTRAINT fk_crons_on_branch_id")
4500 -> 0.0006s
4501-- execute("ALTER TABLE job_configs DROP CONSTRAINT fk_job_configs_on_repository_id")
4502 -> 0.0007s
4503-- execute("ALTER TABLE build_configs DROP CONSTRAINT fk_build_configs_on_repository_id")
4504 -> 0.0007s
4505-- execute("ALTER TABLE pull_requests DROP CONSTRAINT fk_pull_requests_on_repository_id")
4506 -> 0.0007s
4507-- execute("ALTER TABLE ssl_keys DROP CONSTRAINT fk_ssl_keys_on_repository_id")
4508 -> 0.0007s
4509-- execute("ALTER TABLE requests DROP CONSTRAINT fk_requests_on_commit_id")
4510 -> 0.0007s
4511-- execute("ALTER TABLE requests DROP CONSTRAINT fk_requests_on_pull_request_id")
4512 -> 0.0007s
4513-- execute("ALTER TABLE requests DROP CONSTRAINT fk_requests_on_branch_id")
4514 -> 0.0007s
4515-- execute("ALTER TABLE requests DROP CONSTRAINT fk_requests_on_tag_id")
4516 -> 0.0008s
4517-- execute("ALTER TABLE requests DROP CONSTRAINT fk_requests_on_config_id")
4518 -> 0.0007s
4519-- execute("ALTER TABLE stages DROP CONSTRAINT fk_stages_on_build_id")
4520 -> 0.0007s
4521-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_repository_id TO fk_builds_on_repository_id")
4522 -> 0.0005s
4523-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_commit_id TO fk_builds_on_commit_id")
4524 -> 0.0004s
4525-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_request_id TO fk_builds_on_request_id")
4526 -> 0.0004s
4527-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_pull_request_id TO fk_builds_on_pull_request_id")
4528 -> 0.0004s
4529-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_branch_id TO fk_builds_on_branch_id")
4530 -> 0.0004s
4531-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_tag_id TO fk_builds_on_tag_id")
4532 -> 0.0004s
4533-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_config_id TO fk_builds_on_config_id")
4534 -> 0.0004s
4535-- execute("ALTER TABLE jobs RENAME CONSTRAINT fk_new_jobs_on_repository_id TO fk_jobs_on_repository_id")
4536 -> 0.0003s
4537-- execute("ALTER TABLE jobs RENAME CONSTRAINT fk_new_jobs_on_commit_id TO fk_jobs_on_commit_id")
4538 -> 0.0004s
4539-- execute("ALTER TABLE jobs RENAME CONSTRAINT fk_new_jobs_on_stage_id TO fk_jobs_on_stage_id")
4540 -> 0.0004s
4541-- execute("ALTER TABLE jobs RENAME CONSTRAINT fk_new_jobs_on_config_id TO fk_jobs_on_config_id")
4542 -> 0.0005s
4543-- execute("ALTER TABLE branches RENAME CONSTRAINT fk_new_branches_on_repository_id TO fk_branches_on_repository_id")
4544 -> 0.0004s
4545-- execute("ALTER TABLE tags RENAME CONSTRAINT fk_new_tags_on_repository_id TO fk_tags_on_repository_id")
4546 -> 0.0004s
4547-- execute("ALTER TABLE commits RENAME CONSTRAINT fk_new_commits_on_repository_id TO fk_commits_on_repository_id")
4548 -> 0.0004s
4549-- execute("ALTER TABLE commits RENAME CONSTRAINT fk_new_commits_on_branch_id TO fk_commits_on_branch_id")
4550 -> 0.0004s
4551-- execute("ALTER TABLE commits RENAME CONSTRAINT fk_new_commits_on_tag_id TO fk_commits_on_tag_id")
4552 -> 0.0003s
4553-- execute("ALTER TABLE crons RENAME CONSTRAINT fk_new_crons_on_branch_id TO fk_crons_on_branch_id")
4554 -> 0.0003s
4555-- execute("ALTER TABLE job_configs RENAME CONSTRAINT fk_new_job_configs_on_repository_id TO fk_job_configs_on_repository_id")
4556 -> 0.0003s
4557-- execute("ALTER TABLE build_configs RENAME CONSTRAINT fk_new_build_configs_on_repository_id TO fk_build_configs_on_repository_id")
4558 -> 0.0003s
4559-- execute("ALTER TABLE pull_requests RENAME CONSTRAINT fk_new_pull_requests_on_repository_id TO fk_pull_requests_on_repository_id")
4560 -> 0.0004s
4561-- execute("ALTER TABLE ssl_keys RENAME CONSTRAINT fk_new_ssl_keys_on_repository_id TO fk_ssl_keys_on_repository_id")
4562 -> 0.0003s
4563-- execute("ALTER TABLE requests RENAME CONSTRAINT fk_new_requests_on_commit_id TO fk_requests_on_commit_id")
4564 -> 0.0003s
4565-- execute("ALTER TABLE requests RENAME CONSTRAINT fk_new_requests_on_pull_request_id TO fk_requests_on_pull_request_id")
4566 -> 0.0004s
4567-- execute("ALTER TABLE requests RENAME CONSTRAINT fk_new_requests_on_branch_id TO fk_requests_on_branch_id")
4568 -> 0.0003s
4569-- execute("ALTER TABLE requests RENAME CONSTRAINT fk_new_requests_on_tag_id TO fk_requests_on_tag_id")
4570 -> 0.0004s
4571-- execute("ALTER TABLE requests RENAME CONSTRAINT fk_new_requests_on_config_id TO fk_requests_on_config_id")
4572 -> 0.0005s
4573-- execute("ALTER TABLE stages RENAME CONSTRAINT fk_new_stages_on_build_id TO fk_stages_on_build_id")
4574 -> 0.0003s
4575== 20190718092750 AddDeleteCascadeToForeignKeys: migrated (0.1233s) ===========
4577== 20190718100426 UpdateSoftDeleteProcedure: migrating ========================
4578-- execute("DROP FUNCTION IF EXISTS soft_delete_repo_data(bigint);\nCREATE FUNCTION soft_delete_repo_data(r_id bigint) RETURNS void AS $$\nDECLARE\n request_raw_config_ids bigint[];\n request_raw_configuration_ids bigint[];\n request_yaml_config_ids bigint[];\n request_config_ids bigint[];\n tag_ids bigint[];\n ssl_key_ids bigint[];\n build_config_ids bigint[];\n job_config_ids bigint[];\n build_ids bigint[];\n pull_request_ids bigint[];\n commit_ids bigint[];\n request_ids bigint[];\n request_payload_ids bigint[];\n stage_ids bigint[];\n job_ids bigint[];\nBEGIN\n SELECT INTO job_ids array_agg(id) FROM jobs WHERE repository_id = r_id;\n SELECT INTO stage_ids array_agg(id) FROM stages WHERE build_id IN (SELECT id FROM builds WHERE repository_id = r_id);\n SELECT INTO request_payload_ids array_agg(id) FROM request_payloads WHERE request_id IN (SELECT id FROM requests WHERE repository_id = r_id);\n SELECT INTO request_ids array_agg(id) FROM requests WHERE repository_id = r_id;\n SELECT INTO commit_ids array_agg(id) FROM commits WHERE repository_id = r_id;\n SELECT INTO pull_request_ids array_agg(id) FROM pull_requests WHERE repository_id = r_id;\n SELECT INTO build_ids array_agg(id) FROM builds WHERE repository_id = r_id;\n SELECT INTO job_config_ids array_agg(id) FROM job_configs WHERE repository_id = r_id;\n SELECT INTO build_config_ids array_agg(id) FROM build_configs WHERE repository_id = r_id;\n SELECT INTO ssl_key_ids array_agg(id) FROM ssl_keys WHERE repository_id = r_id;\n SELECT INTO tag_ids array_agg(id) FROM tags WHERE repository_id = r_id;\n SELECT INTO request_config_ids array_agg(id) FROM request_configs WHERE repository_id = r_id;\n SELECT INTO request_yaml_config_ids array_agg(id) FROM request_yaml_configs WHERE repository_id = r_id;\n SELECT INTO request_raw_configuration_ids array_agg(id) FROM request_raw_configurations WHERE request_id = ANY(request_ids);\n SELECT INTO request_raw_config_ids array_agg(id) FROM request_raw_configs WHERE id IN (SELECT request_raw_config_id FROM request_raw_configurations WHERE request_id = ANY(request_ids));\n\n INSERT INTO deleted_jobs SELECT * FROM jobs WHERE id = ANY(job_ids);\n INSERT INTO deleted_stages SELECT * FROM stages WHERE id = ANY(stage_ids);\n INSERT INTO deleted_request_payloads SELECT * FROM request_payloads WHERE id = ANY(request_payload_ids);\n INSERT INTO deleted_requests SELECT * FROM requests WHERE id = ANY(request_ids);\n INSERT INTO deleted_commits SELECT * FROM commits WHERE id = ANY(commit_ids);\n INSERT INTO deleted_pull_requests SELECT * FROM pull_requests WHERE id = ANY(pull_request_ids);\n INSERT INTO deleted_builds SELECT * FROM builds WHERE id = ANY(build_ids);\n INSERT INTO deleted_job_configs SELECT * FROM job_configs WHERE id = ANY(job_config_ids);\n INSERT INTO deleted_build_configs SELECT * FROM build_configs WHERE id = ANY(build_config_ids);\n INSERT INTO deleted_ssl_keys SELECT * FROM ssl_keys WHERE id = ANY(ssl_key_ids);\n INSERT INTO deleted_tags SELECT * FROM tags WHERE id = ANY(tag_ids);\n INSERT INTO deleted_request_configs SELECT * FROM request_configs WHERE id = ANY(request_config_ids);\n INSERT INTO deleted_request_yaml_configs SELECT * FROM request_yaml_configs WHERE id = ANY(request_yaml_config_ids);\n INSERT INTO deleted_request_raw_configurations SELECT * FROM request_raw_configurations WHERE id = ANY(request_raw_configuration_ids);\n INSERT INTO deleted_request_raw_configs SELECT * FROM request_raw_configs WHERE id = ANY(request_raw_config_ids);\n\n DELETE FROM jobs WHERE id = ANY(job_ids);\n DELETE FROM stages WHERE id = ANY(stage_ids);\n DELETE FROM request_payloads WHERE id = ANY(request_payload_ids);\n DELETE FROM requests WHERE id = ANY(request_ids);\n DELETE FROM commits WHERE id = ANY(commit_ids);\n DELETE FROM pull_requests WHERE id = ANY(pull_request_ids);\n DELETE FROM builds WHERE id = ANY(build_ids);\n DELETE FROM job_configs WHERE id = ANY(job_config_ids);\n DELETE FROM build_configs WHERE id = ANY(build_config_ids);\n DELETE FROM ssl_keys WHERE id = ANY(ssl_key_ids);\n DELETE FROM tags WHERE id = ANY(tag_ids);\n DELETE FROM request_configs WHERE id = ANY(request_config_ids);\n DELETE FROM request_yaml_configs WHERE id = ANY(request_yaml_config_ids);\n DELETE FROM request_raw_configurations WHERE id = ANY(request_raw_configuration_ids);\n DELETE FROM request_raw_configs WHERE id = ANY(request_raw_config_ids);\nEND;\n$$ LANGUAGE plpgsql;\n")
4579 -> 0.0040s
4580== 20190718100426 UpdateSoftDeleteProcedure: migrated (0.0049s) ===============
4582== 20190725103113 UpdateSoftDelete: migrating =================================
4583-- execute("create table deleted_request_yaml_configs (like request_yaml_configs)")
4584 -> 0.0039s
4585-- execute("DROP FUNCTION IF EXISTS soft_delete_repo_data(bigint);\nCREATE FUNCTION soft_delete_repo_data(r_id bigint) RETURNS void AS $$\nDECLARE\n request_raw_config_ids bigint[];\n request_raw_configuration_ids bigint[];\n request_yaml_config_ids bigint[];\n request_config_ids bigint[];\n tag_ids bigint[];\n ssl_key_ids bigint[];\n build_config_ids bigint[];\n job_config_ids bigint[];\n build_ids bigint[];\n pull_request_ids bigint[];\n commit_ids bigint[];\n request_ids bigint[];\n request_payload_ids bigint[];\n stage_ids bigint[];\n job_ids bigint[];\nBEGIN\n SELECT INTO job_ids array_agg(id) FROM jobs WHERE repository_id = r_id;\n SELECT INTO stage_ids array_agg(id) FROM stages WHERE build_id IN (SELECT id FROM builds WHERE repository_id = r_id);\n SELECT INTO request_payload_ids array_agg(id) FROM request_payloads WHERE request_id IN (SELECT id FROM requests WHERE repository_id = r_id);\n SELECT INTO request_ids array_agg(id) FROM requests WHERE repository_id = r_id;\n SELECT INTO commit_ids array_agg(id) FROM commits WHERE repository_id = r_id;\n SELECT INTO pull_request_ids array_agg(id) FROM pull_requests WHERE repository_id = r_id;\n SELECT INTO build_ids array_agg(id) FROM builds WHERE repository_id = r_id;\n SELECT INTO job_config_ids array_agg(id) FROM job_configs WHERE repository_id = r_id;\n SELECT INTO build_config_ids array_agg(id) FROM build_configs WHERE repository_id = r_id;\n SELECT INTO ssl_key_ids array_agg(id) FROM ssl_keys WHERE repository_id = r_id;\n SELECT INTO tag_ids array_agg(id) FROM tags WHERE repository_id = r_id;\n SELECT INTO request_config_ids array_agg(id) FROM request_configs WHERE repository_id = r_id;\n SELECT INTO request_yaml_config_ids array_agg(id) FROM request_yaml_configs WHERE repository_id = r_id;\n SELECT INTO request_raw_configuration_ids array_agg(id) FROM request_raw_configurations WHERE request_id = ANY(request_ids);\n SELECT INTO request_raw_config_ids array_agg(id) FROM request_raw_configs WHERE id IN (SELECT request_raw_config_id FROM request_raw_configurations WHERE request_id = ANY(request_ids));\n\n INSERT INTO deleted_jobs SELECT * FROM jobs WHERE id = ANY(job_ids);\n INSERT INTO deleted_stages SELECT * FROM stages WHERE id = ANY(stage_ids);\n INSERT INTO deleted_request_payloads SELECT * FROM request_payloads WHERE id = ANY(request_payload_ids);\n INSERT INTO deleted_requests SELECT * FROM requests WHERE id = ANY(request_ids);\n INSERT INTO deleted_commits SELECT * FROM commits WHERE id = ANY(commit_ids);\n INSERT INTO deleted_pull_requests SELECT * FROM pull_requests WHERE id = ANY(pull_request_ids);\n INSERT INTO deleted_builds SELECT * FROM builds WHERE id = ANY(build_ids);\n INSERT INTO deleted_job_configs SELECT * FROM job_configs WHERE id = ANY(job_config_ids);\n INSERT INTO deleted_build_configs SELECT * FROM build_configs WHERE id = ANY(build_config_ids);\n INSERT INTO deleted_ssl_keys SELECT * FROM ssl_keys WHERE id = ANY(ssl_key_ids);\n INSERT INTO deleted_tags SELECT * FROM tags WHERE id = ANY(tag_ids);\n INSERT INTO deleted_request_configs SELECT * FROM request_configs WHERE id = ANY(request_config_ids);\n INSERT INTO deleted_request_yaml_configs SELECT * FROM request_yaml_configs WHERE id = ANY(request_yaml_config_ids);\n INSERT INTO deleted_request_raw_configurations SELECT * FROM request_raw_configurations WHERE id = ANY(request_raw_configuration_ids);\n INSERT INTO deleted_request_raw_configs SELECT * FROM request_raw_configs WHERE id = ANY(request_raw_config_ids);\n\n DELETE FROM jobs WHERE id = ANY(job_ids);\n DELETE FROM stages WHERE id = ANY(stage_ids);\n DELETE FROM request_payloads WHERE id = ANY(request_payload_ids);\n DELETE FROM requests WHERE id = ANY(request_ids);\n DELETE FROM commits WHERE id = ANY(commit_ids);\n DELETE FROM pull_requests WHERE id = ANY(pull_request_ids);\n DELETE FROM builds WHERE id = ANY(build_ids);\n DELETE FROM job_configs WHERE id = ANY(job_config_ids);\n DELETE FROM build_configs WHERE id = ANY(build_config_ids);\n DELETE FROM ssl_keys WHERE id = ANY(ssl_key_ids);\n DELETE FROM tags WHERE id = ANY(tag_ids);\n DELETE FROM request_configs WHERE id = ANY(request_config_ids);\n DELETE FROM request_yaml_configs WHERE id = ANY(request_yaml_config_ids);\n DELETE FROM request_raw_configurations WHERE id = ANY(request_raw_configuration_ids);\n DELETE FROM request_raw_configs WHERE id = ANY(request_raw_config_ids);\nEND;\n$$ LANGUAGE plpgsql;\n")
4586 -> 0.0026s
4587== 20190725103113 UpdateSoftDelete: migrated (0.0069s) ========================
4589== 20190725105934 AddOrgIdToConfigs: migrating ================================
4590-- add_column(:job_configs, :org_id, :bigint)
4591 -> 0.0019s
4592-- add_column(:deleted_job_configs, :org_id, :bigint)
4593 -> 0.0015s
4594-- add_column(:build_configs, :org_id, :bigint)
4595 -> 0.0015s
4596-- add_column(:deleted_build_configs, :org_id, :bigint)
4597 -> 0.0011s
4598-- add_column(:request_configs, :org_id, :bigint)
4599 -> 0.0014s
4600-- add_column(:deleted_request_configs, :org_id, :bigint)
4601 -> 0.0013s
4602-- add_column(:request_yaml_configs, :org_id, :bigint)
4603 -> 0.0012s
4604-- add_column(:deleted_request_yaml_configs, :org_id, :bigint)
4605 -> 0.0013s
4606-- add_column(:request_payloads, :org_id, :bigint)
4607 -> 0.0012s
4608-- add_column(:deleted_request_payloads, :org_id, :bigint)
4609 -> 0.0014s
4610-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_job_configs_on_org_id ON job_configs (org_id)")
4611 -> 0.0042s
4612-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_build_configs_on_org_id ON build_configs (org_id)")
4613 -> 0.0038s
4614-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_configs_on_org_id ON request_configs (org_id)")
4615 -> 0.0041s
4616-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_yaml_configs_on_org_id ON request_yaml_configs (org_id)")
4617 -> 0.0040s
4618-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_payloads_on_org_id ON request_payloads (org_id)")
4619 -> 0.0038s
4620== 20190725105934 AddOrgIdToConfigs: migrated (0.0347s) =======================
4622== 20190729105934 AddOrgAndComIdsToRawConfigs: migrating ======================
4623-- add_column(:request_raw_configs, :org_id, :bigint)
4624 -> 0.0011s
4625-- add_column(:request_raw_configurations, :org_id, :bigint)
4626 -> 0.0013s
4627-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_raw_configs_on_org_id ON request_raw_configs (org_id)")
4628 -> 0.0039s
4629-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_raw_configurations_on_org_id ON request_raw_configurations (org_id)")
4630 -> 0.0035s
4631== 20190729105934 AddOrgAndComIdsToRawConfigs: migrated (0.0099s) =============
4633== 20190801120510 AddMoreDeletedTables: migrating =============================
4634-- execute("create table if not exists deleted_request_raw_configs (like request_raw_configs)")
4635 -> 0.0030s
4636-- execute("create table if not exists deleted_request_raw_configurations (like request_raw_configurations)")
4637 -> 0.0025s
4638-- execute("DROP FUNCTION IF EXISTS soft_delete_repo_data(bigint);\nCREATE FUNCTION soft_delete_repo_data(r_id bigint) RETURNS void AS $$\nDECLARE\n request_raw_config_ids bigint[];\n request_raw_configuration_ids bigint[];\n request_yaml_config_ids bigint[];\n request_config_ids bigint[];\n tag_ids bigint[];\n ssl_key_ids bigint[];\n build_config_ids bigint[];\n job_config_ids bigint[];\n build_ids bigint[];\n pull_request_ids bigint[];\n commit_ids bigint[];\n request_ids bigint[];\n request_payload_ids bigint[];\n stage_ids bigint[];\n job_ids bigint[];\nBEGIN\n SELECT INTO job_ids array_agg(id) FROM jobs WHERE repository_id = r_id;\n SELECT INTO stage_ids array_agg(id) FROM stages WHERE build_id IN (SELECT id FROM builds WHERE repository_id = r_id);\n SELECT INTO request_payload_ids array_agg(id) FROM request_payloads WHERE request_id IN (SELECT id FROM requests WHERE repository_id = r_id);\n SELECT INTO request_ids array_agg(id) FROM requests WHERE repository_id = r_id;\n SELECT INTO commit_ids array_agg(id) FROM commits WHERE repository_id = r_id;\n SELECT INTO pull_request_ids array_agg(id) FROM pull_requests WHERE repository_id = r_id;\n SELECT INTO build_ids array_agg(id) FROM builds WHERE repository_id = r_id;\n SELECT INTO job_config_ids array_agg(id) FROM job_configs WHERE repository_id = r_id;\n SELECT INTO build_config_ids array_agg(id) FROM build_configs WHERE repository_id = r_id;\n SELECT INTO ssl_key_ids array_agg(id) FROM ssl_keys WHERE repository_id = r_id;\n SELECT INTO tag_ids array_agg(id) FROM tags WHERE repository_id = r_id;\n SELECT INTO request_config_ids array_agg(id) FROM request_configs WHERE repository_id = r_id;\n SELECT INTO request_yaml_config_ids array_agg(id) FROM request_yaml_configs WHERE repository_id = r_id;\n SELECT INTO request_raw_configuration_ids array_agg(id) FROM request_raw_configurations WHERE request_id = ANY(request_ids);\n SELECT INTO request_raw_config_ids array_agg(id) FROM request_raw_configs WHERE id IN (SELECT request_raw_config_id FROM request_raw_configurations WHERE request_id = ANY(request_ids));\n\n INSERT INTO deleted_jobs SELECT * FROM jobs WHERE id = ANY(job_ids);\n INSERT INTO deleted_stages SELECT * FROM stages WHERE id = ANY(stage_ids);\n INSERT INTO deleted_request_payloads SELECT * FROM request_payloads WHERE id = ANY(request_payload_ids);\n INSERT INTO deleted_requests SELECT * FROM requests WHERE id = ANY(request_ids);\n INSERT INTO deleted_commits SELECT * FROM commits WHERE id = ANY(commit_ids);\n INSERT INTO deleted_pull_requests SELECT * FROM pull_requests WHERE id = ANY(pull_request_ids);\n INSERT INTO deleted_builds SELECT * FROM builds WHERE id = ANY(build_ids);\n INSERT INTO deleted_job_configs SELECT * FROM job_configs WHERE id = ANY(job_config_ids);\n INSERT INTO deleted_build_configs SELECT * FROM build_configs WHERE id = ANY(build_config_ids);\n INSERT INTO deleted_ssl_keys SELECT * FROM ssl_keys WHERE id = ANY(ssl_key_ids);\n INSERT INTO deleted_tags SELECT * FROM tags WHERE id = ANY(tag_ids);\n INSERT INTO deleted_request_configs SELECT * FROM request_configs WHERE id = ANY(request_config_ids);\n INSERT INTO deleted_request_yaml_configs SELECT * FROM request_yaml_configs WHERE id = ANY(request_yaml_config_ids);\n INSERT INTO deleted_request_raw_configurations SELECT * FROM request_raw_configurations WHERE id = ANY(request_raw_configuration_ids);\n INSERT INTO deleted_request_raw_configs SELECT * FROM request_raw_configs WHERE id = ANY(request_raw_config_ids);\n\n DELETE FROM jobs WHERE id = ANY(job_ids);\n DELETE FROM stages WHERE id = ANY(stage_ids);\n DELETE FROM request_payloads WHERE id = ANY(request_payload_ids);\n DELETE FROM requests WHERE id = ANY(request_ids);\n DELETE FROM commits WHERE id = ANY(commit_ids);\n DELETE FROM pull_requests WHERE id = ANY(pull_request_ids);\n DELETE FROM builds WHERE id = ANY(build_ids);\n DELETE FROM job_configs WHERE id = ANY(job_config_ids);\n DELETE FROM build_configs WHERE id = ANY(build_config_ids);\n DELETE FROM ssl_keys WHERE id = ANY(ssl_key_ids);\n DELETE FROM tags WHERE id = ANY(tag_ids);\n DELETE FROM request_configs WHERE id = ANY(request_config_ids);\n DELETE FROM request_yaml_configs WHERE id = ANY(request_yaml_config_ids);\n DELETE FROM request_raw_configurations WHERE id = ANY(request_raw_configuration_ids);\n DELETE FROM request_raw_configs WHERE id = ANY(request_raw_config_ids);\nEND;\n$$ LANGUAGE plpgsql;\n")
4639 -> 0.0019s
4640== 20190801120510 AddMoreDeletedTables: migrated (0.0078s) ====================
4642== 20190815152336 AddComIdToMoreTables: migrating =============================
4643-- add_column(:request_configs, :com_id, :bigint)
4644 -> 0.0012s
4645-- add_column(:request_yaml_configs, :com_id, :bigint)
4646 -> 0.0010s
4647-- add_column(:deleted_request_configs, :com_id, :bigint)
4648 -> 0.0011s
4649-- add_column(:deleted_request_yaml_configs, :com_id, :bigint)
4650 -> 0.0010s
4651-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_configs_on_com_id ON request_configs (com_id)")
4652 -> 0.0037s
4653-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_yaml_configs_on_com_id ON request_yaml_configs (com_id)")
4654 -> 0.0037s
4655== 20190815152336 AddComIdToMoreTables: migrated (0.0120s) ====================
4657== 20190815164320 AddComIdToBuildConfigs: migrating ===========================
4658-- add_column(:build_configs, :com_id, :bigint)
4659 -> 0.0011s
4660-- add_column(:deleted_build_configs, :com_id, :bigint)
4661 -> 0.0012s
4662-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_build_configs_on_com_id ON build_configs (com_id)")
4663 -> 0.0063s
4664== 20190815164320 AddComIdToBuildConfigs: migrated (0.0088s) ==================
4666== 20190815172205 AddComIdToJobConfigs: migrating =============================
4667-- add_column(:job_configs, :com_id, :bigint)
4668 -> 0.0010s
4669-- add_column(:deleted_job_configs, :com_id, :bigint)
4670 -> 0.0009s
4671-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_job_configs_on_com_id ON job_configs (com_id)")
4672 -> 0.0036s
4673== 20190815172205 AddComIdToJobConfigs: migrated (0.0056s) ====================
4675== 20190819082558 AddVcsIdToUser: migrating ===================================
4676-- add_column(:users, :vcs_id, :string, {:default=>nil})
4677 -> 0.0016s
4678-- execute("CREATE INDEX CONCURRENTLY index_users_on_vcs_id_and_vcs_type ON users (vcs_id, vcs_type);")
4679 -> 0.0036s
4680== 20190819082558 AddVcsIdToUser: migrated (0.0054s) ==========================
4682== 20190819082559 AddVcsIdToRepository: migrating =============================
4683-- add_column(:repositories, :vcs_id, :string, {:default=>nil})
4684 -> 0.0015s
4685-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_vcs_id_and_vcs_type ON repositories (vcs_id, vcs_type);")
4686 -> 0.0039s
4687== 20190819082559 AddVcsIdToRepository: migrated (0.0055s) ====================
4689== 20190820082431 AddVcsIdToOrganization: migrating ===========================
4690-- add_column(:organizations, :vcs_id, :string, {:default=>nil})
4691 -> 0.0013s
4692-- execute("CREATE INDEX CONCURRENTLY index_organizations_on_vcs_id_and_vcs_type ON organizations (vcs_id, vcs_type);")
4693 -> 0.0036s
4694== 20190820082431 AddVcsIdToOrganization: migrated (0.0050s) ==================
4696== 20190913092543 CopyVcsIdForRepository: migrating ===========================
4697-- select_value("SELECT id FROM repositories ORDER BY id DESC LIMIT 1")
4698 -> 0.0008s
4699-- execute("UPDATE \"repositories\" SET vcs_id = github_id WHERE id BETWEEN 0 AND 5000")
4700 -> 0.0007s
4701== 20190913092543 CopyVcsIdForRepository: migrated (0.0019s) ==================
4703== 20190913092554 CopyVcsIdForUser: migrating =================================
4704-- select_value("SELECT id FROM users ORDER BY id DESC LIMIT 1")
4705 -> 0.0008s
4706-- execute("UPDATE \"users\" SET vcs_id = github_id WHERE id BETWEEN 0 AND 5000")
4707 -> 0.0008s
4708== 20190913092554 CopyVcsIdForUser: migrated (0.0021s) ========================
4710== 20190913092565 CopyVcsIdForOrganization: migrating =========================
4711-- select_value("SELECT id FROM organizations ORDER BY id DESC LIMIT 1")
4712 -> 0.0006s
4713-- execute("UPDATE \"organizations\" SET vcs_id = github_id WHERE id BETWEEN 0 AND 5000")
4714 -> 0.0015s
4715== 20190913092565 CopyVcsIdForOrganization: migrated (0.0032s) ================
4717== 20190920160300 MessagesAddTypeSourceLine: migrating ========================
4718-- add_column(:messages, :type, :string, {:default=>nil})
4719 -> 0.0022s
4720-- add_column(:messages, :src, :string, {:default=>nil})
4721 -> 0.0021s
4722-- add_column(:messages, :line, :integer, {:default=>nil})
4723 -> 0.0020s
4724== 20190920160300 MessagesAddTypeSourceLine: migrated (0.0067s) ===============
4726== 20191112000000 ReposAddFork: migrating =====================================
4727-- add_column(:repositories, :fork, :boolean, {:default=>nil})
4728 -> 0.0023s
4729== 20191112000000 ReposAddFork: migrated (0.0025s) ============================
4731== 20191112172015 AddVcsIndexToRepositories: migrating ========================
4732-- add_index(:repositories, [:vcs_type, :vcs_id], {:algorithm=>:concurrently})
4733 -> 0.0075s
4734== 20191112172015 AddVcsIndexToRepositories: migrated (0.0077s) ===============
4736== 20191112172332 AddVcsIndexToUsers: migrating ===============================
4737-- add_index(:users, [:vcs_type, :vcs_id], {:algorithm=>:concurrently})
4738 -> 0.0040s
4739== 20191112172332 AddVcsIndexToUsers: migrated (0.0041s) ======================
4741== 20191219091445 AddHeadRepoVcsIdToPullRequest: migrating ====================
4742-- add_column(:pull_requests, :head_repo_vcs_id, :string, {:default=>nil})
4743 -> 0.0017s
4744-- execute("CREATE INDEX CONCURRENTLY index_pull_requests_on_head_repo_vcs_id ON pull_requests (head_repo_vcs_id);")
4745 -> 0.0036s
4746== 20191219091445 AddHeadRepoVcsIdToPullRequest: migrated (0.0055s) ===========
4748== 20191219091446 AddHeadRepoVcsIdToDeletedPullRequest: migrating =============
4749-- add_column(:deleted_pull_requests, :head_repo_vcs_id, :string, {:default=>nil})
4750 -> 0.0022s
4751-- execute("CREATE INDEX CONCURRENTLY index_deleted_pull_requests_on_head_repo_vcs_id ON deleted_pull_requests (head_repo_vcs_id);")
4752 -> 0.0039s
4753== 20191219091446 AddHeadRepoVcsIdToDeletedPullRequest: migrated (0.0064s) ====
4755== 20200122000000 AddConfigsJson: migrating ===================================
4756-- add_column(:request_configs, :config_json, :json)
4757 -> 0.0021s
4758-- add_column(:build_configs, :config_json, :json)
4759 -> 0.0011s
4760-- add_column(:job_configs, :config_json, :json)
4761 -> 0.0013s
4762-- add_column(:deleted_request_configs, :config_json, :json)
4763 -> 0.0013s
4764-- add_column(:deleted_build_configs, :config_json, :json)
4765 -> 0.0011s
4766-- add_column(:deleted_job_configs, :config_json, :json)
4767 -> 0.0011s
4768== 20200122000000 AddConfigsJson: migrated (0.0084s) ==========================
4770== 20200127000000 DropJobConfigsGpu: migrating ================================
4771-- execute("DROP MATERIALIZED VIEW job_configs_gpu\n")
4772 -> 0.0018s
4773== 20200127000000 DropJobConfigsGpu: migrated (0.0020s) =======================
4775== 20200127000001 RenameConfigsJson: migrating ================================
4776-- remove_column(:request_configs, :config)
4777 -> 0.0016s
4778-- rename_column(:request_configs, :config_json, :config)
4779 -> 0.0053s
4780-- remove_column(:build_configs, :config)
4781 -> 0.0012s
4782-- rename_column(:build_configs, :config_json, :config)
4783 -> 0.0056s
4784-- remove_column(:job_configs, :config)
4785 -> 0.0012s
4786-- rename_column(:job_configs, :config_json, :config)
4787 -> 0.0055s
4788-- remove_column(:deleted_request_configs, :config)
4789 -> 0.0009s
4790-- rename_column(:deleted_request_configs, :config_json, :config)
4791 -> 0.0024s
4792-- remove_column(:deleted_build_configs, :config)
4793 -> 0.0010s
4794-- rename_column(:deleted_build_configs, :config_json, :config)
4795 -> 0.0021s
4796-- remove_column(:deleted_job_configs, :config)
4797 -> 0.0010s
4798-- rename_column(:deleted_job_configs, :config_json, :config)
4799 -> 0.0020s
4800== 20200127000001 RenameConfigsJson: migrated (0.0318s) =======================
4802== 20200214144655 AddIndexToJobVersionsOnJobId: migrating =====================
4803-- add_index(:job_versions, :job_id, {:algorithm=>:concurrently})
4804 -> 0.0046s
4805== 20200214144655 AddIndexToJobVersionsOnJobId: migrated (0.0048s) ============
4807== 20200225085734 AddVcsSlugToRepository: migrating ===========================
4808-- add_column(:repositories, :vcs_slug, :string, {:default=>nil})
4809 -> 0.0025s
4810== 20200225085734 AddVcsSlugToRepository: migrated (0.0027s) ==================
4812== 20200227085734 AddVcsSourceHostToRepository: migrating =====================
4813-- add_column(:repositories, :vcs_source_host, :string, {:default=>nil})
4814 -> 0.0015s
4815== 20200227085734 AddVcsSourceHostToRepository: migrated (0.0016s) ============
4817== 20200227085736 AddVcsIndexes: migrating ====================================
4818-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_lower_slug_or_on_lower_owner_name ON repositories (LOWER(vcs_slug), LOWER(owner_name), LOWER(name), LOWER(vcs_type)) WHERE invalidated_at IS NULL")
4819 -> 0.0045s
4820== 20200227085736 AddVcsIndexes: migrated (0.0046s) ===========================
4822== 20200227085737 AddRepositoryNameAndSlugIndex: migrating ====================
4823-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_slug_or_names ON repositories (vcs_slug, owner_name, name) WHERE invalidated_at IS NULL")
4824 -> 0.0039s
4825== 20200227085737 AddRepositoryNameAndSlugIndex: migrated (0.0040s) ===========
4827== 20200227085742 AddPullRequestSourceData: migrating =========================
4828-- add_column(:pull_requests, :base_repo_slug, :string, {:default=>nil})
4829 -> 0.0016s
4830-- add_column(:pull_requests, :base_repo_vcs_id, :string, {:default=>nil})
4831 -> 0.0016s
4832-- add_column(:pull_requests, :base_ref, :string, {:default=>nil})
4833 -> 0.0015s
4834-- add_column(:deleted_pull_requests, :base_repo_slug, :string, {:default=>nil})
4835 -> 0.0014s
4836-- add_column(:deleted_pull_requests, :base_repo_vcs_id, :string, {:default=>nil})
4837 -> 0.0131s
4838-- add_column(:deleted_pull_requests, :base_ref, :string, {:default=>nil})
4839 -> 0.0021s
4840== 20200227085742 AddPullRequestSourceData: migrated (0.0218s) ================
4842== 20200312184018 AddUserUtmParamsTable: migrating ============================
4843-- create_table(:user_utm_params)
4844 -> 0.0093s
4845== 20200312184018 AddUserUtmParamsTable: migrated (0.0095s) ===================
4847== 20200316085738 AddRepositoryVcsSlugIndex: migrating ========================
4848-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_lower_vcs_slug ON repositories (LOWER(vcs_slug))")
4849 -> 0.0038s
4850-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_lower_vcs_slug_valid ON repositories (LOWER(vcs_slug)) WHERE invalidated_at IS NULL")
4851 -> 0.0043s
4852== 20200316085738 AddRepositoryVcsSlugIndex: migrated (0.0083s) ===============
4854== 20200325115329 AddMultipleJobStateIndexesOrderByNewest: migrating ==========
4855-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_booting_jobs_on_repository_id_order_by_newest on jobs (repository_id, id desc) where state = 'booting'")
4856 -> 0.0038s
4857-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_canceled_jobs_on_repository_id_order_by_newest on jobs (repository_id, id desc) where state = 'canceled'")
4858 -> 0.0039s
4859-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_created_jobs_on_repository_id_order_by_newest on jobs (repository_id, id desc) where state = 'created'")
4860 -> 0.0039s
4861-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_errored_jobs_on_repository_id_order_by_newest on jobs (repository_id, id desc) where state = 'errored'")
4862 -> 0.0038s
4863-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_failed_jobs_on_repository_id_order_by_newest on jobs (repository_id, id desc) where state = 'failed'")
4864 -> 0.0039s
4865-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_passed_jobs_on_repository_id_order_by_newest on jobs (repository_id, id desc) where state = 'passed'")
4866 -> 0.0042s
4867-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_queued_jobs_on_repository_id_order_by_newest on jobs (repository_id, id desc) where state = 'queued'")
4868 -> 0.0042s
4869-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_received_jobs_on_repository_id_order_by_newest on jobs (repository_id, id desc) where state = 'received'")
4870 -> 0.0041s
4871-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_started_jobs_on_repository_id_order_by_newest on jobs (repository_id, id desc) where state = 'started'")
4872 -> 0.0042s
4873== 20200325115329 AddMultipleJobStateIndexesOrderByNewest: migrated (0.0366s) =
4875== 20200325130013 AddFunctionMostRecentJobIdsForUserRepositoriesByStates: migrating
4876-- execute("\n CREATE OR REPLACE FUNCTION\n most_recent_job_ids_for_user_repositories_by_states(uid int, states varchar default '') RETURNS table (id bigint) AS\n $BODY$\n DECLARE\n rid int;\n BEGIN\n SET LOCAL work_mem = '16MB';\n IF states <> '' THEN\n RETURN QUERY WITH matrix AS (\n SELECT repository_id, replace(replace(job_state::varchar, '(', ''), ')', '') as job_state\n FROM permissions p\n CROSS JOIN (\n SELECT unnest(regexp_split_to_array(states, ','))\n ) AS job_state\n WHERE p.user_id = uid\n )\n SELECT recent.id\n FROM matrix m\n CROSS JOIN LATERAL (\n SELECT job_id AS id, repository_id\n FROM most_recent_job_ids_for_repository_by_state(m.repository_id, m.job_state::varchar)\n ) AS recent\n ORDER BY id desc;\n ELSE\n for rid in\n SELECT repository_id\n FROM permissions\n WHERE user_id = uid\n LOOP\n RETURN QUERY select j.id from jobs j where repository_id = rid order by j.id desc limit 100;\n END LOOP;\n END IF;\n END\n $BODY$\n LANGUAGE plpgsql;\n ")
4877 -> 0.0013s
4878== 20200325130013 AddFunctionMostRecentJobIdsForUserRepositoriesByStates: migrated (0.0014s)
4880== 20200330110527 AddFunctionMostRecentJobIdsForRepositoryByState: migrating ==
4881-- execute("\n CREATE OR REPLACE FUNCTION\n most_recent_job_ids_for_repository_by_state(rid int, st varchar) RETURNS table (job_id bigint, repository_id int) AS\n $BODY$\n DECLARE\n BEGIN\n RETURN QUERY select j.id, j.repository_id from jobs j where j.repository_id = rid and j.state = st order by j.id desc limit 100;\n END\n $BODY$\n LANGUAGE plpgsql;\n ")
4882 -> 0.0010s
4883== 20200330110527 AddFunctionMostRecentJobIdsForRepositoryByState: migrated (0.0011s)
4885== 20200406121218 AddIndexJobsOnRepositoryIdOrderByNewest: migrating ==========
4886-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_jobs_on_repository_id_order_by_newest on jobs (repository_id, id desc)")
4887 -> 0.0043s
4888== 20200406121218 AddIndexJobsOnRepositoryIdOrderByNewest: migrated (0.0044s) =
4890== 20200424000000 RequestRawConfigurationsAddMergeMode: migrating =============
4891-- add_column(:request_raw_configurations, :merge_mode, :string, {:default=>nil})
4892 -> 0.0025s
4893-- add_column(:deleted_request_raw_configurations, :merge_mode, :string, {:default=>nil})
4894 -> 0.0025s
4895== 20200424000000 RequestRawConfigurationsAddMergeMode: migrated (0.0052s) ====
4897== 20200527123653 AddColumnPriorityToTableJobsAndDeletedJobs: migrating =======
4898-- add_column(:jobs, :priority, :integer, {:default=>nil})
4899 -> 0.0023s
4900-- add_column(:deleted_jobs, :priority, :integer, {:default=>nil})
4901 -> 0.0016s
4902== 20200527123653 AddColumnPriorityToTableJobsAndDeletedJobs: migrated (0.0042s)
4904== 20200928143126 AddBuildTriggerPermissions: migrating =======================
4905-- add_column(:memberships, :build_permission, :boolean, {:default=>nil})
4906 -> 0.0017s
4907-- add_column(:permissions, :build, :boolean, {:default=>nil})
4908 -> 0.0016s
4909== 20200928143126 AddBuildTriggerPermissions: migrated (0.0035s) ==============
4911== 20202427123653 AddColumnHasLocalRegistrationToTableSubscriptions: migrating
4912-- add_column(:subscriptions, :has_local_registration, :boolean, {:default=>nil})
4913 -> 0.0017s
4914== 20202427123653 AddColumnHasLocalRegistrationToTableSubscriptions: migrated (0.0019s)
4916== 20210203130200 CreateBuildBackupsTable: migrating ==========================
4917-- create_table(:build_backups, {:id=>:integer})
4918 -> 0.0070s
4919== 20210203130200 CreateBuildBackupsTable: migrated (0.0071s) =================
4921== 20210203143155 AddConfirmationFieldsToUser: migrating ======================
4922-- add_column(:users, :confirmed_at, :timestamp, {:precision=>nil})
4923 -> 0.0011s
4924-- add_column(:users, :token_expires_at, :timestamp, {:precision=>nil})
4925 -> 0.0011s
4926-- add_column(:users, :confirmation_token, :string)
4927 -> 0.0009s
4928-- add_index(:users, :confirmation_token)
4929 -> 0.0025s
4930== 20210203143155 AddConfirmationFieldsToUser: migrated (0.0058s) =============
4932== 20210203143406 ConfirmCurrentUsers: migrating ==============================
4933== 20210203143406 ConfirmCurrentUsers: migrated (0.0000s) =====================
4935== 20210614140633 AddServerTypeToRepositories: migrating ======================
4936-- add_column(:repositories, :server_type, :string, {:limit=>20})
4937 -> 0.0018s
4938== 20210614140633 AddServerTypeToRepositories: migrated (0.0018s) =============
4940== 20220610092916 MostRecentJobIdsForUserRepositoriesByStatesLw: migrating ====
4941-- execute("\n CREATE OR REPLACE FUNCTION\n most_recent_job_ids_for_user_repositories_by_states_lw(uid int, states varchar default '') RETURNS table (id bigint)\n LANGUAGE plpgsql\n AS $$\n DECLARE\n rid int;\n BEGIN\n SET LOCAL work_mem = '16MB';\n IF states <> '' THEN\n for rid in\n SELECT repository_id\n FROM permissions\n WHERE user_id = uid\n LOOP\n RETURN QUERY select j.id from jobs j where repository_id = rid and state in (SELECT unnest(regexp_split_to_array(states, ','))) order by j.id desc limit 100;\n END LOOP;\n ELSE\n for rid in\n SELECT repository_id\n FROM permissions\n WHERE user_id = uid\n LOOP\n RETURN QUERY select j.id from jobs j where repository_id = rid order by j.id desc limit 100;\n END LOOP;\n END IF;\n END\n $$;\n ")
4942 -> 0.0013s
4943== 20220610092916 MostRecentJobIdsForUserRepositoriesByStatesLw: migrated (0.0014s)
4945== 20220621151453 AddColumnRestartedByToTableJobs: migrating ==================
4946-- add_column(:jobs, :restarted_by, :integer, {:default=>nil})
4947 -> 0.0017s
4948-- add_column(:deleted_jobs, :restarted_by, :integer, {:default=>nil})
4949 -> 0.0012s
4950== 20220621151453 AddColumnRestartedByToTableJobs: migrated (0.0031s) =========
4952== 20220722162400 CreateAuditsTable: migrating ================================
4953-- create_table(:audits)
4954 -> 0.0070s
4955== 20220722162400 CreateAuditsTable: migrated (0.0072s) =======================
4957== 20220825140522 CreateCustomKeysTable: migrating ============================
4958-- create_table(:custom_keys)
4959 -> 0.0082s
4960== 20220825140522 CreateCustomKeysTable: migrated (0.0083s) ===================
4962== 20220905144600 AddScanFailedAtToRepositories: migrating ====================
4963-- add_column(:repositories, :scan_failed_at, :timestamp)
4964 -> 0.0014s
4965== 20220905144600 AddScanFailedAtToRepositories: migrated (0.0015s) ===========
4967== 20221214171030 AddPurposeColumnToTokens: migrating =========================
4968-- add_column(:tokens, :purpose, :integer, {:limit=>4, :default=>0})
4969 -> 0.0017s
4970== 20221214171030 AddPurposeColumnToTokens: migrated (0.0018s) ================
4972== 20230208161446 AddCloneUrlToRepositories: migrating ========================
4973-- add_column(:repositories, :clone_url, :string)
4974 -> 0.0012s
4975== 20230208161446 AddCloneUrlToRepositories: migrated (0.0013s) ===============
4977== 20230505055250 RolifyCreateRoles: migrating ================================
4978-- create_table(:roles)
4979 -> 0.0094s
4980-- create_table(:role_names)
4981 -> 0.0061s
4982-- create_table(:users_roles, {:id=>false})
4983 -> 0.0063s
4984-- add_index(:roles, :name)
4985 -> 0.0023s
4986-- add_index(:role_names, :name)
4987 -> 0.0023s
4988-- add_index(:roles, [:name, :resource_type, :resource_id])
4989 -> 0.0022s
4990-- add_index(:users_roles, [:user_id, :role_id])
4991 -> 0.0083s
4992== 20230505055250 RolifyCreateRoles: migrated (0.0375s) =======================
4994== 20230505060110 CreatePolicies: migrating ===================================
4995-- create_table(:policy_permissions)
4996 -> 0.0085s
4997-- create_table(:role_permissions, {:id=>false})
4998 -> 0.0060s
4999-- add_index(:policy_permissions, :name)
5000 -> 0.0021s
5001-- add_index(:role_permissions, [:role_name_id, :policy_permission_id])
5002 -> 0.0022s
5003== 20230505060110 CreatePolicies: migrated (0.0192s) ==========================
5005== 20230713115855 CreatePermissionsSync: migrating ============================
5006-- create_table(:permissions_syncs)
5007 -> 0.0097s
5008== 20230713115855 CreatePermissionsSync: migrated (0.0098s) ===================
5010== 20231005111642 CreatePermissionsIndex: migrating ===========================
5011-- add_index(:permissions_syncs, [:user_id, :resource_type, :resource_id], {:name=>"index_permissions_syncs_on_user_and_resource"})
5012 -> 0.0022s
5013-- add_index(:role_names, :role_type)
5014 -> 0.0017s
5015== 20231005111642 CreatePermissionsIndex: migrated (0.0040s) ==================
5017== 20240823085523 AddVmsizeToJobs: migrating ==================================
5018-- add_column(:jobs, :vm_size, :string)
5019 -> 0.0008s
5020-- add_column(:deleted_jobs, :vm_size, :string)
5021 -> 0.0004s
5022== 20240823085523 AddVmsizeToJobs: migrated (0.0012s) =========================
5024== 20250109121404 CreateAccountEnvVarsTable: migrating ========================
5025-- create_table(:account_env_vars)
5026 -> 0.0049s
5027-- add_index(:account_env_vars, :owner_id)
5028 -> 0.0020s
5029== 20250109121404 CreateAccountEnvVarsTable: migrated (0.0069s) ===============
5031 sets unique_number on INSERT
5032 does not set unique_number on INSERT if 0 is given as a value
5033 sets unique_number on UPDATE
5034 does not set unique_number on UPDATE if unique_number is 0
5036set_updated_at trigger
5037 jobs
5038 sets updated_at on INSERT
5039 sets updated_at on UPDATE
5040 works also for new columns
5041 builds
5042 sets updated_at on INSERT
5043 sets updated_at on UPDATE
5044 works also for new columns
5046soft delete repo
5047 ensure that soft delete tables have the same fields that the originals
5048 soft deleting a repo moves all of the related data to deleted_* tables
5050Rake tasks
5051 rake db:create
5052 migrates the main db
5053 rake db:schema:load
5054 loads the main schema
5056Deprecation Warnings:
5058Using `should` from rspec-expectations' old `:should` syntax without explicitly enabling the syntax is deprecated. Use the new `:expect` syntax or explicitly enable `:should` with `config.expect_with(:rspec) { |c| c.syntax = :should }` instead. Called from /home/travis/build/travis-ci/travis-migrations/spec/soft_delete_repo_spec.rb:118:in `block (2 levels) in <top (required)>'.
5061If you need more of the backtrace for any of these deprecations to
5062identify where to make the necessary changes, you can configure
5063`config.raise_errors_for_deprecations!`, and it will turn the
5064deprecation warnings into errors, giving you the full backtrace.
50661 deprecation warning total
5068Finished in 41.27 seconds (files took 0.36922 seconds to load)
506919 examples, 0 failures
5071The command "bundle exec rspec spec" exited with 0.
cache.2
5072store build cache
50730.00s1.43snothing changed
after_success
50750.19s$ script/upload_structure.rb
5076<internal:/home/travis/.rvm/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require': cannot load such file -- s3 (LoadError)
5077 from <internal:/home/travis/.rvm/rubies/ruby-3.2.2/lib/ruby/site_ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
5078 from script/upload_structure.rb:5:in `<main>'
5080Done. Your build exited with 0.
Top