td 0.10.57 → 0.10.58
Sign up to get free protection for your applications and to get access to all the features.
- data/ChangeLog +3 -0
- data/lib/td/command/status.rb +2 -2
- data/lib/td/command/table.rb +2 -2
- data/lib/td/version.rb +1 -1
- metadata +2 -3
data/ChangeLog
CHANGED
data/lib/td/command/status.rb
CHANGED
@@ -42,10 +42,10 @@ module Command
|
|
42
42
|
dbs = client.databases
|
43
43
|
dbs.map {|db|
|
44
44
|
db.tables.each {|table|
|
45
|
-
tables << {:Database => db.name, :Table => table.name, :Count => table.count.to_s}
|
45
|
+
tables << {:Database => db.name, :Table => table.name, :Count => table.count.to_s, :Size => table.estimated_storage_size_string}
|
46
46
|
}
|
47
47
|
}
|
48
|
-
x3, y3 = status_render(0, 0, "[Tables]", tables, :fields => [:Database, :Table, :Count])
|
48
|
+
x3, y3 = status_render(0, 0, "[Tables]", tables, :fields => [:Database, :Table, :Count, :Size])
|
49
49
|
|
50
50
|
rs = client.results
|
51
51
|
rs.each {|r|
|
data/lib/td/command/table.rb
CHANGED
@@ -86,14 +86,14 @@ module Command
|
|
86
86
|
pschema = table.schema.fields.map {|f|
|
87
87
|
"#{f.name}:#{f.type}"
|
88
88
|
}.join(', ')
|
89
|
-
rows << {:Database => db.name, :Table => table.name, :Type => table.type.to_s, :Count => table.count.to_s, :Schema=>pschema
|
89
|
+
rows << {:Database => db.name, :Table => table.name, :Type => table.type.to_s, :Count => table.count.to_s, :Size => table.estimated_storage_size_string, :Schema => pschema}
|
90
90
|
}
|
91
91
|
}
|
92
92
|
rows = rows.sort_by {|map|
|
93
93
|
[map[:Database], map[:Type].size, map[:Table]]
|
94
94
|
}
|
95
95
|
|
96
|
-
puts cmd_render_table(rows, :fields => [:Database, :Table, :Type, :Count, :Schema], :max_width=>500)
|
96
|
+
puts cmd_render_table(rows, :fields => [:Database, :Table, :Type, :Count, :Size, :Schema], :max_width=>500)
|
97
97
|
|
98
98
|
if rows.empty?
|
99
99
|
if db_name
|
data/lib/td/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: td
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.10.
|
4
|
+
version: 0.10.58
|
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: 2012-
|
12
|
+
date: 2012-11-01 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: msgpack
|
@@ -189,4 +189,3 @@ signing_key:
|
|
189
189
|
specification_version: 3
|
190
190
|
summary: CLI to manage data on Treasure Data, the Hadoop-based cloud data warehousing
|
191
191
|
test_files: []
|
192
|
-
has_rdoc: false
|