neo4j 10.0.0.pre.alpha.3 → 10.0.0.pre.alpha.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/neo4j/active_base.rb +4 -4
- data/lib/neo4j/tasks/migration.rake +3 -3
- data/lib/neo4j/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 626509bf7f9cd1085614bf355da5be22e0ced6cb602dfed7e3f561d22f39e1a6
|
4
|
+
data.tar.gz: 189890d9c5f4966fadb9afe9be8b71c1accfbefc6a22cbc331677f486e2596cd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d38e7fee8dcb5c2b03ad177077968c87c68d75e89953c1e6b942268fdc58036da3e37c1295d6b4b8d475d6ecf68d139a83e2180e2a93b87da8dc340892fa2523
|
7
|
+
data.tar.gz: da285e4bbf9b5deffae878a36712fed6ce87375c8dc5931158002fb8bfa95e5a3f24d52b998320143593e628c051c71ec745a4b585258ee94f1589370d181ad9
|
data/lib/neo4j/active_base.rb
CHANGED
@@ -28,12 +28,12 @@ module Neo4j
|
|
28
28
|
.new(url, options.merge(verbose_query_logs: verbose_query_logs))
|
29
29
|
end
|
30
30
|
|
31
|
-
def
|
31
|
+
def transaction
|
32
32
|
current_transaction || Transaction
|
33
33
|
end
|
34
34
|
|
35
35
|
def query(*args)
|
36
|
-
|
36
|
+
transaction.query(*args)
|
37
37
|
end
|
38
38
|
|
39
39
|
# Should support setting driver via config options
|
@@ -43,7 +43,7 @@ module Neo4j
|
|
43
43
|
end
|
44
44
|
|
45
45
|
def run_transaction(run_in_tx = true)
|
46
|
-
|
46
|
+
Transaction.run(current_driver, run_in_tx) do |tx|
|
47
47
|
yield tx
|
48
48
|
end
|
49
49
|
end
|
@@ -68,7 +68,7 @@ module Neo4j
|
|
68
68
|
|
69
69
|
def current_transaction
|
70
70
|
validate_model_schema!
|
71
|
-
|
71
|
+
Transaction.root
|
72
72
|
end
|
73
73
|
|
74
74
|
def label_object(label_name)
|
@@ -64,7 +64,7 @@ namespace :neo4j do
|
|
64
64
|
COMMENT
|
65
65
|
|
66
66
|
def check_neo4j_version_3
|
67
|
-
if Neo4j::ActiveBase.
|
67
|
+
if Neo4j::ActiveBase.transaction.version > '3.0.0'
|
68
68
|
yield
|
69
69
|
else
|
70
70
|
puts 'WARNING: This task does not work for versions of Neo4j before 3.0.0'
|
@@ -76,7 +76,7 @@ COMMENT
|
|
76
76
|
check_neo4j_version_3 do
|
77
77
|
require 'neo4j/migrations/schema'
|
78
78
|
|
79
|
-
schema_data = Neo4j::Migrations::Schema.fetch_schema_data(Neo4j::ActiveBase.
|
79
|
+
schema_data = Neo4j::Migrations::Schema.fetch_schema_data(Neo4j::ActiveBase.transaction)
|
80
80
|
|
81
81
|
runner = Neo4j::Migrations::Runner.new
|
82
82
|
schema_data[:versions] = runner.complete_migration_versions.sort
|
@@ -100,7 +100,7 @@ COMMENT
|
|
100
100
|
Neo4j::Core::CypherSession::Adaptors::Base.subscribe_to_query(&method(:puts))
|
101
101
|
|
102
102
|
Neo4j::ActiveBase.run_transaction do
|
103
|
-
Neo4j::Migrations::Schema.synchronize_schema_data(Neo4j::ActiveBase.
|
103
|
+
Neo4j::Migrations::Schema.synchronize_schema_data(Neo4j::ActiveBase.transaction, schema_data, args[:remove_missing])
|
104
104
|
|
105
105
|
runner = Neo4j::Migrations::Runner.new
|
106
106
|
runner.mark_versions_as_complete(schema_data[:versions]) # Run in test mode?
|
data/lib/neo4j/version.rb
CHANGED