cassie 1.1.1 → 1.1.2
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2dec8906d195a23051dc2070c00d3828386822ea
|
4
|
+
data.tar.gz: 3e266d1a536b315377d42e8cb4ce182e37e56348
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6f8ae6ddfe99989ee0a5eaef5522314e70445d47180fb848fb45389919590472d236183cec548eaa8b0fca01c23ed4dd35dcb8a319b093bbba801b3715b255a9
|
7
|
+
data.tar.gz: 86c0154c8915532481d97a4518f1474364a021e9e3b4de2cfcc82633008003de497e3f5f48ef1d324b09fdd05b47708d39ecfb1b6635a102617924b92ccdd03f
|
data/lib/cassie/schema.rb
CHANGED
@@ -21,7 +21,7 @@ module Cassie
|
|
21
21
|
extend Definition
|
22
22
|
|
23
23
|
# The application namespace. Only applicaple
|
24
|
-
# When cassie manages multiple
|
24
|
+
# When cassie manages multiple application
|
25
25
|
# schemas within the same cluster.
|
26
26
|
# @return [String] the application namespace
|
27
27
|
def self.application
|
@@ -82,7 +82,7 @@ CQL statements are used for 3 different kinds of queries:
|
|
82
82
|
* data modification (e.g. `INSERT`, `UPDATE`, `DELETE`)
|
83
83
|
* data query (e.g. `SELECT`)
|
84
84
|
|
85
|
-
Cassie provides 3 base classes for these 3 kinds of queries. Subclass `Cassie::Definition`, `Cassie::Modification`, and `Cassie::Query` to define your
|
85
|
+
Cassie provides 3 base classes for these 3 kinds of queries. Subclass `Cassie::Definition`, `Cassie::Modification`, and `Cassie::Query` to define your application query classes.
|
86
86
|
|
87
87
|
##### `Cassie::Definition`
|
88
88
|
Only includes the core functionality for statement execution:
|
@@ -24,11 +24,12 @@ namespace :cassie do
|
|
24
24
|
version = Cassie::Schema::Version.new(opts[:version])
|
25
25
|
version = Cassie::Schema.local_versions.find{|v| version == v} || raise_not_found(version)
|
26
26
|
versions = Cassie::Schema.local_versions.select{|v| v <= version}.sort
|
27
|
-
puts "-- Fast-forwarding to version #{version}"
|
27
|
+
puts "-- Fast-forwarding '#{Cassie.env}' schema to version #{version}"
|
28
28
|
t0 = Time.now
|
29
29
|
versions.each.with_index do |v, i|
|
30
30
|
# space IDs out by 10 seconds to ensure they get written in order
|
31
|
-
|
31
|
+
# end on 10 seconds ago in case migrations are run immediately
|
32
|
+
time = t0 - ((versions.count - i) * 10)
|
32
33
|
v.id = ::Cassandra::TimeUuid::Generator.new.at(time)
|
33
34
|
v.executor = "cassie"
|
34
35
|
Cassie::Schema.record_version(v, false)
|
@@ -8,9 +8,6 @@ namespace :cassie do
|
|
8
8
|
begin
|
9
9
|
puts "-- Initializing Cassie Versioning"
|
10
10
|
Cassie::Schema.initialize_versioning
|
11
|
-
puts "-- done"
|
12
|
-
rescue Cassie::Schema::AlreadyInitiailizedError
|
13
|
-
puts " > Cassie Versioning already initialized "
|
14
11
|
puts " > Schema is at version #{Cassie::Schema.version}"
|
15
12
|
puts "-- done"
|
16
13
|
rescue => e
|
data/lib/cassie/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cassie
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Evan Prothro
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-02-
|
11
|
+
date: 2017-02-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: cassandra-driver
|