samidare 0.0.2 → 0.0.4

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: b5773b739c82c8896501f93a28c8f9f16780fbcb
4
- data.tar.gz: dcdf41eb57238dc34b6f399a0b7fc707d25549c4
3
+ metadata.gz: cebd0e6fe168080a1c3e36dc9299564b0fbeee72
4
+ data.tar.gz: b2bacde505cd91182e92592d3e8835dea8055fb8
5
5
  SHA512:
6
- metadata.gz: 0bf4586c4a43e98bd24e36515ae2ac2cdebc072e6c089ca0ac71914bece5266c2ec6f338fedd16cbddaf87f6fae86acb57c9851c8a46b1af34db4ebdc4540da0
7
- data.tar.gz: 116af87aeae963a54116730a1d14e54d62323a96d39f5790028fd9e33e681ff2d1d3d5f793a746b54946bd0f3b62893c854f2be57118d175a1ab26a49cb804fd
6
+ metadata.gz: 9d2564ddc962b6ce9fcbcbd1a75cb6530eff6f77cca2d3a326ff337680a26be43f55595b10d125e7d88c6aeef8123d1ace470afa3883af98083483732a34c93b
7
+ data.tar.gz: 1b4174505b57d13c5a484af60015e81d8913edfa700147e9068d8c77aab7e15bd5e2280d5dca6cd0e9e9a34cab20c18bb365e58b2abe7c592e3433a32d7e6cac
data/.gitignore CHANGED
@@ -1,14 +1,15 @@
1
- /.bundle/
2
- /.yardoc
3
- /Gemfile.lock
4
- /_yardoc/
5
- /coverage/
6
- /doc/
7
- /pkg/
8
- /spec/reports/
9
- /tmp/
10
- *.bundle
11
- *.so
12
- *.o
13
- *.a
14
- mkmf.log
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
10
+ *.bundle
11
+ *.so
12
+ *.o
13
+ *.a
14
+ .rspec
15
+ mkmf.log
data/README.md CHANGED
@@ -1,45 +1,80 @@
1
- # Samidare
2
-
3
- Generate Embulk config and BigQuery schema from MySQL schema and run Embulk.
4
-
5
- ## Installation
6
-
7
- Add this line to your application's Gemfile:
8
-
9
- ```ruby
10
- gem 'samidare'
11
- ```
12
-
13
- And then execute:
14
-
15
- $ bundle
16
-
17
- Or install it yourself as:
18
-
19
- $ gem install samidare
20
-
21
- ## Usage
22
-
23
- ```ruby
24
- config = {
25
- 'project_id' => 'BIGQUERY_PROJECT_ID',
26
- 'project_name' => 'BIGQUERY_PROJECT_NAME',
27
- 'service_email' => 'SERVICE_ACCOUNT_EMAIL',
28
- 'key' => '/etc/embulk/bigquery.p12',
29
- 'schema_dir' => '/var/tmp/embulk/schema',
30
- 'config_dir' => '/var/tmp/embulk/config',
31
- 'auth_method' => 'private_key'
32
- }
33
-
34
- client = Samidare::EmbulkClient.new
35
- client.generate_config(config)
36
- client.run(config)
37
- ```
38
-
39
- ## Contributing
40
-
41
- 1. Fork it ( https://github.com/[my-github-username]/samidare/fork )
42
- 2. Create your feature branch (`git checkout -b my-new-feature`)
43
- 3. Commit your changes (`git commit -am 'Add some feature'`)
44
- 4. Push to the branch (`git push origin my-new-feature`)
45
- 5. Create a new Pull Request
1
+ # Samidare
2
+
3
+ Generate Embulk config and BigQuery schema from MySQL schema and run Embulk.
4
+
5
+ ## Installation
6
+
7
+ Add this line to your application's Gemfile:
8
+
9
+ ```ruby
10
+ gem 'samidare'
11
+ ```
12
+
13
+ And then execute:
14
+
15
+ $ bundle
16
+
17
+ Or install it yourself as:
18
+
19
+ $ gem install samidare
20
+
21
+ ## Usage
22
+ Require `database.yml` and `table.yml`.
23
+ Below is a sample config file.
24
+
25
+ #### database.yml
26
+ ```yml
27
+ db01:
28
+ host: localhost
29
+ username: root
30
+ password:
31
+ database: production
32
+ bq_dataset: mysql_db01
33
+
34
+ db02:
35
+ host: localhost
36
+ username: root
37
+ password:
38
+ database: production
39
+ bq_dataset: mysql_db02
40
+
41
+ ```
42
+
43
+ #### table.yml
44
+ ```yml
45
+ db01:
46
+ tables:
47
+ - name: users
48
+ - name: events
49
+ - name: hobbies
50
+
51
+ db02:
52
+ tables:
53
+ - name: administrators
54
+ - name: configs
55
+ ```
56
+
57
+ Samidare requires BigQuery parameters.
58
+ ```ruby
59
+ config = {
60
+ 'project_id' => 'BIGQUERY_PROJECT_ID',
61
+ 'project_name' => 'BIGQUERY_PROJECT_NAME',
62
+ 'service_email' => 'SERVICE_ACCOUNT_EMAIL',
63
+ 'key' => '/etc/embulk/bigquery.p12',
64
+ 'schema_dir' => '/var/tmp/embulk/schema',
65
+ 'config_dir' => '/var/tmp/embulk/config',
66
+ 'auth_method' => 'private_key'
67
+ }
68
+
69
+ client = Samidare::EmbulkClient.new
70
+ client.generate_config(config)
71
+ client.run(config)
72
+ ```
73
+
74
+ ## Contributing
75
+
76
+ 1. Fork it ( https://github.com/[my-github-username]/samidare/fork )
77
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
78
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
79
+ 4. Push to the branch (`git push origin my-new-feature`)
80
+ 5. Create a new Pull Request
@@ -1,3 +1,3 @@
1
1
  module Samidare
2
- VERSION = "0.0.2"
2
+ VERSION = "0.0.4"
3
3
  end
data/samidare.gemspec CHANGED
@@ -21,8 +21,8 @@ Gem::Specification.new do |spec|
21
21
  spec.add_development_dependency 'bundler', '~> 1.7'
22
22
  spec.add_development_dependency 'rake', '~> 10.0'
23
23
  spec.add_development_dependency 'rspec'
24
- spec.add_development_dependency 'unindent'
25
24
 
25
+ spec.add_dependency 'unindent'
26
26
  spec.add_dependency 'mysql2-cs-bind'
27
27
  spec.add_dependency 'embulk-output-bigquery'
28
28
  spec.add_dependency 'embulk-input-mysql'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: samidare
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryoji Kobori
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-07-14 00:00:00.000000000 Z
11
+ date: 2015-07-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -59,7 +59,7 @@ dependencies:
59
59
  - - ">="
60
60
  - !ruby/object:Gem::Version
61
61
  version: '0'
62
- type: :development
62
+ type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
@@ -173,7 +173,6 @@ extra_rdoc_files: []
173
173
  files:
174
174
  - ".gitignore"
175
175
  - ".rspec"
176
- - ".travis.yml"
177
176
  - Gemfile
178
177
  - LICENSE.txt
179
178
  - README.md
@@ -216,3 +215,4 @@ test_files:
216
215
  - spec/samidare/embulk_utility_spec.rb
217
216
  - spec/samidare_spec.rb
218
217
  - spec/spec_helper.rb
218
+ has_rdoc:
data/.travis.yml DELETED
@@ -1,3 +0,0 @@
1
- language: ruby
2
- rvm:
3
- - 2.1.5