Pull request event #3749 passed

  • Ran for
  • New branch build
AMD64
Ruby: 3.2.2
Git
Raw log
Scroll to End of Log
0.00s0.18s0.12s0.06s0.00s
worker_info
1Worker information
2hostname: de8d85b4-213e-4aad-8ae7-46738d7a9f3e@1.worker-n2-com-f8c4bb956-pk6nj.gce-production-1
3version: deploy_2024.10.02-2-gc32b553 https://github.com/travis-ci/worker/tree/c32b553e81363378d09787f52103ea9bcadf253c
4instance: travis-job-20ad4c58-fbdb-4c03-8e12-8afa15dbed0b travis-ci-ubuntu-2004-1726220016-655c8cb5 (via amqp)
5startup: 5.811178626s
60.23s0.00s0.01s0.00s0.01s
system_info
7Build system information
8Build language: ruby
9Build dist: focal
10Build id: 272813291
11Job id: 627304058
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.77s0.30s0.05s0.01s0.04s0.00s0.03s0.01s0.01s0.01s0.01s0.00s0.39sOK
1650.00s0.03s0.00s0.01s0.13s0.00s0.00s0.00s0.01s0.00s0.14s0.00s1.14s0.00s0.12s6.04s0.00s4.05s0.00s2.24s
docker_mtu_and_registry_mirrors
Docker
resolvconf
apt
166Adding APT Sources
1670.72s$ 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.52s$ 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
17413.68s$ 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 87 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-4.pgdg20.04+1 [1,495 kB]
193Get:2 http://apt.postgresql.org/pub/repos/apt focal-pgdg/main amd64 postgresql-11 amd64 11.22-4.pgdg20.04+1 [14.3 MB]
194Preconfiguring packages ...
195Fetched 15.8 MB in 2s (9,547 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-4.pgdg20.04+1_amd64.deb ...
199Unpacking postgresql-client-11 (11.22-4.pgdg20.04+1) ...
200Selecting previously unselected package postgresql-11.
201Preparing to unpack .../postgresql-11_11.22-4.pgdg20.04+1_amd64.deb ...
202Unpacking postgresql-11 (11.22-4.pgdg20.04+1) ...
203Setting up postgresql-client-11 (11.22-4.pgdg20.04+1) ...
204Setting up postgresql-11 (11.22-4.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
2353.60s$ travis_setup_postgresql 11
236Starting PostgreSQL v11
237sudo systemctl start postgresql@11-main
git.checkout
2390.01s0.55s$ 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.29s$ git fetch origin +refs/pull/299/merge: --depth=50
243From https://github.com/travis-ci/travis-migrations
244 * branch refs/pull/299/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
2552.93s$ 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!
28021.23s$ 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 14.2M 0 0:00:02 0:00:02 --:--:-- 28.2M
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.15s$ Installing caching utilities
3120.00s1.81sattempting to download cache archive
313fetching PR.299/cache--linux-focal-e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855--rvm-3.2.2--gemfile-Gemfile.tgz
314fetching PR.299/cache-linux-focal-e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855--rvm-3.2.2--gemfile-Gemfile.tgz
315fetching PR.299/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.01sadding /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.26s$ gem update --system
332Updating rubygems-update
333Successfully installed rubygems-update-3.5.22
334Installing RubyGems 3.5.22
335 Successfully built RubyGem
336 Name: bundler
337 Version: 2.5.22
338 File: bundler-2.5.22.gem
339Bundler 2.5.22 installed
340RubyGems 3.5.22 installed
341Regenerating binstubs
342Regenerating plugins
344# 3.5.22 / 2024-10-16
346## Enhancements:
348* Prevent `._*` files in packages generated from macOS. Pull request
349 [#8150](https://github.com/rubygems/rubygems/pull/8150) by
350 deivid-rodriguez
351* Fix `gem pristine etc` resetting gem twice sometimes. Pull request
352 [#8117](https://github.com/rubygems/rubygems/pull/8117) by
353 deivid-rodriguez
354* Allow `gem pristine` to reset default gems too. Pull request
355 [#8118](https://github.com/rubygems/rubygems/pull/8118) by
356 deivid-rodriguez
357* Update vendored `uri` and `net-http`. Pull request
358 [#8112](https://github.com/rubygems/rubygems/pull/8112) by segiddins
359* Installs bundler 2.5.22 as a default gem.
361## Bug fixes:
363* Fix `gem contents` for default gems. Pull request
364 [#8132](https://github.com/rubygems/rubygems/pull/8132) by
365 deivid-rodriguez
366* Fix duplicated specs when they have been previously activated. Pull
367 request [#8131](https://github.com/rubygems/rubygems/pull/8131) by
368 deivid-rodriguez
369* Fix `gem install` on NFS shares. Pull request
370 [#8123](https://github.com/rubygems/rubygems/pull/8123) by
371 deivid-rodriguez
372* Fix a `gem install` crash during "done installing" hooks. Pull request
373 [#8113](https://github.com/rubygems/rubygems/pull/8113) by
374 deivid-rodriguez
375* Fix plugin command loading. Pull request
376 [#8121](https://github.com/rubygems/rubygems/pull/8121) by
377 deivid-rodriguez
379# 3.5.21 / 2024-10-03
381## Enhancements:
383* Fix `Gem::MissingSpecVersionError#to_s` not showing exception message.
384 Pull request [#8074](https://github.com/rubygems/rubygems/pull/8074) by
385 deivid-rodriguez
386* Remove code that makes suggest_gems_from_name give worse results. Pull
387 request [#8083](https://github.com/rubygems/rubygems/pull/8083) by
388 duckinator
389* Warning about PATH in `--user-install` mode is only necessary for gems
390 with executables. Pull request
391 [#8071](https://github.com/rubygems/rubygems/pull/8071) by
392 deivid-rodriguez
393* Installs bundler 2.5.21 as a default gem.
395## Bug fixes:
397* Fix error in one source when fetching dependency APIs clearing results
398 from all sources. Pull request
399 [#8080](https://github.com/rubygems/rubygems/pull/8080) by
400 deivid-rodriguez
401* Fix `gem cleanup` warning when two versions of psych installed. Pull
402 request [#8072](https://github.com/rubygems/rubygems/pull/8072) by
403 deivid-rodriguez
405# 3.5.20 / 2024-09-24
407## Enhancements:
409* Installs bundler 2.5.20 as a default gem.
411# 3.5.19 / 2024-09-18
413## Enhancements:
415* Standardize pretty-print output for `Gem::Source` and subclasses. Pull
416 request [#7994](https://github.com/rubygems/rubygems/pull/7994) by
417 djberube
418* Update vendored `molinillo` to master and vendored `resolv` to 0.4.0.
419 Pull request [#7521](https://github.com/rubygems/rubygems/pull/7521) by
420 hsbt
421* Installs bundler 2.5.19 as a default gem.
423## Bug fixes:
425* Fix `bundle exec rake install` failing when local gem has extensions.
426 Pull request [#7977](https://github.com/rubygems/rubygems/pull/7977) by
427 deivid-rodriguez
428* Make `gem exec` use the standard GEM_HOME. Pull request
429 [#7982](https://github.com/rubygems/rubygems/pull/7982) by
430 deivid-rodriguez
431* Fix `gem fetch` always exiting with zero status code. Pull request
432 [#8007](https://github.com/rubygems/rubygems/pull/8007) by
433 deivid-rodriguez
434* Remove temporary `.lock` files unintentionally left around by gem
435 installer. Pull request
436 [#7939](https://github.com/rubygems/rubygems/pull/7939) by nobu
437* Removed unused stringio. Pull request
438 [#8001](https://github.com/rubygems/rubygems/pull/8001) by hsbt
439* Avoid another race condition of open mode. Pull request
440 [#7931](https://github.com/rubygems/rubygems/pull/7931) by nobu
441* Fix `@license` typo preventing licenses from being correctly
442 unmarshalled. Pull request
443 [#7975](https://github.com/rubygems/rubygems/pull/7975) by djberube
445## Performance:
447* Fix `gem install does-not-exist` being super slow. Pull request
448 [#8006](https://github.com/rubygems/rubygems/pull/8006) by
449 deivid-rodriguez
451# 3.5.18 / 2024-08-26
453## Enhancements:
455* Installs bundler 2.5.18 as a default gem.
457## Bug fixes:
459* Fix `gem uninstall <name>:<version>` failing on shadowed default gems.
460 Pull request [#7949](https://github.com/rubygems/rubygems/pull/7949) by
461 deivid-rodriguez
463# 3.5.17 / 2024-08-01
465## Enhancements:
467* Explicitly encode `Gem::Dependency` to yaml. Pull request
468 [#7867](https://github.com/rubygems/rubygems/pull/7867) by segiddins
469* Installs bundler 2.5.17 as a default gem.
471## Bug fixes:
473* Fix `gem list` regression when a regular gem shadows a default one. Pull
474 request [#7892](https://github.com/rubygems/rubygems/pull/7892) by
475 deivid-rodriguez
476* Always leave default gem executables around. Pull request
477 [#7879](https://github.com/rubygems/rubygems/pull/7879) by
478 deivid-rodriguez
479* Fix line comment issue for hash when loading gemrc. Pull request
480 [#7857](https://github.com/rubygems/rubygems/pull/7857) by leetking
482# 3.5.16 / 2024-07-18
484## Enhancements:
486* Installs bundler 2.5.16 as a default gem.
488## Bug fixes:
490* Fix gemspec `require_paths` validation. Pull request
491 [#7866](https://github.com/rubygems/rubygems/pull/7866) by
492 deivid-rodriguez
493* Fix loading of nested `gemrc` config keys when specified as symbols.
494 Pull request [#7851](https://github.com/rubygems/rubygems/pull/7851) by
495 moofkit
497## Performance:
499* Use `caller_locations` instead of splitting `caller`. Pull request
500 [#7708](https://github.com/rubygems/rubygems/pull/7708) by nobu
502# 3.5.15 / 2024-07-09
504## Enhancements:
506* Installs bundler 2.5.15 as a default gem.
508## Bug fixes:
510* Restrict generic `arm` to only match 32-bit arm. Pull request
511 [#7830](https://github.com/rubygems/rubygems/pull/7830) by ntkme
512* Protect creating binstubs with a file lock. Pull request
513 [#7806](https://github.com/rubygems/rubygems/pull/7806) by
514 deivid-rodriguez
516## Documentation:
518* Make it clearer that `add_dependency` is the main way to add
519 non-development dependencies. Pull request
520 [#7800](https://github.com/rubygems/rubygems/pull/7800) by jeromedalbert
522# 3.5.14 / 2024-06-21
524## Enhancements:
526* Installs bundler 2.5.14 as a default gem.
528## Bug fixes:
530* Make "bundler? update --bundler" behave identically. Pull request
531 [#7778](https://github.com/rubygems/rubygems/pull/7778) by x-yuri
533# 3.5.13 / 2024-06-14
535## Enhancements:
537* Installs bundler 2.5.13 as a default gem.
539## Bug fixes:
541* Never remove executables that may belong to a default gem. Pull request
542 [#7747](https://github.com/rubygems/rubygems/pull/7747) by
543 deivid-rodriguez
545# 3.5.12 / 2024-06-13
547## Enhancements:
549* Installs bundler 2.5.12 as a default gem.
551## Bug fixes:
553* Fix `gem uninstall` unresolved specifications warning. Pull request
554 [#7667](https://github.com/rubygems/rubygems/pull/7667) by
555 deivid-rodriguez
556* Fix `gem pristine` sometimes failing to pristine user installed gems.
557 Pull request [#7664](https://github.com/rubygems/rubygems/pull/7664) by
558 deivid-rodriguez
560# 3.5.11 / 2024-05-28
562## Enhancements:
564* Update SPDX license list as of 2024-05-22. Pull request
565 [#7689](https://github.com/rubygems/rubygems/pull/7689) by
566 github-actions[bot]
567* Fix the update_rubygems inconsistency (--disable-gems). Pull request
568 [#7658](https://github.com/rubygems/rubygems/pull/7658) by x-yuri
569* Accept WASI as an OS name in Gem::Platform. Pull request
570 [#7629](https://github.com/rubygems/rubygems/pull/7629) by kateinoigakukun
571* Warn if RubyGems version explicitly set in gemspec does not match
572 running version. Pull request
573 [#7460](https://github.com/rubygems/rubygems/pull/7460) by
574 deivid-rodriguez
575* Installs bundler 2.5.11 as a default gem.
577## Bug fixes:
579* Fix binstubs sometimes not getting regenerated when `--destdir` is
580 given. Pull request
581 [#7660](https://github.com/rubygems/rubygems/pull/7660) by
582 deivid-rodriguez
583* Fix `gem uninstall --user-install` for symlinked HOME. Pull request
584 [#7645](https://github.com/rubygems/rubygems/pull/7645) by
585 deivid-rodriguez
586* Fix issue when plugin stubs would sometimes not be properly removed by
587 `gem uninstall`. Pull request
588 [#7631](https://github.com/rubygems/rubygems/pull/7631) by
589 deivid-rodriguez
590* Fix plugins uninstallation for user installed gems. Pull request
591 [#6456](https://github.com/rubygems/rubygems/pull/6456) by voxik
593## Performance:
595* Use a constant empty tar header to avoid extra allocations. Pull request
596 [#7484](https://github.com/rubygems/rubygems/pull/7484) by segiddins
598## Documentation:
600* Recommend `bin/rake` over `rake` in contributing docs. Pull request
601 [#7648](https://github.com/rubygems/rubygems/pull/7648) by
602 deivid-rodriguez
604# 3.5.10 / 2024-05-03
606## Security:
608* Add a limit to the size of the metadata and checksums files in a gem
609 package. Pull request
610 [#7568](https://github.com/rubygems/rubygems/pull/7568) by segiddins
612## Enhancements:
614* Don't fully require `rubygems` from `rubygems/package` to prevent some
615 circular require warnings when using Bundler. Pull request
616 [#7612](https://github.com/rubygems/rubygems/pull/7612) by
617 deivid-rodriguez
618* Installs bundler 2.5.10 as a default gem.
620## Bug fixes:
622* Rename credential email to identifier in WebAuthn poller. Pull request
623 [#7623](https://github.com/rubygems/rubygems/pull/7623) by jenshenny
625# 3.5.9 / 2024-04-12
627## Enhancements:
629* Installs bundler 2.5.9 as a default gem.
631# 3.5.8 / 2024-04-11
633## Security:
635* Respect global umask when writing regular files. Pull request
636 [#7518](https://github.com/rubygems/rubygems/pull/7518) by
637 deivid-rodriguez
639## Enhancements:
641* Allow string keys with gemrc. Pull request
642 [#7543](https://github.com/rubygems/rubygems/pull/7543) by hsbt
643* [Experimental] Add "gem rebuild" command. Pull request
644 [#4913](https://github.com/rubygems/rubygems/pull/4913) by duckinator
645* Installs bundler 2.5.8 as a default gem.
647## Bug fixes:
649* Fix NoMethodError crash when building errors about corrupt package
650 files. Pull request
651 [#7539](https://github.com/rubygems/rubygems/pull/7539) by jez
652* Fix resolver to properly intersect Arrays of `Gem::Resolver::Activation`
653 objects. Pull request
654 [#7537](https://github.com/rubygems/rubygems/pull/7537) by
655 deivid-rodriguez
657# 3.5.7 / 2024-03-22
659## Enhancements:
661* Warn on empty or open required_ruby_version specification attribute.
662 Pull request [#5010](https://github.com/rubygems/rubygems/pull/5010) by
663 simi
664* Control whether YAML aliases are enabled in Gem::SafeYAML.safe_load via
665 attribute. Pull request
666 [#7464](https://github.com/rubygems/rubygems/pull/7464) by segiddins
667* Update SPDX license list as of 2024-02-08. Pull request
668 [#7468](https://github.com/rubygems/rubygems/pull/7468) by
669 github-actions[bot]
670* Installs bundler 2.5.7 as a default gem.
672## Bug fixes:
674* Allow prerelease activation (even if requirement is not explicit about
675 it) when it's the only possibility. Pull request
676 [#7428](https://github.com/rubygems/rubygems/pull/7428) by kimesf
678## Documentation:
680* Fix a typo. Pull request
681 [#7505](https://github.com/rubygems/rubygems/pull/7505) by hsbt
682* Use https instead of http in documentation links. Pull request
683 [#7481](https://github.com/rubygems/rubygems/pull/7481) by hsbt
685# 3.5.6 / 2024-02-06
687## Enhancements:
689* Deep copy requirements in `Gem::Specification` and `Gem::Requirement`.
690 Pull request [#7439](https://github.com/rubygems/rubygems/pull/7439) by
691 flavorjones
692* Change gem login message to clear up that username can be also used.
693 Pull request [#7422](https://github.com/rubygems/rubygems/pull/7422) by
694 VitaliySerov
695* Add metadata for rubygems.org. Pull request
696 [#7435](https://github.com/rubygems/rubygems/pull/7435) by m-nakamura145
697* Improve gem login scope selection. Pull request
698 [#7342](https://github.com/rubygems/rubygems/pull/7342) by williantenfen
699* Vendor uri in RubyGems. Pull request
700 [#7386](https://github.com/rubygems/rubygems/pull/7386) by
701 deivid-rodriguez
702* Installs bundler 2.5.6 as a default gem.
704## Bug fixes:
706* Skip to load commented out words. Pull request
707 [#7413](https://github.com/rubygems/rubygems/pull/7413) by hsbt
708* Fix rake runtime dependency warning for rake based extension. Pull
709 request [#7395](https://github.com/rubygems/rubygems/pull/7395) by ntkme
711# 3.5.5 / 2024-01-18
713## Enhancements:
715* Installs bundler 2.5.5 as a default gem.
717## Bug fixes:
719* Fix `require` activation conflicts when requiring default gems under
720 some situations. Pull request
721 [#7379](https://github.com/rubygems/rubygems/pull/7379) by
722 deivid-rodriguez
723* Use cache_home instead of data_home in default_spec_cache_dir. Pull
724 request [#7331](https://github.com/rubygems/rubygems/pull/7331) by mrkn
726## Documentation:
728* Use squiggly heredocs in `Gem::Specification#description` documentation,
729 so it doesn't add leading whitespace. Pull request
730 [#7373](https://github.com/rubygems/rubygems/pull/7373) by bravehager
732# 3.5.4 / 2024-01-04
734## Enhancements:
736* Always avoid "Updating rubygems-update" message. Pull request
737 [#7335](https://github.com/rubygems/rubygems/pull/7335) by
738 deivid-rodriguez
739* Installs bundler 2.5.4 as a default gem.
741## Bug fixes:
743* Make `gem update --system` respect ruby version constraints. Pull
744 request [#7334](https://github.com/rubygems/rubygems/pull/7334) by
745 deivid-rodriguez
747# 3.5.3 / 2023-12-22
749## Enhancements:
751* Installs bundler 2.5.3 as a default gem.
753# 3.5.2 / 2023-12-21
755## Enhancements:
757* Support dynamic library loading with extension .so or .o. Pull request
758 [#7241](https://github.com/rubygems/rubygems/pull/7241) by hogelog
759* Installs bundler 2.5.2 as a default gem.
761## Performance:
763* Replace `object_id` comparison with identity Hash. Pull request
764 [#7303](https://github.com/rubygems/rubygems/pull/7303) by amomchilov
765* Use IO.copy_stream when reading, writing. Pull request
766 [#6958](https://github.com/rubygems/rubygems/pull/6958) by martinemde
768# 3.5.1 / 2023-12-15
770## Enhancements:
772* Installs bundler 2.5.1 as a default gem.
774# 3.5.0 / 2023-12-15
776## Security:
778* Replace `Marshal.load` with a fully-checked safe gemspec loader. Pull
779 request [#6896](https://github.com/rubygems/rubygems/pull/6896) by
780 segiddins
782## Breaking changes:
784* Drop ruby 2.6 and 2.7 support. Pull request
785 [#7116](https://github.com/rubygems/rubygems/pull/7116) by
786 deivid-rodriguez
787* Release package no longer includes test files. Pull request
788 [#6781](https://github.com/rubygems/rubygems/pull/6781) by hsbt
789* Hide `Gem::MockGemUi` from users. Pull request
790 [#6623](https://github.com/rubygems/rubygems/pull/6623) by hsbt
791* Deprecated `Gem.datadir` has been removed. Pull request
792 [#6469](https://github.com/rubygems/rubygems/pull/6469) by hsbt
794## Deprecations:
796* Deprecate `Gem::Platform.match?`. Pull request
797 [#6783](https://github.com/rubygems/rubygems/pull/6783) by hsbt
798* Deprecate `Gem::List`. Pull request
799 [#6311](https://github.com/rubygems/rubygems/pull/6311) by segiddins
801## Features:
803* The `generate_index` command can now generate compact index files and
804 lives as an external `rubygems-generate_index` gem. Pull request
805 [#7085](https://github.com/rubygems/rubygems/pull/7085) by segiddins
806* Make `gem install` fallback to user installation directory if default
807 gem home is not writable. Pull request
808 [#5327](https://github.com/rubygems/rubygems/pull/5327) by duckinator
809* Leverage ruby feature to warn when requiring default gems from stdlib
810 that will be turned into bundled gems in the future. Pull request
811 [#6840](https://github.com/rubygems/rubygems/pull/6840) by hsbt
813## Performance:
815* Use match? when regexp match data is unused. Pull request
816 [#7263](https://github.com/rubygems/rubygems/pull/7263) by segiddins
817* Fewer allocations in gem installation. Pull request
818 [#6975](https://github.com/rubygems/rubygems/pull/6975) by segiddins
819* Optimize allocations in `Gem::Version`. Pull request
820 [#6970](https://github.com/rubygems/rubygems/pull/6970) by segiddins
822## Enhancements:
824* Warn for duplicate meta data links when building gems. Pull request
825 [#7213](https://github.com/rubygems/rubygems/pull/7213) by etherbob
826* Vendor `net-http`, `net-protocol`, `resolv`, and `timeout` to reduce
827 conflicts between Gemfile gems and internal dependencies. Pull request
828 [#6793](https://github.com/rubygems/rubygems/pull/6793) by
829 deivid-rodriguez
830* Remove non-transparent requirement added to prerelease gems. Pull
831 request [#7226](https://github.com/rubygems/rubygems/pull/7226) by
832 deivid-rodriguez
833* Stream output from ext builds when --verbose. Pull request
834 [#7240](https://github.com/rubygems/rubygems/pull/7240) by osyoyu
835* Add missing services to CI detection and make it consistent between
836 RubyGems and Bundler. Pull request
837 [#7205](https://github.com/rubygems/rubygems/pull/7205) by nevinera
838* Update generate licenses template to not freeze regexps. Pull request
839 [#7154](https://github.com/rubygems/rubygems/pull/7154) by
840 github-actions[bot]
841* Don't check `LIBRUBY_RELATIVE` in truffleruby to signal a bash prelude
842 in rubygems binstubs. Pull request
843 [#7156](https://github.com/rubygems/rubygems/pull/7156) by
844 deivid-rodriguez
845* Update SPDX list and warn on deprecated identifiers. Pull request
846 [#6926](https://github.com/rubygems/rubygems/pull/6926) by simi
847* Simplify extended `require` to potentially fix some deadlocks. Pull
848 request [#6827](https://github.com/rubygems/rubygems/pull/6827) by nobu
849* Small refactors for `Gem::Resolver`. Pull request
850 [#6766](https://github.com/rubygems/rubygems/pull/6766) by hsbt
851* Use double-quotes instead of single-quotes consistently in warnings.
852 Pull request [#6550](https://github.com/rubygems/rubygems/pull/6550) by
853 hsbt
854* Add debug message for `nil` version gemspec. Pull request
855 [#6436](https://github.com/rubygems/rubygems/pull/6436) by hsbt
856* Installs bundler 2.5.0 as a default gem.
858## Bug fixes:
860* Fix installing from source with same default bundler version already
861 installed. Pull request
862 [#7244](https://github.com/rubygems/rubygems/pull/7244) by
863 deivid-rodriguez
865## Documentation:
867* Improve comment explaining the necessity of `write_default_spec` method.
868 Pull request [#6563](https://github.com/rubygems/rubygems/pull/6563) by
869 voxik
871# 3.4.22 / 2023-11-09
873## Enhancements:
875* Update SPDX license list as of 2023-10-05. Pull request
876 [#7040](https://github.com/rubygems/rubygems/pull/7040) by
877 github-actions[bot]
878* Remove unnecessary rescue. Pull request
879 [#7109](https://github.com/rubygems/rubygems/pull/7109) by
880 deivid-rodriguez
881* Installs bundler 2.4.22 as a default gem.
883## Bug fixes:
885* Handle empty array at built-in YAML serializer. Pull request
886 [#7099](https://github.com/rubygems/rubygems/pull/7099) by hsbt
887* Ignore non-tar format `.gem` files during search. Pull request
888 [#7095](https://github.com/rubygems/rubygems/pull/7095) by dearblue
889* Allow explicitly uninstalling multiple versions of same gem. Pull
890 request [#7063](https://github.com/rubygems/rubygems/pull/7063) by
891 kstevens715
893## Performance:
895* Avoid regexp match on every call to `Gem::Platform.local`. Pull request
896 [#7104](https://github.com/rubygems/rubygems/pull/7104) by segiddins
898## Documentation:
900* Get `Gem::Specification#extensions_dir` documented. Pull request
901 [#6218](https://github.com/rubygems/rubygems/pull/6218) by
902 deivid-rodriguez
904# 3.4.21 / 2023-10-17
906## Enhancements:
908* Abort `setup.rb` if Ruby is too old. Pull request
909 [#7011](https://github.com/rubygems/rubygems/pull/7011) by
910 deivid-rodriguez
911* Remove usage of Dir.chdir that only execute a subprocess. Pull request
912 [#6930](https://github.com/rubygems/rubygems/pull/6930) by segiddins
913* Freeze more strings in generated gemspecs. Pull request
914 [#6974](https://github.com/rubygems/rubygems/pull/6974) by segiddins
915* Use pure-ruby YAML parser for loading configuration at RubyGems. Pull
916 request [#6615](https://github.com/rubygems/rubygems/pull/6615) by hsbt
917* Installs bundler 2.4.21 as a default gem.
919## Documentation:
921* Update suggested variable for bindir. Pull request
922 [#7028](https://github.com/rubygems/rubygems/pull/7028) by hsbt
923* Fix invalid links in documentation. Pull request
924 [#7008](https://github.com/rubygems/rubygems/pull/7008) by simi
926# 3.4.20 / 2023-09-27
928## Enhancements:
930* Raise `Gem::Package::FormatError` when gem encounters corrupt EOF.
931 Pull request [#6882](https://github.com/rubygems/rubygems/pull/6882)
932 by martinemde
933* Allow skipping empty license `gem build` warning by setting license to
934 `nil`. Pull request
935 [#6879](https://github.com/rubygems/rubygems/pull/6879) by jhong97
936* Update SPDX license list as of 2023-06-18. Pull request
937 [#6891](https://github.com/rubygems/rubygems/pull/6891) by
938 github-actions[bot]
939* Update SPDX license list as of 2023-04-28. Pull request
940 [#6642](https://github.com/rubygems/rubygems/pull/6642) by segiddins
941* Update SPDX license list as of 2023-01-26. Pull request
942 [#6310](https://github.com/rubygems/rubygems/pull/6310) by segiddins
943* Installs bundler 2.4.20 as a default gem.
945## Bug fixes:
947* Fixed false positive SymlinkError in symbolic link directory. Pull
948 request [#6947](https://github.com/rubygems/rubygems/pull/6947) by
949 negi0109
950* Ensure that loading multiple gemspecs with legacy YAML class references
951 does not warn. Pull request
952 [#6889](https://github.com/rubygems/rubygems/pull/6889) by segiddins
953* Fix NoMethodError when choosing a too big number from `gem uni` list.
954 Pull request [#6901](https://github.com/rubygems/rubygems/pull/6901) by
955 amatsuda
957## Performance:
959* Reduce allocations for stub specifications. Pull request
960 [#6972](https://github.com/rubygems/rubygems/pull/6972) by segiddins
962# 3.4.19 / 2023-08-17
964## Enhancements:
966* Installs bundler 2.4.19 as a default gem.
968## Performance:
970* Speedup building docs when updating rubygems. Pull request
971 [#6864](https://github.com/rubygems/rubygems/pull/6864) by
972 deivid-rodriguez
974# 3.4.18 / 2023-08-02
976## Enhancements:
978* Add poller to fetch WebAuthn OTP. Pull request
979 [#6774](https://github.com/rubygems/rubygems/pull/6774) by jenshenny
980* Remove side effects when unmarshaling old `Gem::Specification`. Pull
981 request [#6825](https://github.com/rubygems/rubygems/pull/6825) by nobu
982* Ship rubygems executables in `exe` folder. Pull request
983 [#6704](https://github.com/rubygems/rubygems/pull/6704) by hsbt
984* Installs bundler 2.4.18 as a default gem.
986# 3.4.17 / 2023-07-14
988## Enhancements:
990* Installs bundler 2.4.17 as a default gem.
992## Performance:
994* Avoid unnecessary work for private local gem installation. Pull request
995 [#6810](https://github.com/rubygems/rubygems/pull/6810) by
996 deivid-rodriguez
998# 3.4.16 / 2023-07-10
1000## Enhancements:
1002* Installs bundler 2.4.16 as a default gem.
1004# 3.4.15 / 2023-06-29
1006## Enhancements:
1008* Installs bundler 2.4.15 as a default gem.
1010## Bug fixes:
1012* Autoload shellwords when it's needed. Pull request
1013 [#6734](https://github.com/rubygems/rubygems/pull/6734) by ioquatix
1015## Documentation:
1017* Update command to test local gem command changes. Pull request
1018 [#6761](https://github.com/rubygems/rubygems/pull/6761) by jenshenny
1020# 3.4.14 / 2023-06-12
1022## Enhancements:
1024* Load plugin immediately. Pull request
1025 [#6673](https://github.com/rubygems/rubygems/pull/6673) by kou
1026* Installs bundler 2.4.14 as a default gem.
1028## Documentation:
1030* Clarify what the `rubygems-update` gem is for, and link to source code
1031 and guides. Pull request
1032 [#6710](https://github.com/rubygems/rubygems/pull/6710) by davetron5000
1034# 3.4.13 / 2023-05-09
1036## Enhancements:
1038* Installs bundler 2.4.13 as a default gem.
1040# 3.4.12 / 2023-04-11
1042## Enhancements:
1044* [Experimental] Add WebAuthn Support to the CLI. Pull request
1045 [#6560](https://github.com/rubygems/rubygems/pull/6560) by jenshenny
1046* Installs bundler 2.4.12 as a default gem.
1048# 3.4.11 / 2023-04-10
1050## Enhancements:
1052* Installs bundler 2.4.11 as a default gem.
1055------------------------------------------------------------------------------
1057RubyGems installed the following executables:
1058 /home/travis/.rvm/rubies/ruby-3.2.2/bin/gem
1059 /home/travis/.rvm/rubies/ruby-3.2.2/bin/bundle
1060 /home/travis/.rvm/rubies/ruby-3.2.2/bin/bundler
1062RubyGems system software updated
before_install.2
10630.03s$ 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
10640.03s$ sudo sed -i -e 's/^port = 5433/port = 5432/' /etc/postgresql/11/main/postgresql.conf
before_install.4
10652.38s$ sudo systemctl restart postgresql@11-main
install.bundler
10661.60s$ bundle install --jobs=3 --retry=3 --deployment
1067[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
1068Bundler 2.5.22 is running, but your lockfile was generated with 2.4.14. Installing Bundler 2.4.14 and restarting using that version.
1069Fetching gem metadata from https://rubygems.org/.
1070Fetching bundler 2.4.14
1071Installing bundler 2.4.14
1072[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
1073Using rake 13.0.6
1074Using concurrent-ruby 1.2.2
1075Using i18n 1.14.1
1076Using minitest 5.18.1
1077Using tzinfo 2.0.6
1078Using activesupport 7.0.6
1079Using builder 3.2.4
1080Using erubi 1.12.0
1081Using racc 1.7.1
1082Using nokogiri 1.15.2 (x86_64-linux)
1083Using rails-dom-testing 2.1.1
1084Using crass 1.0.6
1085Using loofah 2.21.3
1086Using rails-html-sanitizer 1.6.0
1087Using actionview 7.0.6
1088Using rack 2.2.7
1089Using rack-test 2.1.0
1090Using actionpack 7.0.6
1091Using nio4r 2.5.9
1092Using websocket-extensions 0.1.5
1093Using websocket-driver 0.7.5
1094Using actioncable 7.0.6
1095Using globalid 1.1.0
1096Using activejob 7.0.6
1097Using activemodel 7.0.6
1098Using activerecord 7.0.6
1099Using marcel 1.0.2
1100Using mini_mime 1.1.2
1101Using activestorage 7.0.6
1102Using date 3.3.3
1103Using timeout 0.4.0
1104Using net-protocol 0.2.1
1105Using net-imap 0.3.6
1106Using net-pop 0.1.2
1107Using net-smtp 0.3.3
1108Using mail 2.8.1
1109Using actionmailbox 7.0.6
1110Using actionmailer 7.0.6
1111Using actiontext 7.0.6
1112Using ansi 1.5.0
1113Using ast 2.4.2
1114Using aws-eventstream 1.2.0
1115Using aws-partitions 1.783.0
1116Using aws-sigv4 1.6.0
1117Using jmespath 1.6.2
1118Using aws-sdk-core 3.176.1
1119Using aws-sdk-kms 1.68.0
1120Using aws-sdk-s3 1.127.0
1121Using bundler 2.4.14
1122Using colored 1.2
1123Using diff-lcs 1.5.0
1124Using docile 1.4.0
1125Using json 2.6.3
1126Using language_server-protocol 3.17.0.3
1127Using method_source 1.0.0
1128Using parallel 1.23.0
1129Using parser 3.2.2.3
1130Using pg 1.5.3
1131Using thor 1.2.2
1132Using zeitwerk 2.6.8
1133Using railties 7.0.6
1134Using rails 7.0.6
1135Using rainbow 3.1.1
1136Using rake-notes 0.2.2
1137Using regexp_parser 2.8.1
1138Using rexml 3.2.5
1139Using routes 0.2.0
1140Using rspec-support 3.12.1
1141Using rspec-core 3.12.2
1142Using rspec-expectations 3.12.3
1143Using rspec-mocks 3.12.5
1144Using rspec 3.12.0
1145Using rubocop-ast 1.29.0
1146Using ruby-progressbar 1.13.0
1147Using unicode-display_width 2.4.2
1148Using rubocop 1.54.1
1149Using rubocop-capybara 2.18.0
1150Using rubocop-factory_bot 2.23.1
1151Using rubocop-performance 1.18.0
1152Using rubocop-rspec 2.22.0
1153Using simplecov-html 0.12.3
1154Using simplecov_json_formatter 0.1.4
1155Using simplecov 0.22.0
1156Using terminal-table 3.0.2
1157Using simplecov-console 0.9.1
1158Bundle complete! 12 Gemfile dependencies, 85 gems now installed.
1159Bundled gems are installed into `./vendor/bundle`
before_script.1
11610.01s$ psql --version
1162psql (PostgreSQL) 11.22 (Ubuntu 11.22-4.pgdg20.04+1)
before_script.2
11630.25s$ psql -c 'CREATE DATABASE travis_test;'
1164CREATE DATABASE
before_script.3
11651.26s$ curl -fs https://raw.githubusercontent.com/travis-ci/travis-migrations/master/db/main/structure.sql | psql -v ON_ERROR_STOP=1 travis_test
1166SET
1167SET
1168SET
1169SET
1170SET
1171 set_config
1172------------
1174(1 row)
1176SET
1177SET
1178SET
1179SET
1180CREATE EXTENSION
1181COMMENT
1182CREATE EXTENSION
1183COMMENT
1184CREATE TYPE
1185CREATE FUNCTION
1186CREATE FUNCTION
1187CREATE FUNCTION
1188CREATE FUNCTION
1189CREATE FUNCTION
1190CREATE FUNCTION
1191CREATE FUNCTION
1192CREATE FUNCTION
1193CREATE FUNCTION
1194CREATE FUNCTION
1195CREATE FUNCTION
1196CREATE FUNCTION
1197CREATE FUNCTION
1198CREATE FUNCTION
1199CREATE FUNCTION
1200CREATE FUNCTION
1201CREATE FUNCTION
1202CREATE FUNCTION
1203CREATE FUNCTION
1204CREATE FUNCTION
1205CREATE FUNCTION
1206CREATE FUNCTION
1207CREATE FUNCTION
1208CREATE FUNCTION
1209CREATE FUNCTION
1210CREATE FUNCTION
1211CREATE FUNCTION
1212CREATE FUNCTION
1213CREATE FUNCTION
1214CREATE FUNCTION
1215SET
1216CREATE TABLE
1217CREATE SEQUENCE
1218ALTER SEQUENCE
1219CREATE TABLE
1220CREATE TABLE
1221CREATE SEQUENCE
1222ALTER SEQUENCE
1223CREATE TABLE
1224CREATE SEQUENCE
1225ALTER SEQUENCE
1226CREATE TABLE
1227CREATE SEQUENCE
1228ALTER SEQUENCE
1229CREATE TABLE
1230CREATE SEQUENCE
1231ALTER SEQUENCE
1232CREATE TABLE
1233CREATE SEQUENCE
1234ALTER SEQUENCE
1235CREATE TABLE
1236CREATE SEQUENCE
1237ALTER SEQUENCE
1238CREATE TABLE
1239CREATE SEQUENCE
1240ALTER SEQUENCE
1241CREATE SEQUENCE
1242CREATE TABLE
1243CREATE SEQUENCE
1244ALTER SEQUENCE
1245CREATE TABLE
1246CREATE SEQUENCE
1247ALTER SEQUENCE
1248CREATE TABLE
1249CREATE SEQUENCE
1250ALTER SEQUENCE
1251CREATE TABLE
1252CREATE SEQUENCE
1253ALTER SEQUENCE
1254CREATE TABLE
1255CREATE SEQUENCE
1256ALTER SEQUENCE
1257CREATE TABLE
1258CREATE SEQUENCE
1259ALTER SEQUENCE
1260CREATE TABLE
1261CREATE TABLE
1262CREATE TABLE
1263CREATE TABLE
1264CREATE TABLE
1265CREATE TABLE
1266CREATE TABLE
1267CREATE TABLE
1268CREATE TABLE
1269CREATE TABLE
1270CREATE TABLE
1271CREATE TABLE
1272CREATE TABLE
1273CREATE TABLE
1274CREATE TABLE
1275CREATE TABLE
1276CREATE SEQUENCE
1277ALTER SEQUENCE
1278CREATE TABLE
1279CREATE SEQUENCE
1280ALTER SEQUENCE
1281CREATE TABLE
1282CREATE TABLE
1283CREATE SEQUENCE
1284ALTER SEQUENCE
1285CREATE TABLE
1286CREATE SEQUENCE
1287ALTER SEQUENCE
1288CREATE TABLE
1289CREATE SEQUENCE
1290ALTER SEQUENCE
1291CREATE TABLE
1292CREATE SEQUENCE
1293ALTER SEQUENCE
1294CREATE TABLE
1295CREATE SEQUENCE
1296ALTER SEQUENCE
1297CREATE TABLE
1298CREATE SEQUENCE
1299ALTER SEQUENCE
1300CREATE TABLE
1301CREATE SEQUENCE
1302ALTER SEQUENCE
1303CREATE TABLE
1304CREATE SEQUENCE
1305ALTER SEQUENCE
1306CREATE TABLE
1307CREATE SEQUENCE
1308ALTER SEQUENCE
1309CREATE TABLE
1310CREATE SEQUENCE
1311ALTER SEQUENCE
1312CREATE TABLE
1313CREATE SEQUENCE
1314ALTER SEQUENCE
1315CREATE TABLE
1316CREATE SEQUENCE
1317ALTER SEQUENCE
1318CREATE TABLE
1319CREATE SEQUENCE
1320ALTER SEQUENCE
1321CREATE TABLE
1322CREATE SEQUENCE
1323ALTER SEQUENCE
1324CREATE TABLE
1325CREATE SEQUENCE
1326ALTER SEQUENCE
1327CREATE TABLE
1328CREATE TABLE
1329CREATE SEQUENCE
1330ALTER SEQUENCE
1331CREATE TABLE
1332CREATE SEQUENCE
1333ALTER SEQUENCE
1334CREATE TABLE
1335CREATE SEQUENCE
1336ALTER SEQUENCE
1337CREATE TABLE
1338CREATE SEQUENCE
1339ALTER SEQUENCE
1340CREATE TABLE
1341CREATE SEQUENCE
1342ALTER SEQUENCE
1343CREATE TABLE
1344CREATE SEQUENCE
1345ALTER SEQUENCE
1346CREATE TABLE
1347CREATE SEQUENCE
1348ALTER SEQUENCE
1349CREATE TABLE
1350CREATE SEQUENCE
1351ALTER SEQUENCE
1352CREATE TABLE
1353CREATE TABLE
1354CREATE SEQUENCE
1355ALTER SEQUENCE
1356CREATE TABLE
1357CREATE TABLE
1358CREATE SEQUENCE
1359ALTER SEQUENCE
1360CREATE TABLE
1361CREATE SEQUENCE
1362ALTER SEQUENCE
1363CREATE TABLE
1364CREATE SEQUENCE
1365ALTER SEQUENCE
1366CREATE TABLE
1367CREATE SEQUENCE
1368ALTER SEQUENCE
1369CREATE TABLE
1370CREATE SEQUENCE
1371ALTER SEQUENCE
1372CREATE TABLE
1373CREATE SEQUENCE
1374ALTER SEQUENCE
1375CREATE TABLE
1376CREATE SEQUENCE
1377ALTER SEQUENCE
1378CREATE TABLE
1379CREATE SEQUENCE
1380ALTER SEQUENCE
1381CREATE TABLE
1382CREATE SEQUENCE
1383ALTER SEQUENCE
1384CREATE TABLE
1385CREATE SEQUENCE
1386ALTER SEQUENCE
1387CREATE TABLE
1388CREATE SEQUENCE
1389ALTER SEQUENCE
1390CREATE TABLE
1391CREATE SEQUENCE
1392ALTER SEQUENCE
1393CREATE TABLE
1394CREATE SEQUENCE
1395ALTER SEQUENCE
1396CREATE TABLE
1397ALTER TABLE
1398ALTER TABLE
1399ALTER TABLE
1400ALTER TABLE
1401ALTER TABLE
1402ALTER TABLE
1403ALTER TABLE
1404ALTER TABLE
1405ALTER TABLE
1406ALTER TABLE
1407ALTER TABLE
1408ALTER TABLE
1409ALTER TABLE
1410ALTER TABLE
1411ALTER TABLE
1412ALTER TABLE
1413ALTER TABLE
1414ALTER TABLE
1415ALTER TABLE
1416ALTER TABLE
1417ALTER TABLE
1418ALTER TABLE
1419ALTER TABLE
1420ALTER TABLE
1421ALTER TABLE
1422ALTER TABLE
1423ALTER TABLE
1424ALTER TABLE
1425ALTER TABLE
1426ALTER TABLE
1427ALTER TABLE
1428ALTER TABLE
1429ALTER TABLE
1430ALTER TABLE
1431ALTER TABLE
1432ALTER TABLE
1433ALTER TABLE
1434ALTER TABLE
1435ALTER TABLE
1436ALTER TABLE
1437ALTER TABLE
1438ALTER TABLE
1439ALTER TABLE
1440ALTER TABLE
1441ALTER TABLE
1442ALTER TABLE
1443ALTER TABLE
1444ALTER TABLE
1445ALTER TABLE
1446ALTER TABLE
1447ALTER TABLE
1448ALTER TABLE
1449ALTER TABLE
1450ALTER TABLE
1451ALTER TABLE
1452ALTER TABLE
1453ALTER TABLE
1454ALTER TABLE
1455ALTER TABLE
1456ALTER TABLE
1457ALTER TABLE
1458ALTER TABLE
1459ALTER TABLE
1460ALTER TABLE
1461ALTER TABLE
1462ALTER TABLE
1463ALTER TABLE
1464ALTER TABLE
1465ALTER TABLE
1466ALTER TABLE
1467ALTER TABLE
1468ALTER TABLE
1469ALTER TABLE
1470ALTER TABLE
1471ALTER TABLE
1472ALTER TABLE
1473ALTER TABLE
1474ALTER TABLE
1475ALTER TABLE
1476ALTER TABLE
1477ALTER TABLE
1478ALTER TABLE
1479ALTER TABLE
1480ALTER TABLE
1481ALTER TABLE
1482ALTER TABLE
1483ALTER TABLE
1484ALTER TABLE
1485ALTER TABLE
1486ALTER TABLE
1487ALTER TABLE
1488ALTER TABLE
1489ALTER TABLE
1490ALTER TABLE
1491ALTER TABLE
1492ALTER TABLE
1493ALTER TABLE
1494ALTER TABLE
1495ALTER TABLE
1496ALTER TABLE
1497ALTER TABLE
1498ALTER TABLE
1499ALTER TABLE
1500ALTER TABLE
1501ALTER TABLE
1502ALTER TABLE
1503CREATE INDEX
1504CREATE INDEX
1505CREATE INDEX
1506CREATE INDEX
1507CREATE INDEX
1508CREATE INDEX
1509CREATE INDEX
1510CREATE INDEX
1511CREATE INDEX
1512CREATE INDEX
1513CREATE INDEX
1514CREATE INDEX
1515CREATE INDEX
1516CREATE INDEX
1517CREATE INDEX
1518CREATE INDEX
1519CREATE INDEX
1520CREATE INDEX
1521CREATE INDEX
1522CREATE INDEX
1523CREATE INDEX
1524CREATE INDEX
1525CREATE INDEX
1526CREATE INDEX
1527CREATE INDEX
1528CREATE INDEX
1529CREATE INDEX
1530CREATE INDEX
1531CREATE INDEX
1532CREATE INDEX
1533CREATE INDEX
1534CREATE INDEX
1535CREATE INDEX
1536CREATE INDEX
1537CREATE INDEX
1538CREATE INDEX
1539CREATE INDEX
1540CREATE INDEX
1541CREATE INDEX
1542CREATE INDEX
1543CREATE INDEX
1544CREATE INDEX
1545CREATE INDEX
1546CREATE INDEX
1547CREATE INDEX
1548CREATE INDEX
1549CREATE INDEX
1550CREATE INDEX
1551CREATE INDEX
1552CREATE INDEX
1553CREATE INDEX
1554CREATE INDEX
1555CREATE INDEX
1556CREATE INDEX
1557CREATE INDEX
1558CREATE INDEX
1559CREATE INDEX
1560CREATE INDEX
1561CREATE INDEX
1562CREATE INDEX
1563CREATE INDEX
1564CREATE INDEX
1565CREATE INDEX
1566CREATE INDEX
1567CREATE INDEX
1568CREATE INDEX
1569CREATE INDEX
1570CREATE INDEX
1571CREATE INDEX
1572CREATE INDEX
1573CREATE INDEX
1574CREATE INDEX
1575CREATE INDEX
1576CREATE INDEX
1577CREATE INDEX
1578CREATE INDEX
1579CREATE INDEX
1580CREATE INDEX
1581CREATE INDEX
1582CREATE INDEX
1583CREATE INDEX
1584CREATE INDEX
1585CREATE INDEX
1586CREATE INDEX
1587CREATE INDEX
1588CREATE INDEX
1589CREATE INDEX
1590CREATE INDEX
1591CREATE INDEX
1592CREATE INDEX
1593CREATE INDEX
1594CREATE INDEX
1595CREATE INDEX
1596CREATE INDEX
1597CREATE INDEX
1598CREATE INDEX
1599CREATE INDEX
1600CREATE INDEX
1601CREATE INDEX
1602CREATE INDEX
1603CREATE INDEX
1604CREATE INDEX
1605CREATE INDEX
1606CREATE INDEX
1607CREATE INDEX
1608CREATE INDEX
1609CREATE INDEX
1610CREATE INDEX
1611CREATE INDEX
1612CREATE INDEX
1613CREATE INDEX
1614CREATE INDEX
1615CREATE INDEX
1616CREATE INDEX
1617CREATE INDEX
1618CREATE INDEX
1619CREATE INDEX
1620CREATE INDEX
1621CREATE INDEX
1622CREATE INDEX
1623CREATE INDEX
1624CREATE INDEX
1625CREATE INDEX
1626CREATE INDEX
1627CREATE INDEX
1628CREATE INDEX
1629CREATE INDEX
1630CREATE INDEX
1631CREATE INDEX
1632CREATE INDEX
1633CREATE INDEX
1634CREATE INDEX
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 TRIGGER
1714CREATE TRIGGER
1715CREATE TRIGGER
1716CREATE TRIGGER
1717CREATE TRIGGER
1718CREATE TRIGGER
1719CREATE TRIGGER
1720CREATE TRIGGER
1721CREATE TRIGGER
1722CREATE TRIGGER
1723CREATE TRIGGER
1724CREATE TRIGGER
1725CREATE TRIGGER
1726CREATE TRIGGER
1727CREATE TRIGGER
1728CREATE TRIGGER
1729CREATE TRIGGER
1730ALTER TABLE
1731ALTER TABLE
1732ALTER TABLE
1733ALTER TABLE
1734ALTER TABLE
1735ALTER TABLE
1736ALTER TABLE
1737ALTER TABLE
1738ALTER TABLE
1739ALTER TABLE
1740ALTER TABLE
1741ALTER TABLE
1742ALTER TABLE
1743ALTER TABLE
1744ALTER TABLE
1745ALTER TABLE
1746ALTER TABLE
1747ALTER TABLE
1748ALTER TABLE
1749ALTER TABLE
1750ALTER TABLE
1751ALTER TABLE
1752ALTER TABLE
1753ALTER TABLE
1754ALTER TABLE
1755ALTER TABLE
1756ALTER TABLE
1757ALTER TABLE
1758ALTER TABLE
1759ALTER TABLE
1760ALTER TABLE
1761ALTER TABLE
1762ALTER TABLE
1763SET
1764INSERT 0 394
176539.92s$ bundle exec rspec spec
1767Repo counts
1768 before aggregation
1769 after aggregating per repo
1770 after aggregating all counts
1771 does not raise if repos are missing
1772 does not raise if builds are deleted before stages
1774set_updated_at trigger
1775Dropped database 'travis_test'
1776Created database 'travis_test'
1777== 201207261749 CreatePlans: migrating ========================================
1778-- create_table(:plans, {:id=>:integer})
1779 -> 0.0056s
1780== 201207261749 CreatePlans: migrated (0.0057s) ===============================
1782== 20101126174706 CreateRepositories: migrating ===============================
1783-- create_table(:repositories, {:id=>:integer})
1784 -> 0.0049s
1785== 20101126174706 CreateRepositories: migrated (0.0050s) ======================
1787== 20101126174715 CreateBuilds: migrating =====================================
1788-- create_table(:builds, {:id=>:integer})
1789 -> 0.0050s
1790== 20101126174715 CreateBuilds: migrated (0.0051s) ============================
1792== 20110109130532 DeviseCreateUsers: migrating ================================
1793-- create_table(:users, {:id=>:integer})
1794 -> 0.0043s
1795-- add_index(:users, :login, {:unique=>true})
1796 -> 0.0020s
1797== 20110109130532 DeviseCreateUsers: migrated (0.0064s) =======================
1799== 20110116155100 RepositoriesAddUsername: migrating ==========================
1800-- change_table(:repositories)
1801 -> 0.0007s
1802== 20110116155100 RepositoriesAddUsername: migrated (0.0007s) =================
1804== 20110130102621 CreateTokens: migrating =====================================
1805-- create_table(:tokens, {:id=>:integer})
1806 -> 0.0048s
1807== 20110130102621 CreateTokens: migrated (0.0048s) ============================
1809== 20110301071656 AddBuildParentIdAndConfiguration: migrating =================
1810-- change_table(:builds)
1811 -> 0.0010s
1812-- change_column(:builds, :number, :string)
1813 -> 0.0046s
1814-- add_index(:builds, :repository_id)
1815 -> 0.0019s
1816-- add_index(:builds, :parent_id)
1817 -> 0.0018s
1818== 20110301071656 AddBuildParentIdAndConfiguration: migrated (0.0094s) ========
1820== 20110316174721 RepositoriesDenormalizeLastBuildAttributes: migrating =======
1821-- change_table(:repositories)
1822 -> 0.0021s
1823== 20110316174721 RepositoriesDenormalizeLastBuildAttributes: migrated (0.0021s)
1825== 20110321075539 RepositoriesAddOwnerNameAndOwnerEmail: migrating ============
1826-- change_table(:repositories)
1827 -> 0.0014s
1828-- remove_column(:repositories, :username)
1829 -> 0.0004s
1830== 20110321075539 RepositoriesAddOwnerNameAndOwnerEmail: migrated (0.0019s) ===
1832== 20110411171936 CreateHistoriesTable: migrating =============================
1833-- create_table(:histories, {:id=>:integer})
1834 -> 0.0053s
1835-- add_index(:histories, [:item, :table, :month, :year])
1836 -> 0.0021s
1837== 20110411171936 CreateHistoriesTable: migrated (0.0075s) ====================
1839== 20110411171937 RenameHistoriesToRailsAdminHistories: migrating =============
1840-- remove_index(:histories, nil, {:name=>:index_histories_on_item_and_table_and_month_and_year})
1841 -> 0.0004s
1842-- rename_table(:histories, :rails_admin_histories)
1843 -> 0.0031s
1844-- add_index("rails_admin_histories", ["item", "table", "month", "year"], {:name=>"index_histories_on_item_and_table_and_month_and_year"})
1845 -> 0.0022s
1846== 20110411171937 RenameHistoriesToRailsAdminHistories: migrated (0.0069s) ====
1848== 20110411172518 AddAdminFlagToUser: migrating ===============================
1849-- change_table(:users)
1850 -> 0.0011s
1851== 20110411172518 AddAdminFlagToUser: migrated (0.0011s) ======================
1853== 20110413101057 BuildsAddRef: migrating =====================================
1854-- change_table(:builds)
1855 -> 0.0010s
1856== 20110413101057 BuildsAddRef: migrated (0.0010s) ============================
1858== 20110414131100 BuildsAddGithubPayload: migrating ===========================
1859-- change_table(:builds)
1860 -> 0.0006s
1861== 20110414131100 BuildsAddGithubPayload: migrated (0.0008s) ==================
1863== 20110503150504 AddGithubIdToUsersTable: migrating ==========================
1864-- add_column(:users, :github_id, :integer)
1865 -> 0.0006s
1866-- add_index(:users, :github_id)
1867 -> 0.0020s
1868== 20110503150504 AddGithubIdToUsersTable: migrated (0.0026s) =================
1870== 20110523012243 RepositoriesChangeOwnerEmailType: migrating =================
1871-- change_column(:repositories, :owner_email, :text)
1872 -> 0.0006s
1873== 20110523012243 RepositoriesChangeOwnerEmailType: migrated (0.0006s) ========
1875== 20110611203537 AddGithubOauthTokenToUser: migrating ========================
1876-- add_column(:users, :github_oauth_token, :string)
1877 -> 0.0005s
1878-- add_index(:users, :github_oauth_token)
1879 -> 0.0018s
1880== 20110611203537 AddGithubOauthTokenToUser: migrated (0.0024s) ===============
1882== 20110613210252 AddCompareUrlToBuild: migrating =============================
1883-- add_column(:builds, :compare_url, :string)
1884 -> 0.0006s
1885== 20110613210252 AddCompareUrlToBuild: migrated (0.0006s) ====================
1887== 20110615152003 BuildsRemoveJobId: migrating ================================
1888-- change_table(:builds)
1889 -> 0.0006s
1890== 20110615152003 BuildsRemoveJobId: migrated (0.0006s) =======================
1892== 20110616211744 BuildRemoveLastBuiltAt: migrating ===========================
1893-- change_table(:repositories)
1894 -> 0.0006s
1895== 20110616211744 BuildRemoveLastBuiltAt: migrated (0.0006s) ==================
1897== 20110617114728 AddMissingIndexes: migrating ================================
1898-- add_index(:repositories, :last_build_started_at)
1899 -> 0.0026s
1900-- add_index(:repositories, [:owner_name, :name])
1901 -> 0.0020s
1902-- add_index(:builds, [:repository_id, :parent_id, :started_at])
1903 -> 0.0019s
1904== 20110617114728 AddMissingIndexes: migrated (0.0067s) =======================
1906== 20110619100906 AddActiveToRepositories: migrating ==========================
1907-- add_column(:repositories, :is_active, :boolean)
1908 -> 0.0006s
1909== 20110619100906 AddActiveToRepositories: migrated (0.0007s) =================
1911== 20110729094426 StoreTokenInBuild: migrating ================================
1912-- add_column(:builds, :token, :string)
1913 -> 0.0006s
1914== 20110729094426 StoreTokenInBuild: migrated (0.0006s) =======================
1916== 20110801161819 CreateRequestsCommitsAndTasks: migrating ====================
1917-- change_table(:builds)
1918 -> 0.0014s
1919-- create_table(:commits, {:force=>true, :id=>:integer})
1920 -> 0.0049s
1921-- create_table(:requests, {:force=>true, :id=>:integer})
1922 -> 0.0048s
1923-- create_table(:tasks, {:force=>true, :id=>:integer})
1924 -> 0.0052s
1925-- add_index(:commits, :commit)
1926 -> 0.0018s
1927-- add_index(:builds, :commit)
1928 -> 0.0018s
1929-- add_index(:requests, :commit)
1930 -> 0.0018s
1931-- add_index(:tasks, :commit)
1932 -> 0.0035s
1933-- execute("UPDATE requests SET commit_id = (SELECT commits.id FROM commits WHERE commits.commit = requests.commit LIMIT 1)")
1934 -> 0.0006s
1935-- execute("UPDATE tasks SET commit_id = (SELECT commits.id FROM commits WHERE commits.commit = tasks.commit LIMIT 1)")
1936 -> 0.0004s
1937-- execute("DELETE FROM builds WHERE parent_id IS NOT NULL")
1938 -> 0.0004s
1939-- execute("UPDATE builds SET request_id = (SELECT requests.id FROM requests WHERE requests.commit = builds.commit LIMIT 1)")
1940 -> 0.0003s
1941-- execute("UPDATE builds SET commit_id = (SELECT commits.id FROM commits WHERE commits.commit = builds.commit LIMIT 1)")
1942 -> 0.0003s
1943-- execute("CREATE SEQUENCE shared_builds_tasks_seq CACHE 30")
1944 -> 0.0005s
1945-- execute("ALTER TABLE builds ALTER COLUMN id TYPE BIGINT")
1946 -> 0.0108s
1947-- execute("ALTER TABLE builds ALTER COLUMN id SET DEFAULT nextval('shared_builds_tasks_seq')")
1948 -> 0.0005s
1949-- execute("ALTER TABLE tasks ALTER COLUMN id TYPE BIGINT")
1950 -> 0.0059s
1951-- execute("ALTER TABLE tasks ALTER COLUMN id SET DEFAULT nextval('shared_builds_tasks_seq')")
1952 -> 0.0004s
1953-- select_value("SELECT max(id) FROM commits")
1954 -> 0.0005s
1955-- execute("SELECT setval('commits_id_seq', 1)")
1956 -> 0.0003s
1957-- select_value("SELECT max(id) FROM requests")
1958 -> 0.0004s
1959-- execute("SELECT setval('requests_id_seq', 1)")
1960 -> 0.0003s
1961-- select_value("SELECT max(id) FROM tasks")
1962 -> 0.0005s
1963-- execute("SELECT setval('tasks_id_seq', 1)")
1964 -> 0.0002s
1965-- remove_column(:builds, :parent_id)
1966 -> 0.0005s
1967-- remove_column(:builds, :commit)
1968 -> 0.0004s
1969-- remove_column(:requests, :commit)
1970 -> 0.0004s
1971-- remove_column(:tasks, :commit)
1972 -> 0.0004s
1973== 20110801161819 CreateRequestsCommitsAndTasks: migrated (0.0498s) ===========
1975== 20110805030147 RepositoryRenameIsActiveToActive: migrating =================
1976-- rename_column(:repositories, :is_active, :active)
1977 -> 0.0066s
1978== 20110805030147 RepositoryRenameIsActiveToActive: migrated (0.0067s) ========
1980== 20110819232908 TasksAddTags: migrating =====================================
1981-- add_column(:tasks, :tags, :text)
1982 -> 0.0009s
1983== 20110819232908 TasksAddTags: migrated (0.0010s) ============================
1985== 20110911204538 CacheOneNumberForSharedBuildsTasksSequence: migrating =======
1986-- execute("ALTER SEQUENCE shared_builds_tasks_seq CACHE 1 NO MAXVALUE NO CYCLE")
1987 -> 0.0009s
1988== 20110911204538 CacheOneNumberForSharedBuildsTasksSequence: migrated (0.0009s)
1990== 20111107134436 RenameTasksToJobs: migrating ================================
1991-- rename_table(:tasks, :jobs)
1992 -> 0.0043s
1993-- execute("UPDATE jobs SET type = 'Job::Test' WHERE type = 'Task::Test'")
1994 -> 0.0006s
1995-- execute("UPDATE jobs SET type = 'Job::Configure' WHERE type = 'Task::Configure'")
1996 -> 0.0004s
1997== 20111107134436 RenameTasksToJobs: migrated (0.0054s) =======================
1999== 20111107134437 CreateArtifacts: migrating ==================================
2000-- create_table(:artifacts, {:id=>:integer})
2001 -> 0.0067s
2002-- execute("UPDATE artifacts SET job_id = id")
2003 -> 0.0006s
2004-- execute("select setval('artifacts_id_seq', (select max(id) + 1 from artifacts));")
2005 -> 0.0006s
2006-- add_index(:artifacts, [:type, :job_id])
2007 -> 0.0027s
2008== 20111107134437 CreateArtifacts: migrated (0.0109s) =========================
2010== 20111107134438 CreateWorkers: migrating ====================================
2011-- create_table(:workers, {:id=>:integer})
2012 -> 0.0068s
2013-- add_index(:workers, [:name, :host])
2014 -> 0.0023s
2015== 20111107134438 CreateWorkers: migrated (0.0092s) ===========================
2017== 20111107134439 JobsAddRetries: migrating ===================================
2018-- change_table(:jobs)
2019 -> 0.0034s
2020== 20111107134439 JobsAddRetries: migrated (0.0035s) ==========================
2022== 20111107134440 RemoveRailsAdmin: migrating =================================
2023-- drop_table(:rails_admin_histories)
2024 -> 0.0021s
2025== 20111107134440 RemoveRailsAdmin: migrated (0.0022s) ========================
2027== 20111128235043 AddIndexesToJobs: migrating =================================
2028-- add_index(:jobs, [:queue, :state])
2029 -> 0.0031s
2030== 20111128235043 AddIndexesToJobs: migrated (0.0031s) ========================
2032== 20111129014329 AddRepositoryIdIndexToJobs: migrating =======================
2033-- add_index(:jobs, :repository_id)
2034 -> 0.0031s
2035== 20111129014329 AddRepositoryIdIndexToJobs: migrated (0.0032s) ==============
2037== 20111129022625 AddOwnerAndTypeIndexToJobs: migrating =======================
2038-- add_index(:jobs, [:type, :owner_id, :owner_type])
2039 -> 0.0033s
2040== 20111129022625 AddOwnerAndTypeIndexToJobs: migrated (0.0035s) ==============
2042== 20111201113500 WorkersAddPayloadAndLastError: migrating ====================
2043-- change_table(:workers)
2044 -> 0.0014s
2045== 20111201113500 WorkersAddPayloadAndLastError: migrated (0.0014s) ===========
2047== 20111203002341 RepositoriesAddDescriptionAndLastLanguage: migrating ========
2048-- change_table(:repositories)
2049 -> 0.0031s
2050-- change_table(:builds)
2051 -> 0.0014s
2052== 20111203002341 RepositoriesAddDescriptionAndLastLanguage: migrated (0.0048s)
2054== 20111203221720 BuildsAddArchivedAt: migrating ==============================
2055-- change_table(:builds)
2056 -> 0.0020s
2057== 20111203221720 BuildsAddArchivedAt: migrated (0.0022s) =====================
2059== 20111207093700 MimicProductionDb: migrating ================================
2060-- column_exists?(:users, :oauth2_uid, :integer)
2061 -> 0.0021s
2062-- column_exists?(:users, :oauth2_token, :string)
2063 -> 0.0014s
2064-- column_exists?(:repositories, :user_id, :integer)
2065 -> 0.0018s
2066== 20111207093700 MimicProductionDb: migrated (0.0055s) =======================
2068== 20111212103859 BuildsAddDuration: migrating ================================
2069-- change_table(:builds)
2070 -> 0.0039s
2071== 20111212103859 BuildsAddDuration: migrated (0.0039s) =======================
2073== 20111212112411 RepositoriesAddLastBuildDuration: migrating =================
2074-- change_table(:repositories)
2075 -> 0.0024s
2076== 20111212112411 RepositoriesAddLastBuildDuration: migrated (0.0029s) ========
2078== 20111214173922 CreateSslKeys: migrating ====================================
2079-- create_table(:ssl_keys, {:id=>:integer})
2080 -> 0.0067s
2081-- add_index("ssl_keys", ["repository_id"], {:name=>"index_ssl_key_on_repository_id"})
2082 -> 0.0021s
2083== 20111214173922 CreateSslKeys: migrated (0.0090s) ===========================
2085== 20120114125404 AddAllowFailureToJobs: migrating ============================
2086-- add_column(:jobs, :allow_failure, :boolean, {:default=>false})
2087 -> 0.0013s
2088== 20120114125404 AddAllowFailureToJobs: migrated (0.0014s) ===================
2090== 20120216133223 AddPullRequestFieldsToRequest: migrating ====================
2091-- add_column(:requests, :event_type, :string)
2092 -> 0.0090s
2093-- add_column(:requests, :comments_url, :string)
2094 -> 0.0005s
2095-- add_column(:requests, :base_commit, :string)
2096 -> 0.0005s
2097-- add_column(:requests, :head_commit, :string)
2098 -> 0.0004s
2099== 20120216133223 AddPullRequestFieldsToRequest: migrated (0.0106s) ===========
2101== 20120222082522 AddGravatarIdToUsers: migrating =============================
2102-- add_column(:users, :gravatar_id, :string)
2103 -> 0.0008s
2104== 20120222082522 AddGravatarIdToUsers: migrated (0.0008s) ====================
2106== 20120301131209 OrganizationsCreate: migrating ==============================
2107-- create_table(:organizations, {:id=>:integer})
2108 -> 0.0057s
2109== 20120301131209 OrganizationsCreate: migrated (0.0057s) =====================
2111== 20120304000502 JobsRenameOwnerToSource: migrating ==========================
2112-- change_table(:jobs)
2113 -> 0.0072s
2114== 20120304000502 JobsRenameOwnerToSource: migrated (0.0073s) =================
2116== 20120304000503 RepositoriesAddOwner: migrating =============================
2117-- change_table(:repositories)
2118 -> 0.0015s
2119== 20120304000503 RepositoriesAddOwner: migrated (0.0015s) ====================
2121== 20120304000504 BuildsAddOwner: migrating ===================================
2122-- change_table(:builds)
2123 -> 0.0014s
2124== 20120304000504 BuildsAddOwner: migrated (0.0014s) ==========================
2126== 20120304000505 JobsAddOwner: migrating =====================================
2127-- change_table(:jobs)
2128 -> 0.0012s
2129== 20120304000505 JobsAddOwner: migrated (0.0013s) ============================
2131== 20120304000506 RequestsAddOwner: migrating =================================
2132-- change_table(:requests)
2133 -> 0.0012s
2134== 20120304000506 RequestsAddOwner: migrated (0.0012s) ========================
2136== 20120311234933 AddLocaleToUser: migrating ==================================
2137-- add_column(:users, :locale, :string)
2138 -> 0.0007s
2139== 20120311234933 AddLocaleToUser: migrated (0.0008s) =========================
2141== 20120316123726 CreateMemberships: migrating ================================
2142-- create_table(:memberships, {:id=>:integer})
2143 -> 0.0035s
2144== 20120316123726 CreateMemberships: migrated (0.0036s) =======================
2146== 20120319170001 RepositoriesAddPrivate: migrating ===========================
2147-- change_table(:repositories)
2148 -> 0.0011s
2149== 20120319170001 RepositoriesAddPrivate: migrated (0.0012s) ==================
2151== 20120324104051 CreateUrls: migrating =======================================
2152-- create_table(:urls, {:id=>:integer})
2153 -> 0.0049s
2154== 20120324104051 CreateUrls: migrated (0.0050s) ==============================
2156== 20120505165100 CopyStatusToResult: migrating ===============================
2157-- add_column(:builds, :result, :integer)
2158 -> 0.0007s
2159-- add_column(:jobs, :result, :integer)
2160 -> 0.0004s
2161-- add_column(:repositories, :last_build_result, :integer)
2162 -> 0.0004s
2163Executing: UPDATE builds SET result = status;
2164Executing: UPDATE jobs SET result = status;
2165Executing: UPDATE repositories SET last_build_result = last_build_status;
2166== 20120505165100 CopyStatusToResult: migrated (0.0027s) ======================
2168== 20120511171900 RequestsAddIndexOnHeadCommit: migrating =====================
2169-- add_index(:requests, :head_commit)
2170 -> 0.0024s
2171== 20120511171900 RequestsAddIndexOnHeadCommit: migrated (0.0024s) ============
2173== 20120521174400 CreatePermissions: migrating ================================
2174-- create_table(:permissions, {:id=>:integer})
2175 -> 0.0101s
2176-- add_index(:permissions, :user_id)
2177 -> 0.0023s
2178-- add_index(:permissions, :repository_id)
2179 -> 0.0022s
2180== 20120521174400 CreatePermissions: migrated (0.0148s) =======================
2182== 20120527235800 BuildsAddPreviousResult: migrating ==========================
2183-- change_table(:builds)
2184 -> 0.0009s
2185== 20120527235800 BuildsAddPreviousResult: migrated (0.0010s) =================
2187== 20120702111126 CreateSubscriptions: migrating ==============================
2188-- create_table(:subscriptions, {:id=>:integer})
2189 -> 0.0097s
2190== 20120702111126 CreateSubscriptions: migrated (0.0098s) =====================
2192== 20120703114226 AddBillingEmailCreditCardDataToSubscriptions: migrating =====
2193-- change_table(:subscriptions)
2194 -> 0.0023s
2195== 20120703114226 AddBillingEmailCreditCardDataToSubscriptions: migrated (0.0024s)
2197== 20120713140816 AddSyncInfoToUser: migrating ================================
2198-- add_column(:users, :in_sync, :boolean)
2199 -> 0.0017s
2200-- add_column(:users, :synced_at, :timestamp)
2201 -> 0.0005s
2202== 20120713140816 AddSyncInfoToUser: migrated (0.0022s) =======================
2204== 20120713153215 RenameInSyncToIsSyncing: migrating ==========================
2205-- rename_column(:users, :in_sync, :is_syncing)
2206 -> 0.0051s
2207== 20120713153215 RenameInSyncToIsSyncing: migrated (0.0053s) =================
2209== 20120725005300 AddQueueToWorkers: migrating ================================
2210-- add_column(:workers, :queue, :string)
2211 -> 0.0012s
2212== 20120725005300 AddQueueToWorkers: migrated (0.0014s) =======================
2214== 20120727151900 AddJobsIndexOnStateOwnerTypeOwnerId: migrating ==============
2215-- add_index(:jobs, ["state", "owner_id", "owner_type"], {:name=>"index_jobs_on_state_owner_type_owner_id"})
2216 -> 0.0023s
2217== 20120727151900 AddJobsIndexOnStateOwnerTypeOwnerId: migrated (0.0024s) =====
2219== 20120731005301 AddQueuedAtToJobs: migrating ================================
2220-- add_column(:jobs, :queued_at, :timestamp, {:precision=>nil})
2221 -> 0.0008s
2222== 20120731005301 AddQueuedAtToJobs: migrated (0.0008s) =======================
2224== 20120731074000 AddAmountToPlans: migrating =================================
2225-- change_table(:plans)
2226 -> 0.0008s
2227== 20120731074000 AddAmountToPlans: migrated (0.0008s) ========================
2229== 20120802001001 AddPushAndPullToPermissions: migrating ======================
2230-- add_column(:permissions, :push, :boolean, {:default=>false})
2231 -> 0.0037s
2232-- add_column(:permissions, :pull, :boolean, {:default=>false})
2233 -> 0.0009s
2234-- change_column_default(:permissions, :admin, false)
2235 -> 0.0032s
2236== 20120802001001 AddPushAndPullToPermissions: migrated (0.0082s) =============
2238== 20120803164000 CreateInvoices: migrating ===================================
2239-- create_table(:invoices, {:id=>:integer})
2240 -> 0.0071s
2241== 20120803164000 CreateInvoices: migrated (0.0073s) ==========================
2243== 20120803182300 AddInvoiceIdToInvoices: migrating ===========================
2244-- change_table(:invoices)
2245 -> 0.0009s
2246== 20120803182300 AddInvoiceIdToInvoices: migrated (0.0010s) ==================
2248== 20120804122700 AddStripeInvoiceIdToInvoices: migrating =====================
2249-- change_table(:invoices)
2250 -> 0.0012s
2251-- add_index(:invoices, :stripe_id)
2252 -> 0.0050s
2253== 20120804122700 AddStripeInvoiceIdToInvoices: migrated (0.0064s) ============
2255== 20120806120400 AddPlanToSubscriptions: migrating ===========================
2256-- change_table(:subscriptions)
2257 -> 0.0010s
2258== 20120806120400 AddPlanToSubscriptions: migrated (0.0011s) ==================
2260== 20120820164000 RenamePlanOnSubscriptions: migrating ========================
2261-- change_table(:subscriptions)
2262 -> 0.0015s
2263== 20120820164000 RenamePlanOnSubscriptions: migrated (0.0016s) ===============
2265== 20120905093300 CreateStripeEvents: migrating ===============================
2266-- create_table(:stripe_events, {:id=>:integer})
2267 -> 0.0062s
2268-- add_index(:stripe_events, :event_type)
2269 -> 0.0036s
2270-- add_index(:stripe_events, :date)
2271 -> 0.0025s
2272== 20120905093300 CreateStripeEvents: migrated (0.0126s) ======================
2274== 20120905171300 AddEventIdToStripeEvents: migrating =========================
2275-- change_table(:stripe_events)
2276 -> 0.0010s
2277-- add_index(:stripe_events, :event_id)
2278 -> 0.0019s
2279== 20120905171300 AddEventIdToStripeEvents: migrated (0.0030s) ================
2281== 20120911160000 AddBuildsIndexOnRepositoryIdAndState: migrating =============
2282-- remove_index("builds", nil, {:column=>"repository_id", :name=>"index_builds_on_repository_id"})
2283 -> 0.0021s
2284-- add_index("builds", ["repository_id", "state"])
2285 -> 0.0033s
2286== 20120911160000 AddBuildsIndexOnRepositoryIdAndState: migrated (0.0066s) ====
2288== 20120911230000 ArtifactsAddAggregatedAt: migrating =========================
2289-- add_column(:artifacts, :aggregated_at, :timestamp, {:precision=>nil})
2290 -> 0.0018s
2291== 20120911230000 ArtifactsAddAggregatedAt: migrated (0.0021s) ================
2293== 20120911230001 AddArtifactParts: migrating =================================
2294-- create_table(:artifact_parts, {:id=>:integer})
2295 -> 0.0051s
2296-- add_index(:artifact_parts, [:artifact_id, :number])
2297 -> 0.0019s
2298== 20120911230001 AddArtifactParts: migrated (0.0071s) ========================
2300== 20120913143800 AddSubscriptionsCoupon: migrating ===========================
2301-- change_table(:subscriptions)
2302 -> 0.0007s
2303== 20120913143800 AddSubscriptionsCoupon: migrated (0.0008s) ==================
2305== 20120915012000 BuildsAddIndexOnFinishedAt: migrating =======================
2306-- add_index("builds", "finished_at")
2307 -> 0.0023s
2308== 20120915012000 BuildsAddIndexOnFinishedAt: migrated (0.0023s) ==============
2310== 20120915012001 CommitsAddIndexOnBranch: migrating ==========================
2311-- add_index("commits", "branch")
2312 -> 0.0022s
2313== 20120915012001 CommitsAddIndexOnBranch: migrated (0.0022s) =================
2315== 20120915150000 JobsAddIndexOnCreatedAt: migrating ==========================
2316-- add_index("jobs", "created_at")
2317 -> 0.0021s
2318== 20120915150000 JobsAddIndexOnCreatedAt: migrated (0.0021s) =================
2320== 20121015002500 CreateEvents: migrating =====================================
2321-- create_table(:events, {:id=>:integer})
2322 -> 0.0045s
2323== 20121015002500 CreateEvents: migrated (0.0045s) ============================
2325== 20121015002501 RequestsAddResultAndMessage: migrating ======================
2326-- add_column(:requests, :result, :string)
2327 -> 0.0007s
2328-- add_column(:requests, :message, :string)
2329 -> 0.0004s
2330== 20121015002501 RequestsAddResultAndMessage: migrated (0.0011s) =============
2332== 20121017040100 CreateBroadcasts: migrating =================================
2333-- create_table(:broadcasts, {:id=>:integer})
2334 -> 0.0053s
2335== 20121017040100 CreateBroadcasts: migrated (0.0053s) ========================
2337== 20121017040200 EventsChangeDataToText: migrating ===========================
2338-- change_column(:events, :data, :text)
2339 -> 0.0007s
2340== 20121017040200 EventsChangeDataToText: migrated (0.0007s) ==================
2342== 20121018201301 AddEventTypeToBuilds: migrating =============================
2343-- add_column(:builds, :event_type, :string)
2344 -> 0.0006s
2345== 20121018201301 AddEventTypeToBuilds: migrated (0.0006s) ====================
2347== 20121018203728 UpdateEventTypeOnBuilds: migrating ==========================
2348-- execute(" UPDATE builds\n SET event_type = requests.event_type\n FROM requests\n WHERE builds.request_id = requests.id\n")
2349 -> 0.0009s
2350== 20121018203728 UpdateEventTypeOnBuilds: migrated (0.0009s) =================
2352== 20121018210156 AddIndexOnRepositoryIdAndEventTypeToBuilds: migrating =======
2353-- add_index(:builds, [:repository_id, :event_type])
2354 -> 0.0023s
2355== 20121018210156 AddIndexOnRepositoryIdAndEventTypeToBuilds: migrated (0.0023s)
2357== 20121125122700 RepositoriesAddLastBuildState: migrating ====================
2358-- add_column(:repositories, :last_build_state, :string)
2359 -> 0.0006s
2360== 20121125122700 RepositoriesAddLastBuildState: migrated (0.0007s) ===========
2362== 20121125122701 BuildsAddPreviousState: migrating ===========================
2363-- add_column(:builds, :previous_state, :string)
2364 -> 0.0006s
2365== 20121125122701 BuildsAddPreviousState: migrated (0.0007s) ==================
2367== 20121222125200 ArtifactPartsAddFinal: migrating ============================
2368-- add_column(:artifact_parts, :final, :boolean)
2369 -> 0.0018s
2370-- add_column(:artifact_parts, :created_at, :timestamp)
2371 -> 0.0013s
2372== 20121222125200 ArtifactPartsAddFinal: migrated (0.0033s) ===================
2374== 20121222125300 ArtifactPartsChangeContentToText: migrating =================
2375-- change_column(:artifact_parts, :content, :text)
2376 -> 0.0017s
2377== 20121222125300 ArtifactPartsChangeContentToText: migrated (0.0019s) ========
2379== 20121222140200 ArtifactPartsAddIndexOnArtifactId: migrating ================
2380-- add_index(:artifact_parts, :artifact_id)
2381 -> 0.0033s
2382== 20121222140200 ArtifactPartsAddIndexOnArtifactId: migrated (0.0033s) =======
2384== 20121223162300 ArtifactPartsRemoveIndexOnArtifactId: migrating =============
2385-- remove_index(:artifact_parts, :artifact_id, {:name=>"index_artifact_parts_on_artifact_id"})
2386 -> 0.0047s
2387== 20121223162300 ArtifactPartsRemoveIndexOnArtifactId: migrated (0.0070s) ====
2389== 20130107165057 AddGithubScopesToUser: migrating ============================
2390-- add_column(:users, :github_scopes, :text)
2391 -> 0.0016s
2392== 20130107165057 AddGithubScopesToUser: migrated (0.0019s) ===================
2394== 20130115125836 AddIndexOnLastSeenAtToWorkers: migrating ====================
2395-- add_index(:workers, :last_seen_at)
2396 -> 0.0036s
2397== 20130115125836 AddIndexOnLastSeenAtToWorkers: migrated (0.0038s) ===========
2399== 20130115145728 CacheFullNameInWorkers: migrating ===========================
2400-- add_column(:workers, :full_name, :string)
2401 -> 0.0019s
2402-- add_index(:workers, :full_name)
2403 -> 0.0028s
2404== 20130115145728 CacheFullNameInWorkers: migrated (0.0049s) ==================
2406== 20130125002600 ArtifactsAddArchivedAt: migrating ===========================
2407-- add_column(:artifacts, :archived_at, :timestamp, {:precision=>nil})
2408 -> 0.0018s
2409-- add_index(:artifacts, :archived_at)
2410 -> 0.0027s
2411== 20130125002600 ArtifactsAddArchivedAt: migrated (0.0048s) ==================
2413== 20130125171100 ArtifactsAddArchivingAndVerified: migrating =================
2414-- add_column(:artifacts, :archiving, :boolean)
2415 -> 0.0019s
2416-- add_column(:artifacts, :archive_verified, :boolean)
2417 -> 0.0011s
2418-- add_index(:artifacts, :archiving)
2419 -> 0.0029s
2420-- add_index(:artifacts, :archive_verified)
2421 -> 0.0023s
2422== 20130125171100 ArtifactsAddArchivingAndVerified: migrated (0.0086s) ========
2424== 20130129142703 CreateEmails: migrating =====================================
2425-- create_table(:emails, {:id=>:integer})
2426 -> 0.0073s
2427-- add_index(:emails, :user_id)
2428 -> 0.0021s
2429-- add_index(:emails, :email)
2430 -> 0.0020s
2431== 20130129142703 CreateEmails: migrated (0.0118s) ============================
2433== 20130208135800 RenameArtifacts: migrating ==================================
2434-- rename_table(:artifacts, :artifacts_backup)
2435 -> 0.0058s
2436-- rename_table(:artifact_parts, :artifact_parts_backup)
2437 -> 0.0034s
2438== 20130208135800 RenameArtifacts: migrated (0.0093s) =========================
2440== 20130208135801 DropArtifacts: migrating ====================================
2441-- drop_table(:artifacts_backup)
2442 -> 0.0011s
2443-- drop_table(:artifact_parts_backup)
2444 -> 0.0007s
2445== 20130208135801 DropArtifacts: migrated (0.0018s) ===========================
2447== 20130306154311 CreatePgcryptoExtension: migrating ==========================
2448-- execute("create extension if not exists pgcrypto")
2449 -> 0.0036s
2450== 20130306154311 CreatePgcryptoExtension: migrated (0.0036s) =================
2452== 20130311211101 AddPullRequestTitleToBuilds: migrating ======================
2453-- add_column(:builds, :pull_request_title, :text)
2454 -> 0.0007s
2455== 20130311211101 AddPullRequestTitleToBuilds: migrated (0.0007s) =============
2457== 20130327100801 AddPullRequestNumberToBuilds: migrating =====================
2458-- add_column(:builds, :pull_request_number, :integer)
2459 -> 0.0006s
2460== 20130327100801 AddPullRequestNumberToBuilds: migrated (0.0007s) ============
2462== 20130418101437 AddIndexToBuildsRequestId: migrating ========================
2463-- execute("CREATE INDEX CONCURRENTLY index_builds_on_request_id ON builds(request_id)")
2464 -> 0.0040s
2465== 20130418101437 AddIndexToBuildsRequestId: migrated (0.0040s) ===============
2467== 20130418103306 AddIndexToJobsOnOwnerIdOwnerTypeAndState: migrating =========
2468-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_owner_id_and_owner_type_and_state ON jobs(owner_id, owner_type, state)")
2469 -> 0.0037s
2470== 20130418103306 AddIndexToJobsOnOwnerIdOwnerTypeAndState: migrated (0.0038s)
2472== 20130505023259 AddMoreIndexesToBuilds: migrating ===========================
2473-- 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")
2474 -> 0.0037s
2475== 20130505023259 AddMoreIndexesToBuilds: migrated (0.0037s) ==================
2477== 20130521115725 AddIndexOnBuildState: migrating =============================
2478-- execute(" CREATE INDEX CONCURRENTLY index_builds_on_state\n ON builds(state);\n")
2479 -> 0.0037s
2480== 20130521115725 AddIndexOnBuildState: migrated (0.0038s) ====================
2482== 20130521133050 UpdateFinishedJobs: migrating ===============================
2483-- execute("UPDATE jobs SET state = 'passed' WHERE state = 'finished' AND result = 0 AND type = 'Job::Test'")
2484 -> 0.0007s
2485-- execute("UPDATE jobs SET state = 'failed' WHERE state = 'finished' AND result = 1 AND type = 'Job::Test'")
2486 -> 0.0003s
2487-- execute("UPDATE jobs SET state = 'errored' WHERE state = 'finished' AND result IS NULL AND type = 'Job::Test'")
2488 -> 0.0003s
2489-- execute("SELECT COUNT(*) FROM jobs WHERE state = 'finished' AND type = 'Job::Test'")
2490 -> 0.0004s
2491== 20130521133050 UpdateFinishedJobs: migrated (0.0018s) ======================
2493== 20130521134224 UpdateFinishedBuilds: migrating =============================
2494-- execute("UPDATE builds SET state = 'passed' WHERE state = 'finished' AND result = 0")
2495 -> 0.0007s
2496-- execute("UPDATE builds SET state = 'failed' WHERE state = 'finished' AND result = 1")
2497 -> 0.0003s
2498-- execute("UPDATE builds SET state = 'errored' WHERE state = 'finished' AND result IS NULL")
2499 -> 0.0003s
2500-- execute("SELECT COUNT(*) FROM builds WHERE state = 'finished'")
2501 -> 0.0003s
2502== 20130521134224 UpdateFinishedBuilds: migrated (0.0017s) ====================
2504== 20130521134800 RemoveUnusedBuildColumns: migrating =========================
2505-- remove_column(:builds, :result)
2506 -> 0.0006s
2507-- remove_column(:builds, :status)
2508 -> 0.0003s
2509-- remove_column(:builds, :previous_result)
2510 -> 0.0003s
2511-- remove_column(:builds, :agent)
2512 -> 0.0003s
2513-- remove_column(:builds, :language)
2514 -> 0.0003s
2515-- remove_column(:builds, :archived_at)
2516 -> 0.0003s
2517== 20130521134800 RemoveUnusedBuildColumns: migrated (0.0023s) ================
2519== 20130521141357 RemoveUnusedJobColumns: migrating ===========================
2520-- remove_column(:jobs, :status)
2521 -> 0.0005s
2522-- remove_column(:jobs, :job_id)
2523 -> 0.0003s
2524-- remove_column(:jobs, :retries)
2525 -> 0.0004s
2526== 20130521141357 RemoveUnusedJobColumns: migrated (0.0013s) ==================
2528== 20130618084205 AddCoupons: migrating =======================================
2529-- create_table(:coupons, {:id=>:integer})
2530 -> 0.0092s
2531== 20130618084205 AddCoupons: migrated (0.0093s) ==============================
2533== 20130629122945 AddGithubIdToUsers: migrating ===============================
2534-- add_column(:repositories, :github_id, :integer)
2535 -> 0.0007s
2536-- add_index(:repositories, :github_id)
2537 -> 0.0020s
2538== 20130629122945 AddGithubIdToUsers: migrated (0.0027s) ======================
2540== 20130629133531 AddDefaultBranchToRepositories: migrating ===================
2541-- add_column(:repositories, :default_branch, :string)
2542 -> 0.0006s
2543== 20130629133531 AddDefaultBranchToRepositories: migrated (0.0006s) ==========
2545== 20130629174449 AddGithubLanguageToRepositories: migrating ==================
2546-- add_column(:repositories, :github_language, :string)
2547 -> 0.0006s
2548== 20130629174449 AddGithubLanguageToRepositories: migrated (0.0006s) =========
2550== 20130701175200 AddContactIdToSubscriptions: migrating ======================
2551-- change_table(:subscriptions)
2552 -> 0.0006s
2553== 20130701175200 AddContactIdToSubscriptions: migrated (0.0007s) =============
2555== 20130702123456 RemoveUnusedRepositoryColumns: migrating ====================
2556-- remove_column(:repositories, :last_duration)
2557 -> 0.0010s
2558-- remove_column(:repositories, :last_build_status)
2559 -> 0.0006s
2560-- remove_column(:repositories, :last_build_result)
2561 -> 0.0006s
2562-- remove_column(:repositories, :last_build_language)
2563 -> 0.0005s
2564== 20130702123456 RemoveUnusedRepositoryColumns: migrated (0.0029s) ===========
2566== 20130702144325 AddUniqueIndexOnUsersGithubIdAndRemoveUniqueIndexOnUsersLogin: migrating
2567-- execute("DROP INDEX index_users_on_login")
2568 -> 0.0013s
2569-- execute("CREATE INDEX CONCURRENTLY index_users_on_login ON users(login)")
2570 -> 0.0041s
2571-- execute("DROP INDEX index_users_on_github_id")
2572 -> 0.0016s
2573-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_users_on_github_id ON users(github_id)")
2574 -> 0.0045s
2575== 20130702144325 AddUniqueIndexOnUsersGithubIdAndRemoveUniqueIndexOnUsersLogin: migrated (0.0118s)
2577== 20130705123456 AddExtraColumnsToOrganizations: migrating ===================
2578-- add_column(:organizations, :avatar_url, :string)
2579 -> 0.0012s
2580-- add_column(:organizations, :location, :string)
2581 -> 0.0008s
2582-- add_column(:organizations, :email, :string)
2583 -> 0.0008s
2584-- add_column(:organizations, :company, :string)
2585 -> 0.0008s
2586-- add_column(:organizations, :homepage, :string)
2587 -> 0.0007s
2588== 20130705123456 AddExtraColumnsToOrganizations: migrated (0.0045s) ==========
2590== 20130707164854 AddIndexOnGithubIdToOrganizations: migrating ================
2591-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_organizations_on_github_id ON organizations(github_id)")
2592 -> 0.0044s
2593== 20130707164854 AddIndexOnGithubIdToOrganizations: migrated (0.0045s) =======
2595== 20130709185200 CreateAnnotations: migrating ================================
2596-- create_table(:annotations, {:id=>:integer})
2597 -> 0.0075s
2598== 20130709185200 CreateAnnotations: migrated (0.0077s) =======================
2600== 20130709233500 CreateAnnotationProviders: migrating ========================
2601-- create_table(:annotation_providers, {:id=>:integer})
2602 -> 0.0059s
2603== 20130709233500 CreateAnnotationProviders: migrated (0.0059s) ===============
2605== 20130710000745 AddAnnotationProviderIdToAnnotations: migrating =============
2606-- add_column(:annotations, :annotation_provider_id, :integer, {:null=>false})
2607 -> 0.0008s
2608== 20130710000745 AddAnnotationProviderIdToAnnotations: migrated (0.0009s) ====
2610== 20130726101124 AddCanceledAtToJobsAndBuilds: migrating =====================
2611-- add_column(:builds, :canceled_at, :timestamp, {:precision=>nil})
2612 -> 0.0008s
2613-- add_column(:jobs, :canceled_at, :timestamp, {:precision=>nil})
2614 -> 0.0004s
2615== 20130726101124 AddCanceledAtToJobsAndBuilds: migrated (0.0013s) ============
2617== 20130901183019 AddIndexOnRepositoryGithubId: migrating =====================
2618-- execute("DROP INDEX index_repositories_on_github_id")
2619 -> 0.0011s
2620-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_github_id ON repositories(github_id)")
2621 -> 0.0040s
2622== 20130901183019 AddIndexOnRepositoryGithubId: migrated (0.0052s) ============
2624== 20130909203321 AddCachedMatrixIdsToBuilds: migrating =======================
2625-- execute("ALTER TABLE builds ADD COLUMN cached_matrix_ids integer[]")
2626 -> 0.0011s
2627== 20130909203321 AddCachedMatrixIdsToBuilds: migrated (0.0012s) ==============
2629== 20130910184823 CreateIndexOnBuildsIdDescAndRepositoryIdAndEventType: migrating
2630-- execute("CREATE INDEX CONCURRENTLY index_builds_on_id_repository_id_and_event_type_desc ON builds (id DESC, repository_id, event_type);")
2631 -> 0.0042s
2632== 20130910184823 CreateIndexOnBuildsIdDescAndRepositoryIdAndEventType: migrated (0.0043s)
2634== 20130916101056 AddUniqueIndexOnRepositoryGithubId: migrating ===============
2635-- execute("DROP INDEX index_repositories_on_github_id")
2636 -> 0.0014s
2637-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_repositories_on_github_id ON repositories(github_id)")
2638 -> 0.0039s
2639== 20130916101056 AddUniqueIndexOnRepositoryGithubId: migrated (0.0054s) ======
2641== 20130920135744 AddSettingsToRepositories: migrating ========================
2642-- add_column(:repositories, :settings, :json)
2643 -> 0.0013s
2644== 20130920135744 AddSettingsToRepositories: migrated (0.0013s) ===============
2646== 20131104101056 RemoveWorkersTableAndIndexes: migrating =====================
2647-- drop_table(:workers)
2648 -> 0.0019s
2649== 20131104101056 RemoveWorkersTableAndIndexes: migrated (0.0020s) ============
2651== 20131109101056 RemoveEventsTable: migrating ================================
2652-- drop_table(:events)
2653 -> 0.0014s
2654== 20131109101056 RemoveEventsTable: migrated (0.0015s) =======================
2656== 20140120225125 RemoveAnnotationImageInfo: migrating ========================
2657-- remove_column(:annotations, :image_url)
2658 -> 0.0011s
2659-- remove_column(:annotations, :image_alt)
2660 -> 0.0005s
2661== 20140120225125 RemoveAnnotationImageInfo: migrated (0.0018s) ===============
2663== 20140121003026 AddStatusToAnnotations: migrating ===========================
2664-- add_column(:annotations, :status, :string)
2665 -> 0.0012s
2666== 20140121003026 AddStatusToAnnotations: migrated (0.0013s) ==================
2668== 20140204220926 AddIndicesToRequests: migrating =============================
2669-- execute("CREATE INDEX CONCURRENTLY index_requests_on_repository_id ON requests(repository_id)")
2670 -> 0.0041s
2671-- execute("CREATE INDEX CONCURRENTLY index_requests_on_commit_id ON requests(commit_id)")
2672 -> 0.0042s
2673== 20140204220926 AddIndicesToRequests: migrated (0.0085s) ====================
2675== 20140210003014 AddIndicesToMemberships: migrating ==========================
2676-- execute("CREATE INDEX CONCURRENTLY index_memberships_on_user_id ON memberships(user_id)")
2677 -> 0.0041s
2678== 20140210003014 AddIndicesToMemberships: migrated (0.0041s) =================
2680== 20140210012509 RemoveUnusedIndices: migrating ==============================
2681-- execute("DROP INDEX CONCURRENTLY index_commits_on_commit")
2682 -> 0.0024s
2683-- execute("DROP INDEX CONCURRENTLY index_builds_on_state")
2684 -> 0.0022s
2685-- execute("DROP INDEX CONCURRENTLY index_commits_on_branch")
2686 -> 0.0020s
2687-- execute("DROP INDEX CONCURRENTLY index_users_on_github_oauth_token")
2688 -> 0.0023s
2689-- execute("DROP INDEX CONCURRENTLY index_builds_on_finished_at")
2690 -> 0.0021s
2691-- execute("DROP INDEX CONCURRENTLY index_jobs_on_queue_and_state")
2692 -> 0.0020s
2693-- execute("DROP INDEX CONCURRENTLY index_jobs_on_created_at")
2694 -> 0.0019s
2695== 20140210012509 RemoveUnusedIndices: migrated (0.0153s) =====================
2697== 20140612131826 AddRemovedInfoToLogs: migrating =============================
2698== 20140612131826 AddRemovedInfoToLogs: migrated (0.0007s) ====================
2700== 20140827121945 AddEducationFieldToUser: migrating ==========================
2701-- add_column(:users, :education, :boolean)
2702 -> 0.0008s
2703== 20140827121945 AddEducationFieldToUser: migrated (0.0008s) =================
2705== 20150121135400 JobsAddReceivedAt: migrating ================================
2706-- add_column(:jobs, :received_at, :timestamp, {:precision=>nil})
2707 -> 0.0006s
2708== 20150121135400 JobsAddReceivedAt: migrated (0.0007s) =======================
2710== 20150121135401 BuildsAddReceivedAt: migrating ==============================
2711-- add_column(:builds, :received_at, :timestamp, {:precision=>nil})
2712 -> 0.0006s
2713== 20150121135401 BuildsAddReceivedAt: migrated (0.0006s) =====================
2715== 20150204144312 AddIndexOnRepositoryIdToCommits: migrating ==================
2716-- execute("DROP INDEX IF EXISTS index_commits_on_repository_id")
2717 -> 0.0002s
2718-- execute("CREATE INDEX CONCURRENTLY index_commits_on_repository_id ON commits(repository_id)")
2719 -> 0.0036s
2720== 20150204144312 AddIndexOnRepositoryIdToCommits: migrated (0.0039s) =========
2722== 20150210170900 IndexRequestsOnCreatedAt: migrating =========================
2723-- execute("DROP INDEX IF EXISTS index_requests_on_created_at")
2724 -> 0.0002s
2725-- execute("CREATE INDEX CONCURRENTLY index_requests_on_created_at ON requests(created_at)")
2726 -> 0.0033s
2727== 20150210170900 IndexRequestsOnCreatedAt: migrated (0.0036s) ================
2729== 20150223125700 CreateBranches: migrating ===================================
2730-- create_table(:branches, {:id=>:integer})
2731 -> 0.0142s
2732-- add_index(:branches, [:repository_id, :name], {:unique=>true})
2733 -> 0.0024s
2734== 20150223125700 CreateBranches: migrated (0.0167s) ==========================
2736== 20150311020321 AddNextBuildNumberToRepository: migrating ===================
2737-- add_column(:repositories, :next_build_number, :integer)
2738 -> 0.0008s
2739== 20150311020321 AddNextBuildNumberToRepository: migrated (0.0008s) ==========
2741== 20150316020321 AddActiveIndexToRepository: migrating =======================
2742-- execute("DROP INDEX IF EXISTS index_repositories_on_active")
2743 -> 0.0003s
2744-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_active ON repositories(active)")
2745 -> 0.0038s
2746== 20150316020321 AddActiveIndexToRepository: migrated (0.0042s) ==============
2748== 20150316080321 AddOwnerTypeAndOwnerIdIndexesToBuilds: migrating ============
2749-- execute("DROP INDEX IF EXISTS index_builds_on_owner_type")
2750 -> 0.0003s
2751-- execute("DROP INDEX IF EXISTS index_builds_on_owner_id")
2752 -> 0.0003s
2753-- execute("CREATE INDEX CONCURRENTLY index_builds_on_owner_type ON builds(owner_type)")
2754 -> 0.0040s
2755-- execute("CREATE INDEX CONCURRENTLY index_builds_on_owner_id ON builds(owner_id)")
2756 -> 0.0036s
2757== 20150316080321 AddOwnerTypeAndOwnerIdIndexesToBuilds: migrated (0.0082s) ===
2759== 20150316100321 AddOwnerTypeAndOwnerIdIndexesToRepositories: migrating ======
2760-- execute("DROP INDEX IF EXISTS index_repositories_on_owner_type")
2761 -> 0.0003s
2762-- execute("DROP INDEX IF EXISTS index_repositories_on_owner_id")
2763 -> 0.0003s
2764-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_owner_type ON repositories(owner_type)")
2765 -> 0.0035s
2766-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_owner_id ON repositories(owner_id)")
2767 -> 0.0037s
2768== 20150316100321 AddOwnerTypeAndOwnerIdIndexesToRepositories: migrated (0.0081s)
2770== 20150317004600 AddSlugIndexToRepositories: migrating =======================
2771-- execute("CREATE EXTENSION IF NOT EXISTS pg_trgm")
2772 -> 0.0154s
2773-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_slug ON repositories USING gin((owner_name || '/' || name) gin_trgm_ops)")
2774 -> 0.0040s
2775== 20150317004600 AddSlugIndexToRepositories: migrated (0.0196s) ==============
2777== 20150317020321 AddTokenIndexToTokens: migrating ============================
2778-- execute("DROP INDEX IF EXISTS index_tokens_on_token")
2779 -> 0.0005s
2780-- execute("CREATE INDEX CONCURRENTLY index_tokens_on_token ON tokens(token)")
2781 -> 0.0046s
2782== 20150317020321 AddTokenIndexToTokens: migrated (0.0052s) ===================
2784== 20150317080321 AddLoginIndexToOrganizations: migrating =====================
2785-- execute("DROP INDEX IF EXISTS index_organizations_on_login")
2786 -> 0.0006s
2787-- execute("CREATE INDEX CONCURRENTLY index_organizations_on_login ON organizations(login)")
2788 -> 0.0041s
2789== 20150317080321 AddLoginIndexToOrganizations: migrated (0.0049s) ============
2791== 20150414001337 AddLowerCaseIndices: migrating ==============================
2792-- execute("DROP INDEX IF EXISTS index_organizations_on_lower_login")
2793 -> 0.0004s
2794-- execute("CREATE INDEX CONCURRENTLY index_organizations_on_lower_login ON organizations USING btree(lower(login))")
2795 -> 0.0038s
2796-- execute("DROP INDEX IF EXISTS index_users_on_lower_login")
2797 -> 0.0004s
2798-- execute("CREATE INDEX CONCURRENTLY index_users_on_lower_login ON users USING btree(lower(login))")
2799 -> 0.0035s
2800-- execute("DROP INDEX IF EXISTS index_repositories_on_lower_name")
2801 -> 0.0004s
2802-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_lower_name ON repositories USING btree(lower(name))")
2803 -> 0.0037s
2804-- execute("DROP INDEX IF EXISTS index_repositories_on_lower_owner_name")
2805 -> 0.0004s
2806-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_lower_owner_name ON repositories USING btree(lower(owner_name))")
2807 -> 0.0040s
2808== 20150414001337 AddLowerCaseIndices: migrated (0.0170s) =====================
2810== 20150528101600 RepositoriesAddIndexOwnerName: migrating ====================
2811-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_owner_name ON repositories(owner_name)")
2812 -> 0.0036s
2813== 20150528101600 RepositoriesAddIndexOwnerName: migrated (0.0037s) ===========
2815== 20150528101601 RepositoriesAddIndexName: migrating =========================
2816-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_name ON repositories(name)")
2817 -> 0.0036s
2818== 20150528101601 RepositoriesAddIndexName: migrated (0.0037s) ================
2820== 20150528101602 RepositoriesDropIndexOwnerNameName: migrating ===============
2821-- execute("DROP INDEX CONCURRENTLY index_repositories_on_owner_name_and_name")
2822 -> 0.0023s
2823== 20150528101602 RepositoriesDropIndexOwnerNameName: migrated (0.0024s) ======
2825== 20150528101603 BuildsAddIndexEventType: migrating ==========================
2826-- execute("CREATE INDEX CONCURRENTLY index_builds_on_event_type ON builds (event_type)")
2827 -> 0.0038s
2828== 20150528101603 BuildsAddIndexEventType: migrated (0.0039s) =================
2830== 20150528101604 BuildsAddIndexRepositoryId: migrating =======================
2831-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id ON builds (repository_id)")
2832 -> 0.0033s
2833== 20150528101604 BuildsAddIndexRepositoryId: migrated (0.0033s) ==============
2835== 20150528101605 BuildsAddIndexState: migrating ==============================
2836-- execute("CREATE INDEX CONCURRENTLY index_builds_on_state ON builds (state)")
2837 -> 0.0033s
2838== 20150528101605 BuildsAddIndexState: migrated (0.0033s) =====================
2840== 20150528101607 BuildsAddIndexBranch: migrating =============================
2841-- execute("CREATE INDEX CONCURRENTLY index_builds_on_branch ON builds (branch)")
2842 -> 0.0030s
2843== 20150528101607 BuildsAddIndexBranch: migrated (0.0030s) ====================
2845== 20150528101608 BuildsDropIndexRepositoryIdAndState: migrating ==============
2846-- execute("DROP INDEX CONCURRENTLY index_builds_on_repository_id_and_state")
2847 -> 0.0018s
2848== 20150528101608 BuildsDropIndexRepositoryIdAndState: migrated (0.0019s) =====
2850== 20150528101609 BuildsDropIndexRepositoryIdAndEventType: migrating ==========
2851-- execute("DROP INDEX CONCURRENTLY index_builds_on_repository_id_and_event_type")
2852 -> 0.0018s
2853== 20150528101609 BuildsDropIndexRepositoryIdAndEventType: migrated (0.0018s) =
2855== 20150528101610 BuildsDropIndexIdRepositoryIdAndEventTypeDesc: migrating ====
2856-- execute("DROP INDEX CONCURRENTLY index_builds_on_id_repository_id_and_event_type_desc")
2857 -> 0.0018s
2858== 20150528101610 BuildsDropIndexIdRepositoryIdAndEventTypeDesc: migrated (0.0018s)
2860== 20150528101611 BuildsDropIndexRepositoryIdAndEventTypeAndStateAndBranch: migrating
2861-- execute("DROP INDEX CONCURRENTLY index_builds_on_repository_id_and_event_type_and_state_and_bran")
2862 -> 0.0020s
2863== 20150528101611 BuildsDropIndexRepositoryIdAndEventTypeAndStateAndBranch: migrated (0.0020s)
2865== 20150609175200 AddCancelationColumnsToSubscriptions: migrating =============
2866-- change_table(:subscriptions)
2867 -> 0.0011s
2868== 20150609175200 AddCancelationColumnsToSubscriptions: migrated (0.0011s) ====
2870== 20150610143500 JobsAddIndexOwnerId: migrating ==============================
2871-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_owner_id ON jobs (owner_id)")
2872 -> 0.0035s
2873== 20150610143500 JobsAddIndexOwnerId: migrated (0.0035s) =====================
2875== 20150610143501 JobsAddIndexOwnerType: migrating ============================
2876-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_owner_type ON jobs (owner_type)")
2877 -> 0.0034s
2878== 20150610143501 JobsAddIndexOwnerType: migrated (0.0034s) ===================
2880== 20150610143502 JobsAddIndexSourceId: migrating =============================
2881-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_source_id ON jobs (source_id)")
2882 -> 0.0032s
2883== 20150610143502 JobsAddIndexSourceId: migrated (0.0032s) ====================
2885== 20150610143503 JobsAddIndexSourceType: migrating ===========================
2886-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_source_type ON jobs (source_type)")
2887 -> 0.0029s
2888== 20150610143503 JobsAddIndexSourceType: migrated (0.0029s) ==================
2890== 20150610143504 JobsAddIndexType: migrating =================================
2891-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_type ON jobs (type)")
2892 -> 0.0033s
2893== 20150610143504 JobsAddIndexType: migrated (0.0033s) ========================
2895== 20150610143505 JobsDropIndexOwnerIdAndOwnerTypeAndState: migrating =========
2896-- execute("DROP INDEX CONCURRENTLY index_jobs_on_owner_id_and_owner_type_and_state")
2897 -> 0.0020s
2898== 20150610143505 JobsDropIndexOwnerIdAndOwnerTypeAndState: migrated (0.0020s)
2900== 20150610143506 JobsDropIndexStateOwnerTypeOwnerId: migrating ===============
2901-- execute("DROP INDEX CONCURRENTLY index_jobs_on_state_owner_type_owner_id")
2902 -> 0.0021s
2903== 20150610143506 JobsDropIndexStateOwnerTypeOwnerId: migrated (0.0021s) ======
2905== 20150610143507 JobsDropIndexTypeAndSourceIdAndSourceType: migrating ========
2906-- 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"})
2907 -> 0.0063s
2908== 20150610143507 JobsDropIndexTypeAndSourceIdAndSourceType: migrated (0.0064s)
2910== 20150610143508 JobsAddIndexState: migrating ================================
2911-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_state ON jobs (state)")
2912 -> 0.0039s
2913== 20150610143508 JobsAddIndexState: migrated (0.0039s) =======================
2915== 20150610143509 JobsAddIndexQueue: migrating ================================
2916-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_queue ON jobs (queue)")
2917 -> 0.0037s
2918== 20150610143509 JobsAddIndexQueue: migrated (0.0038s) =======================
2920== 20150610143510 TokensAddIndexUserId: migrating =============================
2921-- execute("CREATE INDEX CONCURRENTLY index_tokens_on_user_id ON tokens (user_id)")
2922 -> 0.0039s
2923== 20150610143510 TokensAddIndexUserId: migrated (0.0040s) ====================
2925== 20150615103059 AddStatusToSubscriptions: migrating =========================
2926-- add_column(:subscriptions, :status, :string)
2927 -> 0.0011s
2928== 20150615103059 AddStatusToSubscriptions: migrated (0.0011s) ================
2930== 20150629231300 ReposAddInvalidatedAt: migrating ============================
2931-- add_column(:repositories, :invalidated_at, :timestamp, {:precision=>nil})
2932 -> 0.0011s
2933== 20150629231300 ReposAddInvalidatedAt: migrated (0.0012s) ===================
2935== 20150923131400 BroadcastsAddCategory: migrating ============================
2936-- add_column(:broadcasts, :category, :string)
2937 -> 0.0010s
2938== 20150923131400 BroadcastsAddCategory: migrated (0.0011s) ===================
2940== 20151112153500 CreateStars: migrating ======================================
2941-- create_table(:stars, {:id=>:integer})
2942 -> 0.0044s
2943-- add_index(:stars, :user_id)
2944 -> 0.0022s
2945== 20151112153500 CreateStars: migrated (0.0074s) =============================
2947== 20151113111400 StarsAddIndexUserIdAndRepositoryId: migrating ===============
2948-- execute("CREATE UNIQUE INDEX index_stars_on_user_id_and_repository_id ON stars (user_id, repository_id)")
2949 -> 0.0027s
2950== 20151113111400 StarsAddIndexUserIdAndRepositoryId: migrated (0.0028s) ======
2952== 20151127153500 UsersAddIndexGithubOauthToken: migrating ====================
2953-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_users_on_github_oauth_token ON users (github_oauth_token)")
2954 -> 0.0077s
2955== 20151127153500 UsersAddIndexGithubOauthToken: migrated (0.0078s) ===========
2957== 20151127154200 AnnotationsAddIndexJobId: migrating =========================
2958-- execute("CREATE INDEX CONCURRENTLY index_annotations_on_job_id ON annotations (job_id)")
2959 -> 0.0039s
2960== 20151127154200 AnnotationsAddIndexJobId: migrated (0.0040s) ================
2962== 20151127154600 BroadcastsAddIndexRecipientIdAndRecipientType: migrating ====
2963-- execute("CREATE INDEX CONCURRENTLY index_broadcasts_on_recipient_id_and_recipient_type ON broadcasts (recipient_id, recipient_type)")
2964 -> 0.0037s
2965== 20151127154600 BroadcastsAddIndexRecipientIdAndRecipientType: migrated (0.0038s)
2967== 20151202122200 UsersAddFirstLoggedInAt: migrating ==========================
2968-- add_column(:users, :first_logged_in_at, :timestamp, {:precision=>nil})
2969 -> 0.0016s
2970== 20151202122200 UsersAddFirstLoggedInAt: migrated (0.0017s) =================
2972== 20160107120927 AddCronTable: migrating =====================================
2973-- create_table(:crons, {:id=>:integer})
2974 -> 0.0084s
2975== 20160107120927 AddCronTable: migrated (0.0086s) ============================
2977== 20160303165750 AddDebugOptionsToJobs: migrating ============================
2978-- add_column(:jobs, :debug_options, :text)
2979 -> 0.0007s
2980== 20160303165750 AddDebugOptionsToJobs: migrated (0.0007s) ===================
2982== 20160412113020 BuildsDropIndexOwnerType: migrating =========================
2983-- execute("DROP INDEX CONCURRENTLY index_builds_on_owner_type")
2984 -> 0.0021s
2985== 20160412113020 BuildsDropIndexOwnerType: migrated (0.0021s) ================
2987== 20160412113070 RepositoriesDropIndexLastBuildStartedAt: migrating ==========
2988-- execute("DROP INDEX CONCURRENTLY index_repositories_on_last_build_started_at")
2989 -> 0.0022s
2990== 20160412113070 RepositoriesDropIndexLastBuildStartedAt: migrated (0.0022s) =
2992== 20160412121405 JobsDropIndexType: migrating ================================
2993-- execute("DROP INDEX CONCURRENTLY index_jobs_on_type")
2994 -> 0.0019s
2995== 20160412121405 JobsDropIndexType: migrated (0.0019s) =======================
2997== 20160412123900 JobsDropIndexSourceType: migrating ==========================
2998-- execute("DROP INDEX CONCURRENTLY index_jobs_on_source_type")
2999 -> 0.0019s
3000== 20160412123900 JobsDropIndexSourceType: migrated (0.0019s) =================
3002== 20160414214442 JobsAddIndexQueuedAt: migrating =============================
3003-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_queued_at ON jobs (queued_at)")
3004 -> 0.0034s
3005== 20160414214442 JobsAddIndexQueuedAt: migrated (0.0034s) ====================
3007== 20160422104300 BuildsAddIndexNumber: migrating =============================
3008-- execute("CREATE INDEX CONCURRENTLY index_builds_on_number ON builds (number)")
3009 -> 0.0033s
3010== 20160422104300 BuildsAddIndexNumber: migrated (0.0033s) ====================
3012== 20160422121400 BuildsAddIndexRepositoryIdAndNumberAndEventType: migrating ==
3013-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id_and_number_and_event_type ON builds (repository_id, number, event_type)")
3014 -> 0.0032s
3015== 20160422121400 BuildsAddIndexRepositoryIdAndNumberAndEventType: migrated (0.0033s)
3017== 20160510142700 JobsAddIndexCreatedAt: migrating ============================
3018-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_created_at ON jobs (created_at)")
3019 -> 0.0032s
3020== 20160510142700 JobsAddIndexCreatedAt: migrated (0.0033s) ===================
3022== 20160510144200 BuildsAddPrivate: migrating =================================
3023-- change_table(:builds)
3024 -> 0.0007s
3025== 20160510144200 BuildsAddPrivate: migrated (0.0007s) ========================
3027== 20160510150300 JobsAddPrivate: migrating ===================================
3028-- change_table(:jobs)
3029 -> 0.0007s
3030== 20160510150300 JobsAddPrivate: migrated (0.0007s) ==========================
3032== 20160510150400 RequestsAddPrivate: migrating ===============================
3033-- change_table(:requests)
3034 -> 0.0006s
3035== 20160510150400 RequestsAddPrivate: migrated (0.0007s) ======================
3037== 20160513074300 AddCurrentBuildIdToRepositories: migrating ==================
3038-- add_column(:repositories, :current_build_id, :bigint)
3039 -> 0.0006s
3040-- execute("ALTER TABLE repositories ADD CONSTRAINT fk_repositories_current_build_id FOREIGN KEY (current_build_id) REFERENCES builds (id);")
3041 -> 0.0015s
3042== 20160513074300 AddCurrentBuildIdToRepositories: migrated (0.0021s) =========
3044== 20160609163600 PermissionsAddIndexUserIdAndRepositoryId: migrating =========
3045-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_permissions_on_user_id_and_repository_id ON permissions (user_id, repository_id)")
3046 -> 0.0053s
3047== 20160609163600 PermissionsAddIndexUserIdAndRepositoryId: migrated (0.0053s)
3049== 20160623133900 CreatePreviousJobStates: migrating ==========================
3050-- create_table(:previous_job_states, {:id=>:integer})
3051 -> 0.0048s
3052-- add_column(:jobs, :previous_job_state_id, :bigint)
3053 -> 0.0004s
3054== 20160623133900 CreatePreviousJobStates: migrated (0.0053s) =================
3056== 20160623133901 AddPreviousStatesTriggers: migrating ========================
3057-- 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")
3058 -> 0.0096s
3059== 20160623133901 AddPreviousStatesTriggers: migrated (0.0096s) ===============
3061== 20160712125400 RevertPreviousJobStates: migrating ==========================
3062-- 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")
3063 -> 0.0016s
3064-- remove_column(:jobs, :previous_job_state_id)
3065 -> 0.0011s
3066-- drop_table(:previous_job_states)
3067 -> 0.0014s
3068== 20160712125400 RevertPreviousJobStates: migrated (0.0044s) =================
3070== 20160819103700 AddAvatarUrlToUsers: migrating ==============================
3071-- add_column(:users, :avatar_url, :string)
3072 -> 0.0018s
3073== 20160819103700 AddAvatarUrlToUsers: migrated (0.0020s) =====================
3075== 20160920220400 AddRoleToMemberships: migrating =============================
3076-- add_column(:memberships, :role, :string)
3077 -> 0.0038s
3078== 20160920220400 AddRoleToMemberships: migrated (0.0040s) ====================
3080== 20161028154600 RemoveTypeIndices: migrating ================================
3081-- execute("DROP INDEX CONCURRENTLY IF EXISTS index_requests_on_event_type")
3082 -> 0.0008s
3083-- execute("DROP INDEX CONCURRENTLY IF EXISTS index_jobs_on_owner_type")
3084 -> 0.0023s
3085== 20161028154600 RemoveTypeIndices: migrated (0.0032s) =======================
3087== 20161101000000 AddNextRunLastRunToCrons: migrating =========================
3088-- column_exists?(:crons, :next_run)
3089 -> 0.0032s
3090-- add_column(:crons, :next_run, :timestamp, {:precision=>nil})
3091 -> 0.0006s
3092-- column_exists?(:crons, :last_run)
3093 -> 0.0019s
3094-- add_column(:crons, :last_run, :timestamp, {:precision=>nil})
3095 -> 0.0006s
3096== 20161101000000 AddNextRunLastRunToCrons: migrated (0.0065s) ================
3098== 20161101000001 AddDontRunIfRecentBuildExists: migrating ====================
3099-- column_exists?(:crons, :dont_run_if_recent_build_exists)
3100 -> 0.0020s
3101-- add_column(:crons, :dont_run_if_recent_build_exists, :boolean, {:default=>false})
3102 -> 0.0011s
3103== 20161101000001 AddDontRunIfRecentBuildExists: migrated (0.0032s) ===========
3105== 20161201112200 CreateBetaFeatures: migrating ===============================
3106-- create_table(:beta_features, {:id=>:integer})
3107 -> 0.0065s
3108== 20161201112200 CreateBetaFeatures: migrated (0.0066s) ======================
3110== 20161201112600 CreateUserBetaFeatures: migrating ===========================
3111-- create_table(:user_beta_features, {:id=>:integer})
3112 -> 0.0039s
3113-- add_index(:user_beta_features, [:user_id, :beta_feature_id])
3114 -> 0.0067s
3115== 20161201112600 CreateUserBetaFeatures: migrated (0.0108s) ==================
3117== 20161202000000 RemoveDisableByBuildFromCrons: migrating ====================
3118-- remove_column(:crons, :disable_by_build)
3119 -> 0.0023s
3120== 20161202000000 RemoveDisableByBuildFromCrons: migrated (0.0024s) ===========
3122== 20161206155800 AddBillingAdminOnlyToOrganizations: migrating ===============
3123-- add_column(:organizations, :billing_admin_only, :boolean)
3124 -> 0.0006s
3125== 20161206155800 AddBillingAdminOnlyToOrganizations: migrated (0.0007s) ======
3127== 20161221171300 BuildsAddIndexRepositoryIdAndNumber: migrating ==============
3128-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id_and_number ON builds(repository_id, (number::integer))")
3129 -> 0.0038s
3130== 20161221171300 BuildsAddIndexRepositoryIdAndNumber: migrated (0.0038s) =====
3132== 20170211000000 JobsAddStageNumber: migrating ===============================
3133-- add_column(:jobs, :stage_number, :string)
3134 -> 0.0006s
3135== 20170211000000 JobsAddStageNumber: migrated (0.0007s) ======================
3137== 20170211000001 JobsAddStageId: migrating ===================================
3138-- change_table(:jobs)
3139 -> 0.0007s
3140== 20170211000001 JobsAddStageId: migrated (0.0007s) ==========================
3142== 20170211000002 StagesCreate: migrating =====================================
3143-- create_table(:stages, {:id=>:integer})
3144 -> 0.0049s
3145== 20170211000002 StagesCreate: migrated (0.0049s) ============================
3147== 20170211000003 StagesAddStateAndTimestamps: migrating ======================
3148-- change_table(:stages)
3149 -> 0.0014s
3150== 20170211000003 StagesAddStateAndTimestamps: migrated (0.0014s) =============
3152== 20170213124000 AddConstraintForOwnerIdToSubscriptions: migrating ===========
3153-- execute("CREATE UNIQUE INDEX subscriptions_owner ON subscriptions (owner_id, owner_type) WHERE (status = 'subscribed');")
3154 -> 0.0022s
3155== 20170213124000 AddConstraintForOwnerIdToSubscriptions: migrated (0.0022s) ==
3157== 20170316000000 QueueableJobsCreate: migrating ==============================
3158-- create_table(:queueable_jobs, {:id=>:integer})
3159 -> 0.0028s
3160== 20170316000000 QueueableJobsCreate: migrated (0.0028s) =====================
3162== 20170316000001 QueueableJobsIndexJobId: migrating ==========================
3163-- add_index(:queueable_jobs, :job_id, {:algorithm=>:concurrently})
3164 -> 0.0032s
3165== 20170316000001 QueueableJobsIndexJobId: migrated (0.0032s) =================
3167== 20170318000000 PullRequestsCreate: migrating ===============================
3168-- create_table(:pull_requests, {:id=>:integer})
3169 -> 0.0045s
3170== 20170318000000 PullRequestsCreate: migrated (0.0045s) ======================
3172== 20170318000001 RequestsAddPullRequestId: migrating =========================
3173-- change_table(:requests)
3174 -> 0.0006s
3175== 20170318000001 RequestsAddPullRequestId: migrated (0.0007s) ================
3177== 20170318000002 BuildsAddPullRequestId: migrating ===========================
3178-- change_table(:builds)
3179 -> 0.0006s
3180== 20170318000002 BuildsAddPullRequestId: migrated (0.0008s) ==================
3182== 20170322000000 AddIndexOnRequestsRepositoryIdAndIdDesc: migrating ==========
3183-- execute("CREATE INDEX CONCURRENTLY index_requests_on_repository_id_and_id_desc ON requests (repository_id, id DESC);")
3184 -> 0.0032s
3185== 20170322000000 AddIndexOnRequestsRepositoryIdAndIdDesc: migrated (0.0033s) =
3187== 20170331000000 AddIndexRepositoryIdOnPullRequests: migrating ===============
3188-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_pull_requests_on_repository_id_and_number ON pull_requests (repository_id, (number::integer));")
3189 -> 0.0033s
3190== 20170331000000 AddIndexRepositoryIdOnPullRequests: migrated (0.0033s) ======
3192== 20170401000000 OwnerGroupsCreate: migrating ================================
3193-- create_table(:owner_groups, {:id=>:integer})
3194 -> 0.0045s
3195== 20170401000000 OwnerGroupsCreate: migrated (0.0045s) =======================
3197== 20170401000001 OwnerGroupsIndexOwnerIdOwnerType: migrating =================
3198-- execute("CREATE INDEX CONCURRENTLY index_owner_groups_on_owner_type_and_owner_id ON owner_groups (owner_type, owner_id);")
3199 -> 0.0030s
3200== 20170401000001 OwnerGroupsIndexOwnerIdOwnerType: migrated (0.0030s) ========
3202== 20170401000002 OwnerGroupsIndexUuid: migrating =============================
3203-- execute("CREATE INDEX CONCURRENTLY index_owner_groups_on_uuid ON owner_groups (uuid);")
3204 -> 0.0032s
3205== 20170401000002 OwnerGroupsIndexUuid: migrated (0.0033s) ====================
3207== 20170405000000 TagsCreate: migrating =======================================
3208-- create_table(:tags, {:id=>:integer})
3209 -> 0.0051s
3210== 20170405000000 TagsCreate: migrated (0.0052s) ==============================
3212== 20170405000001 RequestsAddBranchIdAndTagId: migrating ======================
3213-- change_table(:requests)
3214 -> 0.0139s
3215== 20170405000001 RequestsAddBranchIdAndTagId: migrated (0.0148s) =============
3217== 20170405000002 CommitsAddBranchIdAndTagId: migrating =======================
3218-- change_table(:commits)
3219 -> 0.0040s
3220== 20170405000002 CommitsAddBranchIdAndTagId: migrated (0.0043s) ==============
3222== 20170405000003 BuildsAddBranchIdAndTagId: migrating ========================
3223-- change_table(:builds)
3224 -> 0.0035s
3225== 20170405000003 BuildsAddBranchIdAndTagId: migrated (0.0037s) ===============
3227== 20170408000000 RequestsAddSenderId: migrating ==============================
3228-- change_table(:requests)
3229 -> 0.0039s
3230== 20170408000000 RequestsAddSenderId: migrated (0.0040s) =====================
3232== 20170408000001 BuildsAddSenderId: migrating ================================
3233-- change_table(:builds)
3234 -> 0.0034s
3235== 20170408000001 BuildsAddSenderId: migrated (0.0037s) =======================
3237== 20170410000000 JobsIndexStageId: migrating =================================
3238-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_stage_id ON jobs (stage_id);")
3239 -> 0.0043s
3240== 20170410000000 JobsIndexStageId: migrated (0.0044s) ========================
3242== 20170411000000 TagsIndexRepoIdAndName: migrating ===========================
3243-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_tags_on_repository_id_and_name ON tags (repository_id, name);")
3244 -> 0.0036s
3245== 20170411000000 TagsIndexRepoIdAndName: migrated (0.0036s) ==================
3247== 20170419093249 AddSourceToSubscriptions: migrating =========================
3248-- execute(" CREATE TYPE source_type AS ENUM ('manual', 'stripe', 'github', 'unknown');\n")
3249 -> 0.0019s
3250-- add_column(:subscriptions, :source, :source_type, {:default=>"unknown", :null=>false})
3251 -> 0.0031s
3252== 20170419093249 AddSourceToSubscriptions: migrated (0.0054s) ================
3254== 20170531125700 AddIndexOnBuildsSenderTypeAndSenderId: migrating ============
3255-- execute("CREATE INDEX CONCURRENTLY index_builds_on_sender_type_and_sender_id ON builds (sender_type, sender_id);")
3256 -> 0.0047s
3257== 20170531125700 AddIndexOnBuildsSenderTypeAndSenderId: migrated (0.0047s) ===
3259== 20170601163700 DropIndexOnRepositoriesBuildsAndCommits: migrating ==========
3260-- execute("DROP INDEX CONCURRENTLY index_repositories_on_lower_owner_name")
3261 -> 0.0023s
3262-- execute("DROP INDEX CONCURRENTLY index_repositories_on_owner_type")
3263 -> 0.0020s
3264-- execute("DROP INDEX CONCURRENTLY index_commits_on_repository_id")
3265 -> 0.0019s
3266-- execute("DROP INDEX CONCURRENTLY index_builds_on_number")
3267 -> 0.0019s
3268== 20170601163700 DropIndexOnRepositoriesBuildsAndCommits: migrated (0.0082s) =
3270== 20170601164400 AddIndexOnBuildsAndStages: migrating ========================
3271-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id_and_branch_and_event_type_and_id ON builds (repository_id, branch, event_type, id)")
3272 -> 0.0038s
3273-- execute("CREATE INDEX CONCURRENTLY index_stages_on_build_id ON stages (build_id)")
3274 -> 0.0033s
3275== 20170601164400 AddIndexOnBuildsAndStages: migrated (0.0072s) ===============
3277== 20170609174400 DropUnusedIndexesOnJobsAndBuilds: migrating =================
3278-- execute("DROP INDEX CONCURRENTLY index_jobs_on_repository_id")
3279 -> 0.0023s
3280-- execute("DROP INDEX CONCURRENTLY index_jobs_on_queued_at")
3281 -> 0.0021s
3282-- execute("DROP INDEX CONCURRENTLY index_jobs_on_queue")
3283 -> 0.0019s
3284-- execute("DROP INDEX CONCURRENTLY index_jobs_on_owner_id")
3285 -> 0.0019s
3286-- execute("DROP INDEX CONCURRENTLY index_builds_on_branch")
3287 -> 0.0019s
3288-- execute("DROP INDEX CONCURRENTLY index_builds_on_event_type")
3289 -> 0.0019s
3290-- execute("DROP INDEX CONCURRENTLY index_builds_on_owner_id")
3291 -> 0.0019s
3292== 20170609174400 DropUnusedIndexesOnJobsAndBuilds: migrated (0.0141s) ========
3294== 20170613000000 CreateTrials: migrating =====================================
3295-- create_table(:trials, {:id=>:integer})
3296 -> 0.0060s
3297-- execute("CREATE INDEX CONCURRENTLY index_trials_on_owner ON trials(owner_id, owner_type)")
3298 -> 0.0032s
3299== 20170613000000 CreateTrials: migrated (0.0093s) ============================
3301== 20170620144500 AddIndexesOnBuildsAndJobsAndBranches: migrating =============
3302-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id_and_branch_and_id_desc ON builds (repository_id, branch, id DESC)")
3303 -> 0.0032s
3304-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_owner_id_and_owner_type_and_state ON jobs (owner_id, owner_type, state)")
3305 -> 0.0032s
3306-- execute("CREATE INDEX CONCURRENTLY index_branches_on_repository_id ON branches (repository_id)")
3307 -> 0.0031s
3308== 20170620144500 AddIndexesOnBuildsAndJobsAndBranches: migrated (0.0097s) ====
3310== 20170621142300 RemovePlansTable: migrating =================================
3311-- drop_table(:plans)
3312 -> 0.0009s
3313== 20170621142300 RemovePlansTable: migrated (0.0009s) ========================
3315== 20170713162000 AddCcLastDigitsToInvoices: migrating ========================
3316-- change_table(:invoices)
3317 -> 0.0006s
3318== 20170713162000 AddCcLastDigitsToInvoices: migrated (0.0007s) ===============
3320== 20170822171600 CreateMessages: migrating ===================================
3321-- create_table("messages", {:force=>:cascade, :id=>:integer})
3322 -> 0.0054s
3323-- execute("CREATE INDEX CONCURRENTLY index_messages_on_subject_type_and_subject_id ON messages(subject_type, subject_id)")
3324 -> 0.0036s
3325== 20170822171600 CreateMessages: migrated (0.0090s) ==========================
3327== 20170831000000 CreateTrialAllowances: migrating ============================
3328-- create_table(:trial_allowances, {:id=>:integer})
3329 -> 0.0047s
3330-- add_index(:trial_allowances, :trial_id)
3331 -> 0.0018s
3332-- add_index(:trial_allowances, [:creator_id, :creator_type])
3333 -> 0.0018s
3334== 20170831000000 CreateTrialAllowances: migrated (0.0085s) ===================
3336== 20170911172800 AddIndexOnJobsUpdatedAt: migrating ==========================
3337-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_updated_at ON jobs (updated_at)")
3338 -> 0.0036s
3339== 20170911172800 AddIndexOnJobsUpdatedAt: migrated (0.0036s) =================
3341== 20171017104500 AddConcurrencyToSubscriptions: migrating ====================
3342-- change_table(:subscriptions)
3343 -> 0.0007s
3344== 20171017104500 AddConcurrencyToSubscriptions: migrated (0.0007s) ===========
3346== 20171024000000 AddAbuseTable: migrating ====================================
3347-- create_table(:abuses, {:id=>:integer})
3348 -> 0.0054s
3349-- execute("CREATE INDEX CONCURRENTLY index_abuses_on_owner ON abuses(owner_id)")
3350 -> 0.0034s
3351== 20171024000000 AddAbuseTable: migrated (0.0089s) ===========================
3353== 20171025000000 AddUpdatedAtTriggerToBuildsAndJobs: migrating ===============
3354-- 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")
3355 -> 0.0008s
3356== 20171025000000 AddUpdatedAtTriggerToBuildsAndJobs: migrated (0.0008s) ======
3358== 20171103000000 UpdateIndexOnAbuses: migrating ==============================
3359-- index_exists?(:abuses, :owner, {:name=>"index_abuses_on_owner"})
3360 -> 0.0013s
3361-- index_exists?(:abuses, [:owner_id, :owner_type, :level], {:name=>"index_abuses_on_owner_id_and_owner_type_and_level"})
3362 -> 0.0011s
3363-- add_index(:abuses, [:owner_id, :owner_type, :level], {:unique=>true, :algorithm=>:concurrently})
3364 -> 0.0034s
3365== 20171103000000 UpdateIndexOnAbuses: migrated (0.0059s) =====================
3367== 20171211000000 AddRepositoryIdBranchEventTypeIndexOnBuilds: migrating ======
3368-- 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')")
3369 -> 0.0036s
3370== 20171211000000 AddRepositoryIdBranchEventTypeIndexOnBuilds: migrated (0.0037s)
3372== 20180212000000 UsersAddSuspended: migrating ================================
3373-- add_column(:users, :suspended, :boolean, {:default=>false})
3374 -> 0.0025s
3375== 20180212000000 UsersAddSuspended: migrated (0.0025s) =======================
3377== 20180213000000 UsersAddSuspendedAt: migrating ==============================
3378-- add_column(:users, :suspended_at, :timestamp, {:precision=>nil})
3379 -> 0.0007s
3380== 20180213000000 UsersAddSuspendedAt: migrated (0.0007s) =====================
3382== 20180222000000 AddComIdAndOrgId: migrating =================================
3383-- add_column(:branches, :org_id, :integer)
3384 -> 0.0020s
3385-- add_column(:builds, :org_id, :integer)
3386 -> 0.0011s
3387-- add_column(:commits, :org_id, :integer)
3388 -> 0.0010s
3389-- add_column(:crons, :org_id, :integer)
3390 -> 0.0010s
3391-- add_column(:jobs, :org_id, :integer)
3392 -> 0.0010s
3393-- add_column(:organizations, :org_id, :integer)
3394 -> 0.0010s
3395-- add_column(:permissions, :org_id, :integer)
3396 -> 0.0007s
3397-- add_column(:pull_requests, :org_id, :integer)
3398 -> 0.0004s
3399-- add_column(:repositories, :org_id, :integer)
3400 -> 0.0017s
3401-- add_column(:requests, :org_id, :integer)
3402 -> 0.0010s
3403-- add_column(:ssl_keys, :org_id, :integer)
3404 -> 0.0010s
3405-- add_column(:stages, :org_id, :integer)
3406 -> 0.0009s
3407-- add_column(:tags, :org_id, :integer)
3408 -> 0.0010s
3409-- add_column(:users, :org_id, :integer)
3410 -> 0.0010s
3411-- add_column(:branches, :com_id, :integer)
3412 -> 0.0011s
3413-- add_column(:builds, :com_id, :integer)
3414 -> 0.0010s
3415-- add_column(:commits, :com_id, :integer)
3416 -> 0.0010s
3417-- add_column(:crons, :com_id, :integer)
3418 -> 0.0010s
3419-- add_column(:jobs, :com_id, :integer)
3420 -> 0.0009s
3421-- add_column(:organizations, :com_id, :integer)
3422 -> 0.0004s
3423-- add_column(:permissions, :com_id, :integer)
3424 -> 0.0015s
3425-- add_column(:pull_requests, :com_id, :integer)
3426 -> 0.0010s
3427-- add_column(:repositories, :com_id, :integer)
3428 -> 0.0011s
3429-- add_column(:requests, :com_id, :integer)
3430 -> 0.0007s
3431-- add_column(:ssl_keys, :com_id, :integer)
3432 -> 0.0009s
3433-- add_column(:stages, :com_id, :integer)
3434 -> 0.0011s
3435-- add_column(:tags, :com_id, :integer)
3436 -> 0.0010s
3437-- add_column(:users, :com_id, :integer)
3438 -> 0.0010s
3439== 20180222000000 AddComIdAndOrgId: migrated (0.0316s) ========================
3441== 20180222000001 AddComIdAndOrgIdIndices: migrating ==========================
3442-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_branches_on_org_id ON branches USING btree (org_id)")
3443 -> 0.0041s
3444-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_builds_on_org_id ON builds USING btree (org_id)")
3445 -> 0.0037s
3446-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_jobs_on_org_id ON jobs USING btree (org_id)")
3447 -> 0.0040s
3448-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_commits_on_org_id ON commits USING btree (org_id)")
3449 -> 0.0040s
3450-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_crons_on_org_id ON crons USING btree (org_id)")
3451 -> 0.0037s
3452-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_organizations_on_org_id ON organizations USING btree (org_id)")
3453 -> 0.0036s
3454-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_permissions_on_org_id ON permissions USING btree (org_id)")
3455 -> 0.0035s
3456-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_pull_requests_on_org_id ON pull_requests USING btree (org_id)")
3457 -> 0.0035s
3458-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_repositories_on_org_id ON repositories USING btree (org_id)")
3459 -> 0.0037s
3460-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_requests_on_org_id ON requests USING btree (org_id)")
3461 -> 0.0035s
3462-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_ssl_keys_on_org_id ON ssl_keys USING btree (org_id)")
3463 -> 0.0035s
3464-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_stages_on_org_id ON stages USING btree (org_id)")
3465 -> 0.0033s
3466-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_tags_on_org_id ON tags USING btree (org_id)")
3467 -> 0.0032s
3468-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_users_on_org_id ON users USING btree (org_id)")
3469 -> 0.0032s
3470-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_branches_on_com_id ON branches USING btree (com_id)")
3471 -> 0.0032s
3472-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_builds_on_com_id ON builds USING btree (com_id)")
3473 -> 0.0035s
3474-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_jobs_on_com_id ON jobs USING btree (com_id)")
3475 -> 0.0032s
3476-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_commits_on_com_id ON commits USING btree (com_id)")
3477 -> 0.0048s
3478-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_crons_on_com_id ON crons USING btree (com_id)")
3479 -> 0.0028s
3480-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_organizations_on_com_id ON organizations USING btree (com_id)")
3481 -> 0.0026s
3482-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_permissions_on_com_id ON permissions USING btree (com_id)")
3483 -> 0.0032s
3484-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_pull_requests_on_com_id ON pull_requests USING btree (com_id)")
3485 -> 0.0032s
3486-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_repositories_on_com_id ON repositories USING btree (com_id)")
3487 -> 0.0035s
3488-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_requests_on_com_id ON requests USING btree (com_id)")
3489 -> 0.0032s
3490-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_ssl_keys_on_com_id ON ssl_keys USING btree (com_id)")
3491 -> 0.0032s
3492-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_stages_on_com_id ON stages USING btree (com_id)")
3493 -> 0.0031s
3494-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_tags_on_com_id ON tags USING btree (com_id)")
3495 -> 0.0030s
3496-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_users_on_com_id ON users USING btree (com_id)")
3497 -> 0.0032s
3498== 20180222000001 AddComIdAndOrgIdIndices: migrated (0.0973s) =================
3500== 20180222000002 AddMigrating: migrating =====================================
3501-- add_column(:repositories, :migrating, :boolean)
3502 -> 0.0007s
3503-- add_column(:repositories, :migrated_at, :timestamp, {:precision=>nil})
3504 -> 0.0004s
3505-- add_column(:organizations, :migrating, :boolean)
3506 -> 0.0004s
3507-- add_column(:organizations, :migrated_at, :timestamp, {:precision=>nil})
3508 -> 0.0003s
3509-- add_column(:users, :migrating, :boolean)
3510 -> 0.0004s
3511-- add_column(:users, :migrated_at, :timestamp, {:precision=>nil})
3512 -> 0.0004s
3513== 20180222000002 AddMigrating: migrated (0.0027s) ============================
3515== 20180222000003 DropFkRepositoriesCurrentBuildId: migrating =================
3516-- execute("ALTER TABLE repositories DROP CONSTRAINT fk_repositories_current_build_id")
3517 -> 0.0007s
3518== 20180222000003 DropFkRepositoriesCurrentBuildId: migrated (0.0008s) ========
3520== 20180222000009 CreateRepoCounts: migrating =================================
3521-- create_table(:repo_counts, {:id=>false})
3522 -> 0.0062s
3523-- add_index(:repo_counts, :repository_id)
3524 -> 0.0018s
3525== 20180222000009 CreateRepoCounts: migrated (0.0081s) ========================
3527== 20180222000012 CreateRepoCountsTriggers: migrating =========================
3528-- 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")
3529 -> 0.0148s
3530== 20180222000012 CreateRepoCountsTriggers: migrated (0.0152s) ================
3532== 20180222164100 DropAnnotations: migrating ==================================
3533-- drop_table(:annotations)
3534 -> 0.0027s
3535-- drop_table(:annotation_providers)
3536 -> 0.0025s
3537== 20180222164100 DropAnnotations: migrated (0.0053s) =========================
3539== 20180305143800 IndexBuildsOnRepositoryIdWhereStateNotFinished: migrating ===
3540-- execute("CREATE INDEX CONCURRENTLY index_builds_on_repository_id_where_state_not_finished ON builds (repository_id) WHERE state IN ('created', 'queued', 'received', 'started');")
3541 -> 0.0046s
3542== 20180305143800 IndexBuildsOnRepositoryIdWhereStateNotFinished: migrated (0.0046s)
3544== 20180321102400 IndexJobsOnRepositoryIdWhereStateRunning: migrating =========
3545-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_repository_id_where_state_running ON jobs (repository_id) WHERE state IN ('queued', 'received', 'started')")
3546 -> 0.0042s
3547== 20180321102400 IndexJobsOnRepositoryIdWhereStateRunning: migrated (0.0043s)
3549== 20180330000000 CreateRequestPayloads: migrating ============================
3550-- create_table(:request_payloads, {:id=>:integer})
3551 -> 0.0060s
3552-- add_index(:request_payloads, :request_id)
3553 -> 0.0029s
3554-- add_index(:request_payloads, [:created_at, :archived])
3555 -> 0.0020s
3556== 20180330000000 CreateRequestPayloads: migrated (0.0110s) ===================
3558== 20180331000000 CreateConfigs: migrating ====================================
3559-- create_table(:request_configs, {:id=>:integer})
3560 -> 0.0120s
3561-- create_table(:build_configs, {:id=>:integer})
3562 -> 0.0100s
3563-- create_table(:job_configs, {:id=>:integer})
3564 -> 0.0047s
3565-- add_index(:request_configs, [:repository_id, :key])
3566 -> 0.0022s
3567-- add_index(:build_configs, [:repository_id, :key])
3568 -> 0.0021s
3569-- add_index(:job_configs, [:repository_id, :key])
3570 -> 0.0027s
3571-- add_column(:requests, :config_id, :integer)
3572 -> 0.0007s
3573-- add_column(:builds, :config_id, :integer)
3574 -> 0.0007s
3575-- add_column(:jobs, :config_id, :integer)
3576 -> 0.0006s
3577== 20180331000000 CreateConfigs: migrated (0.0363s) ===========================
3579== 20180404000001 CreateInstallations: migrating ==============================
3580-- create_table(:installations, {:id=>:integer})
3581 -> 0.0154s
3582-- change_table(:repositories)
3583 -> 0.0014s
3584== 20180404000001 CreateInstallations: migrated (0.0170s) =====================
3586== 20180410000000 RequestsDropPayload: migrating ==============================
3587-- remove_column(:requests, :payload, :text)
3588 -> 0.0024s
3589== 20180410000000 RequestsDropPayload: migrated (0.0026s) =====================
3591== 20180413000000 IndexBranchesOnRepositoryIdAndNameAndId: migrating ==========
3592-- execute("CREATE INDEX CONCURRENTLY index_branches_on_repository_id_and_name_and_id ON branches (repository_id, name, id)")
3593 -> 0.0039s
3594-- execute("DROP INDEX CONCURRENTLY index_branches_on_repository_id_and_name")
3595 -> 0.0023s
3596== 20180413000000 IndexBranchesOnRepositoryIdAndNameAndId: migrated (0.0064s) =
3598== 20180417000000 IndexBuildsOrganizationsUsersOnUpdatedAt: migrating =========
3599-- execute("CREATE INDEX CONCURRENTLY index_builds_on_updated_at ON builds (updated_at)")
3600 -> 0.0042s
3601-- execute("CREATE INDEX CONCURRENTLY index_users_on_updated_at ON users (updated_at)")
3602 -> 0.0035s
3603-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_updated_at ON repositories (updated_at)")
3604 -> 0.0035s
3605-- execute("CREATE INDEX CONCURRENTLY index_organizations_on_updated_at ON organizations (updated_at)")
3606 -> 0.0032s
3607== 20180417000000 IndexBuildsOrganizationsUsersOnUpdatedAt: migrated (0.0146s)
3609== 20180420000000 ConstraintsAndIndexesForGhApps: migrating ===================
3610-- execute("CREATE UNIQUE INDEX CONCURRENTLY github_id_installations_idx ON installations (github_id)")
3611 -> 0.0033s
3612-- execute("CREATE INDEX CONCURRENTLY managed_repositories_idx ON repositories (managed_by_installation_at)")
3613 -> 0.0036s
3614-- execute("CREATE UNIQUE INDEX CONCURRENTLY owner_installations_idx ON installations (owner_id, owner_type) WHERE removed_by_id IS NULL")
3615 -> 0.0033s
3616== 20180420000000 ConstraintsAndIndexesForGhApps: migrated (0.0104s) ==========
3618== 20180425000000 IndexActiveOnOrg: migrating =================================
3619-- execute("CREATE INDEX CONCURRENTLY index_active_on_org ON repositories (active_on_org)")
3620 -> 0.0036s
3621== 20180425000000 IndexActiveOnOrg: migrated (0.0036s) ========================
3623== 20180425100000 AddRemovedAtOnInstallations: migrating ======================
3624-- add_column(:installations, :removed_at, :timestamp, {:precision=>nil})
3625 -> 0.0008s
3626== 20180425100000 AddRemovedAtOnInstallations: migrated (0.0009s) =============
3628== 20180429000000 IndexRepositoriesOnOwnerNameAndName: migrating ==============
3629-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_owner_name_and_name ON repositories (owner_name, name) WHERE invalidated_at IS NULL")
3630 -> 0.0035s
3631== 20180429000000 IndexRepositoriesOnOwnerNameAndName: migrated (0.0036s) =====
3633== 20180501000000 IndexJobsOnOwnerWhereStateRunning: migrating ================
3634-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_owner_where_state_running ON jobs (owner_id, owner_type) WHERE state IN ('queued', 'received', 'started')")
3635 -> 0.0039s
3636== 20180501000000 IndexJobsOnOwnerWhereStateRunning: migrated (0.0039s) =======
3638== 20180517000000 IndexRequestsConfigId: migrating ============================
3639-- execute("CREATE INDEX CONCURRENTLY index_requests_on_config_id ON requests (config_id)")
3640 -> 0.0033s
3641== 20180517000000 IndexRequestsConfigId: migrated (0.0034s) ===================
3643== 20180517000001 IndexBuildsConfigId: migrating ==============================
3644-- execute("CREATE INDEX CONCURRENTLY index_builds_on_config_id ON requests (config_id)")
3645 -> 0.0035s
3646== 20180517000001 IndexBuildsConfigId: migrated (0.0036s) =====================
3648== 20180517000002 IndexJobsConfigId: migrating ================================
3649-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_config_id ON requests (config_id)")
3650 -> 0.0035s
3651== 20180517000002 IndexJobsConfigId: migrated (0.0036s) =======================
3653== 20180518000000 IndexBuildsOnMultiple: migrating ============================
3654-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_builds_on_repo_branch_event_type_and_private ON builds (repository_id, branch, event_type, private)")
3655 -> 0.0038s
3656== 20180518000000 IndexBuildsOnMultiple: migrated (0.0039s) ===================
3658== 20180522000000 AddActiveFlagToCrons: migrating =============================
3659-- change_table(:crons)
3660 -> 0.0018s
3661-- add_index(:crons, :next_run, {:where=>"(active IS TRUE)", :algorithm=>:concurrently})
3662 -> 0.0037s
3663== 20180522000000 AddActiveFlagToCrons: migrated (0.0056s) ====================
3665== 20180531000000 CreateRequestYamlConfigs: migrating =========================
3666-- create_table(:request_yaml_configs, {:id=>:integer})
3667 -> 0.0060s
3668-- add_index(:request_yaml_configs, [:repository_id, :key])
3669 -> 0.0026s
3670-- add_column(:requests, :yaml_config_id, :integer)
3671 -> 0.0012s
3672== 20180531000000 CreateRequestYamlConfigs: migrated (0.0100s) ================
3674== 20180606000000 IndexCommitsOnRepositoryId: migrating =======================
3675-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_commits_on_repository_id ON commits (repository_id)")
3676 -> 0.0035s
3677== 20180606000000 IndexCommitsOnRepositoryId: migrated (0.0036s) ==============
3679== 20180606000001 IndexJobsOnRepositoryId: migrating ==========================
3680-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_jobs_on_repository_id ON jobs (repository_id)")
3681 -> 0.0038s
3682== 20180606000001 IndexJobsOnRepositoryId: migrated (0.0038s) =================
3684== 20180614000000 DropRequestsConfig: migrating ===============================
3685-- remove_column(:requests, :config)
3686 -> 0.0009s
3687== 20180614000000 DropRequestsConfig: migrated (0.0010s) ======================
3689== 20180614000001 DropBuildsConfig: migrating =================================
3690-- remove_column(:builds, :config)
3691 -> 0.0022s
3692== 20180614000001 DropBuildsConfig: migrated (0.0025s) ========================
3694== 20180614000002 DropJobsConfig: migrating ===================================
3695-- remove_column(:jobs, :config)
3696 -> 0.0020s
3697== 20180614000002 DropJobsConfig: migrated (0.0026s) ==========================
3699== 20180620000000 IndexBuildsOnRepositoryIdEventTypeId: migrating =============
3700-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_builds_on_repository_id_event_type_id ON builds (repository_id, event_type, id DESC)")
3701 -> 0.0047s
3702== 20180620000000 IndexBuildsOnRepositoryIdEventTypeId: migrated (0.0048s) ====
3704== 20180725000000 CreateCancellations: migrating ==============================
3705-- create_table(:cancellations, {:id=>:integer})
3706 -> 0.0118s
3707== 20180725000000 CreateCancellations: migrated (0.0122s) =====================
3709== 20180726000000 CommitsIndexAuthorEmail: migrating ==========================
3710-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_commits_on_author_email ON commits (author_email)")
3711 -> 0.0038s
3712== 20180726000000 CommitsIndexAuthorEmail: migrated (0.0038s) =================
3714== 20180726000001 CommitsIndexCommitterEmail: migrating =======================
3715-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_commits_on_committer_email ON commits (committer_email)")
3716 -> 0.0037s
3717== 20180726000001 CommitsIndexCommitterEmail: migrated (0.0037s) ==============
3719== 20180801000001 UsersAddRedactedAt: migrating ===============================
3720-- change_table(:users)
3721 -> 0.0012s
3722== 20180801000001 UsersAddRedactedAt: migrated (0.0013s) ======================
3724== 20180822000000 CreateEmailUnsubscribes: migrating ==========================
3725-- create_table(:email_unsubscribes, {:id=>:integer})
3726 -> 0.0129s
3727== 20180822000000 CreateEmailUnsubscribes: migrated (0.0130s) =================
3729== 20180823000000 AddPreferences: migrating ===================================
3730-- change_table(:users)
3731 -> 0.0011s
3732== 20180823000000 AddPreferences: migrated (0.0012s) ==========================
3734== 20180828000000 ChangePreferencesDefault: migrating =========================
3735-- change_column_default(:users, :preferences, {})
3736 -> 0.0038s
3737== 20180828000000 ChangePreferencesDefault: migrated (0.0038s) ================
3739== 20180829000000 MakeEmailUnsubscribesIdBigint: migrating ====================
3740-- change_column(:email_unsubscribes, :id, :bigint)
3741 -> 0.0080s
3742== 20180829000000 MakeEmailUnsubscribesIdBigint: migrated (0.0081s) ===========
3744== 20180830000001 JobsAddRestartedAt: migrating ===============================
3745-- change_table(:jobs)
3746 -> 0.0010s
3747== 20180830000001 JobsAddRestartedAt: migrated (0.0010s) ======================
3749== 20180830000002 BuildsAddRestartedAt: migrating =============================
3750-- change_table(:builds)
3751 -> 0.0010s
3752== 20180830000002 BuildsAddRestartedAt: migrated (0.0011s) ====================
3754== 20180830000003 JobVersionsCreate: migrating ================================
3755-- create_table(:job_versions, {:id=>:integer})
3756 -> 0.0088s
3757== 20180830000003 JobVersionsCreate: migrated (0.0089s) =======================
3759== 20180903000000 JobConfigsIndexConfigResourcesGpu: migrating ================
3760-- 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")
3761 -> 0.0019s
3762-- 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")
3763 -> 0.0045s
3764== 20180903000000 JobConfigsIndexConfigResourcesGpu: migrated (0.0065s) =======
3766== 20180903000001 FixIndexesOnBuildsAndJobsConfigId: migrating ================
3767-- execute("DROP INDEX index_builds_on_config_id")
3768 -> 0.0012s
3769-- execute("CREATE INDEX CONCURRENTLY index_builds_on_config_id ON builds (config_id)")
3770 -> 0.0037s
3771-- execute("DROP INDEX index_jobs_on_config_id")
3772 -> 0.0011s
3773-- execute("CREATE INDEX CONCURRENTLY index_jobs_on_config_id ON jobs (config_id)")
3774 -> 0.0054s
3775== 20180903000001 FixIndexesOnBuildsAndJobsConfigId: migrated (0.0115s) =======
3777== 20180904000001 CreateJobConfigsGpu: migrating ==============================
3778-- 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")
3779 -> 0.0023s
3780== 20180904000001 CreateJobConfigsGpu: migrated (0.0024s) =====================
3782== 20180906000000 AddIndexUsersPreferencesBuildEmails: migrating ==============
3783-- execute("CREATE INDEX CONCURRENTLY user_preferences_build_emails_false ON users (id) WHERE preferences->>'build_emails' = 'false';\n")
3784 -> 0.0041s
3785== 20180906000000 AddIndexUsersPreferencesBuildEmails: migrated (0.0042s) =====
3787== 20181002115306 DeleteDuplicateRecordsFromMemberships: migrating ============
3788-- 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")
3789 -> 0.0014s
3790== 20181002115306 DeleteDuplicateRecordsFromMemberships: migrated (0.0014s) ===
3792== 20181002115307 AddConstraintOnOrganizationAndUserToMemberships: migrating ==
3793-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_organization_id_and_user_id_on_memberships ON memberships USING btree (organization_id, user_id);\n")
3794 -> 0.0042s
3795== 20181002115307 AddConstraintOnOrganizationAndUserToMemberships: migrated (0.0044s)
3797== 20181018000000 IndexBuildsOnCreatedAt: migrating ===========================
3798-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_builds_on_created_at ON builds (created_at)")
3799 -> 0.0039s
3800== 20181018000000 IndexBuildsOnCreatedAt: migrated (0.0040s) ==================
3802== 20181029120000 AddMigrationStatusColumnToRepositories: migrating ===========
3803-- add_column(:repositories, :migration_status, :string)
3804 -> 0.0007s
3805== 20181029120000 AddMigrationStatusColumnToRepositories: migrated (0.0008s) ==
3807== 20181113120000 AddGithubGuidColumnToRequests: migrating ====================
3808-- add_column(:requests, :github_guid, :text)
3809 -> 0.0019s
3810-- add_index(:requests, :github_guid, {:algorithm=>:concurrently, :unique=>true})
3811 -> 0.0044s
3812== 20181113120000 AddGithubGuidColumnToRequests: migrated (0.0066s) ===========
3814== 20181116800000 AddConstraintsToMultipleTables: migrating ===================
3815-- 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")
3816 -> 0.0008s
3817-- 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")
3818 -> 0.0005s
3819-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3820 -> 0.0005s
3821-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_commit_id FOREIGN KEY (commit_id) REFERENCES commits(id) NOT VALID")
3822 -> 0.0005s
3823-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_request_id FOREIGN KEY (request_id) REFERENCES requests(id) NOT VALID")
3824 -> 0.0005s
3825-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_pull_request_id FOREIGN KEY (pull_request_id) REFERENCES pull_requests(id) NOT VALID")
3826 -> 0.0005s
3827-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) NOT VALID")
3828 -> 0.0005s
3829-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_tag_id FOREIGN KEY (tag_id) REFERENCES tags(id) NOT VALID")
3830 -> 0.0005s
3831-- execute("ALTER TABLE builds ADD CONSTRAINT fk_builds_on_config_id FOREIGN KEY (config_id) REFERENCES build_configs(id) NOT VALID")
3832 -> 0.0005s
3833-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_jobs_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3834 -> 0.0005s
3835-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_jobs_on_commit_id FOREIGN KEY (commit_id) REFERENCES commits(id) NOT VALID")
3836 -> 0.0007s
3837-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_jobs_on_stage_id FOREIGN KEY (stage_id) REFERENCES stages(id) NOT VALID")
3838 -> 0.0009s
3839-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_jobs_on_config_id FOREIGN KEY (config_id) REFERENCES job_configs(id) NOT VALID")
3840 -> 0.0012s
3841-- execute("ALTER TABLE branches ADD CONSTRAINT fk_branches_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3842 -> 0.0007s
3843-- 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")
3844 -> 0.0007s
3845-- execute("ALTER TABLE tags ADD CONSTRAINT fk_tags_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3846 -> 0.0007s
3847-- 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")
3848 -> 0.0007s
3849-- execute("ALTER TABLE commits ADD CONSTRAINT fk_commits_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3850 -> 0.0007s
3851-- execute("ALTER TABLE commits ADD CONSTRAINT fk_commits_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) NOT VALID")
3852 -> 0.0006s
3853-- execute("ALTER TABLE commits ADD CONSTRAINT fk_commits_on_tag_id FOREIGN KEY (tag_id) REFERENCES tags(id) NOT VALID")
3854 -> 0.0006s
3855-- execute("ALTER TABLE crons ADD CONSTRAINT fk_crons_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) NOT VALID")
3856 -> 0.0008s
3857-- execute("ALTER TABLE job_configs ADD CONSTRAINT fk_job_configs_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3858 -> 0.0007s
3859-- execute("ALTER TABLE build_configs ADD CONSTRAINT fk_build_configs_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3860 -> 0.0007s
3861-- execute("ALTER TABLE pull_requests ADD CONSTRAINT fk_pull_requests_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3862 -> 0.0007s
3863-- execute("ALTER TABLE ssl_keys ADD CONSTRAINT fk_ssl_keys_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) NOT VALID")
3864 -> 0.0007s
3865-- execute("ALTER TABLE requests ADD CONSTRAINT fk_requests_on_commit_id FOREIGN KEY (commit_id) REFERENCES commits(id) NOT VALID")
3866 -> 0.0007s
3867-- execute("ALTER TABLE requests ADD CONSTRAINT fk_requests_on_pull_request_id FOREIGN KEY (pull_request_id) REFERENCES pull_requests(id) NOT VALID")
3868 -> 0.0007s
3869-- execute("ALTER TABLE requests ADD CONSTRAINT fk_requests_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) NOT VALID")
3870 -> 0.0007s
3871-- execute("ALTER TABLE requests ADD CONSTRAINT fk_requests_on_tag_id FOREIGN KEY (tag_id) REFERENCES tags(id) NOT VALID")
3872 -> 0.0007s
3873-- execute("ALTER TABLE requests ADD CONSTRAINT fk_requests_on_config_id FOREIGN KEY (config_id) REFERENCES request_configs(id) NOT VALID")
3874 -> 0.0007s
3875-- execute("ALTER TABLE stages ADD CONSTRAINT fk_stages_on_build_id FOREIGN KEY (build_id) REFERENCES builds(id) NOT VALID")
3876 -> 0.0007s
3877== 20181116800000 AddConstraintsToMultipleTables: migrated (0.0211s) ==========
3879== 20181116800001 ValidateConstraints: migrating ==============================
3880-- execute("ALTER TABLE repositories VALIDATE CONSTRAINT fk_repositories_on_current_build_id")
3881 -> 0.0021s
3882-- execute("ALTER TABLE repositories VALIDATE CONSTRAINT fk_repositories_on_last_build_id")
3883 -> 0.0010s
3884-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_repository_id")
3885 -> 0.0012s
3886-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_commit_id")
3887 -> 0.0010s
3888-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_request_id")
3889 -> 0.0013s
3890-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_pull_request_id")
3891 -> 0.0010s
3892-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_branch_id")
3893 -> 0.0010s
3894-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_tag_id")
3895 -> 0.0010s
3896-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_builds_on_config_id")
3897 -> 0.0010s
3898-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_jobs_on_repository_id")
3899 -> 0.0013s
3900-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_jobs_on_commit_id")
3901 -> 0.0008s
3902-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_jobs_on_stage_id")
3903 -> 0.0009s
3904-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_jobs_on_config_id")
3905 -> 0.0008s
3906-- execute("ALTER TABLE branches VALIDATE CONSTRAINT fk_branches_on_repository_id")
3907 -> 0.0007s
3908-- execute("ALTER TABLE branches VALIDATE CONSTRAINT fk_branches_on_last_build_id")
3909 -> 0.0008s
3910-- execute("ALTER TABLE tags VALIDATE CONSTRAINT fk_tags_on_repository_id")
3911 -> 0.0007s
3912-- execute("ALTER TABLE tags VALIDATE CONSTRAINT fk_tags_on_last_build_id")
3913 -> 0.0007s
3914-- execute("ALTER TABLE commits VALIDATE CONSTRAINT fk_commits_on_repository_id")
3915 -> 0.0007s
3916-- execute("ALTER TABLE commits VALIDATE CONSTRAINT fk_commits_on_branch_id")
3917 -> 0.0007s
3918-- execute("ALTER TABLE commits VALIDATE CONSTRAINT fk_commits_on_tag_id")
3919 -> 0.0006s
3920-- execute("ALTER TABLE crons VALIDATE CONSTRAINT fk_crons_on_branch_id")
3921 -> 0.0008s
3922-- execute("ALTER TABLE job_configs VALIDATE CONSTRAINT fk_job_configs_on_repository_id")
3923 -> 0.0007s
3924-- execute("ALTER TABLE build_configs VALIDATE CONSTRAINT fk_build_configs_on_repository_id")
3925 -> 0.0007s
3926-- execute("ALTER TABLE pull_requests VALIDATE CONSTRAINT fk_pull_requests_on_repository_id")
3927 -> 0.0008s
3928-- execute("ALTER TABLE ssl_keys VALIDATE CONSTRAINT fk_ssl_keys_on_repository_id")
3929 -> 0.0009s
3930-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_requests_on_commit_id")
3931 -> 0.0007s
3932-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_requests_on_pull_request_id")
3933 -> 0.0008s
3934-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_requests_on_branch_id")
3935 -> 0.0007s
3936-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_requests_on_tag_id")
3937 -> 0.0007s
3938-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_requests_on_config_id")
3939 -> 0.0009s
3940-- execute("ALTER TABLE stages VALIDATE CONSTRAINT fk_stages_on_build_id")
3941 -> 0.0008s
3942== 20181116800001 ValidateConstraints: migrated (0.0289s) =====================
3944== 20181126080000 AddIndexesForForeignKeys: migrating =========================
3945-- index_exists?(:builds, :branch_id)
3946 -> 0.0092s
3947-- add_index(:builds, :branch_id, {:algorithm=>:concurrently})
3948 -> 0.0048s
3949-- index_exists?(:builds, :commit_id)
3950 -> 0.0094s
3951-- add_index(:builds, :commit_id, {:algorithm=>:concurrently})
3952 -> 0.0044s
3953-- index_exists?(:builds, :pull_request_id)
3954 -> 0.0105s
3955-- add_index(:builds, :pull_request_id, {:algorithm=>:concurrently})
3956 -> 0.0043s
3957-- index_exists?(:builds, :tag_id)
3958 -> 0.0108s
3959-- add_index(:builds, :tag_id, {:algorithm=>:concurrently})
3960 -> 0.0043s
3961-- index_exists?(:jobs, :commit_id)
3962 -> 0.0082s
3963-- add_index(:jobs, :commit_id, {:algorithm=>:concurrently})
3964 -> 0.0074s
3965-- index_exists?(:branches, :last_build_id)
3966 -> 0.0028s
3967-- add_index(:branches, :last_build_id, {:algorithm=>:concurrently})
3968 -> 0.0041s
3969-- index_exists?(:tags, :repository_id)
3970 -> 0.0026s
3971-- add_index(:tags, :repository_id, {:algorithm=>:concurrently})
3972 -> 0.0040s
3973-- index_exists?(:tags, :last_build_id)
3974 -> 0.0029s
3975-- add_index(:tags, :last_build_id, {:algorithm=>:concurrently})
3976 -> 0.0042s
3977-- index_exists?(:commits, :tag_id)
3978 -> 0.0032s
3979-- add_index(:commits, :tag_id, {:algorithm=>:concurrently})
3980 -> 0.0037s
3981-- index_exists?(:commits, :branch_id)
3982 -> 0.0032s
3983-- add_index(:commits, :branch_id, {:algorithm=>:concurrently})
3984 -> 0.0036s
3985-- index_exists?(:job_configs, :repository_id)
3986 -> 0.0014s
3987-- add_index(:job_configs, :repository_id, {:algorithm=>:concurrently})
3988 -> 0.0034s
3989-- index_exists?(:build_configs, :repository_id)
3990 -> 0.0016s
3991-- add_index(:build_configs, :repository_id, {:algorithm=>:concurrently})
3992 -> 0.0041s
3993-- index_exists?(:pull_requests, :repository_id)
3994 -> 0.0024s
3995-- add_index(:pull_requests, :repository_id, {:algorithm=>:concurrently})
3996 -> 0.0040s
3997-- index_exists?(:requests, :pull_request_id)
3998 -> 0.0050s
3999-- add_index(:requests, :pull_request_id, {:algorithm=>:concurrently})
4000 -> 0.0041s
4001-- index_exists?(:requests, :tag_id)
4002 -> 0.0092s
4003-- add_index(:requests, :tag_id, {:algorithm=>:concurrently})
4004 -> 0.0041s
4005-- index_exists?(:requests, :branch_id)
4006 -> 0.0063s
4007-- add_index(:requests, :branch_id, {:algorithm=>:concurrently})
4008 -> 0.0041s
4009-- index_exists?(:repositories, :current_build_id)
4010 -> 0.0063s
4011-- add_index(:repositories, :current_build_id, {:algorithm=>:concurrently})
4012 -> 0.0044s
4013-- index_exists?(:repositories, :last_build_id)
4014 -> 0.0062s
4015-- add_index(:repositories, :last_build_id, {:algorithm=>:concurrently})
4016 -> 0.0044s
4017-- index_exists?(:crons, :branch_id)
4018 -> 0.0025s
4019-- add_index(:crons, :branch_id, {:algorithm=>:concurrently})
4020 -> 0.0040s
4021== 20181126080000 AddIndexesForForeignKeys: migrated (0.1904s) ================
4023== 20181128120000 AddUniqueIndexToBranchesOnRepositoryIdAndName: migrating ====
4024-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_branches_on_repository_id_and_name ON branches(repository_id, name)")
4025 -> 0.0041s
4026== 20181128120000 AddUniqueIndexToBranchesOnRepositoryIdAndName: migrated (0.0042s)
4028== 20181203075818 AddUniqueNameColumnToBranches: migrating ====================
4029-- add_column(:branches, :unique_name, :text)
4030 -> 0.0007s
4031== 20181203075818 AddUniqueNameColumnToBranches: migrated (0.0007s) ===========
4033== 20181203075819 AddSetUniqueNameTriggerToBranches: migrating ================
4034-- 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")
4035 -> 0.0011s
4036== 20181203075819 AddSetUniqueNameTriggerToBranches: migrated (0.0013s) =======
4038== 20181203080356 CreateIndexOnBranchesUniqueNameAndRepositoryId: migrating ===
4039-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_branches_repository_id_unique_name ON branches(repository_id, unique_name) WHERE unique_name IS NOT NULL")
4040 -> 0.0039s
4041== 20181203080356 CreateIndexOnBranchesUniqueNameAndRepositoryId: migrated (0.0040s)
4043== 20181205152712 AddUniqueIndexToCronsOnBranchId: migrating ==================
4044-- execute("DROP INDEX CONCURRENTLY index_crons_on_branch_id")
4045 -> 0.0024s
4046-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_crons_on_branch_id ON crons(branch_id)")
4047 -> 0.0046s
4048== 20181205152712 AddUniqueIndexToCronsOnBranchId: migrated (0.0071s) =========
4050== 20190102000000 AddOrganizationPreferences: migrating =======================
4051-- change_table(:organizations)
4052 -> 0.0030s
4053== 20190102000000 AddOrganizationPreferences: migrated (0.0031s) ==============
4055== 20190102000001 ChangeOrganizationPreferencesDefault: migrating =============
4056-- change_column_default(:organizations, :preferences, {})
4057 -> 0.0046s
4058== 20190102000001 ChangeOrganizationPreferencesDefault: migrated (0.0047s) ====
4060== 20190109000000 CreateBetaMigrationRequestTable: migrating ==================
4061-- create_table(:beta_migration_requests, {:id=>:integer})
4062 -> 0.0064s
4063-- add_index(:beta_migration_requests, [:owner_type, :owner_id])
4064 -> 0.0022s
4065== 20190109000000 CreateBetaMigrationRequestTable: migrated (0.0087s) =========
4067== 20190118000000 AddBetaMigrationRequestColumnToOrganizations: migrating =====
4068-- add_column(:organizations, :beta_migration_request_id, :integer)
4069 -> 0.0016s
4070== 20190118000000 AddBetaMigrationRequestColumnToOrganizations: migrated (0.0017s)
4072== 20190204000000 MakeSubscriptionOwnerNotNullable: migrating =================
4073-- change_column_null(:subscriptions, :owner_type, false)
4074 -> 0.0025s
4075-- change_column_null(:subscriptions, :owner_id, false)
4076 -> 0.0011s
4077== 20190204000000 MakeSubscriptionOwnerNotNullable: migrated (0.0039s) ========
4079== 20190313000000 RequestRawConfigsCreate: migrating ==========================
4080-- create_table(:request_raw_configs, {:id=>:integer})
4081 -> 0.0078s
4082-- add_index(:request_raw_configs, [:repository_id, :key])
4083 -> 0.0021s
4084-- create_table(:request_raw_configurations, {:id=>:integer})
4085 -> 0.0061s
4086-- add_index(:request_raw_configurations, :request_id)
4087 -> 0.0019s
4088-- add_index(:request_raw_configurations, :request_raw_config_id)
4089 -> 0.0018s
4090== 20190313000000 RequestRawConfigsCreate: migrated (0.0200s) =================
4092== 20190329093854 CreateGatekeeperWorkers: migrating ==========================
4093-- create_table(:gatekeeper_workers)
4094 -> 0.0029s
4095-- execute("INSERT INTO gatekeeper_workers(id) SELECT generate_series(1,200) as id;")
4096 -> 0.0007s
4097== 20190329093854 CreateGatekeeperWorkers: migrated (0.0036s) =================
4099== 20190409133118 AddUniqueNumberColumnToBuilds: migrating ====================
4100-- add_column(:builds, :unique_number, :int)
4101 -> 0.0007s
4102== 20190409133118 AddUniqueNumberColumnToBuilds: migrated (0.0007s) ===========
4104== 20190409133320 AddSetUniqueNumberTriggerToBuilds: migrating ================
4105-- 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")
4106 -> 0.0008s
4107== 20190409133320 AddSetUniqueNumberTriggerToBuilds: migrated (0.0009s) =======
4109== 20190409133444 CreateUniqueIndexOnRepositoryIdAndNumberOnBuilds: migrating =
4110-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_builds_repository_id_unique_number ON builds(repository_id, unique_number) WHERE unique_number IS NOT NULL")
4111 -> 0.0039s
4112== 20190409133444 CreateUniqueIndexOnRepositoryIdAndNumberOnBuilds: migrated (0.0039s)
4114== 20190410121039 MakeSetUniqueNumberTriggerRunOnlyOnInsert: migrating ========
4115-- 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")
4116 -> 0.0007s
4117== 20190410121039 MakeSetUniqueNumberTriggerRunOnlyOnInsert: migrated (0.0009s)
4119== 20190416071629 RemoveUniqueNameFromBranches: migrating =====================
4120-- execute("drop index concurrently index_branches_repository_id_unique_name;")
4121 -> 0.0021s
4122-- execute("DROP TRIGGER IF EXISTS set_unique_name_on_branches ON branches;\nDROP FUNCTION IF EXISTS set_unique_name();\n\n")
4123 -> 0.0009s
4124-- remove_column(:branches, :unique_name)
4125 -> 0.0009s
4126== 20190416071629 RemoveUniqueNameFromBranches: migrated (0.0041s) ============
4128== 20190417072423 AlterBuildsUniqueNumberIndex: migrating =====================
4129-- 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")
4130 -> 0.0036s
4131-- execute("DROP INDEX CONCURRENTLY index_builds_repository_id_unique_number")
4132 -> 0.0018s
4133-- execute("ALTER INDEX index_builds_repository_id_unique_number_new RENAME TO index_builds_repository_id_unique_number")
4134 -> 0.0007s
4135== 20190417072423 AlterBuildsUniqueNumberIndex: migrated (0.0062s) ============
4137== 20190417072838 ReinstallSetUniqueNumberTrigger: migrating ==================
4138-- execute("DROP TRIGGER IF EXISTS set_unique_number_on_builds ON builds;\nDROP FUNCTION IF EXISTS set_unique_number();\n")
4139 -> 0.0092s
4140-- 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")
4141 -> 0.0021s
4142== 20190417072838 ReinstallSetUniqueNumberTrigger: migrated (0.0150s) =========
4144== 20190502175059 AddMergeableStateToPullRequests: migrating ==================
4145-- add_column(:pull_requests, :mergeable_state, :string)
4146 -> 0.0021s
4147== 20190502175059 AddMergeableStateToPullRequests: migrated (0.0023s) =========
4149== 20190510121000 AddReposIndexOnLowerOwnerNameAndName: migrating =============
4150-- 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")
4151 -> 0.0044s
4152== 20190510121000 AddReposIndexOnLowerOwnerNameAndName: migrated (0.0045s) ====
4154== 20190605121000 AddHistoryMigrationStatusToRepositories: migrating ==========
4155-- add_column(:repositories, :history_migration_status, :string)
4156 -> 0.0012s
4157== 20190605121000 AddHistoryMigrationStatusToRepositories: migrated (0.0013s) =
4159== 20190605155459 AddPullRequestMergeableToRequests: migrating ================
4160-- add_column(:requests, :pull_request_mergeable, :string)
4161 -> 0.0020s
4162== 20190605155459 AddPullRequestMergeableToRequests: migrated (0.0022s) =======
4164== 20190613120000 SoftDeleteRepositoryAlongWithItsData: migrating =============
4165-- execute("create table if not exists deleted_builds (like builds)")
4166 -> 0.0041s
4167-- execute("create table if not exists deleted_stages (like stages)")
4168 -> 0.0034s
4169-- execute("create table if not exists deleted_jobs (like jobs)")
4170 -> 0.0032s
4171-- execute("create table if not exists deleted_requests (like requests)")
4172 -> 0.0036s
4173-- execute("create table if not exists deleted_commits (like commits)")
4174 -> 0.0041s
4175-- execute("create table if not exists deleted_pull_requests (like pull_requests)")
4176 -> 0.0039s
4177-- execute("create table if not exists deleted_job_configs (like job_configs)")
4178 -> 0.0103s
4179-- execute("create table if not exists deleted_build_configs (like build_configs)")
4180 -> 0.0034s
4181-- execute("create table if not exists deleted_request_configs (like request_configs)")
4182 -> 0.0029s
4183-- execute("create table if not exists deleted_request_payloads (like request_payloads)")
4184 -> 0.0055s
4185-- execute("create table if not exists deleted_ssl_keys (like ssl_keys)")
4186 -> 0.0033s
4187-- execute("create table if not exists deleted_tags (like tags)")
4188 -> 0.0046s
4189-- 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")
4190 -> 0.0028s
4191== 20190613120000 SoftDeleteRepositoryAlongWithItsData: migrated (0.0562s) ====
4193== 20190618082559 AddVcsTypeToUser: migrating =================================
4194-- add_column(:users, :vcs_type, :string, {:default=>nil})
4195 -> 0.0011s
4196-- execute("ALTER TABLE users ALTER COLUMN vcs_type SET DEFAULT 'GithubUser'")
4197 -> 0.0004s
4198-- select_value("SELECT id FROM users ORDER BY id DESC LIMIT 1")
4199 -> 0.0007s
4200-- execute("UPDATE users SET vcs_type = 'GithubUser' WHERE id BETWEEN 0 AND 5000")
4201 -> 0.0098s
4202== 20190618082559 AddVcsTypeToUser: migrated (0.0131s) ========================
4204== 20190701082559 AddVcsTypeToRepository: migrating ===========================
4205-- add_column(:repositories, :vcs_type, :string, {:default=>nil})
4206 -> 0.0011s
4207-- execute("ALTER TABLE repositories ALTER COLUMN vcs_type SET DEFAULT 'GithubRepository'")
4208 -> 0.0005s
4209-- select_value("SELECT id FROM repositories ORDER BY id DESC LIMIT 1")
4210 -> 0.0008s
4211-- execute("UPDATE repositories SET vcs_type = 'GithubRepository' WHERE id BETWEEN 0 AND 5000")
4212 -> 0.0007s
4213== 20190701082559 AddVcsTypeToRepository: migrated (0.0041s) ==================
4215== 20190704082559 AddVcsTypeToOrganization: migrating =========================
4216-- add_column(:organizations, :vcs_type, :string, {:default=>nil})
4217 -> 0.0010s
4218-- execute("ALTER TABLE organizations ALTER COLUMN vcs_type SET DEFAULT 'GithubOrganization'")
4219 -> 0.0004s
4220-- select_value("SELECT id FROM organizations ORDER BY id DESC LIMIT 1")
4221 -> 0.0007s
4222-- execute("UPDATE organizations SET vcs_type = 'GithubOrganization' WHERE id BETWEEN 0 AND 5000")
4223 -> 0.0006s
4224== 20190704082559 AddVcsTypeToOrganization: migrated (0.0038s) ================
4226== 20190718092750 AddDeleteCascadeToForeignKeys: migrating ====================
4227-- execute("ALTER TABLE builds ADD CONSTRAINT fk_new_builds_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4228 -> 0.0012s
4229-- execute("ALTER TABLE builds ADD CONSTRAINT fk_new_builds_on_commit_id FOREIGN KEY (commit_id) REFERENCES commits(id) ON DELETE CASCADE NOT VALID")
4230 -> 0.0008s
4231-- execute("ALTER TABLE builds ADD CONSTRAINT fk_new_builds_on_request_id FOREIGN KEY (request_id) REFERENCES requests(id) ON DELETE CASCADE NOT VALID")
4232 -> 0.0009s
4233-- 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")
4234 -> 0.0011s
4235-- execute("ALTER TABLE builds ADD CONSTRAINT fk_new_builds_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) ON DELETE CASCADE NOT VALID")
4236 -> 0.0011s
4237-- execute("ALTER TABLE builds ADD CONSTRAINT fk_new_builds_on_tag_id FOREIGN KEY (tag_id) REFERENCES tags(id) ON DELETE CASCADE NOT VALID")
4238 -> 0.0012s
4239-- 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")
4240 -> 0.0010s
4241-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_new_jobs_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4242 -> 0.0010s
4243-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_new_jobs_on_commit_id FOREIGN KEY (commit_id) REFERENCES commits(id) ON DELETE CASCADE NOT VALID")
4244 -> 0.0010s
4245-- execute("ALTER TABLE jobs ADD CONSTRAINT fk_new_jobs_on_stage_id FOREIGN KEY (stage_id) REFERENCES stages(id) ON DELETE CASCADE NOT VALID")
4246 -> 0.0010s
4247-- 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")
4248 -> 0.0010s
4249-- execute("ALTER TABLE branches ADD CONSTRAINT fk_new_branches_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4250 -> 0.0009s
4251-- execute("ALTER TABLE tags ADD CONSTRAINT fk_new_tags_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4252 -> 0.0013s
4253-- execute("ALTER TABLE commits ADD CONSTRAINT fk_new_commits_on_repository_id FOREIGN KEY (repository_id) REFERENCES repositories(id) ON DELETE CASCADE NOT VALID")
4254 -> 0.0011s
4255-- execute("ALTER TABLE commits ADD CONSTRAINT fk_new_commits_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) ON DELETE CASCADE NOT VALID")
4256 -> 0.0010s
4257-- execute("ALTER TABLE commits ADD CONSTRAINT fk_new_commits_on_tag_id FOREIGN KEY (tag_id) REFERENCES tags(id) ON DELETE CASCADE NOT VALID")
4258 -> 0.0011s
4259-- execute("ALTER TABLE crons ADD CONSTRAINT fk_new_crons_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) ON DELETE CASCADE NOT VALID")
4260 -> 0.0011s
4261-- 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")
4262 -> 0.0011s
4263-- 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")
4264 -> 0.0012s
4265-- 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")
4266 -> 0.0011s
4267-- 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")
4268 -> 0.0011s
4269-- execute("ALTER TABLE requests ADD CONSTRAINT fk_new_requests_on_commit_id FOREIGN KEY (commit_id) REFERENCES commits(id) ON DELETE CASCADE NOT VALID")
4270 -> 0.0011s
4271-- 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")
4272 -> 0.0010s
4273-- execute("ALTER TABLE requests ADD CONSTRAINT fk_new_requests_on_branch_id FOREIGN KEY (branch_id) REFERENCES branches(id) ON DELETE CASCADE NOT VALID")
4274 -> 0.0011s
4275-- execute("ALTER TABLE requests ADD CONSTRAINT fk_new_requests_on_tag_id FOREIGN KEY (tag_id) REFERENCES tags(id) ON DELETE CASCADE NOT VALID")
4276 -> 0.0008s
4277-- 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")
4278 -> 0.0011s
4279-- execute("ALTER TABLE stages ADD CONSTRAINT fk_new_stages_on_build_id FOREIGN KEY (build_id) REFERENCES builds(id) ON DELETE CASCADE NOT VALID")
4280 -> 0.0013s
4281-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_repository_id")
4282 -> 0.0019s
4283-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_commit_id")
4284 -> 0.0015s
4285-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_request_id")
4286 -> 0.0016s
4287-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_pull_request_id")
4288 -> 0.0014s
4289-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_branch_id")
4290 -> 0.0015s
4291-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_tag_id")
4292 -> 0.0014s
4293-- execute("ALTER TABLE builds VALIDATE CONSTRAINT fk_new_builds_on_config_id")
4294 -> 0.0013s
4295-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_new_jobs_on_repository_id")
4296 -> 0.0014s
4297-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_new_jobs_on_commit_id")
4298 -> 0.0012s
4299-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_new_jobs_on_stage_id")
4300 -> 0.0011s
4301-- execute("ALTER TABLE jobs VALIDATE CONSTRAINT fk_new_jobs_on_config_id")
4302 -> 0.0012s
4303-- execute("ALTER TABLE branches VALIDATE CONSTRAINT fk_new_branches_on_repository_id")
4304 -> 0.0010s
4305-- execute("ALTER TABLE tags VALIDATE CONSTRAINT fk_new_tags_on_repository_id")
4306 -> 0.0011s
4307-- execute("ALTER TABLE commits VALIDATE CONSTRAINT fk_new_commits_on_repository_id")
4308 -> 0.0011s
4309-- execute("ALTER TABLE commits VALIDATE CONSTRAINT fk_new_commits_on_branch_id")
4310 -> 0.0010s
4311-- execute("ALTER TABLE commits VALIDATE CONSTRAINT fk_new_commits_on_tag_id")
4312 -> 0.0007s
4313-- execute("ALTER TABLE crons VALIDATE CONSTRAINT fk_new_crons_on_branch_id")
4314 -> 0.0010s
4315-- execute("ALTER TABLE job_configs VALIDATE CONSTRAINT fk_new_job_configs_on_repository_id")
4316 -> 0.0010s
4317-- execute("ALTER TABLE build_configs VALIDATE CONSTRAINT fk_new_build_configs_on_repository_id")
4318 -> 0.0010s
4319-- execute("ALTER TABLE pull_requests VALIDATE CONSTRAINT fk_new_pull_requests_on_repository_id")
4320 -> 0.0011s
4321-- execute("ALTER TABLE ssl_keys VALIDATE CONSTRAINT fk_new_ssl_keys_on_repository_id")
4322 -> 0.0011s
4323-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_new_requests_on_commit_id")
4324 -> 0.0010s
4325-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_new_requests_on_pull_request_id")
4326 -> 0.0011s
4327-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_new_requests_on_branch_id")
4328 -> 0.0009s
4329-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_new_requests_on_tag_id")
4330 -> 0.0010s
4331-- execute("ALTER TABLE requests VALIDATE CONSTRAINT fk_new_requests_on_config_id")
4332 -> 0.0010s
4333-- execute("ALTER TABLE stages VALIDATE CONSTRAINT fk_new_stages_on_build_id")
4334 -> 0.0011s
4335-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_repository_id")
4336 -> 0.0013s
4337-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_commit_id")
4338 -> 0.0011s
4339-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_request_id")
4340 -> 0.0010s
4341-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_pull_request_id")
4342 -> 0.0011s
4343-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_branch_id")
4344 -> 0.0011s
4345-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_tag_id")
4346 -> 0.0011s
4347-- execute("ALTER TABLE builds DROP CONSTRAINT fk_builds_on_config_id")
4348 -> 0.0011s
4349-- execute("ALTER TABLE jobs DROP CONSTRAINT fk_jobs_on_repository_id")
4350 -> 0.0013s
4351-- execute("ALTER TABLE jobs DROP CONSTRAINT fk_jobs_on_commit_id")
4352 -> 0.0011s
4353-- execute("ALTER TABLE jobs DROP CONSTRAINT fk_jobs_on_stage_id")
4354 -> 0.0008s
4355-- execute("ALTER TABLE jobs DROP CONSTRAINT fk_jobs_on_config_id")
4356 -> 0.0007s
4357-- execute("ALTER TABLE branches DROP CONSTRAINT fk_branches_on_repository_id")
4358 -> 0.0011s
4359-- execute("ALTER TABLE tags DROP CONSTRAINT fk_tags_on_repository_id")
4360 -> 0.0011s
4361-- execute("ALTER TABLE commits DROP CONSTRAINT fk_commits_on_repository_id")
4362 -> 0.0011s
4363-- execute("ALTER TABLE commits DROP CONSTRAINT fk_commits_on_branch_id")
4364 -> 0.0010s
4365-- execute("ALTER TABLE commits DROP CONSTRAINT fk_commits_on_tag_id")
4366 -> 0.0009s
4367-- execute("ALTER TABLE crons DROP CONSTRAINT fk_crons_on_branch_id")
4368 -> 0.0010s
4369-- execute("ALTER TABLE job_configs DROP CONSTRAINT fk_job_configs_on_repository_id")
4370 -> 0.0010s
4371-- execute("ALTER TABLE build_configs DROP CONSTRAINT fk_build_configs_on_repository_id")
4372 -> 0.0010s
4373-- execute("ALTER TABLE pull_requests DROP CONSTRAINT fk_pull_requests_on_repository_id")
4374 -> 0.0010s
4375-- execute("ALTER TABLE ssl_keys DROP CONSTRAINT fk_ssl_keys_on_repository_id")
4376 -> 0.0009s
4377-- execute("ALTER TABLE requests DROP CONSTRAINT fk_requests_on_commit_id")
4378 -> 0.0011s
4379-- execute("ALTER TABLE requests DROP CONSTRAINT fk_requests_on_pull_request_id")
4380 -> 0.0048s
4381-- execute("ALTER TABLE requests DROP CONSTRAINT fk_requests_on_branch_id")
4382 -> 0.0011s
4383-- execute("ALTER TABLE requests DROP CONSTRAINT fk_requests_on_tag_id")
4384 -> 0.0011s
4385-- execute("ALTER TABLE requests DROP CONSTRAINT fk_requests_on_config_id")
4386 -> 0.0012s
4387-- execute("ALTER TABLE stages DROP CONSTRAINT fk_stages_on_build_id")
4388 -> 0.0007s
4389-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_repository_id TO fk_builds_on_repository_id")
4390 -> 0.0004s
4391-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_commit_id TO fk_builds_on_commit_id")
4392 -> 0.0004s
4393-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_request_id TO fk_builds_on_request_id")
4394 -> 0.0004s
4395-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_pull_request_id TO fk_builds_on_pull_request_id")
4396 -> 0.0003s
4397-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_branch_id TO fk_builds_on_branch_id")
4398 -> 0.0003s
4399-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_tag_id TO fk_builds_on_tag_id")
4400 -> 0.0003s
4401-- execute("ALTER TABLE builds RENAME CONSTRAINT fk_new_builds_on_config_id TO fk_builds_on_config_id")
4402 -> 0.0003s
4403-- execute("ALTER TABLE jobs RENAME CONSTRAINT fk_new_jobs_on_repository_id TO fk_jobs_on_repository_id")
4404 -> 0.0003s
4405-- execute("ALTER TABLE jobs RENAME CONSTRAINT fk_new_jobs_on_commit_id TO fk_jobs_on_commit_id")
4406 -> 0.0004s
4407-- execute("ALTER TABLE jobs RENAME CONSTRAINT fk_new_jobs_on_stage_id TO fk_jobs_on_stage_id")
4408 -> 0.0003s
4409-- execute("ALTER TABLE jobs RENAME CONSTRAINT fk_new_jobs_on_config_id TO fk_jobs_on_config_id")
4410 -> 0.0004s
4411-- execute("ALTER TABLE branches RENAME CONSTRAINT fk_new_branches_on_repository_id TO fk_branches_on_repository_id")
4412 -> 0.0003s
4413-- execute("ALTER TABLE tags RENAME CONSTRAINT fk_new_tags_on_repository_id TO fk_tags_on_repository_id")
4414 -> 0.0003s
4415-- execute("ALTER TABLE commits RENAME CONSTRAINT fk_new_commits_on_repository_id TO fk_commits_on_repository_id")
4416 -> 0.0003s
4417-- execute("ALTER TABLE commits RENAME CONSTRAINT fk_new_commits_on_branch_id TO fk_commits_on_branch_id")
4418 -> 0.0003s
4419-- execute("ALTER TABLE commits RENAME CONSTRAINT fk_new_commits_on_tag_id TO fk_commits_on_tag_id")
4420 -> 0.0003s
4421-- execute("ALTER TABLE crons RENAME CONSTRAINT fk_new_crons_on_branch_id TO fk_crons_on_branch_id")
4422 -> 0.0003s
4423-- execute("ALTER TABLE job_configs RENAME CONSTRAINT fk_new_job_configs_on_repository_id TO fk_job_configs_on_repository_id")
4424 -> 0.0003s
4425-- execute("ALTER TABLE build_configs RENAME CONSTRAINT fk_new_build_configs_on_repository_id TO fk_build_configs_on_repository_id")
4426 -> 0.0003s
4427-- execute("ALTER TABLE pull_requests RENAME CONSTRAINT fk_new_pull_requests_on_repository_id TO fk_pull_requests_on_repository_id")
4428 -> 0.0004s
4429-- execute("ALTER TABLE ssl_keys RENAME CONSTRAINT fk_new_ssl_keys_on_repository_id TO fk_ssl_keys_on_repository_id")
4430 -> 0.0003s
4431-- execute("ALTER TABLE requests RENAME CONSTRAINT fk_new_requests_on_commit_id TO fk_requests_on_commit_id")
4432 -> 0.0003s
4433-- execute("ALTER TABLE requests RENAME CONSTRAINT fk_new_requests_on_pull_request_id TO fk_requests_on_pull_request_id")
4434 -> 0.0004s
4435-- execute("ALTER TABLE requests RENAME CONSTRAINT fk_new_requests_on_branch_id TO fk_requests_on_branch_id")
4436 -> 0.0003s
4437-- execute("ALTER TABLE requests RENAME CONSTRAINT fk_new_requests_on_tag_id TO fk_requests_on_tag_id")
4438 -> 0.0004s
4439-- execute("ALTER TABLE requests RENAME CONSTRAINT fk_new_requests_on_config_id TO fk_requests_on_config_id")
4440 -> 0.0005s
4441-- execute("ALTER TABLE stages RENAME CONSTRAINT fk_new_stages_on_build_id TO fk_stages_on_build_id")
4442 -> 0.0004s
4443== 20190718092750 AddDeleteCascadeToForeignKeys: migrated (0.1046s) ===========
4445== 20190718100426 UpdateSoftDeleteProcedure: migrating ========================
4446-- 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")
4447 -> 0.0113s
4448== 20190718100426 UpdateSoftDeleteProcedure: migrated (0.0114s) ===============
4450== 20190725103113 UpdateSoftDelete: migrating =================================
4451-- execute("create table deleted_request_yaml_configs (like request_yaml_configs)")
4452 -> 0.0030s
4453-- 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")
4454 -> 0.0010s
4455== 20190725103113 UpdateSoftDelete: migrated (0.0041s) ========================
4457== 20190725105934 AddOrgIdToConfigs: migrating ================================
4458-- add_column(:job_configs, :org_id, :bigint)
4459 -> 0.0011s
4460-- add_column(:deleted_job_configs, :org_id, :bigint)
4461 -> 0.0011s
4462-- add_column(:build_configs, :org_id, :bigint)
4463 -> 0.0009s
4464-- add_column(:deleted_build_configs, :org_id, :bigint)
4465 -> 0.0008s
4466-- add_column(:request_configs, :org_id, :bigint)
4467 -> 0.0009s
4468-- add_column(:deleted_request_configs, :org_id, :bigint)
4469 -> 0.0008s
4470-- add_column(:request_yaml_configs, :org_id, :bigint)
4471 -> 0.0009s
4472-- add_column(:deleted_request_yaml_configs, :org_id, :bigint)
4473 -> 0.0010s
4474-- add_column(:request_payloads, :org_id, :bigint)
4475 -> 0.0009s
4476-- add_column(:deleted_request_payloads, :org_id, :bigint)
4477 -> 0.0010s
4478-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_job_configs_on_org_id ON job_configs (org_id)")
4479 -> 0.0037s
4480-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_build_configs_on_org_id ON build_configs (org_id)")
4481 -> 0.0033s
4482-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_configs_on_org_id ON request_configs (org_id)")
4483 -> 0.0041s
4484-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_yaml_configs_on_org_id ON request_yaml_configs (org_id)")
4485 -> 0.0034s
4486-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_payloads_on_org_id ON request_payloads (org_id)")
4487 -> 0.0035s
4488== 20190725105934 AddOrgIdToConfigs: migrated (0.0280s) =======================
4490== 20190729105934 AddOrgAndComIdsToRawConfigs: migrating ======================
4491-- add_column(:request_raw_configs, :org_id, :bigint)
4492 -> 0.0009s
4493-- add_column(:request_raw_configurations, :org_id, :bigint)
4494 -> 0.0010s
4495-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_raw_configs_on_org_id ON request_raw_configs (org_id)")
4496 -> 0.0034s
4497-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_raw_configurations_on_org_id ON request_raw_configurations (org_id)")
4498 -> 0.0036s
4499== 20190729105934 AddOrgAndComIdsToRawConfigs: migrated (0.0091s) =============
4501== 20190801120510 AddMoreDeletedTables: migrating =============================
4502-- execute("create table if not exists deleted_request_raw_configs (like request_raw_configs)")
4503 -> 0.0030s
4504-- execute("create table if not exists deleted_request_raw_configurations (like request_raw_configurations)")
4505 -> 0.0025s
4506-- 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")
4507 -> 0.0016s
4508== 20190801120510 AddMoreDeletedTables: migrated (0.0073s) ====================
4510== 20190815152336 AddComIdToMoreTables: migrating =============================
4511-- add_column(:request_configs, :com_id, :bigint)
4512 -> 0.0011s
4513-- add_column(:request_yaml_configs, :com_id, :bigint)
4514 -> 0.0009s
4515-- add_column(:deleted_request_configs, :com_id, :bigint)
4516 -> 0.0010s
4517-- add_column(:deleted_request_yaml_configs, :com_id, :bigint)
4518 -> 0.0007s
4519-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_configs_on_com_id ON request_configs (com_id)")
4520 -> 0.0032s
4521-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_request_yaml_configs_on_com_id ON request_yaml_configs (com_id)")
4522 -> 0.0034s
4523== 20190815152336 AddComIdToMoreTables: migrated (0.0105s) ====================
4525== 20190815164320 AddComIdToBuildConfigs: migrating ===========================
4526-- add_column(:build_configs, :com_id, :bigint)
4527 -> 0.0010s
4528-- add_column(:deleted_build_configs, :com_id, :bigint)
4529 -> 0.0010s
4530-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_build_configs_on_com_id ON build_configs (com_id)")
4531 -> 0.0036s
4532== 20190815164320 AddComIdToBuildConfigs: migrated (0.0058s) ==================
4534== 20190815172205 AddComIdToJobConfigs: migrating =============================
4535-- add_column(:job_configs, :com_id, :bigint)
4536 -> 0.0011s
4537-- add_column(:deleted_job_configs, :com_id, :bigint)
4538 -> 0.0010s
4539-- execute("CREATE UNIQUE INDEX CONCURRENTLY index_job_configs_on_com_id ON job_configs (com_id)")
4540 -> 0.0036s
4541== 20190815172205 AddComIdToJobConfigs: migrated (0.0059s) ====================
4543== 20190819082558 AddVcsIdToUser: migrating ===================================
4544-- add_column(:users, :vcs_id, :string, {:default=>nil})
4545 -> 0.0015s
4546-- execute("CREATE INDEX CONCURRENTLY index_users_on_vcs_id_and_vcs_type ON users (vcs_id, vcs_type);")
4547 -> 0.0038s
4548== 20190819082558 AddVcsIdToUser: migrated (0.0054s) ==========================
4550== 20190819082559 AddVcsIdToRepository: migrating =============================
4551-- add_column(:repositories, :vcs_id, :string, {:default=>nil})
4552 -> 0.0011s
4553-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_vcs_id_and_vcs_type ON repositories (vcs_id, vcs_type);")
4554 -> 0.0039s
4555== 20190819082559 AddVcsIdToRepository: migrated (0.0051s) ====================
4557== 20190820082431 AddVcsIdToOrganization: migrating ===========================
4558-- add_column(:organizations, :vcs_id, :string, {:default=>nil})
4559 -> 0.0013s
4560-- execute("CREATE INDEX CONCURRENTLY index_organizations_on_vcs_id_and_vcs_type ON organizations (vcs_id, vcs_type);")
4561 -> 0.0039s
4562== 20190820082431 AddVcsIdToOrganization: migrated (0.0052s) ==================
4564== 20190913092543 CopyVcsIdForRepository: migrating ===========================
4565-- select_value("SELECT id FROM repositories ORDER BY id DESC LIMIT 1")
4566 -> 0.0008s
4567-- execute("UPDATE \"repositories\" SET vcs_id = github_id WHERE id BETWEEN 0 AND 5000")
4568 -> 0.0008s
4569== 20190913092543 CopyVcsIdForRepository: migrated (0.0019s) ==================
4571== 20190913092554 CopyVcsIdForUser: migrating =================================
4572-- select_value("SELECT id FROM users ORDER BY id DESC LIMIT 1")
4573 -> 0.0006s
4574-- execute("UPDATE \"users\" SET vcs_id = github_id WHERE id BETWEEN 0 AND 5000")
4575 -> 0.0006s
4576== 20190913092554 CopyVcsIdForUser: migrated (0.0017s) ========================
4578== 20190913092565 CopyVcsIdForOrganization: migrating =========================
4579-- select_value("SELECT id FROM organizations ORDER BY id DESC LIMIT 1")
4580 -> 0.0006s
4581-- execute("UPDATE \"organizations\" SET vcs_id = github_id WHERE id BETWEEN 0 AND 5000")
4582 -> 0.0006s
4583== 20190913092565 CopyVcsIdForOrganization: migrated (0.0016s) ================
4585== 20190920160300 MessagesAddTypeSourceLine: migrating ========================
4586-- add_column(:messages, :type, :string, {:default=>nil})
4587 -> 0.0014s
4588-- add_column(:messages, :src, :string, {:default=>nil})
4589 -> 0.0014s
4590-- add_column(:messages, :line, :integer, {:default=>nil})
4591 -> 0.0014s
4592== 20190920160300 MessagesAddTypeSourceLine: migrated (0.0043s) ===============
4594== 20191112000000 ReposAddFork: migrating =====================================
4595-- add_column(:repositories, :fork, :boolean, {:default=>nil})
4596 -> 0.0015s
4597== 20191112000000 ReposAddFork: migrated (0.0016s) ============================
4599== 20191112172015 AddVcsIndexToRepositories: migrating ========================
4600-- add_index(:repositories, [:vcs_type, :vcs_id], {:algorithm=>:concurrently})
4601 -> 0.0043s
4602== 20191112172015 AddVcsIndexToRepositories: migrated (0.0044s) ===============
4604== 20191112172332 AddVcsIndexToUsers: migrating ===============================
4605-- add_index(:users, [:vcs_type, :vcs_id], {:algorithm=>:concurrently})
4606 -> 0.0035s
4607== 20191112172332 AddVcsIndexToUsers: migrated (0.0036s) ======================
4609== 20191219091445 AddHeadRepoVcsIdToPullRequest: migrating ====================
4610-- add_column(:pull_requests, :head_repo_vcs_id, :string, {:default=>nil})
4611 -> 0.0016s
4612-- execute("CREATE INDEX CONCURRENTLY index_pull_requests_on_head_repo_vcs_id ON pull_requests (head_repo_vcs_id);")
4613 -> 0.0038s
4614== 20191219091445 AddHeadRepoVcsIdToPullRequest: migrated (0.0055s) ===========
4616== 20191219091446 AddHeadRepoVcsIdToDeletedPullRequest: migrating =============
4617-- add_column(:deleted_pull_requests, :head_repo_vcs_id, :string, {:default=>nil})
4618 -> 0.0015s
4619-- execute("CREATE INDEX CONCURRENTLY index_deleted_pull_requests_on_head_repo_vcs_id ON deleted_pull_requests (head_repo_vcs_id);")
4620 -> 0.0036s
4621== 20191219091446 AddHeadRepoVcsIdToDeletedPullRequest: migrated (0.0052s) ====
4623== 20200122000000 AddConfigsJson: migrating ===================================
4624-- add_column(:request_configs, :config_json, :json)
4625 -> 0.0009s
4626-- add_column(:build_configs, :config_json, :json)
4627 -> 0.0006s
4628-- add_column(:job_configs, :config_json, :json)
4629 -> 0.0005s
4630-- add_column(:deleted_request_configs, :config_json, :json)
4631 -> 0.0006s
4632-- add_column(:deleted_build_configs, :config_json, :json)
4633 -> 0.0005s
4634-- add_column(:deleted_job_configs, :config_json, :json)
4635 -> 0.0005s
4636== 20200122000000 AddConfigsJson: migrated (0.0040s) ==========================
4638== 20200127000000 DropJobConfigsGpu: migrating ================================
4639-- execute("DROP MATERIALIZED VIEW job_configs_gpu\n")
4640 -> 0.0010s
4641== 20200127000000 DropJobConfigsGpu: migrated (0.0011s) =======================
4643== 20200127000001 RenameConfigsJson: migrating ================================
4644-- remove_column(:request_configs, :config)
4645 -> 0.0008s
4646-- rename_column(:request_configs, :config_json, :config)
4647 -> 0.0035s
4648-- remove_column(:build_configs, :config)
4649 -> 0.0005s
4650-- rename_column(:build_configs, :config_json, :config)
4651 -> 0.0034s
4652-- remove_column(:job_configs, :config)
4653 -> 0.0006s
4654-- rename_column(:job_configs, :config_json, :config)
4655 -> 0.0033s
4656-- remove_column(:deleted_request_configs, :config)
4657 -> 0.0005s
4658-- rename_column(:deleted_request_configs, :config_json, :config)
4659 -> 0.0013s
4660-- remove_column(:deleted_build_configs, :config)
4661 -> 0.0005s
4662-- rename_column(:deleted_build_configs, :config_json, :config)
4663 -> 0.0013s
4664-- remove_column(:deleted_job_configs, :config)
4665 -> 0.0005s
4666-- rename_column(:deleted_job_configs, :config_json, :config)
4667 -> 0.0013s
4668== 20200127000001 RenameConfigsJson: migrated (0.0182s) =======================
4670== 20200214144655 AddIndexToJobVersionsOnJobId: migrating =====================
4671-- add_index(:job_versions, :job_id, {:algorithm=>:concurrently})
4672 -> 0.0040s
4673== 20200214144655 AddIndexToJobVersionsOnJobId: migrated (0.0041s) ============
4675== 20200225085734 AddVcsSlugToRepository: migrating ===========================
4676-- add_column(:repositories, :vcs_slug, :string, {:default=>nil})
4677 -> 0.0016s
4678== 20200225085734 AddVcsSlugToRepository: migrated (0.0017s) ==================
4680== 20200227085734 AddVcsSourceHostToRepository: migrating =====================
4681-- add_column(:repositories, :vcs_source_host, :string, {:default=>nil})
4682 -> 0.0014s
4683== 20200227085734 AddVcsSourceHostToRepository: migrated (0.0015s) ============
4685== 20200227085736 AddVcsIndexes: migrating ====================================
4686-- 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")
4687 -> 0.0045s
4688== 20200227085736 AddVcsIndexes: migrated (0.0046s) ===========================
4690== 20200227085737 AddRepositoryNameAndSlugIndex: migrating ====================
4691-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_slug_or_names ON repositories (vcs_slug, owner_name, name) WHERE invalidated_at IS NULL")
4692 -> 0.0041s
4693== 20200227085737 AddRepositoryNameAndSlugIndex: migrated (0.0041s) ===========
4695== 20200227085742 AddPullRequestSourceData: migrating =========================
4696-- add_column(:pull_requests, :base_repo_slug, :string, {:default=>nil})
4697 -> 0.0015s
4698-- add_column(:pull_requests, :base_repo_vcs_id, :string, {:default=>nil})
4699 -> 0.0015s
4700-- add_column(:pull_requests, :base_ref, :string, {:default=>nil})
4701 -> 0.0015s
4702-- add_column(:deleted_pull_requests, :base_repo_slug, :string, {:default=>nil})
4703 -> 0.0014s
4704-- add_column(:deleted_pull_requests, :base_repo_vcs_id, :string, {:default=>nil})
4705 -> 0.0014s
4706-- add_column(:deleted_pull_requests, :base_ref, :string, {:default=>nil})
4707 -> 0.0014s
4708== 20200227085742 AddPullRequestSourceData: migrated (0.0089s) ================
4710== 20200312184018 AddUserUtmParamsTable: migrating ============================
4711-- create_table(:user_utm_params)
4712 -> 0.0088s
4713== 20200312184018 AddUserUtmParamsTable: migrated (0.0088s) ===================
4715== 20200316085738 AddRepositoryVcsSlugIndex: migrating ========================
4716-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_lower_vcs_slug ON repositories (LOWER(vcs_slug))")
4717 -> 0.0041s
4718-- execute("CREATE INDEX CONCURRENTLY index_repositories_on_lower_vcs_slug_valid ON repositories (LOWER(vcs_slug)) WHERE invalidated_at IS NULL")
4719 -> 0.0039s
4720== 20200316085738 AddRepositoryVcsSlugIndex: migrated (0.0081s) ===============
4722== 20200325115329 AddMultipleJobStateIndexesOrderByNewest: migrating ==========
4723-- 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'")
4724 -> 0.0039s
4725-- 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'")
4726 -> 0.0040s
4727-- 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'")
4728 -> 0.0035s
4729-- 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'")
4730 -> 0.0039s
4731-- 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'")
4732 -> 0.0037s
4733-- 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'")
4734 -> 0.0040s
4735-- 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'")
4736 -> 0.0041s
4737-- 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'")
4738 -> 0.0043s
4739-- 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'")
4740 -> 0.0043s
4741== 20200325115329 AddMultipleJobStateIndexesOrderByNewest: migrated (0.0362s) =
4743== 20200325130013 AddFunctionMostRecentJobIdsForUserRepositoriesByStates: migrating
4744-- 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 ")
4745 -> 0.0012s
4746== 20200325130013 AddFunctionMostRecentJobIdsForUserRepositoriesByStates: migrated (0.0014s)
4748== 20200330110527 AddFunctionMostRecentJobIdsForRepositoryByState: migrating ==
4749-- 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 ")
4750 -> 0.0009s
4751== 20200330110527 AddFunctionMostRecentJobIdsForRepositoryByState: migrated (0.0010s)
4753== 20200406121218 AddIndexJobsOnRepositoryIdOrderByNewest: migrating ==========
4754-- execute("CREATE INDEX CONCURRENTLY IF NOT EXISTS index_jobs_on_repository_id_order_by_newest on jobs (repository_id, id desc)")
4755 -> 0.0038s
4756== 20200406121218 AddIndexJobsOnRepositoryIdOrderByNewest: migrated (0.0039s) =
4758== 20200424000000 RequestRawConfigurationsAddMergeMode: migrating =============
4759-- add_column(:request_raw_configurations, :merge_mode, :string, {:default=>nil})
4760 -> 0.0014s
4761-- add_column(:deleted_request_raw_configurations, :merge_mode, :string, {:default=>nil})
4762 -> 0.0019s
4763== 20200424000000 RequestRawConfigurationsAddMergeMode: migrated (0.0034s) ====
4765== 20200527123653 AddColumnPriorityToTableJobsAndDeletedJobs: migrating =======
4766-- add_column(:jobs, :priority, :integer, {:default=>nil})
4767 -> 0.0014s
4768-- add_column(:deleted_jobs, :priority, :integer, {:default=>nil})
4769 -> 0.0014s
4770== 20200527123653 AddColumnPriorityToTableJobsAndDeletedJobs: migrated (0.0030s)
4772== 20200928143126 AddBuildTriggerPermissions: migrating =======================
4773-- add_column(:memberships, :build_permission, :boolean, {:default=>nil})
4774 -> 0.0013s
4775-- add_column(:permissions, :build, :boolean, {:default=>nil})
4776 -> 0.0014s
4777== 20200928143126 AddBuildTriggerPermissions: migrated (0.0029s) ==============
4779== 20202427123653 AddColumnHasLocalRegistrationToTableSubscriptions: migrating
4780-- add_column(:subscriptions, :has_local_registration, :boolean, {:default=>nil})
4781 -> 0.0015s
4782== 20202427123653 AddColumnHasLocalRegistrationToTableSubscriptions: migrated (0.0015s)
4784== 20210203130200 CreateBuildBackupsTable: migrating ==========================
4785-- create_table(:build_backups, {:id=>:integer})
4786 -> 0.0061s
4787== 20210203130200 CreateBuildBackupsTable: migrated (0.0062s) =================
4789== 20210203143155 AddConfirmationFieldsToUser: migrating ======================
4790-- add_column(:users, :confirmed_at, :timestamp, {:precision=>nil})
4791 -> 0.0012s
4792-- add_column(:users, :token_expires_at, :timestamp, {:precision=>nil})
4793 -> 0.0011s
4794-- add_column(:users, :confirmation_token, :string)
4795 -> 0.0011s
4796-- add_index(:users, :confirmation_token)
4797 -> 0.0030s
4798== 20210203143155 AddConfirmationFieldsToUser: migrated (0.0070s) =============
4800== 20210203143406 ConfirmCurrentUsers: migrating ==============================
4801== 20210203143406 ConfirmCurrentUsers: migrated (0.0000s) =====================
4803== 20210614140633 AddServerTypeToRepositories: migrating ======================
4804-- add_column(:repositories, :server_type, :string, {:limit=>20})
4805 -> 0.0010s
4806== 20210614140633 AddServerTypeToRepositories: migrated (0.0010s) =============
4808== 20220610092916 MostRecentJobIdsForUserRepositoriesByStatesLw: migrating ====
4809-- 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 ")
4810 -> 0.0010s
4811== 20220610092916 MostRecentJobIdsForUserRepositoriesByStatesLw: migrated (0.0011s)
4813== 20220621151453 AddColumnRestartedByToTableJobs: migrating ==================
4814-- add_column(:jobs, :restarted_by, :integer, {:default=>nil})
4815 -> 0.0013s
4816-- add_column(:deleted_jobs, :restarted_by, :integer, {:default=>nil})
4817 -> 0.0009s
4818== 20220621151453 AddColumnRestartedByToTableJobs: migrated (0.0023s) =========
4820== 20220722162400 CreateAuditsTable: migrating ================================
4821-- create_table(:audits)
4822 -> 0.0062s
4823== 20220722162400 CreateAuditsTable: migrated (0.0063s) =======================
4825== 20220825140522 CreateCustomKeysTable: migrating ============================
4826-- create_table(:custom_keys)
4827 -> 0.0062s
4828== 20220825140522 CreateCustomKeysTable: migrated (0.0062s) ===================
4830== 20220905144600 AddScanFailedAtToRepositories: migrating ====================
4831-- add_column(:repositories, :scan_failed_at, :timestamp)
4832 -> 0.0010s
4833== 20220905144600 AddScanFailedAtToRepositories: migrated (0.0011s) ===========
4835== 20221214171030 AddPurposeColumnToTokens: migrating =========================
4836-- add_column(:tokens, :purpose, :integer, {:limit=>4, :default=>0})
4837 -> 0.0013s
4838== 20221214171030 AddPurposeColumnToTokens: migrated (0.0013s) ================
4840== 20230208161446 AddCloneUrlToRepositories: migrating ========================
4841-- add_column(:repositories, :clone_url, :string)
4842 -> 0.0101s
4843== 20230208161446 AddCloneUrlToRepositories: migrated (0.0101s) ===============
4845== 20230505055250 RolifyCreateRoles: migrating ================================
4846-- create_table(:roles)
4847 -> 0.0078s
4848-- create_table(:role_names)
4849 -> 0.0052s
4850-- create_table(:users_roles, {:id=>false})
4851 -> 0.0049s
4852-- add_index(:roles, :name)
4853 -> 0.0019s
4854-- add_index(:role_names, :name)
4855 -> 0.0019s
4856-- add_index(:roles, [:name, :resource_type, :resource_id])
4857 -> 0.0019s
4858-- add_index(:users_roles, [:user_id, :role_id])
4859 -> 0.0019s
4860== 20230505055250 RolifyCreateRoles: migrated (0.0258s) =======================
4862== 20230505060110 CreatePolicies: migrating ===================================
4863-- create_table(:policy_permissions)
4864 -> 0.0054s
4865-- create_table(:role_permissions, {:id=>false})
4866 -> 0.0046s
4867-- add_index(:policy_permissions, :name)
4868 -> 0.0017s
4869-- add_index(:role_permissions, [:role_name_id, :policy_permission_id])
4870 -> 0.0018s
4871== 20230505060110 CreatePolicies: migrated (0.0137s) ==========================
4873== 20230713115855 CreatePermissionsSync: migrating ============================
4874-- create_table(:permissions_syncs)
4875 -> 0.0088s
4876== 20230713115855 CreatePermissionsSync: migrated (0.0089s) ===================
4878== 20231005111642 CreatePermissionsIndex: migrating ===========================
4879-- add_index(:permissions_syncs, [:user_id, :resource_type, :resource_id], {:name=>"index_permissions_syncs_on_user_and_resource"})
4880 -> 0.0022s
4881-- add_index(:role_names, :role_type)
4882 -> 0.0018s
4883== 20231005111642 CreatePermissionsIndex: migrated (0.0041s) ==================
4885== 20240823085523 AddVmsizeToJobs: migrating ==================================
4886-- add_column(:jobs, :vm_size, :string)
4887 -> 0.0009s
4888-- add_column(:deleted_jobs, :vm_size, :string)
4889 -> 0.0005s
4890== 20240823085523 AddVmsizeToJobs: migrated (0.0014s) =========================
4892== 20241021074612 AddTrialToCancellations: migrating ==========================
4893-- add_column(:cancellations, :on_trial, :boolean, {:default=>false})
4894 -> 0.0011s
4895== 20241021074612 AddTrialToCancellations: migrated (0.0012s) =================
4897 sets unique_number on INSERT
4898 does not set unique_number on INSERT if 0 is given as a value
4899 sets unique_number on UPDATE
4900 does not set unique_number on UPDATE if unique_number is 0
4902set_updated_at trigger
4903 jobs
4904 sets updated_at on INSERT
4905 sets updated_at on UPDATE
4906 works also for new columns
4907 builds
4908 sets updated_at on INSERT
4909 sets updated_at on UPDATE
4910 works also for new columns
4912soft delete repo
4913 ensure that soft delete tables have the same fields that the originals
4914 soft deleting a repo moves all of the related data to deleted_* tables
4916Rake tasks
4917 rake db:create
4918 migrates the main db
4919 rake db:schema:load
4920 loads the main schema
4922Deprecation Warnings:
4924Using `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)>'.
4927If you need more of the backtrace for any of these deprecations to
4928identify where to make the necessary changes, you can configure
4929`config.raise_errors_for_deprecations!`, and it will turn the
4930deprecation warnings into errors, giving you the full backtrace.
49321 deprecation warning total
4934Finished in 39.2 seconds (files took 0.35851 seconds to load)
493519 examples, 0 failures
4937The command "bundle exec rspec spec" exited with 0.
cache.2
4938store build cache
49390.00s1.44snothing changed
after_success
49410.19s$ script/upload_structure.rb
4942<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)
4943 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'
4944 from script/upload_structure.rb:5:in `<main>'
4946Done. Your build exited with 0.
Top