flydata 0.5.1 → 0.5.2

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3363c696e28b167255482e1d6b7352d5e3989786
4
- data.tar.gz: 57d1039674d07396d58b2cf32d25c5c38db703ca
3
+ metadata.gz: ebe9adcd4a61f2b5867fa924d77c19d363a13d60
4
+ data.tar.gz: 5b08edfb063b96ce328457e164a8ac2ba0613642
5
5
  SHA512:
6
- metadata.gz: 24e8879e214ec3b0cfa21d7b725e05bca66b4c668f59d3bfc5869285e70d1a92f97971002566f9d7e65332d91897561a20ffab26916ee7ce35c163e25066546a
7
- data.tar.gz: 6303e50004f8d927867892a94e309d8e578cee1ed633f2768bae4470aca808cd9945ff2694ac220a07d4e20bea35df2df194963475ee971417910c22bdc6914b
6
+ metadata.gz: 7ab6b64aecf376f7f0bb3a8a6e58ab5be27aab47e357f52f1904f420b9c85a7ad4808488e89a4983694b94708789dc316627a9b79ef2b92b7d28a17d7a50f3cc
7
+ data.tar.gz: 9291d7b54299bef2fc32ff4b725f4982b57265a0bb2656dde863b7fb413d4c18fc074125a4e86c3d60deef31a3ac23dd9706d822f0025d5d8bcd747fd50c27a6
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.5.1
1
+ 0.5.2
data/flydata.gemspec CHANGED
@@ -2,16 +2,16 @@
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
3
  # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
- # stub: flydata 0.5.1 ruby lib
5
+ # stub: flydata 0.5.2 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "flydata"
9
- s.version = "0.5.1"
9
+ s.version = "0.5.2"
10
10
 
11
11
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
12
12
  s.require_paths = ["lib"]
13
13
  s.authors = ["Koichi Fujikawa", "Masashi Miyazaki", "Matthew Luu", "Mak Inada", "Sriram NS"]
14
- s.date = "2015-08-04"
14
+ s.date = "2015-08-14"
15
15
  s.description = "FlyData Agent"
16
16
  s.email = "sysadmin@flydata.com"
17
17
  s.executables = ["fdmysqldump", "flydata", "serverinfo"]
@@ -223,7 +223,7 @@ Gem::Specification.new do |s|
223
223
  ]
224
224
  s.homepage = "http://flydata.com/"
225
225
  s.licenses = ["All right reserved."]
226
- s.rubygems_version = "2.4.6"
226
+ s.rubygems_version = "2.4.3"
227
227
  s.summary = "FlyData Agent"
228
228
 
229
229
  if s.respond_to? :specification_version then
@@ -635,6 +635,13 @@ EOM
635
635
 
636
636
  # save check point
637
637
  sync_fm.save_dump_pos(STATUS_PARSING, table_name, last_pos, binlog_pos, state, substate)
638
+
639
+ # send record count for the table
640
+ if mysql_table &&
641
+ state == Flydata::Parser::Mysql::MysqlDumpParser::State::CREATE_TABLE
642
+ # all records for `mysql_table` have been sent
643
+ send_record_counts(de, sync_fm, mysql_table.table_name)
644
+ end
638
645
  }
639
646
  )
640
647
  rescue DumpParseError =>e
@@ -746,8 +753,9 @@ EOM
746
753
  end
747
754
 
748
755
  NUM_TABLES_IN_CHUNK = 30
749
- def send_record_counts(de, sync_fm)
756
+ def send_record_counts(de, sync_fm, table = nil)
750
757
  stats = sync_fm.load_stats
758
+ stats = { table => stats[table] } if table # single table stats
751
759
  stats.each_slice(NUM_TABLES_IN_CHUNK) do |slice|
752
760
  h = Hash[slice]
753
761
  send_record_counts_chunk(de, h)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: flydata
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Koichi Fujikawa
@@ -12,7 +12,7 @@ authors:
12
12
  autorequire:
13
13
  bindir: bin
14
14
  cert_chain: []
15
- date: 2015-08-04 00:00:00.000000000 Z
15
+ date: 2015-08-14 00:00:00.000000000 Z
16
16
  dependencies:
17
17
  - !ruby/object:Gem::Dependency
18
18
  name: rest-client
@@ -677,7 +677,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
677
677
  version: '0'
678
678
  requirements: []
679
679
  rubyforge_project:
680
- rubygems_version: 2.4.6
680
+ rubygems_version: 2.4.3
681
681
  signing_key:
682
682
  specification_version: 4
683
683
  summary: FlyData Agent