rails_async_migrations 1.0.4 → 1.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/README.md +5 -10
- data/_resource/schema.png +0 -0
- data/_resource/schema.sketch +0 -0
- data/lib/rails_async_migrations/config.rb +2 -2
- data/lib/rails_async_migrations/tracer.rb +1 -1
- data/lib/rails_async_migrations/version.rb +1 -1
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c3631f04a30cfc01a7e695616190b5c9b2cf4af242b0f8fc6ae8eb04bf947e86
|
4
|
+
data.tar.gz: e60a2a45d1aecdfbd6af82760c94d7ccb55ebd4baf0c6ffeee6f8dca65b70632
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: aab6691233585c732d12a3beea642e7529ee590e396086091f9a87edd7dd9daa824c84308b3f738691db285b9458e74052c50c7d41a62c708e3d982aad0be410
|
7
|
+
data.tar.gz: 268821ee21b8bccbfeb58a88e9b8bc565a480970fd40e0381fdcbb1988bc75e76110633195a6eff6a3145600793d15eac27a9ad3a9492419702f99830b9f23ec
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -91,17 +91,9 @@ RailsAsyncMigrations.config do |config|
|
|
91
91
|
# :verbose can be used if you want a full log of the execution
|
92
92
|
config.mode = :quiet
|
93
93
|
|
94
|
-
# which
|
94
|
+
# which adapter worker you want to use for this library
|
95
95
|
# for now you have two options: :delayed_job or :sidekiq
|
96
96
|
config.workers = :sidekiq
|
97
|
-
|
98
|
-
# when the migration is turned asynchronous
|
99
|
-
# it watches over some specific `ActiveRecord` methods
|
100
|
-
# by adding them to this array, you'll lock and turn those methods asynchronous
|
101
|
-
# by removing them you'll let them use the classical migration process
|
102
|
-
# for example, if you set the `locked_methods` to %i[async] the migration will be processed normally
|
103
|
-
# but the content of the `#async` method will be taken away and executed within the asynchronous queue
|
104
|
-
config.locked_methods = %i[change up down]
|
105
97
|
end
|
106
98
|
```
|
107
99
|
|
@@ -111,11 +103,14 @@ Each migration which is turned asynchronous follows each other, once one migrati
|
|
111
103
|
|
112
104
|
If it fails, the error will be raised within the worker so it retries until it eventually works, or until it's considered dead. None of the further asynchronous migrations will be run until you fix the failed one, which is a good protection for data consistency.
|
113
105
|
|
106
|
+
![RailsAsyncMigrations Schema](https://cdn-images-1.medium.com/max/1600/1*e1MElsR3B5rItwwVQkBYCw.png "RailsAsyncMigrations Schema")
|
107
|
+
|
108
|
+
|
114
109
|
You can also manually launch the queue check and fire by using:
|
115
110
|
|
116
111
|
$ rake rails_async_migrations:check_queue
|
117
112
|
|
118
|
-
**For now, there is no rollback mechanism authorized
|
113
|
+
**For now, there is no rollback mechanism authorized. It means if you rollback the asynchronous migrations will be simply ignored. Handling multiple directions complexifies the build up logic and may not be needed in asynchronous cases.**
|
119
114
|
|
120
115
|
## States
|
121
116
|
|
Binary file
|
Binary file
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rails_async_migrations
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Laurent Schaffner
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-01-
|
11
|
+
date: 2019-01-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -138,6 +138,8 @@ files:
|
|
138
138
|
- LICENSE.txt
|
139
139
|
- README.md
|
140
140
|
- Rakefile
|
141
|
+
- _resource/schema.png
|
142
|
+
- _resource/schema.sketch
|
141
143
|
- bin/console
|
142
144
|
- bin/setup
|
143
145
|
- lib/generators/rails_async_migrations/install_generator.rb
|