ros-apartment 2.6.1 → 2.8.1.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (40) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/changelog.yml +63 -0
  3. data/.rubocop.yml +74 -4
  4. data/.rubocop_todo.yml +50 -13
  5. data/.story_branch.yml +1 -0
  6. data/.travis.yml +5 -0
  7. data/CHANGELOG.md +962 -0
  8. data/Gemfile +1 -1
  9. data/Guardfile +0 -15
  10. data/HISTORY.md +159 -68
  11. data/README.md +30 -3
  12. data/Rakefile +4 -2
  13. data/TODO.md +0 -1
  14. data/gemfiles/rails_5_0.gemfile +1 -1
  15. data/gemfiles/rails_5_1.gemfile +1 -1
  16. data/gemfiles/rails_5_2.gemfile +1 -1
  17. data/gemfiles/rails_6_0.gemfile +1 -1
  18. data/gemfiles/rails_master.gemfile +1 -1
  19. data/lib/apartment.rb +13 -12
  20. data/lib/apartment/active_record/connection_handling.rb +3 -0
  21. data/lib/apartment/active_record/internal_metadata.rb +0 -2
  22. data/lib/apartment/active_record/schema_migration.rb +0 -2
  23. data/lib/apartment/adapters/abstract_adapter.rb +3 -4
  24. data/lib/apartment/adapters/abstract_jdbc_adapter.rb +2 -1
  25. data/lib/apartment/adapters/jdbc_postgresql_adapter.rb +2 -1
  26. data/lib/apartment/adapters/mysql2_adapter.rb +5 -0
  27. data/lib/apartment/adapters/postgresql_adapter.rb +34 -7
  28. data/lib/apartment/console.rb +2 -8
  29. data/lib/apartment/custom_console.rb +2 -2
  30. data/lib/apartment/log_subscriber.rb +29 -0
  31. data/lib/apartment/railtie.rb +24 -21
  32. data/lib/apartment/tasks/enhancements.rb +1 -1
  33. data/lib/apartment/tasks/task_helper.rb +40 -0
  34. data/lib/apartment/tenant.rb +3 -16
  35. data/lib/apartment/version.rb +1 -1
  36. data/lib/generators/apartment/install/templates/apartment.rb +7 -1
  37. data/lib/tasks/apartment.rake +18 -46
  38. data/{apartment.gemspec → ros-apartment.gemspec} +3 -4
  39. metadata +17 -14
  40. data/.github/workflows/.rubocop-linter.yml +0 -22
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e57016e050d57190e3baa0693ccd7e2e094db1cdb864f9c75e193ce06fcdddbb
4
- data.tar.gz: 65b587e5c59e03e957e42c8ca0c0cf4d078859e078eebdcda4594e69284c3175
3
+ metadata.gz: f446466c85cecc098b1fec480bd1400bc849ea49ea4f7b5607c1bb3bd46ab6b6
4
+ data.tar.gz: ed713631a71b9b9948f942f25f6cb5dba586a41dcdebe40f14fdef6effccf25c
5
5
  SHA512:
6
- metadata.gz: d1ebfaf0a5e4da01bceed2f3cec330aefec6bbfdb5e98dd706ec7b0305cb8bc820e58106ebb60854fc7f5d8735c02d426c87a17a9f16c4b12f34104059644419
7
- data.tar.gz: 1a72b322cf5913313aedfb1f84d3117c5cbbd5ba36a7b62ab1cf10d2e3987d8eca8b465cfc38538b86482a08fd8412e43e1d39708d3a952e4fad8c946b0b0203
6
+ metadata.gz: a7bf926bd676c7025c1567063b1b97eb01993e7d6f4821ff8e103e9b1057791712a8590247191070764fdbbfd17dc70cc54848fee5c5a7e5379315eda4554cb5
7
+ data.tar.gz: 86375a0c10ce05b3a2e9c217c9c0e574a643725fcba1f98631165d7e8682f9d840d152238d24370ebc55d2713989ff47d633e35fd7c2cdde171443cbcbc3dd07
@@ -0,0 +1,63 @@
1
+ name: Changelog
2
+
3
+ on:
4
+ pull_request:
5
+ types: [closed]
6
+
7
+ release:
8
+ types: [published]
9
+
10
+ issues:
11
+ types: [closed, edited]
12
+
13
+ jobs:
14
+ generate_changelog:
15
+ runs-on: ubuntu-latest
16
+ name: Generate changelog for master branch
17
+ steps:
18
+ - uses: actions/checkout@v2
19
+ with:
20
+ fetch-depth: 0 # otherwise, you will failed to push refs to dest repo
21
+
22
+ - name: Generate changelog
23
+ uses: charmixer/auto-changelog-action@v1
24
+ with:
25
+ token: ${{ secrets.GITHUB_TOKEN }}
26
+
27
+ - name: Commit files
28
+ env:
29
+ ACTION_EMAIL: action@github.com
30
+ ACTION_USERNAME: GitHub Action
31
+ run: |
32
+ git config --local user.email "$ACTION_EMAIL"
33
+ git config --local user.name "$ACTION_USERNAME"
34
+ git add CHANGELOG.md && git commit -m 'Updated CHANGELOG.md' && echo ::set-env name=push::1 || echo "No changes to CHANGELOG.md"
35
+
36
+ - name: Push changes
37
+ if: env.push == 1
38
+ env:
39
+ # CI_USER: ${{ secrets.YOUR_GITHUB_USER }}
40
+ CI_TOKEN: ${{ secrets.CHANGELOG_GITHUB_TOKEN }}
41
+ run: |
42
+ git push "https://$GITHUB_ACTOR:$CI_TOKEN@github.com/$GITHUB_REPOSITORY.git" HEAD:master
43
+
44
+ # - name: Push changelog to master
45
+ # if: env.push == 1
46
+ # uses: ad-m/github-push-action@master
47
+ # with:
48
+ # github_token: ${{ secrets.CHANGELOG_GITHUB_TOKEN }}
49
+ # branch: master
50
+
51
+ # - name: Cherry-pick changelog to development
52
+ # if: env.push == 1
53
+ # env:
54
+ # ACTION_EMAIL: action@github.com
55
+ # ACTION_USERNAME: GitHub Action
56
+ # run: |
57
+ # git config --local user.email "$ACTION_EMAIL"
58
+ # git config --local user.name "$ACTION_USERNAME"
59
+ # commit_hash=`git show HEAD | egrep commit\ .+$ | cut -d' ' -f2`
60
+ # git checkout development
61
+ # git pull
62
+ # git cherry-pick $commit_hash
63
+ # git push
@@ -1,12 +1,9 @@
1
1
  inherit_from: .rubocop_todo.yml
2
2
 
3
- inherit_gem:
4
- perx-rubocop:
5
- - default.yml
6
-
7
3
  AllCops:
8
4
  Exclude:
9
5
  - 'gemfiles/**/*.gemfile'
6
+ - 'gemfiles/vendor/**/*'
10
7
 
11
8
  Style/WordArray:
12
9
  Exclude:
@@ -19,3 +16,76 @@ Style/NumericLiterals:
19
16
  Layout/EmptyLineAfterMagicComment:
20
17
  Exclude:
21
18
  - spec/schemas/**/*.rb
19
+
20
+ Metrics/BlockLength:
21
+ Exclude:
22
+ - spec/**/*.rb
23
+
24
+ Layout/EmptyLinesAroundAttributeAccessor:
25
+ Enabled: true
26
+
27
+ Layout/SpaceAroundMethodCallOperator:
28
+ Enabled: true
29
+
30
+ Lint/DeprecatedOpenSSLConstant:
31
+ Enabled: true
32
+
33
+ Lint/DuplicateElsifCondition:
34
+ Enabled: true
35
+
36
+ Lint/MixedRegexpCaptureTypes:
37
+ Enabled: true
38
+
39
+ Lint/RaiseException:
40
+ Enabled: true
41
+
42
+ Lint/StructNewOverride:
43
+ Enabled: true
44
+
45
+ Style/AccessorGrouping:
46
+ Enabled: true
47
+
48
+ Style/ArrayCoercion:
49
+ Enabled: true
50
+
51
+ Style/BisectedAttrAccessor:
52
+ Enabled: true
53
+
54
+ Style/CaseLikeIf:
55
+ Enabled: true
56
+
57
+ Style/ExponentialNotation:
58
+ Enabled: true
59
+
60
+ Style/HashAsLastArrayItem:
61
+ Enabled: true
62
+
63
+ Style/HashEachMethods:
64
+ Enabled: true
65
+
66
+ Style/HashLikeCase:
67
+ Enabled: true
68
+
69
+ Style/HashTransformKeys:
70
+ Enabled: true
71
+
72
+ Style/HashTransformValues:
73
+ Enabled: true
74
+
75
+ Style/RedundantAssignment:
76
+ Enabled: true
77
+
78
+ Style/RedundantFetchBlock:
79
+ Enabled: true
80
+
81
+ Style/RedundantFileExtensionInRequire:
82
+ Enabled: true
83
+
84
+ Style/RedundantRegexpCharacterClass:
85
+ Enabled: true
86
+
87
+ Style/RedundantRegexpEscape:
88
+ Enabled: true
89
+
90
+ Style/SlicingWithRange:
91
+ Enabled: true
@@ -1,29 +1,66 @@
1
1
  # This configuration was generated by
2
2
  # `rubocop --auto-gen-config`
3
- # on 2020-02-16 15:36:55 +0800 using RuboCop version 0.77.0.
3
+ # on 2020-07-16 04:15:41 UTC using RuboCop version 0.88.0.
4
4
  # The point is for the user to remove these configuration records
5
5
  # one by one as the offenses are removed from the code base.
6
6
  # Note that changes in the inspected code, or installation of new
7
7
  # versions of RuboCop, may require this file to be generated again.
8
8
 
9
- # Offense count: 5
9
+ # Offense count: 1
10
+ Lint/MixedRegexpCaptureTypes:
11
+ Exclude:
12
+ - 'lib/apartment/elevators/domain.rb'
13
+
14
+ # Offense count: 2
15
+ # Cop supports --auto-correct.
16
+ Lint/NonDeterministicRequireOrder:
17
+ Exclude:
18
+ - 'spec/spec_helper.rb'
19
+
20
+ # Offense count: 7
21
+ # Configuration parameters: IgnoredMethods.
10
22
  Metrics/AbcSize:
11
23
  Max: 33
12
24
 
13
- # Offense count: 11
14
- # Configuration parameters: CountComments, ExcludedMethods.
25
+ # Offense count: 3
26
+ # Configuration parameters: CountComments, CountAsOne, ExcludedMethods.
15
27
  # ExcludedMethods: refine
16
28
  Metrics/BlockLength:
17
- Max: 176
29
+ Max: 102
18
30
 
19
- # Offense count: 18
20
- # Cop supports --auto-correct.
21
- # Configuration parameters: AutoCorrect, AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
22
- # URISchemes: http, https
23
- Metrics/LineLength:
24
- Max: 200
31
+ # Offense count: 1
32
+ # Configuration parameters: CountComments, CountAsOne.
33
+ Metrics/ClassLength:
34
+ Max: 151
25
35
 
26
- # Offense count: 4
27
- # Configuration parameters: CountComments, ExcludedMethods.
36
+ # Offense count: 6
37
+ # Configuration parameters: CountComments, CountAsOne, ExcludedMethods.
28
38
  Metrics/MethodLength:
29
39
  Max: 24
40
+
41
+ # Offense count: 17
42
+ Style/Documentation:
43
+ Exclude:
44
+ - 'spec/**/*'
45
+ - 'test/**/*'
46
+ - 'lib/apartment/adapters/jdbc_mysql_adapter.rb'
47
+ - 'lib/apartment/adapters/postgis_adapter.rb'
48
+ - 'lib/apartment/adapters/postgresql_adapter.rb'
49
+ - 'lib/apartment/adapters/sqlite3_adapter.rb'
50
+ - 'lib/apartment/custom_console.rb'
51
+ - 'lib/apartment/deprecation.rb'
52
+ - 'lib/apartment/migrator.rb'
53
+ - 'lib/apartment/model.rb'
54
+ - 'lib/apartment/railtie.rb'
55
+ - 'lib/apartment/reloader.rb'
56
+ - 'lib/apartment/tasks/enhancements.rb'
57
+ - 'lib/apartment/tasks/task_helper.rb'
58
+ - 'lib/generators/apartment/install/install_generator.rb'
59
+
60
+ # Offense count: 3
61
+ # Cop supports --auto-correct.
62
+ Style/IfUnlessModifier:
63
+ Exclude:
64
+ - 'Rakefile'
65
+ - 'lib/apartment.rb'
66
+ - 'lib/apartment/tenant.rb'
@@ -1,4 +1,5 @@
1
1
  ---
2
2
  tracker: github
3
+ issue_placement: beginning
3
4
  project_id:
4
5
  - rails-on-services/apartment
@@ -29,10 +29,15 @@ before_install:
29
29
  - sudo /etc/init.d/mysql stop
30
30
  - sudo /etc/init.d/postgresql stop
31
31
  - docker-compose up -d
32
+
32
33
  env:
33
34
  RUBY_GC_MALLOC_LIMIT: 90000000
34
35
  RUBY_GC_HEAP_FREE_SLOTS: 200000
35
36
  jobs:
37
+ include:
38
+ - name: Rubocop Lint
39
+ script: gem install rubocop
40
+
36
41
  allow_failures:
37
42
  - rvm: ruby-head
38
43
  - rvm: jruby-head
@@ -0,0 +1,962 @@
1
+ # Changelog
2
+
3
+ ## [Unreleased](https://github.com/rails-on-services/apartment/tree/HEAD)
4
+
5
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v2.8.0...HEAD)
6
+
7
+ **Implemented enhancements:**
8
+
9
+ **Fixed bugs:**
10
+
11
+ - New version raises an error with ActiveSupport::LogSubscriber [#128](https://github.com/rails-on-services/apartment/issues/128)
12
+
13
+ **Closed issues:**
14
+
15
+ ## [v2.8.0](https://github.com/rails-on-services/apartment/tree/v2.8.0) (2020-12-16)
16
+
17
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v2.7.2...v2.8.0)
18
+
19
+ **Implemented enhancements:**
20
+
21
+ - Uses a transaction to create a tenant [#66](https://github.com/rails-on-services/apartment/issues/66)
22
+
23
+ **Fixed bugs:**
24
+
25
+ - Fix seeding errors [#86](https://github.com/rails-on-services/apartment/issues/86)
26
+ - When tests run in a transaction, new tenants in tests fail to create [#123](https://github.com/rails-on-services/apartment/issues/123)
27
+ - Reverted unsafe initializer - introduces the possibility of disabling the initial connection to the database via
28
+ environment variable. Relates to the following tickets/PRs:
29
+ - [#113](https://github.com/rails-on-services/apartment/issues/113)
30
+ - [#39](https://github.com/rails-on-services/apartment/pull/39)
31
+ - [#53](https://github.com/rails-on-services/apartment/pull/53)
32
+ - [#118](https://github.com/rails-on-services/apartment/pull/118)
33
+
34
+ **Closed issues:**
35
+
36
+ - Improve changelog automatic generation [#98](https://github.com/rails-on-services/apartment/issues/98)
37
+ - Relaxes dependencies to allow rails 6.1 [#121](https://github.com/rails-on-services/apartment/issues/121)
38
+
39
+
40
+ ## [v2.7.2](https://github.com/rails-on-services/apartment/tree/v2.7.2) (2020-07-17)
41
+
42
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v2.7.1...v2.7.2)
43
+
44
+ **Implemented enhancements:**
45
+
46
+ - Deprecate History.md [\#80](https://github.com/rails-on-services/apartment/issues/80)
47
+
48
+ **Fixed bugs:**
49
+
50
+ - Tenant.switch! raises exception on first call / Postgresql [\#92](https://github.com/rails-on-services/apartment/issues/92)
51
+ - NameError: instance variable @sequence\_name not defined [\#81](https://github.com/rails-on-services/apartment/issues/81)
52
+
53
+ **Closed issues:**
54
+
55
+ - Error creating tenant with uuid column [\#85](https://github.com/rails-on-services/apartment/issues/85)
56
+ - enhanced db:create task breaks plugins compatibility [\#82](https://github.com/rails-on-services/apartment/issues/82)
57
+ - Support disabling of full\_migration\_on\_create [\#30](https://github.com/rails-on-services/apartment/issues/30)
58
+
59
+ **Merged pull requests:**
60
+
61
+ - \[Chore\] Fix Changelog github action [\#97](https://github.com/rails-on-services/apartment/pull/97) ([rpbaltazar](https://github.com/rpbaltazar))
62
+ - Prepare release - 2.7.2 [\#96](https://github.com/rails-on-services/apartment/pull/96) ([rpbaltazar](https://github.com/rpbaltazar))
63
+ - \[Resolves \#92\] tenant switch raises exception on first call [\#95](https://github.com/rails-on-services/apartment/pull/95) ([rpbaltazar](https://github.com/rpbaltazar))
64
+ - Dont use custom rubocop [\#94](https://github.com/rails-on-services/apartment/pull/94) ([rpbaltazar](https://github.com/rpbaltazar))
65
+ - \[Resolves \#80\] added changelog action [\#90](https://github.com/rails-on-services/apartment/pull/90) ([rpbaltazar](https://github.com/rpbaltazar))
66
+ - \[Resolves \#81\] check for var existence before [\#89](https://github.com/rails-on-services/apartment/pull/89) ([rpbaltazar](https://github.com/rpbaltazar))
67
+
68
+ ## [v2.7.1](https://github.com/rails-on-services/apartment/tree/v2.7.1) (2020-06-27)
69
+
70
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v2.7.0...v2.7.1)
71
+
72
+ **Merged pull requests:**
73
+
74
+ - Prepare Release 2.7.1 [\#84](https://github.com/rails-on-services/apartment/pull/84) ([rpbaltazar](https://github.com/rpbaltazar))
75
+ - \[Resolves \#82\] Enhanced db create task breaks plugins compatibility [\#83](https://github.com/rails-on-services/apartment/pull/83) ([rpbaltazar](https://github.com/rpbaltazar))
76
+ - \[ci\] update rake [\#79](https://github.com/rails-on-services/apartment/pull/79) ([ahorek](https://github.com/ahorek))
77
+
78
+ ## [v2.7.0](https://github.com/rails-on-services/apartment/tree/v2.7.0) (2020-06-26)
79
+
80
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v2.6.1...v2.7.0)
81
+
82
+ **Implemented enhancements:**
83
+
84
+ - Rake tasks define methods on main [\#70](https://github.com/rails-on-services/apartment/issues/70)
85
+
86
+ **Fixed bugs:**
87
+
88
+ - Undefined method devise with 2.6.1 [\#65](https://github.com/rails-on-services/apartment/issues/65)
89
+ - db:create is failed [\#61](https://github.com/rails-on-services/apartment/issues/61)
90
+
91
+ **Closed issues:**
92
+
93
+ - configure story branch [\#68](https://github.com/rails-on-services/apartment/issues/68)
94
+ - HISTORY.md has not been updated for latest releases [\#62](https://github.com/rails-on-services/apartment/issues/62)
95
+ - \[Postgresql users\] Help testing development branch in your environment [\#34](https://github.com/rails-on-services/apartment/issues/34)
96
+
97
+ **Merged pull requests:**
98
+
99
+ - Prepare Release - 2.7.0 [\#77](https://github.com/rails-on-services/apartment/pull/77) ([rpbaltazar](https://github.com/rpbaltazar))
100
+ - \[Fixes \#61\] db create is failed [\#76](https://github.com/rails-on-services/apartment/pull/76) ([rpbaltazar](https://github.com/rpbaltazar))
101
+ - \[Resolves \#70\] rake tasks define methods on main [\#75](https://github.com/rails-on-services/apartment/pull/75) ([rpbaltazar](https://github.com/rpbaltazar))
102
+ - \[Chore\] Update travis config to run rubocop [\#74](https://github.com/rails-on-services/apartment/pull/74) ([rpbaltazar](https://github.com/rpbaltazar))
103
+ - Remove and warn depracated config `tld\_length` [\#72](https://github.com/rails-on-services/apartment/pull/72) ([choznerol](https://github.com/choznerol))
104
+ - \[Resolves \#62\] added Missing notes in history.md [\#63](https://github.com/rails-on-services/apartment/pull/63) ([rpbaltazar](https://github.com/rpbaltazar))
105
+ - Add database and schema to active record log [\#55](https://github.com/rails-on-services/apartment/pull/55) ([woohoou](https://github.com/woohoou))
106
+
107
+ ## [v2.6.1](https://github.com/rails-on-services/apartment/tree/v2.6.1) (2020-06-02)
108
+
109
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v2.6.0...v2.6.1)
110
+
111
+ **Closed issues:**
112
+
113
+ - db:rollback uses second latest migration for tenants [\#56](https://github.com/rails-on-services/apartment/issues/56)
114
+ - rake db:setup tries to seed non existing tenant [\#52](https://github.com/rails-on-services/apartment/issues/52)
115
+ - Custom Console deprecation warning [\#37](https://github.com/rails-on-services/apartment/issues/37)
116
+
117
+ **Merged pull requests:**
118
+
119
+ - Version bump - 2.6.1 [\#60](https://github.com/rails-on-services/apartment/pull/60) ([rpbaltazar](https://github.com/rpbaltazar))
120
+ - Prepare Release - 2.6.1 [\#59](https://github.com/rails-on-services/apartment/pull/59) ([rpbaltazar](https://github.com/rpbaltazar))
121
+ - \[\#56\] Db rollback uses second latest migration [\#57](https://github.com/rails-on-services/apartment/pull/57) ([rpbaltazar](https://github.com/rpbaltazar))
122
+ - \[\#52\] enhance after db create [\#54](https://github.com/rails-on-services/apartment/pull/54) ([rpbaltazar](https://github.com/rpbaltazar))
123
+ - fix init after reload on development [\#53](https://github.com/rails-on-services/apartment/pull/53) ([fsateler](https://github.com/fsateler))
124
+ - fix: reset sequence\_name after tenant switch [\#51](https://github.com/rails-on-services/apartment/pull/51) ([fsateler](https://github.com/fsateler))
125
+ - Avoid early connection [\#39](https://github.com/rails-on-services/apartment/pull/39) ([fsateler](https://github.com/fsateler))
126
+
127
+ ## [v2.6.0](https://github.com/rails-on-services/apartment/tree/v2.6.0) (2020-05-14)
128
+
129
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v2.5.0...v2.6.0)
130
+
131
+ **Closed issues:**
132
+
133
+ - Error Dropping Tenant [\#46](https://github.com/rails-on-services/apartment/issues/46)
134
+ - After switch callback not working with nil argument [\#42](https://github.com/rails-on-services/apartment/issues/42)
135
+ - Add tenant info to console boot? [\#41](https://github.com/rails-on-services/apartment/issues/41)
136
+ - Support configuration for skip checking of schema existence before switching [\#26](https://github.com/rails-on-services/apartment/issues/26)
137
+
138
+ **Merged pull requests:**
139
+
140
+ - \[Resolves \#37\] Custom console deprecation warning [\#49](https://github.com/rails-on-services/apartment/pull/49) ([rpbaltazar](https://github.com/rpbaltazar))
141
+ - Prepare Release 2.6.0 [\#48](https://github.com/rails-on-services/apartment/pull/48) ([rpbaltazar](https://github.com/rpbaltazar))
142
+ - Add console welcome message [\#47](https://github.com/rails-on-services/apartment/pull/47) ([JeremiahChurch](https://github.com/JeremiahChurch))
143
+ - \[Resolves \#26\] Support configuration for skip checking of schema existence before switching [\#45](https://github.com/rails-on-services/apartment/pull/45) ([rpbaltazar](https://github.com/rpbaltazar))
144
+ - \[Resolves \#42\] After switch callback not working with nil argument [\#43](https://github.com/rails-on-services/apartment/pull/43) ([rpbaltazar](https://github.com/rpbaltazar))
145
+
146
+ ## [v2.5.0](https://github.com/rails-on-services/apartment/tree/v2.5.0) (2020-05-05)
147
+
148
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/2.4.0...v2.5.0)
149
+
150
+ **Implemented enhancements:**
151
+
152
+ - Add latest ruby verisons to test matrix [\#31](https://github.com/rails-on-services/apartment/issues/31)
153
+ - Deprecate EOL ruby and rails versions [\#11](https://github.com/rails-on-services/apartment/issues/11)
154
+
155
+ **Fixed bugs:**
156
+
157
+ - When manually switching the connection it resets the search path [\#27](https://github.com/rails-on-services/apartment/issues/27)
158
+
159
+ **Closed issues:**
160
+
161
+ - Cached statement breaks in find [\#35](https://github.com/rails-on-services/apartment/issues/35)
162
+ - rails 6.1.alpha support [\#6](https://github.com/rails-on-services/apartment/issues/6)
163
+ - How to exclude all models from engine? [\#4](https://github.com/rails-on-services/apartment/issues/4)
164
+
165
+ **Merged pull requests:**
166
+
167
+ - Prepare Release 2.5.0 [\#44](https://github.com/rails-on-services/apartment/pull/44) ([rpbaltazar](https://github.com/rpbaltazar))
168
+ - \[Resolves \#27\] Added before hook to connected to to try to set the tenant [\#40](https://github.com/rails-on-services/apartment/pull/40) ([rpbaltazar](https://github.com/rpbaltazar))
169
+ - \[Resolves \#35\] update cache key to use a string or an array [\#36](https://github.com/rails-on-services/apartment/pull/36) ([rpbaltazar](https://github.com/rpbaltazar))
170
+ - \[Hotfix \#27\] Some errors were being thrown due to caching issues [\#33](https://github.com/rails-on-services/apartment/pull/33) ([rpbaltazar](https://github.com/rpbaltazar))
171
+ - \[Resolves \#31\] Add latest ruby verisons to test matrix [\#32](https://github.com/rails-on-services/apartment/pull/32) ([rpbaltazar](https://github.com/rpbaltazar))
172
+ - \[Chore\] refactored files to their names [\#29](https://github.com/rails-on-services/apartment/pull/29) ([rpbaltazar](https://github.com/rpbaltazar))
173
+ - \[Resolves \#27\] When manually switching the connection it resets the search path [\#28](https://github.com/rails-on-services/apartment/pull/28) ([rpbaltazar](https://github.com/rpbaltazar))
174
+ - \[Resolves \#11\] Remove old ruby and rails versions from the supported versions [\#20](https://github.com/rails-on-services/apartment/pull/20) ([rpbaltazar](https://github.com/rpbaltazar))
175
+ - Support rails 6.1 [\#7](https://github.com/rails-on-services/apartment/pull/7) ([jean-francois-labbe](https://github.com/jean-francois-labbe))
176
+
177
+ ## [2.4.0](https://github.com/rails-on-services/apartment/tree/2.4.0) (2020-04-01)
178
+
179
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v2.3.0...2.4.0)
180
+
181
+ **Implemented enhancements:**
182
+
183
+ - Add console info about tenants and fast switches [\#14](https://github.com/rails-on-services/apartment/issues/14)
184
+ - Update travis config to only run PR's instead of running all commits [\#12](https://github.com/rails-on-services/apartment/issues/12)
185
+
186
+ **Closed issues:**
187
+
188
+ - Rubocop cleanup [\#9](https://github.com/rails-on-services/apartment/issues/9)
189
+ - Apartment.configure throws NoMethodError [\#3](https://github.com/rails-on-services/apartment/issues/3)
190
+ - upcoming Rails 6 multi-database [\#2](https://github.com/rails-on-services/apartment/issues/2)
191
+
192
+ **Merged pull requests:**
193
+
194
+ - Fix gemspec open versions and updated version [\#25](https://github.com/rails-on-services/apartment/pull/25) ([rpbaltazar](https://github.com/rpbaltazar))
195
+ - Fix gemspec open versions and updated version [\#24](https://github.com/rails-on-services/apartment/pull/24) ([rpbaltazar](https://github.com/rpbaltazar))
196
+ - Cleanup travis matrix [\#23](https://github.com/rails-on-services/apartment/pull/23) ([rpbaltazar](https://github.com/rpbaltazar))
197
+ - Prepare v2.4.0 Release [\#22](https://github.com/rails-on-services/apartment/pull/22) ([rpbaltazar](https://github.com/rpbaltazar))
198
+ - Updated readme badges [\#21](https://github.com/rails-on-services/apartment/pull/21) ([rpbaltazar](https://github.com/rpbaltazar))
199
+ - Rescuing ActiveRecord::NoDatabaseError when dropping tenants [\#19](https://github.com/rails-on-services/apartment/pull/19) ([rpbaltazar](https://github.com/rpbaltazar))
200
+ - Skip init if we're running webpacker:compile [\#18](https://github.com/rails-on-services/apartment/pull/18) ([rpbaltazar](https://github.com/rpbaltazar))
201
+ - \[Resolves \#14\] Add console info about tenants and fast switches [\#17](https://github.com/rails-on-services/apartment/pull/17) ([rpbaltazar](https://github.com/rpbaltazar))
202
+ - Don't crash when no database connection is present [\#16](https://github.com/rails-on-services/apartment/pull/16) ([ArthurWD](https://github.com/ArthurWD))
203
+ - \[Resolves \#12\] Update travis config to only run PRs instead of all commits [\#13](https://github.com/rails-on-services/apartment/pull/13) ([rpbaltazar](https://github.com/rpbaltazar))
204
+ - \[Chore\] Fix rubocop usage [\#10](https://github.com/rails-on-services/apartment/pull/10) ([rpbaltazar](https://github.com/rpbaltazar))
205
+ - \[Resolves \#9\] Cleanup rubocop todo [\#8](https://github.com/rails-on-services/apartment/pull/8) ([rpbaltazar](https://github.com/rpbaltazar))
206
+ - Rakefile should use mysql port from configuration [\#5](https://github.com/rails-on-services/apartment/pull/5) ([jean-francois-labbe](https://github.com/jean-francois-labbe))
207
+
208
+ ## [v2.3.0](https://github.com/rails-on-services/apartment/tree/v2.3.0) (2020-01-03)
209
+
210
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v2.2.1...v2.3.0)
211
+
212
+ **Merged pull requests:**
213
+
214
+ - \[Resolves\] Basic support for Rails 6 [\#1](https://github.com/rails-on-services/apartment/pull/1) ([rpbaltazar](https://github.com/rpbaltazar))
215
+
216
+ ## [v2.2.1](https://github.com/rails-on-services/apartment/tree/v2.2.1) (2019-06-19)
217
+
218
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v2.2.0...v2.2.1)
219
+
220
+ ## [v2.2.0](https://github.com/rails-on-services/apartment/tree/v2.2.0) (2018-04-13)
221
+
222
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v2.1.0...v2.2.0)
223
+
224
+ ## [v2.1.0](https://github.com/rails-on-services/apartment/tree/v2.1.0) (2017-12-15)
225
+
226
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v2.0.0...v2.1.0)
227
+
228
+ ## [v2.0.0](https://github.com/rails-on-services/apartment/tree/v2.0.0) (2017-07-26)
229
+
230
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v1.2.0...v2.0.0)
231
+
232
+ ## [v1.2.0](https://github.com/rails-on-services/apartment/tree/v1.2.0) (2016-07-28)
233
+
234
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v1.1.0...v1.2.0)
235
+
236
+ ## [v1.1.0](https://github.com/rails-on-services/apartment/tree/v1.1.0) (2016-05-26)
237
+
238
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v1.0.2...v1.1.0)
239
+
240
+ ## [v1.0.2](https://github.com/rails-on-services/apartment/tree/v1.0.2) (2015-07-02)
241
+
242
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v1.0.1...v1.0.2)
243
+
244
+ ## [v1.0.1](https://github.com/rails-on-services/apartment/tree/v1.0.1) (2015-04-28)
245
+
246
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v1.0.0...v1.0.1)
247
+
248
+ ## [v1.0.0](https://github.com/rails-on-services/apartment/tree/v1.0.0) (2015-02-03)
249
+
250
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.26.1...v1.0.0)
251
+
252
+ ## [v0.26.1](https://github.com/rails-on-services/apartment/tree/v0.26.1) (2015-01-13)
253
+
254
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.26.0...v0.26.1)
255
+
256
+ ## [v0.26.0](https://github.com/rails-on-services/apartment/tree/v0.26.0) (2015-01-05)
257
+
258
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.25.2...v0.26.0)
259
+
260
+ ## [v0.25.2](https://github.com/rails-on-services/apartment/tree/v0.25.2) (2014-09-08)
261
+
262
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.25.1...v0.25.2)
263
+
264
+ ## [v0.25.1](https://github.com/rails-on-services/apartment/tree/v0.25.1) (2014-07-17)
265
+
266
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.25.0...v0.25.1)
267
+
268
+ ## [v0.25.0](https://github.com/rails-on-services/apartment/tree/v0.25.0) (2014-07-03)
269
+
270
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.24.3...v0.25.0)
271
+
272
+ ## [v0.24.3](https://github.com/rails-on-services/apartment/tree/v0.24.3) (2014-03-05)
273
+
274
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.24.2...v0.24.3)
275
+
276
+ ## [v0.24.2](https://github.com/rails-on-services/apartment/tree/v0.24.2) (2014-02-24)
277
+
278
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.24.1...v0.24.2)
279
+
280
+ ## [v0.24.1](https://github.com/rails-on-services/apartment/tree/v0.24.1) (2014-02-21)
281
+
282
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.24.0...v0.24.1)
283
+
284
+ ## [v0.24.0](https://github.com/rails-on-services/apartment/tree/v0.24.0) (2014-02-21)
285
+
286
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.23.2...v0.24.0)
287
+
288
+ ## [v0.23.2](https://github.com/rails-on-services/apartment/tree/v0.23.2) (2014-01-09)
289
+
290
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.23.1...v0.23.2)
291
+
292
+ ## [v0.23.1](https://github.com/rails-on-services/apartment/tree/v0.23.1) (2014-01-08)
293
+
294
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.23.0...v0.23.1)
295
+
296
+ ## [v0.23.0](https://github.com/rails-on-services/apartment/tree/v0.23.0) (2013-12-15)
297
+
298
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.22.1...v0.23.0)
299
+
300
+ ## [v0.22.1](https://github.com/rails-on-services/apartment/tree/v0.22.1) (2013-08-21)
301
+
302
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.22.0...v0.22.1)
303
+
304
+ ## [v0.22.0](https://github.com/rails-on-services/apartment/tree/v0.22.0) (2013-07-09)
305
+
306
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.21.1...v0.22.0)
307
+
308
+ ## [v0.21.1](https://github.com/rails-on-services/apartment/tree/v0.21.1) (2013-05-31)
309
+
310
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.21.0...v0.21.1)
311
+
312
+ ## [v0.21.0](https://github.com/rails-on-services/apartment/tree/v0.21.0) (2013-04-25)
313
+
314
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.20.0...v0.21.0)
315
+
316
+ ## [v0.20.0](https://github.com/rails-on-services/apartment/tree/v0.20.0) (2013-02-06)
317
+
318
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/rm...v0.20.0)
319
+
320
+ ## [rm](https://github.com/rails-on-services/apartment/tree/rm) (2013-01-30)
321
+
322
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.19.2...rm)
323
+
324
+ ## [v0.19.2](https://github.com/rails-on-services/apartment/tree/v0.19.2) (2013-01-30)
325
+
326
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.19.0...v0.19.2)
327
+
328
+ ## [v0.19.0](https://github.com/rails-on-services/apartment/tree/v0.19.0) (2012-12-30)
329
+
330
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.18.0...v0.19.0)
331
+
332
+ ## [v0.18.0](https://github.com/rails-on-services/apartment/tree/v0.18.0) (2012-11-28)
333
+
334
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.17.3...v0.18.0)
335
+
336
+ ## [v0.17.3](https://github.com/rails-on-services/apartment/tree/v0.17.3) (2012-11-20)
337
+
338
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.17.2...v0.17.3)
339
+
340
+ ## [v0.17.2](https://github.com/rails-on-services/apartment/tree/v0.17.2) (2012-11-15)
341
+
342
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.17.1...v0.17.2)
343
+
344
+ ## [v0.17.1](https://github.com/rails-on-services/apartment/tree/v0.17.1) (2012-10-30)
345
+
346
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.17.0...v0.17.1)
347
+
348
+ ## [v0.17.0](https://github.com/rails-on-services/apartment/tree/v0.17.0) (2012-09-26)
349
+
350
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.16.0...v0.17.0)
351
+
352
+ ## [v0.16.0](https://github.com/rails-on-services/apartment/tree/v0.16.0) (2012-06-01)
353
+
354
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.15.0...v0.16.0)
355
+
356
+ ## [v0.15.0](https://github.com/rails-on-services/apartment/tree/v0.15.0) (2012-03-18)
357
+
358
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.14.4...v0.15.0)
359
+
360
+ ## [v0.14.4](https://github.com/rails-on-services/apartment/tree/v0.14.4) (2012-03-08)
361
+
362
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.14.3...v0.14.4)
363
+
364
+ ## [v0.14.3](https://github.com/rails-on-services/apartment/tree/v0.14.3) (2012-02-21)
365
+
366
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.14.2...v0.14.3)
367
+
368
+ ## [v0.14.2](https://github.com/rails-on-services/apartment/tree/v0.14.2) (2012-02-21)
369
+
370
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.13.0.1...v0.14.2)
371
+
372
+ ## [v0.13.0.1](https://github.com/rails-on-services/apartment/tree/v0.13.0.1) (2012-02-09)
373
+
374
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.14.1...v0.13.0.1)
375
+
376
+ ## [v0.14.1](https://github.com/rails-on-services/apartment/tree/v0.14.1) (2011-12-13)
377
+
378
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.14.0...v0.14.1)
379
+
380
+ ## [v0.14.0](https://github.com/rails-on-services/apartment/tree/v0.14.0) (2011-12-13)
381
+
382
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.13.1...v0.14.0)
383
+
384
+ ## [v0.13.1](https://github.com/rails-on-services/apartment/tree/v0.13.1) (2011-11-08)
385
+
386
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.13.0...v0.13.1)
387
+
388
+ ## [v0.13.0](https://github.com/rails-on-services/apartment/tree/v0.13.0) (2011-10-25)
389
+
390
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.12.0...v0.13.0)
391
+
392
+ ## [v0.12.0](https://github.com/rails-on-services/apartment/tree/v0.12.0) (2011-10-04)
393
+
394
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.11.1...v0.12.0)
395
+
396
+ ## [v0.11.1](https://github.com/rails-on-services/apartment/tree/v0.11.1) (2011-09-22)
397
+
398
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.11.0...v0.11.1)
399
+
400
+ ## [v0.11.0](https://github.com/rails-on-services/apartment/tree/v0.11.0) (2011-09-20)
401
+
402
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.10.3...v0.11.0)
403
+
404
+ ## [v0.10.3](https://github.com/rails-on-services/apartment/tree/v0.10.3) (2011-09-20)
405
+
406
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.10.2...v0.10.3)
407
+
408
+ ## [v0.10.2](https://github.com/rails-on-services/apartment/tree/v0.10.2) (2011-09-15)
409
+
410
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.10.1...v0.10.2)
411
+
412
+ ## [v0.10.1](https://github.com/rails-on-services/apartment/tree/v0.10.1) (2011-08-11)
413
+
414
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.10.0...v0.10.1)
415
+
416
+ ## [v0.10.0](https://github.com/rails-on-services/apartment/tree/v0.10.0) (2011-07-29)
417
+
418
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.9.2...v0.10.0)
419
+
420
+ ## [v0.9.2](https://github.com/rails-on-services/apartment/tree/v0.9.2) (2011-07-04)
421
+
422
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.9.1...v0.9.2)
423
+
424
+ ## [v0.9.1](https://github.com/rails-on-services/apartment/tree/v0.9.1) (2011-06-24)
425
+
426
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.9.0...v0.9.1)
427
+
428
+ ## [v0.9.0](https://github.com/rails-on-services/apartment/tree/v0.9.0) (2011-06-23)
429
+
430
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.8.0...v0.9.0)
431
+
432
+ ## [v0.8.0](https://github.com/rails-on-services/apartment/tree/v0.8.0) (2011-06-23)
433
+
434
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.7.0...v0.8.0)
435
+
436
+ ## [v0.7.0](https://github.com/rails-on-services/apartment/tree/v0.7.0) (2011-06-22)
437
+
438
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.6.0...v0.7.0)
439
+
440
+ ## [v0.6.0](https://github.com/rails-on-services/apartment/tree/v0.6.0) (2011-06-21)
441
+
442
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/0.6.0...v0.6.0)
443
+
444
+ ## [0.6.0](https://github.com/rails-on-services/apartment/tree/0.6.0) (2011-06-21)
445
+
446
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.5.1...0.6.0)
447
+
448
+ ## [v0.5.1](https://github.com/rails-on-services/apartment/tree/v0.5.1) (2011-06-21)
449
+
450
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/0.5.0...v0.5.1)
451
+
452
+ ## [0.5.0](https://github.com/rails-on-services/apartment/tree/0.5.0) (2011-06-20)
453
+
454
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.5.0...0.5.0)
455
+
456
+ ## [v0.5.0](https://github.com/rails-on-services/apartment/tree/v0.5.0) (2011-06-20)
457
+
458
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/v0.1.3...v0.5.0)
459
+
460
+ ## [v0.1.3](https://github.com/rails-on-services/apartment/tree/v0.1.3) (2011-04-18)
461
+
462
+ [Full Changelog](https://github.com/rails-on-services/apartment/compare/7100f34a185ab7d48947f06aa8c14f0cf0a68bb7...v0.1.3)
463
+
464
+ # v2.7.1
465
+
466
+ **Implemented enhancements:**
467
+
468
+ - N/a
469
+
470
+ **Fixed bugs:**
471
+
472
+ - [Resolves #82] Enhanced db:create breaks plugin compatibility - <https://github.com/rails-on-services/apartment/pull/83>
473
+
474
+ **Closed issues:**
475
+
476
+ - Update rake version in development
477
+ - Renamed gemspec to match gem name
478
+
479
+ # v2.7.0
480
+
481
+ **Implemented enhancements:**
482
+
483
+ - [Resolves #70] Rake tasks define methods on main - <https://github.com/rails-on-services/apartment/pull/75>
484
+ - Add database and schema to active record log. Configurable, defaults to false to keep current behavior - <https://github.com/rails-on-services/apartment/pull/55>
485
+
486
+ **Fixed bugs:**
487
+
488
+ - [Fixes #61] Fix database create in mysql - <https://github.com/rails-on-services/apartment/pull/76>
489
+
490
+ **Closed issues:**
491
+
492
+ - Remove deprecated tld_length config option: tld_length was removed in influitive#309, this configuration option doesn't have any effect now. - <https://github.com/rails-on-services/apartment/pull/72>
493
+ - Using [diffend.io proxy](https://diffend.io) to safely check required gems
494
+ - Added [story branch](https://github.com/story-branch/story_branch) to the configuration
495
+ - Using travis-ci to run rubocop as well, replacing github actions: github actions do not work in fork's PRs
496
+
497
+ # v2.6.1
498
+
499
+ **Implemented enhancements:**
500
+ - N/a
501
+
502
+ **Fixed bugs:**
503
+ - [Resolves influitive#607] Avoid early connection
504
+ - <https://github.com/rails-on-services/apartment/pull/39>
505
+ - <https://github.com/rails-on-services/apartment/pull/53>
506
+ - <https://github.com/rails-on-services/apartment/pull/51>
507
+ - [Resolves #52] Rake db:setup tries to seed non existent tenant - <https://github.com/rails-on-services/apartment/pull/54>
508
+ - [Resolves #56] DB rollback uses second last migration - <https://github.com/rails-on-services/apartment/pull/57>
509
+
510
+ #**Closed issues:**
511
+ - N/a
512
+
513
+ # v2.6.0
514
+
515
+ **Implemented enhancements:**
516
+ - [Resolves #26] Support configuration for skip checking of schema existence before switching
517
+ - [Resolves #41] Add tenant info to console boot
518
+
519
+ **Fixed bugs:**
520
+ - [Resolves #37] Custom Console deprecation warning
521
+ - [Resolves #42] After switch callback not working with nil argument
522
+
523
+ #**Closed issues:**
524
+ - Updated github actions configuration to run on PRs as well
525
+
526
+ # v2.5.0
527
+
528
+ **Implemented enhancements:**
529
+ - [Resolves #6] Adds support for rails 6.1
530
+ - [Resolves #27] Adds support to not rely on set search path, but instead prepends the schema name to the table name when using postgresql with schemas.
531
+ - [Resolves #35] Cache keys are now tenant dependent
532
+
533
+ **Fixed bugs:**
534
+ - [Resolves #27] Manually switching connection between read and write forgets the schema
535
+
536
+ #**Closed issues:**
537
+ - [Resolves #31] Add latest ruby versions to test matrix
538
+
539
+ # v2.4.0
540
+
541
+ **Implemented enhancements:**
542
+ - [Resolves #14] Add console info about tenants and fast switches #17
543
+ - Skip init if we're running webpacker:compile #18
544
+
545
+ **Fixed bugs:**
546
+ - Don't crash when no database connection is present #16
547
+ - Rescuing ActiveRecord::NoDatabaseError when dropping tenants #19
548
+
549
+ #**Closed issues:**
550
+ - Rakefile should use mysql port from configuration #5
551
+ - [Resolves #9] Cleanup rubocop todo #8
552
+ - Cleanup travis matrix #23
553
+
554
+ # v2.3.0
555
+ * January 3, 2020
556
+
557
+ **Implemented enhancements:**
558
+ - Basic support for rails 6
559
+ - Released different gem name, with same API as apartment
560
+
561
+ # v2.2.1
562
+ * June 19, 2019
563
+
564
+ **Implemented enhancements:**
565
+ - #566: IGNORE_EMPTY_TENANTS environment variable to ignore empty tenants
566
+ warning. [Pysis868]
567
+
568
+ **Fixed bugs:**
569
+ - #586: Ignore `CREATE SCHEMA public` statement in pg dump [artemave]
570
+ - #549: Fix Postgres schema creation with dump SQL [ancorcruz]
571
+
572
+ # v2.2.0
573
+ * April 14, 2018
574
+
575
+ **Implemented enhancements:**
576
+ - #523: Add Rails 5.2 support [IngusSkaistkalns]
577
+ - #504: Test against Ruby 2.5.0 [ahorek]
578
+ - #528: Test against Rails 5.2 [meganemura]
579
+
580
+ **Removed:**
581
+ - #504: Remove Rails 4.0/4.1 support [ahorek]
582
+ - #545: Stop supporting for JRuby + Rails 5.0 [meganemura]
583
+
584
+ **Fixed bugs:**
585
+ - #537: Fix PostgresqlSchemaFromSqlAdapter for newer PostgreSQL [shterrett]
586
+ - #532: Issue is reported by [aldrinmartoq]
587
+ - #519: Fix exception when main database doesn't exist [mayeco]
588
+
589
+ **Closed issues:**
590
+
591
+ - #514: Fix typo [menorval]
592
+
593
+ # v2.1.0
594
+ * December 15, 2017
595
+
596
+ - Add `parallel_migration_threads` configuration option for running migrations
597
+ in parallel [ryanbrunner]
598
+ - Drop Ruby 2.0.0 support [meganemura]
599
+ - ignore_private when parsing subdomains with PublicSuffix [michiomochi]
600
+ - Ignore row_security statements in psql dumps for backward compatibility
601
+ [meganemura]
602
+ - "Host" elevator [shrmnk]
603
+ - Enhance db:drop task to act on all tenants [kuzukuzu]
604
+
605
+ # v2.0.0
606
+ * July 26, 2017
607
+
608
+ - Raise FileNotFound rather than abort when loading files [meganemura]
609
+ - Add 5.1 support with fixes for deprecations [meganemura]
610
+ - Fix tests for 5.x and a host of dev-friendly improvements [meganemura]
611
+ - Keep query cache config after switching databases [fernandomm]
612
+ - Pass constants not strings to middleware stack (Rails 5) [tzabaman]
613
+ - Remove deprecations from 1.0.0 [caironoleto]
614
+ - Replace `tld_length` configuration option with PublicSuffix gem for the
615
+ subdomain elevator [humancopy]
616
+ - Pass full config to create_database to allow :encoding/:collation/etc
617
+ [kakipo]
618
+ - Don't retain a connection during initialization [mikecmpbll]
619
+ - Fix database name escaping in drop_command [mikecmpbll]
620
+ - Skip initialization for assets:clean and assets:precompile tasks
621
+ [frank-west-iii]
622
+
623
+ # v1.2.0
624
+ * July 28, 2016
625
+
626
+ - Official Rails 5 support
627
+
628
+ # v1.1.0
629
+ * May 26, 2016
630
+
631
+ - Reset tenant after each request
632
+ - [Support callbacks](https://github.com/influitive/apartment/commit/ff9c9d092a781026502f5997c0bbedcb5748bc83) on switch [cbeer]
633
+ - Preliminary support for [separate database hosts](https://github.com/influitive/apartment/commit/abdffbf8cd9fba87243f16c86390da13e318ee1f) [apneadiving]
634
+
635
+ # v1.0.2
636
+ * July 2, 2015
637
+
638
+ - Fix pg_dump env vars - pull/208 [MitinPavel]
639
+ - Allow custom seed data file - pull/234 [typeoneerror]
640
+
641
+ # v1.0.1
642
+ * April 28, 2015
643
+
644
+ - Fix `Apartment::Deprecation` which was rescuing all exceptions
645
+
646
+ # v1.0.0
647
+ * Feb 3, 2015
648
+
649
+ - [BREAKING CHANGE] `Apartment::Tenant.process` is deprecated in favour of `Apartment::Tenant.switch`
650
+ - [BREAKING CHANGE] `Apartment::Tenant.switch` without a block is deprecated in favour of `Apartment::Tenant.switch!`
651
+ - Raise proper `TenantNotFound`, `TenantExists` exceptions
652
+ - Deprecate old `SchemaNotFound`, `DatabaseNotFound` exceptions
653
+
654
+ # v0.26.1
655
+ * Jan 13, 2015
656
+
657
+ - Fixed [schema quoting bug](https://github.com/influitive/apartment/issues/198#issuecomment-69782651) [jonsgreen]
658
+
659
+ # v0.26.0
660
+ * Jan 5, 2015
661
+
662
+ - Rails 4.2 support
663
+
664
+ # v0.25.2
665
+ * Sept 8, 2014
666
+
667
+ - Heroku fix on `assets:precompile` - pull/169 [rabbitt]
668
+
669
+ # v0.25.1
670
+ * July 17, 2014
671
+
672
+ - Fixed a few vestiges of Apartment::Database
673
+
674
+ # v0.25.0
675
+ * July 3, 2014
676
+
677
+ - [BREAKING CHANGE] - `Apartment::Database` is not deprecated in favour of
678
+ `Apartment::Tenant`
679
+ - ActiveRecord (and Rails) 4.1 now supported
680
+ - A new sql based adapter that dumps the schema using sql
681
+
682
+ # v0.24.3
683
+ * March 5, 2014
684
+
685
+ - Rake enhancements weren't removed from the generator template
686
+
687
+ # v0.24.2
688
+ * February 24, 2014
689
+
690
+ - Better warnings if `apartment:migrate` is run
691
+
692
+ # v0.24.1
693
+ * February 21, 2014
694
+
695
+ - requiring `apartment/tasks/enhancements` in an initializer doesn't work
696
+ - One can disable tenant migrations using `Apartment.db_migrate_tenants = false` in the Rakefile
697
+
698
+ # v0.24
699
+ * February 21, 2014 (In honour of the Women's Gold Medal in Hockey at Sochi)
700
+
701
+ - [BREAKING CHANGE] `apartment:migrate` task no longer depends on `db:migrate`
702
+ - Instead, you can `require 'apartment/tasks/enhancements'` in your Apartment initializer
703
+ - This will enhance `rake db:migrate` to also run `apartment:migrate`
704
+ - You can now forget about ever running `apartment:migrate` again
705
+ - Numerous deprecations for things referencing the word 'database'
706
+ - This is an ongoing effort to completely replace 'database' with 'tenant' as a better abstraction
707
+ - Note the obvious `Apartment::Database` still exists but will hopefully become `Apartment::Tenant` soon
708
+
709
+ # v0.23.2
710
+ * January 9, 2014
711
+
712
+ - Increased visibility of #parse_database_name warning
713
+
714
+ # v0.23.1
715
+ * January 8, 2014
716
+
717
+ - Schema adapters now initialize with default and persistent schemas
718
+ - Deprecated Apartment::Elevators#parse_database_name
719
+
720
+ # v0.23.0
721
+ * August 21, 2013
722
+
723
+ - Subdomain Elevator now allows for exclusions
724
+ - Delayed::Job has been completely removed
725
+
726
+ # v0.22.1
727
+ * August 21, 2013
728
+
729
+ - Fix bug where if your ruby process importing the database schema is run
730
+ from a directory other than the app root, Apartment wouldn't know what
731
+ schema_migrations to insert into the database (Rails only)
732
+
733
+ # v0.22.0
734
+ * June 9, 2013
735
+
736
+ - Numerous bug fixes:
737
+ - Mysql reset could connect to wrong database [eric88]
738
+ - Postgresql schema names weren't quoted properly [gdott9]
739
+ - Fixed error message on SchemaNotFound in `process`
740
+ - HostHash elevator allows mapping host based on hash contents [gdott9]
741
+ - Official Sidekiq support with the [apartment-sidekiq gem](https://github.com/influitive/apartment-sidekiq)
742
+
743
+
744
+ # v0.21.1
745
+ * May 31, 2013
746
+
747
+ - Clearing the AR::QueryCache after switching databases.
748
+ - Fixes issue with stale model being loaded for schema adapters
749
+
750
+ # v0.21.0
751
+ * April 24, 2013
752
+
753
+ - JDBC support!! [PetrolMan]
754
+
755
+ # v0.20.0
756
+ * Feb 6, 2013
757
+
758
+ - Mysql now has a 'schema like' option to perform like Postgresql (default)
759
+ - This should be significantly more performant than using connections
760
+ - Psych is now supported for Delayed::Job yaml parsing
761
+
762
+ # v0.19.2
763
+ * Jan 30, 2013
764
+
765
+ - Database schema file can now be set manually or skipped altogether
766
+
767
+ # v0.19.1
768
+ * Jan 30, 2013
769
+
770
+ - Allow schema.rb import file to be specified in config or skip schema.rb import altogether
771
+
772
+ # v0.19.0
773
+ * Dec 29, 2012
774
+
775
+ - Apartment is now threadsafe
776
+ - New postgis adapter [zonpantli]
777
+ - Removed ActionDispatch dependency for use with Rack apps (regression)
778
+
779
+ # v0.18.0
780
+ * Nov 27, 2012
781
+
782
+ - Added `append_environment` config option [virtualstaticvoid]
783
+ - Cleaned up the readme and generator documentation
784
+ - Added `connection_class` config option [smashtank]
785
+ - Fixed a [bug](https://github.com/influitive/apartment/issues/17#issuecomment-10758327) in pg adapter when missing schema
786
+
787
+ # v0.17.1
788
+ * Oct 30, 2012
789
+
790
+ - Fixed a bug where switching to an unknown db in mysql2 would crash the app [Frodotus]
791
+
792
+ # v0.17.0
793
+ * Sept 26, 2012
794
+
795
+ - Apartment has [a new home!](https://github.com/influitive/apartment)
796
+ - Support Sidekiq hooks to switch dbs [maedhr]
797
+ - Allow VERSION to be used on apartment:migrate [Bhavin Kamani]
798
+
799
+ # v0.16.0
800
+ * June 1, 2012
801
+
802
+ - Apartment now supports a default_schema to be set, rather than relying on ActiveRecord's default schema_search_path
803
+ - Additional schemas can always be maintained in the schema_search_path by configuring persistent_schemas [ryanbrunner]
804
+ - This means Hstore is officially supported!!
805
+ - There is now a full domain based elevator to switch dbs based on the whole domain [lcowell]
806
+ - There is now a generic elevator that takes a Proc to switch dbs based on the return value of that proc.
807
+
808
+ # v0.15.0
809
+ * March 18, 2012
810
+
811
+ - Remove Rails dependency, Apartment can now be used with any Rack based framework using ActiveRecord
812
+
813
+ # v0.14.4
814
+ * March 8, 2012
815
+
816
+ - Delayed::Job Hooks now return to the previous database, rather than resetting
817
+
818
+ # v0.14.3
819
+ * Feb 21, 2012
820
+
821
+ - Fix yaml serialization of non DJ models
822
+
823
+ # v0.14.2
824
+ * Feb 21, 2012
825
+
826
+ - Fix Delayed::Job yaml encoding with Rails > 3.0.x
827
+
828
+ # v0.14.1
829
+ * Dec 13, 2011
830
+
831
+ - Fix ActionDispatch::Callbacks deprecation warnings
832
+
833
+ # v0.14.0
834
+ * Dec 13, 2011
835
+
836
+ - Rails 3.1 Support
837
+
838
+ # v0.13.1
839
+ * Nov 8, 2011
840
+
841
+ - Reset prepared statement cache for rails 3.1.1 before switching dbs when using postgresql schemas
842
+ - Only necessary until the next release which will be more schema aware
843
+
844
+ # v0.13.0
845
+ * Oct 25, 2011
846
+
847
+ - `process` will now rescue with reset if the previous schema/db is no longer available
848
+ - `create` now takes an optional block which allows you to process within the newly created db
849
+ - Fixed Rails version >= 3.0.10 and < 3.1 because there have been significant testing problems with 3.1, next version will hopefully fix this
850
+
851
+ # v0.12.0
852
+ * Oct 4, 2011
853
+
854
+ - Added a `drop` method for removing databases/schemas
855
+ - Refactored abstract adapter to further remove duplication in concrete implementations
856
+ - Excluded models now take string references so they are properly reloaded in development
857
+ - Better silencing of `schema.rb` loading using `verbose` flag
858
+
859
+ # v0.11.1
860
+ * Sep 22, 2011
861
+
862
+ - Better use of Railties for initializing apartment
863
+ - The following changes were necessary as I haven't figured out how to properly hook into Rails reloading
864
+ - Added reloader middleware in development to init Apartment on each request
865
+ - Override `reload!` in console to also init Apartment
866
+
867
+ # v0.11.0
868
+ * Sep 20, 2011
869
+
870
+ - Excluded models no longer use a different connection when using postgresql schemas. Instead their table_name is prefixed with `public.`
871
+
872
+ # v0.10.3
873
+ * Sep 20, 2011
874
+
875
+ - Fix improper raising of exceptions on create and reset
876
+
877
+ # v0.10.2
878
+ * Sep 15, 2011
879
+
880
+ - Remove all the annoying logging for loading db schema and seeding on create
881
+
882
+ # v0.10.1
883
+ * Aug 11, 2011
884
+
885
+ - Fixed bug in DJ where new objects (that hadn't been pulled from the db) didn't have the proper database assigned
886
+
887
+ # v0.10.0
888
+ * July 29, 2011
889
+
890
+ - Added better support for Delayed Job
891
+ - New config option that enables Delayed Job wrappers
892
+ - Note that DJ support uses a work-around in order to get queues stored in the public schema, not sure why it doesn't work out of the box, will look into it, until then, see documentation on queue'ng jobs
893
+
894
+ # v0.9.2
895
+ * July 4, 2011
896
+
897
+ - Migrations now run associated rails migration fully, fixes schema.rb not being reloaded after migrations
898
+
899
+ # v0.9.1
900
+ * June 24, 2011
901
+
902
+ - Hooks now take the payload object as an argument to fetch the proper db for DJ hooks
903
+
904
+ # v0.9.0
905
+ * June 23, 2011
906
+
907
+ - Added module to provide delayed job hooks
908
+
909
+ # v0.8.0
910
+ * June 23, 2011
911
+
912
+ - Added #current_database which will return the current database (or schema) name
913
+
914
+ # v0.7.0
915
+ * June 22, 2011
916
+
917
+ - Added apartment:seed rake task for seeding all dbs
918
+
919
+ # v0.6.0
920
+ * June 21, 2011
921
+
922
+ - Added #process to connect to new db, perform operations, then ensure a reset
923
+
924
+ # v0.5.1
925
+ * June 21, 2011
926
+
927
+ - Fixed db migrate up/down/rollback
928
+ - added db:redo
929
+
930
+ # v0.5.0
931
+ * June 20, 2011
932
+
933
+ - Added the concept of an "Elevator", a rack based strategy for db switching
934
+ - Added the Subdomain Elevator middleware to enabled db switching based on subdomain
935
+
936
+ # v0.4.0
937
+ * June 14, 2011
938
+
939
+ - Added `configure` method on Apartment instead of using yml file, allows for dynamic setting of db names to migrate for rake task
940
+ - Added `seed_after_create` config option to import seed data to new db on create
941
+
942
+ # v0.3.0
943
+ * June 10, 2011
944
+
945
+ - Added full support for database migration
946
+ - Added in method to establish new connection for excluded models on startup rather than on each switch
947
+
948
+ # v0.2.0
949
+ * June 6, 2011 *
950
+
951
+ - Refactor to use more rails/active_support functionality
952
+ - Refactor config to lazily load apartment.yml if exists
953
+ - Remove OStruct and just use hashes for fetching methods
954
+ - Added schema load on create instead of migrating from scratch
955
+
956
+ # v0.1.3
957
+ * March 30, 2011 *
958
+
959
+ - Original pass from Ryan
960
+
961
+
962
+ \* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/github-changelog-generator/github-changelog-generator)*