myreplicator 1.1.37 → 1.1.38
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/lib/loader/vertica/types.rb
CHANGED
@@ -426,13 +426,23 @@ module Myreplicator
|
|
426
426
|
if exp.analyze_constraints == true
|
427
427
|
sql = "SELECT analyze_constraints('#{options[:vertica_db]}.#{options[:vertica_schema]}.#{options[:table]}');"
|
428
428
|
result = Myreplicator::DB.exec_sql("vertica",sql)
|
429
|
-
|
429
|
+
if result.entries.size > 0
|
430
|
+
return 1
|
431
|
+
end
|
432
|
+
sql = "SELECT COUNT(*) FROM #{options[:vertica_schema]}.#{options[:table]} WHERE modified_date < '#{(DateTime.now() -1.hour).strftime('%Y-%m-%d %H:%M:%S')}';"
|
433
|
+
source_count = Myreplicator::DB.exec_sql("#{options[:source_schema]}",sql)
|
434
|
+
target_count = Myreplicator::DB.exec_sql("vertica",sql)
|
435
|
+
if source_count != target_count
|
436
|
+
return 1
|
437
|
+
end
|
430
438
|
end
|
431
439
|
rescue Exception => e
|
432
440
|
puts e.message
|
433
441
|
end
|
434
442
|
return 0
|
435
443
|
end
|
444
|
+
|
445
|
+
|
436
446
|
=begin
|
437
447
|
def create_all_tables db
|
438
448
|
tables = Myreplicator::DB.get_tables(db)
|
data/lib/myreplicator/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: myreplicator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.38
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-04-
|
12
|
+
date: 2013-04-30 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
@@ -335,7 +335,6 @@ files:
|
|
335
335
|
- test/dummy/tmp/cache/assets/F08/560/sprockets%2F5ab2cf5fb087fdef95cfe9fe6fabf9df
|
336
336
|
- test/dummy/tmp/myreplicator/load_logs/public_.log
|
337
337
|
- test/dummy/tmp/myreplicator/load_logs/public_app_csvs.log
|
338
|
-
- test/dummy/tmp/pids/server.pid
|
339
338
|
- test/fixtures/myreplicator/exports.yml
|
340
339
|
- test/functional/myreplicator/exports_controller_test.rb
|
341
340
|
- test/integration/navigation_test.rb
|
@@ -360,7 +359,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
360
359
|
version: '0'
|
361
360
|
segments:
|
362
361
|
- 0
|
363
|
-
hash:
|
362
|
+
hash: 2481048643632585697
|
364
363
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
365
364
|
none: false
|
366
365
|
requirements:
|
@@ -369,7 +368,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
369
368
|
version: '0'
|
370
369
|
segments:
|
371
370
|
- 0
|
372
|
-
hash:
|
371
|
+
hash: 2481048643632585697
|
373
372
|
requirements: []
|
374
373
|
rubyforge_project:
|
375
374
|
rubygems_version: 1.8.24
|
@@ -473,7 +472,6 @@ test_files:
|
|
473
472
|
- test/dummy/tmp/cache/assets/F08/560/sprockets%2F5ab2cf5fb087fdef95cfe9fe6fabf9df
|
474
473
|
- test/dummy/tmp/myreplicator/load_logs/public_.log
|
475
474
|
- test/dummy/tmp/myreplicator/load_logs/public_app_csvs.log
|
476
|
-
- test/dummy/tmp/pids/server.pid
|
477
475
|
- test/fixtures/myreplicator/exports.yml
|
478
476
|
- test/functional/myreplicator/exports_controller_test.rb
|
479
477
|
- test/integration/navigation_test.rb
|
@@ -1 +0,0 @@
|
|
1
|
-
4522
|