impala 0.1.6 → 0.2.0
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/Rakefile +0 -2
- data/impala.gemspec +1 -2
- data/lib/impala.rb +1 -1
- data/lib/impala/cursor.rb +10 -4
- data/lib/impala/protocol/beeswax_constants.rb +2 -1
- data/lib/impala/protocol/beeswax_service.rb +46 -46
- data/lib/impala/protocol/beeswax_types.rb +31 -30
- data/lib/impala/protocol/cli_service_constants.rb +60 -0
- data/lib/impala/protocol/cli_service_types.rb +1452 -0
- data/lib/impala/protocol/facebook_service.rb +17 -17
- data/lib/impala/protocol/fb303_constants.rb +2 -1
- data/lib/impala/protocol/fb303_types.rb +3 -2
- data/lib/impala/protocol/hive_metastore_constants.rb +2 -1
- data/lib/impala/protocol/hive_metastore_types.rb +102 -101
- data/lib/impala/protocol/impala_hive_server2_service.rb +29 -0
- data/lib/impala/protocol/impala_service.rb +135 -18
- data/lib/impala/protocol/impala_service_constants.rb +2 -1
- data/lib/impala/protocol/impala_service_types.rb +54 -10
- data/lib/impala/protocol/status_constants.rb +2 -1
- data/lib/impala/protocol/status_types.rb +9 -7
- data/lib/impala/protocol/t_c_l_i_service.rb +948 -0
- data/lib/impala/protocol/thrift_hive_metastore.rb +507 -507
- data/lib/impala/version.rb +1 -1
- data/test/test_impala_connected.rb +93 -13
- data/thrift/ImpalaService.thrift +78 -6
- data/thrift/Status.thrift +2 -1
- data/thrift/beeswax.thrift +1 -1
- data/thrift/cli_service.thrift +1015 -0
- metadata +9 -75
- data/lib/impala/protocol/data_constants.rb +0 -12
- data/lib/impala/protocol/data_sinks_constants.rb +0 -12
- data/lib/impala/protocol/data_sinks_types.rb +0 -107
- data/lib/impala/protocol/data_types.rb +0 -77
- data/lib/impala/protocol/descriptors_constants.rb +0 -12
- data/lib/impala/protocol/descriptors_types.rb +0 -266
- data/lib/impala/protocol/exprs_constants.rb +0 -12
- data/lib/impala/protocol/exprs_types.rb +0 -345
- data/lib/impala/protocol/frontend_constants.rb +0 -12
- data/lib/impala/protocol/frontend_types.rb +0 -347
- data/lib/impala/protocol/impala_internal_service.rb +0 -244
- data/lib/impala/protocol/impala_internal_service_constants.rb +0 -12
- data/lib/impala/protocol/impala_internal_service_types.rb +0 -362
- data/lib/impala/protocol/impala_plan_service.rb +0 -310
- data/lib/impala/protocol/impala_plan_service_constants.rb +0 -12
- data/lib/impala/protocol/impala_plan_service_types.rb +0 -36
- data/lib/impala/protocol/java_constants_constants.rb +0 -42
- data/lib/impala/protocol/java_constants_types.rb +0 -14
- data/lib/impala/protocol/opcodes_constants.rb +0 -12
- data/lib/impala/protocol/opcodes_types.rb +0 -309
- data/lib/impala/protocol/partitions_constants.rb +0 -12
- data/lib/impala/protocol/partitions_types.rb +0 -44
- data/lib/impala/protocol/plan_nodes_constants.rb +0 -12
- data/lib/impala/protocol/plan_nodes_types.rb +0 -345
- data/lib/impala/protocol/planner_constants.rb +0 -12
- data/lib/impala/protocol/planner_types.rb +0 -78
- data/lib/impala/protocol/runtime_profile_constants.rb +0 -12
- data/lib/impala/protocol/runtime_profile_types.rb +0 -97
- data/lib/impala/protocol/state_store_service.rb +0 -244
- data/lib/impala/protocol/state_store_service_constants.rb +0 -12
- data/lib/impala/protocol/state_store_service_types.rb +0 -185
- data/lib/impala/protocol/state_store_subscriber_service.rb +0 -82
- data/lib/impala/protocol/state_store_subscriber_service_constants.rb +0 -12
- data/lib/impala/protocol/state_store_subscriber_service_types.rb +0 -67
- data/lib/impala/protocol/statestore_types_constants.rb +0 -12
- data/lib/impala/protocol/statestore_types_types.rb +0 -77
- data/lib/impala/protocol/types_constants.rb +0 -12
- data/lib/impala/protocol/types_types.rb +0 -86
- data/thrift/Data.thrift +0 -52
- data/thrift/DataSinks.thrift +0 -61
- data/thrift/Descriptors.thrift +0 -115
- data/thrift/Exprs.thrift +0 -134
- data/thrift/Frontend.thrift +0 -193
- data/thrift/ImpalaInternalService.thrift +0 -265
- data/thrift/ImpalaPlanService.thrift +0 -44
- data/thrift/JavaConstants.thrift +0 -60
- data/thrift/Opcodes.thrift +0 -317
- data/thrift/Partitions.thrift +0 -41
- data/thrift/PlanNodes.thrift +0 -184
- data/thrift/Planner.thrift +0 -72
- data/thrift/RuntimeProfile.thrift +0 -58
- data/thrift/StateStoreService.thrift +0 -121
- data/thrift/StateStoreSubscriberService.thrift +0 -64
- data/thrift/StatestoreTypes.thrift +0 -50
- data/thrift/Types.thrift +0 -71
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: impala
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.2.0
|
|
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-
|
|
12
|
+
date: 2013-09-17 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: thrift
|
|
@@ -18,7 +18,7 @@ dependencies:
|
|
|
18
18
|
requirements:
|
|
19
19
|
- - ~>
|
|
20
20
|
- !ruby/object:Gem::Version
|
|
21
|
-
version:
|
|
21
|
+
version: 0.9.1
|
|
22
22
|
type: :runtime
|
|
23
23
|
prerelease: false
|
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
|
@@ -26,7 +26,7 @@ dependencies:
|
|
|
26
26
|
requirements:
|
|
27
27
|
- - ~>
|
|
28
28
|
- !ruby/object:Gem::Version
|
|
29
|
-
version:
|
|
29
|
+
version: 0.9.1
|
|
30
30
|
- !ruby/object:Gem::Dependency
|
|
31
31
|
name: rake
|
|
32
32
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -43,22 +43,6 @@ dependencies:
|
|
|
43
43
|
- - ! '>='
|
|
44
44
|
- !ruby/object:Gem::Version
|
|
45
45
|
version: '0'
|
|
46
|
-
- !ruby/object:Gem::Dependency
|
|
47
|
-
name: eden
|
|
48
|
-
requirement: !ruby/object:Gem::Requirement
|
|
49
|
-
none: false
|
|
50
|
-
requirements:
|
|
51
|
-
- - ! '>='
|
|
52
|
-
- !ruby/object:Gem::Version
|
|
53
|
-
version: '0'
|
|
54
|
-
type: :development
|
|
55
|
-
prerelease: false
|
|
56
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
57
|
-
none: false
|
|
58
|
-
requirements:
|
|
59
|
-
- - ! '>='
|
|
60
|
-
- !ruby/object:Gem::Version
|
|
61
|
-
version: '0'
|
|
62
46
|
- !ruby/object:Gem::Dependency
|
|
63
47
|
name: pry
|
|
64
48
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -175,78 +159,28 @@ files:
|
|
|
175
159
|
- lib/impala/protocol/beeswax_constants.rb
|
|
176
160
|
- lib/impala/protocol/beeswax_service.rb
|
|
177
161
|
- lib/impala/protocol/beeswax_types.rb
|
|
178
|
-
- lib/impala/protocol/
|
|
179
|
-
- lib/impala/protocol/
|
|
180
|
-
- lib/impala/protocol/data_sinks_types.rb
|
|
181
|
-
- lib/impala/protocol/data_types.rb
|
|
182
|
-
- lib/impala/protocol/descriptors_constants.rb
|
|
183
|
-
- lib/impala/protocol/descriptors_types.rb
|
|
184
|
-
- lib/impala/protocol/exprs_constants.rb
|
|
185
|
-
- lib/impala/protocol/exprs_types.rb
|
|
162
|
+
- lib/impala/protocol/cli_service_constants.rb
|
|
163
|
+
- lib/impala/protocol/cli_service_types.rb
|
|
186
164
|
- lib/impala/protocol/facebook_service.rb
|
|
187
165
|
- lib/impala/protocol/fb303_constants.rb
|
|
188
166
|
- lib/impala/protocol/fb303_types.rb
|
|
189
|
-
- lib/impala/protocol/frontend_constants.rb
|
|
190
|
-
- lib/impala/protocol/frontend_types.rb
|
|
191
167
|
- lib/impala/protocol/hive_metastore_constants.rb
|
|
192
168
|
- lib/impala/protocol/hive_metastore_types.rb
|
|
193
|
-
- lib/impala/protocol/
|
|
194
|
-
- lib/impala/protocol/impala_internal_service_constants.rb
|
|
195
|
-
- lib/impala/protocol/impala_internal_service_types.rb
|
|
196
|
-
- lib/impala/protocol/impala_plan_service.rb
|
|
197
|
-
- lib/impala/protocol/impala_plan_service_constants.rb
|
|
198
|
-
- lib/impala/protocol/impala_plan_service_types.rb
|
|
169
|
+
- lib/impala/protocol/impala_hive_server2_service.rb
|
|
199
170
|
- lib/impala/protocol/impala_service.rb
|
|
200
171
|
- lib/impala/protocol/impala_service_constants.rb
|
|
201
172
|
- lib/impala/protocol/impala_service_types.rb
|
|
202
|
-
- lib/impala/protocol/java_constants_constants.rb
|
|
203
|
-
- lib/impala/protocol/java_constants_types.rb
|
|
204
|
-
- lib/impala/protocol/opcodes_constants.rb
|
|
205
|
-
- lib/impala/protocol/opcodes_types.rb
|
|
206
|
-
- lib/impala/protocol/partitions_constants.rb
|
|
207
|
-
- lib/impala/protocol/partitions_types.rb
|
|
208
|
-
- lib/impala/protocol/plan_nodes_constants.rb
|
|
209
|
-
- lib/impala/protocol/plan_nodes_types.rb
|
|
210
|
-
- lib/impala/protocol/planner_constants.rb
|
|
211
|
-
- lib/impala/protocol/planner_types.rb
|
|
212
|
-
- lib/impala/protocol/runtime_profile_constants.rb
|
|
213
|
-
- lib/impala/protocol/runtime_profile_types.rb
|
|
214
|
-
- lib/impala/protocol/state_store_service.rb
|
|
215
|
-
- lib/impala/protocol/state_store_service_constants.rb
|
|
216
|
-
- lib/impala/protocol/state_store_service_types.rb
|
|
217
|
-
- lib/impala/protocol/state_store_subscriber_service.rb
|
|
218
|
-
- lib/impala/protocol/state_store_subscriber_service_constants.rb
|
|
219
|
-
- lib/impala/protocol/state_store_subscriber_service_types.rb
|
|
220
|
-
- lib/impala/protocol/statestore_types_constants.rb
|
|
221
|
-
- lib/impala/protocol/statestore_types_types.rb
|
|
222
173
|
- lib/impala/protocol/status_constants.rb
|
|
223
174
|
- lib/impala/protocol/status_types.rb
|
|
175
|
+
- lib/impala/protocol/t_c_l_i_service.rb
|
|
224
176
|
- lib/impala/protocol/thrift_hive_metastore.rb
|
|
225
|
-
- lib/impala/protocol/types_constants.rb
|
|
226
|
-
- lib/impala/protocol/types_types.rb
|
|
227
177
|
- lib/impala/version.rb
|
|
228
178
|
- test/test_impala.rb
|
|
229
179
|
- test/test_impala_connected.rb
|
|
230
|
-
- thrift/Data.thrift
|
|
231
|
-
- thrift/DataSinks.thrift
|
|
232
|
-
- thrift/Descriptors.thrift
|
|
233
|
-
- thrift/Exprs.thrift
|
|
234
|
-
- thrift/Frontend.thrift
|
|
235
|
-
- thrift/ImpalaInternalService.thrift
|
|
236
|
-
- thrift/ImpalaPlanService.thrift
|
|
237
180
|
- thrift/ImpalaService.thrift
|
|
238
|
-
- thrift/JavaConstants.thrift
|
|
239
|
-
- thrift/Opcodes.thrift
|
|
240
|
-
- thrift/Partitions.thrift
|
|
241
|
-
- thrift/PlanNodes.thrift
|
|
242
|
-
- thrift/Planner.thrift
|
|
243
|
-
- thrift/RuntimeProfile.thrift
|
|
244
|
-
- thrift/StateStoreService.thrift
|
|
245
|
-
- thrift/StateStoreSubscriberService.thrift
|
|
246
|
-
- thrift/StatestoreTypes.thrift
|
|
247
181
|
- thrift/Status.thrift
|
|
248
|
-
- thrift/Types.thrift
|
|
249
182
|
- thrift/beeswax.thrift
|
|
183
|
+
- thrift/cli_service.thrift
|
|
250
184
|
- thrift/fb303.thrift
|
|
251
185
|
- thrift/hive_metastore.thrift
|
|
252
186
|
homepage: https://github.com/colinmarc/impala-ruby
|
|
@@ -1,107 +0,0 @@
|
|
|
1
|
-
#
|
|
2
|
-
# Autogenerated by Thrift Compiler (0.8.0)
|
|
3
|
-
#
|
|
4
|
-
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
|
5
|
-
#
|
|
6
|
-
|
|
7
|
-
require 'exprs_types'
|
|
8
|
-
require 'types_types'
|
|
9
|
-
require 'descriptors_types'
|
|
10
|
-
require 'partitions_types'
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
module Impala
|
|
14
|
-
module Protocol
|
|
15
|
-
module TDataSinkType
|
|
16
|
-
DATA_STREAM_SINK = 0
|
|
17
|
-
TABLE_SINK = 1
|
|
18
|
-
VALUE_MAP = { 0 => "DATA_STREAM_SINK", 1 => "TABLE_SINK" }
|
|
19
|
-
VALID_VALUES = Set.new([DATA_STREAM_SINK, TABLE_SINK]).freeze
|
|
20
|
-
end
|
|
21
|
-
|
|
22
|
-
class TDataStreamSink
|
|
23
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
24
|
-
DEST_NODE_ID = 1
|
|
25
|
-
OUTPUT_PARTITION = 2
|
|
26
|
-
|
|
27
|
-
FIELDS = {
|
|
28
|
-
DEST_NODE_ID => { :type => ::Thrift::Types::I32, :name => 'dest_node_id' },
|
|
29
|
-
OUTPUT_PARTITION => { :type => ::Thrift::Types::STRUCT, :name => 'output_partition', :class => Impala::Protocol::TDataPartition }
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
def struct_fields; FIELDS; end
|
|
33
|
-
|
|
34
|
-
def validate
|
|
35
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field dest_node_id is unset!') unless @dest_node_id
|
|
36
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field output_partition is unset!') unless @output_partition
|
|
37
|
-
end
|
|
38
|
-
|
|
39
|
-
::Thrift::Struct.generate_accessors self
|
|
40
|
-
end
|
|
41
|
-
|
|
42
|
-
class THdfsTableSink
|
|
43
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
44
|
-
PARTITION_KEY_EXPRS = 1
|
|
45
|
-
OVERWRITE = 2
|
|
46
|
-
|
|
47
|
-
FIELDS = {
|
|
48
|
-
PARTITION_KEY_EXPRS => { :type => ::Thrift::Types::LIST, :name => 'partition_key_exprs', :element => { :type => ::Thrift::Types::STRUCT, :class => Impala::Protocol::TExpr } },
|
|
49
|
-
OVERWRITE => { :type => ::Thrift::Types::BOOL, :name => 'overwrite' }
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
def struct_fields; FIELDS; end
|
|
53
|
-
|
|
54
|
-
def validate
|
|
55
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field partition_key_exprs is unset!') unless @partition_key_exprs
|
|
56
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field overwrite is unset!') if @overwrite.nil?
|
|
57
|
-
end
|
|
58
|
-
|
|
59
|
-
::Thrift::Struct.generate_accessors self
|
|
60
|
-
end
|
|
61
|
-
|
|
62
|
-
class TTableSink
|
|
63
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
64
|
-
TARGET_TABLE_ID = 1
|
|
65
|
-
HDFS_TABLE_SINK = 2
|
|
66
|
-
|
|
67
|
-
FIELDS = {
|
|
68
|
-
TARGET_TABLE_ID => { :type => ::Thrift::Types::I32, :name => 'target_table_id' },
|
|
69
|
-
HDFS_TABLE_SINK => { :type => ::Thrift::Types::STRUCT, :name => 'hdfs_table_sink', :class => Impala::Protocol::THdfsTableSink }
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
def struct_fields; FIELDS; end
|
|
73
|
-
|
|
74
|
-
def validate
|
|
75
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field target_table_id is unset!') unless @target_table_id
|
|
76
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field hdfs_table_sink is unset!') unless @hdfs_table_sink
|
|
77
|
-
end
|
|
78
|
-
|
|
79
|
-
::Thrift::Struct.generate_accessors self
|
|
80
|
-
end
|
|
81
|
-
|
|
82
|
-
class TDataSink
|
|
83
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
84
|
-
TYPE = 1
|
|
85
|
-
STREAM_SINK = 2
|
|
86
|
-
TABLE_SINK = 3
|
|
87
|
-
|
|
88
|
-
FIELDS = {
|
|
89
|
-
TYPE => { :type => ::Thrift::Types::I32, :name => 'type', :enum_class => Impala::Protocol::TDataSinkType },
|
|
90
|
-
STREAM_SINK => { :type => ::Thrift::Types::STRUCT, :name => 'stream_sink', :class => Impala::Protocol::TDataStreamSink, :optional => true },
|
|
91
|
-
TABLE_SINK => { :type => ::Thrift::Types::STRUCT, :name => 'table_sink', :class => Impala::Protocol::TTableSink, :optional => true }
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
def struct_fields; FIELDS; end
|
|
95
|
-
|
|
96
|
-
def validate
|
|
97
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field type is unset!') unless @type
|
|
98
|
-
unless @type.nil? || Impala::Protocol::TDataSinkType::VALID_VALUES.include?(@type)
|
|
99
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field type!')
|
|
100
|
-
end
|
|
101
|
-
end
|
|
102
|
-
|
|
103
|
-
::Thrift::Struct.generate_accessors self
|
|
104
|
-
end
|
|
105
|
-
|
|
106
|
-
end
|
|
107
|
-
end
|
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
#
|
|
2
|
-
# Autogenerated by Thrift Compiler (0.8.0)
|
|
3
|
-
#
|
|
4
|
-
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
|
5
|
-
#
|
|
6
|
-
|
|
7
|
-
require 'types_types'
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
module Impala
|
|
11
|
-
module Protocol
|
|
12
|
-
class TRowBatch
|
|
13
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
14
|
-
NUM_ROWS = 1
|
|
15
|
-
ROW_TUPLES = 2
|
|
16
|
-
TUPLE_OFFSETS = 3
|
|
17
|
-
TUPLE_DATA = 4
|
|
18
|
-
|
|
19
|
-
FIELDS = {
|
|
20
|
-
NUM_ROWS => { :type => ::Thrift::Types::I32, :name => 'num_rows' },
|
|
21
|
-
ROW_TUPLES => { :type => ::Thrift::Types::LIST, :name => 'row_tuples', :element => { :type => ::Thrift::Types::I32 } },
|
|
22
|
-
TUPLE_OFFSETS => { :type => ::Thrift::Types::LIST, :name => 'tuple_offsets', :element => { :type => ::Thrift::Types::I32 } },
|
|
23
|
-
TUPLE_DATA => { :type => ::Thrift::Types::LIST, :name => 'tuple_data', :element => { :type => ::Thrift::Types::STRING } }
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
def struct_fields; FIELDS; end
|
|
27
|
-
|
|
28
|
-
def validate
|
|
29
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field num_rows is unset!') unless @num_rows
|
|
30
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field row_tuples is unset!') unless @row_tuples
|
|
31
|
-
end
|
|
32
|
-
|
|
33
|
-
::Thrift::Struct.generate_accessors self
|
|
34
|
-
end
|
|
35
|
-
|
|
36
|
-
class TColumnValue
|
|
37
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
38
|
-
BOOLVAL = 1
|
|
39
|
-
INTVAL = 2
|
|
40
|
-
LONGVAL = 3
|
|
41
|
-
DOUBLEVAL = 4
|
|
42
|
-
STRINGVAL = 5
|
|
43
|
-
|
|
44
|
-
FIELDS = {
|
|
45
|
-
BOOLVAL => { :type => ::Thrift::Types::BOOL, :name => 'boolVal', :optional => true },
|
|
46
|
-
INTVAL => { :type => ::Thrift::Types::I32, :name => 'intVal', :optional => true },
|
|
47
|
-
LONGVAL => { :type => ::Thrift::Types::I64, :name => 'longVal', :optional => true },
|
|
48
|
-
DOUBLEVAL => { :type => ::Thrift::Types::DOUBLE, :name => 'doubleVal', :optional => true },
|
|
49
|
-
STRINGVAL => { :type => ::Thrift::Types::STRING, :name => 'stringVal', :optional => true }
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
def struct_fields; FIELDS; end
|
|
53
|
-
|
|
54
|
-
def validate
|
|
55
|
-
end
|
|
56
|
-
|
|
57
|
-
::Thrift::Struct.generate_accessors self
|
|
58
|
-
end
|
|
59
|
-
|
|
60
|
-
class TResultRow
|
|
61
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
62
|
-
COLVALS = 1
|
|
63
|
-
|
|
64
|
-
FIELDS = {
|
|
65
|
-
COLVALS => { :type => ::Thrift::Types::LIST, :name => 'colVals', :element => { :type => ::Thrift::Types::STRUCT, :class => Impala::Protocol::TColumnValue } }
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
def struct_fields; FIELDS; end
|
|
69
|
-
|
|
70
|
-
def validate
|
|
71
|
-
end
|
|
72
|
-
|
|
73
|
-
::Thrift::Struct.generate_accessors self
|
|
74
|
-
end
|
|
75
|
-
|
|
76
|
-
end
|
|
77
|
-
end
|
|
@@ -1,266 +0,0 @@
|
|
|
1
|
-
#
|
|
2
|
-
# Autogenerated by Thrift Compiler (0.8.0)
|
|
3
|
-
#
|
|
4
|
-
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
|
5
|
-
#
|
|
6
|
-
|
|
7
|
-
require 'types_types'
|
|
8
|
-
require 'exprs_types'
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
module Impala
|
|
12
|
-
module Protocol
|
|
13
|
-
module TTableType
|
|
14
|
-
HDFS_TABLE = 0
|
|
15
|
-
HBASE_TABLE = 1
|
|
16
|
-
VALUE_MAP = { 0 => "HDFS_TABLE", 1 => "HBASE_TABLE" }
|
|
17
|
-
VALID_VALUES = Set.new([HDFS_TABLE, HBASE_TABLE]).freeze
|
|
18
|
-
end
|
|
19
|
-
|
|
20
|
-
module THdfsFileFormat
|
|
21
|
-
TEXT = 0
|
|
22
|
-
LZO_TEXT = 1
|
|
23
|
-
RC_FILE = 2
|
|
24
|
-
SEQUENCE_FILE = 3
|
|
25
|
-
TREVNI = 4
|
|
26
|
-
VALUE_MAP = { 0 => "TEXT", 1 => "LZO_TEXT", 2 => "RC_FILE", 3 => "SEQUENCE_FILE", 4 => "TREVNI" }
|
|
27
|
-
VALID_VALUES = Set.new([TEXT, LZO_TEXT, RC_FILE, SEQUENCE_FILE, TREVNI]).freeze
|
|
28
|
-
end
|
|
29
|
-
|
|
30
|
-
module THdfsCompression
|
|
31
|
-
NONE = 0
|
|
32
|
-
DEFAULT = 1
|
|
33
|
-
GZIP = 2
|
|
34
|
-
BZIP2 = 3
|
|
35
|
-
SNAPPY = 4
|
|
36
|
-
SNAPPY_BLOCKED = 5
|
|
37
|
-
VALUE_MAP = { 0 => "NONE", 1 => "DEFAULT", 2 => "GZIP", 3 => "BZIP2", 4 => "SNAPPY", 5 => "SNAPPY_BLOCKED" }
|
|
38
|
-
VALID_VALUES = Set.new([NONE, DEFAULT, GZIP, BZIP2, SNAPPY, SNAPPY_BLOCKED]).freeze
|
|
39
|
-
end
|
|
40
|
-
|
|
41
|
-
class TSlotDescriptor
|
|
42
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
43
|
-
ID = 1
|
|
44
|
-
PARENT = 2
|
|
45
|
-
SLOTTYPE = 3
|
|
46
|
-
COLUMNPOS = 4
|
|
47
|
-
BYTEOFFSET = 5
|
|
48
|
-
NULLINDICATORBYTE = 6
|
|
49
|
-
NULLINDICATORBIT = 7
|
|
50
|
-
SLOTIDX = 9
|
|
51
|
-
ISMATERIALIZED = 10
|
|
52
|
-
|
|
53
|
-
FIELDS = {
|
|
54
|
-
ID => { :type => ::Thrift::Types::I32, :name => 'id' },
|
|
55
|
-
PARENT => { :type => ::Thrift::Types::I32, :name => 'parent' },
|
|
56
|
-
SLOTTYPE => { :type => ::Thrift::Types::I32, :name => 'slotType', :enum_class => Impala::Protocol::TPrimitiveType },
|
|
57
|
-
COLUMNPOS => { :type => ::Thrift::Types::I32, :name => 'columnPos' },
|
|
58
|
-
BYTEOFFSET => { :type => ::Thrift::Types::I32, :name => 'byteOffset' },
|
|
59
|
-
NULLINDICATORBYTE => { :type => ::Thrift::Types::I32, :name => 'nullIndicatorByte' },
|
|
60
|
-
NULLINDICATORBIT => { :type => ::Thrift::Types::I32, :name => 'nullIndicatorBit' },
|
|
61
|
-
SLOTIDX => { :type => ::Thrift::Types::I32, :name => 'slotIdx' },
|
|
62
|
-
ISMATERIALIZED => { :type => ::Thrift::Types::BOOL, :name => 'isMaterialized' }
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
def struct_fields; FIELDS; end
|
|
66
|
-
|
|
67
|
-
def validate
|
|
68
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field id is unset!') unless @id
|
|
69
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field parent is unset!') unless @parent
|
|
70
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field slotType is unset!') unless @slotType
|
|
71
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field columnPos is unset!') unless @columnPos
|
|
72
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field byteOffset is unset!') unless @byteOffset
|
|
73
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nullIndicatorByte is unset!') unless @nullIndicatorByte
|
|
74
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nullIndicatorBit is unset!') unless @nullIndicatorBit
|
|
75
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field slotIdx is unset!') unless @slotIdx
|
|
76
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field isMaterialized is unset!') if @isMaterialized.nil?
|
|
77
|
-
unless @slotType.nil? || Impala::Protocol::TPrimitiveType::VALID_VALUES.include?(@slotType)
|
|
78
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field slotType!')
|
|
79
|
-
end
|
|
80
|
-
end
|
|
81
|
-
|
|
82
|
-
::Thrift::Struct.generate_accessors self
|
|
83
|
-
end
|
|
84
|
-
|
|
85
|
-
class THdfsPartition
|
|
86
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
87
|
-
LINEDELIM = 1
|
|
88
|
-
FIELDDELIM = 2
|
|
89
|
-
COLLECTIONDELIM = 3
|
|
90
|
-
MAPKEYDELIM = 4
|
|
91
|
-
ESCAPECHAR = 5
|
|
92
|
-
FILEFORMAT = 6
|
|
93
|
-
PARTITIONKEYEXPRS = 7
|
|
94
|
-
BLOCKSIZE = 8
|
|
95
|
-
COMPRESSION = 9
|
|
96
|
-
|
|
97
|
-
FIELDS = {
|
|
98
|
-
LINEDELIM => { :type => ::Thrift::Types::BYTE, :name => 'lineDelim' },
|
|
99
|
-
FIELDDELIM => { :type => ::Thrift::Types::BYTE, :name => 'fieldDelim' },
|
|
100
|
-
COLLECTIONDELIM => { :type => ::Thrift::Types::BYTE, :name => 'collectionDelim' },
|
|
101
|
-
MAPKEYDELIM => { :type => ::Thrift::Types::BYTE, :name => 'mapKeyDelim' },
|
|
102
|
-
ESCAPECHAR => { :type => ::Thrift::Types::BYTE, :name => 'escapeChar' },
|
|
103
|
-
FILEFORMAT => { :type => ::Thrift::Types::I32, :name => 'fileFormat', :enum_class => Impala::Protocol::THdfsFileFormat },
|
|
104
|
-
PARTITIONKEYEXPRS => { :type => ::Thrift::Types::LIST, :name => 'partitionKeyExprs', :element => { :type => ::Thrift::Types::STRUCT, :class => Impala::Protocol::TExpr } },
|
|
105
|
-
BLOCKSIZE => { :type => ::Thrift::Types::I32, :name => 'blockSize' },
|
|
106
|
-
COMPRESSION => { :type => ::Thrift::Types::I32, :name => 'compression', :enum_class => Impala::Protocol::THdfsCompression }
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
def struct_fields; FIELDS; end
|
|
110
|
-
|
|
111
|
-
def validate
|
|
112
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field lineDelim is unset!') unless @lineDelim
|
|
113
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field fieldDelim is unset!') unless @fieldDelim
|
|
114
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field collectionDelim is unset!') unless @collectionDelim
|
|
115
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field mapKeyDelim is unset!') unless @mapKeyDelim
|
|
116
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field escapeChar is unset!') unless @escapeChar
|
|
117
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field fileFormat is unset!') unless @fileFormat
|
|
118
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field blockSize is unset!') unless @blockSize
|
|
119
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field compression is unset!') unless @compression
|
|
120
|
-
unless @fileFormat.nil? || Impala::Protocol::THdfsFileFormat::VALID_VALUES.include?(@fileFormat)
|
|
121
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field fileFormat!')
|
|
122
|
-
end
|
|
123
|
-
unless @compression.nil? || Impala::Protocol::THdfsCompression::VALID_VALUES.include?(@compression)
|
|
124
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field compression!')
|
|
125
|
-
end
|
|
126
|
-
end
|
|
127
|
-
|
|
128
|
-
::Thrift::Struct.generate_accessors self
|
|
129
|
-
end
|
|
130
|
-
|
|
131
|
-
class THdfsTable
|
|
132
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
133
|
-
HDFSBASEDIR = 1
|
|
134
|
-
PARTITIONKEYNAMES = 2
|
|
135
|
-
NULLPARTITIONKEYVALUE = 3
|
|
136
|
-
PARTITIONS = 4
|
|
137
|
-
|
|
138
|
-
FIELDS = {
|
|
139
|
-
HDFSBASEDIR => { :type => ::Thrift::Types::STRING, :name => 'hdfsBaseDir' },
|
|
140
|
-
PARTITIONKEYNAMES => { :type => ::Thrift::Types::LIST, :name => 'partitionKeyNames', :element => { :type => ::Thrift::Types::STRING } },
|
|
141
|
-
NULLPARTITIONKEYVALUE => { :type => ::Thrift::Types::STRING, :name => 'nullPartitionKeyValue' },
|
|
142
|
-
PARTITIONS => { :type => ::Thrift::Types::MAP, :name => 'partitions', :key => { :type => ::Thrift::Types::I64 }, :value => { :type => ::Thrift::Types::STRUCT, :class => Impala::Protocol::THdfsPartition } }
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
def struct_fields; FIELDS; end
|
|
146
|
-
|
|
147
|
-
def validate
|
|
148
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field hdfsBaseDir is unset!') unless @hdfsBaseDir
|
|
149
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field partitionKeyNames is unset!') unless @partitionKeyNames
|
|
150
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nullPartitionKeyValue is unset!') unless @nullPartitionKeyValue
|
|
151
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field partitions is unset!') unless @partitions
|
|
152
|
-
end
|
|
153
|
-
|
|
154
|
-
::Thrift::Struct.generate_accessors self
|
|
155
|
-
end
|
|
156
|
-
|
|
157
|
-
class THBaseTable
|
|
158
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
159
|
-
TABLENAME = 1
|
|
160
|
-
FAMILIES = 2
|
|
161
|
-
QUALIFIERS = 3
|
|
162
|
-
|
|
163
|
-
FIELDS = {
|
|
164
|
-
TABLENAME => { :type => ::Thrift::Types::STRING, :name => 'tableName' },
|
|
165
|
-
FAMILIES => { :type => ::Thrift::Types::LIST, :name => 'families', :element => { :type => ::Thrift::Types::STRING } },
|
|
166
|
-
QUALIFIERS => { :type => ::Thrift::Types::LIST, :name => 'qualifiers', :element => { :type => ::Thrift::Types::STRING } }
|
|
167
|
-
}
|
|
168
|
-
|
|
169
|
-
def struct_fields; FIELDS; end
|
|
170
|
-
|
|
171
|
-
def validate
|
|
172
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field tableName is unset!') unless @tableName
|
|
173
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field families is unset!') unless @families
|
|
174
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field qualifiers is unset!') unless @qualifiers
|
|
175
|
-
end
|
|
176
|
-
|
|
177
|
-
::Thrift::Struct.generate_accessors self
|
|
178
|
-
end
|
|
179
|
-
|
|
180
|
-
class TTableDescriptor
|
|
181
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
182
|
-
ID = 1
|
|
183
|
-
TABLETYPE = 2
|
|
184
|
-
NUMCOLS = 3
|
|
185
|
-
NUMCLUSTERINGCOLS = 4
|
|
186
|
-
HDFSTABLE = 5
|
|
187
|
-
HBASETABLE = 6
|
|
188
|
-
TABLENAME = 7
|
|
189
|
-
DBNAME = 8
|
|
190
|
-
|
|
191
|
-
FIELDS = {
|
|
192
|
-
ID => { :type => ::Thrift::Types::I32, :name => 'id' },
|
|
193
|
-
TABLETYPE => { :type => ::Thrift::Types::I32, :name => 'tableType', :enum_class => Impala::Protocol::TTableType },
|
|
194
|
-
NUMCOLS => { :type => ::Thrift::Types::I32, :name => 'numCols' },
|
|
195
|
-
NUMCLUSTERINGCOLS => { :type => ::Thrift::Types::I32, :name => 'numClusteringCols' },
|
|
196
|
-
HDFSTABLE => { :type => ::Thrift::Types::STRUCT, :name => 'hdfsTable', :class => Impala::Protocol::THdfsTable, :optional => true },
|
|
197
|
-
HBASETABLE => { :type => ::Thrift::Types::STRUCT, :name => 'hbaseTable', :class => Impala::Protocol::THBaseTable, :optional => true },
|
|
198
|
-
TABLENAME => { :type => ::Thrift::Types::STRING, :name => 'tableName' },
|
|
199
|
-
DBNAME => { :type => ::Thrift::Types::STRING, :name => 'dbName' }
|
|
200
|
-
}
|
|
201
|
-
|
|
202
|
-
def struct_fields; FIELDS; end
|
|
203
|
-
|
|
204
|
-
def validate
|
|
205
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field id is unset!') unless @id
|
|
206
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field tableType is unset!') unless @tableType
|
|
207
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field numCols is unset!') unless @numCols
|
|
208
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field numClusteringCols is unset!') unless @numClusteringCols
|
|
209
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field tableName is unset!') unless @tableName
|
|
210
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field dbName is unset!') unless @dbName
|
|
211
|
-
unless @tableType.nil? || Impala::Protocol::TTableType::VALID_VALUES.include?(@tableType)
|
|
212
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field tableType!')
|
|
213
|
-
end
|
|
214
|
-
end
|
|
215
|
-
|
|
216
|
-
::Thrift::Struct.generate_accessors self
|
|
217
|
-
end
|
|
218
|
-
|
|
219
|
-
class TTupleDescriptor
|
|
220
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
221
|
-
ID = 1
|
|
222
|
-
BYTESIZE = 2
|
|
223
|
-
NUMNULLBYTES = 3
|
|
224
|
-
TABLEID = 4
|
|
225
|
-
|
|
226
|
-
FIELDS = {
|
|
227
|
-
ID => { :type => ::Thrift::Types::I32, :name => 'id' },
|
|
228
|
-
BYTESIZE => { :type => ::Thrift::Types::I32, :name => 'byteSize' },
|
|
229
|
-
NUMNULLBYTES => { :type => ::Thrift::Types::I32, :name => 'numNullBytes' },
|
|
230
|
-
TABLEID => { :type => ::Thrift::Types::I32, :name => 'tableId', :optional => true }
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
def struct_fields; FIELDS; end
|
|
234
|
-
|
|
235
|
-
def validate
|
|
236
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field id is unset!') unless @id
|
|
237
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field byteSize is unset!') unless @byteSize
|
|
238
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field numNullBytes is unset!') unless @numNullBytes
|
|
239
|
-
end
|
|
240
|
-
|
|
241
|
-
::Thrift::Struct.generate_accessors self
|
|
242
|
-
end
|
|
243
|
-
|
|
244
|
-
class TDescriptorTable
|
|
245
|
-
include ::Thrift::Struct, ::Thrift::Struct_Union
|
|
246
|
-
SLOTDESCRIPTORS = 1
|
|
247
|
-
TUPLEDESCRIPTORS = 2
|
|
248
|
-
TABLEDESCRIPTORS = 3
|
|
249
|
-
|
|
250
|
-
FIELDS = {
|
|
251
|
-
SLOTDESCRIPTORS => { :type => ::Thrift::Types::LIST, :name => 'slotDescriptors', :element => { :type => ::Thrift::Types::STRUCT, :class => Impala::Protocol::TSlotDescriptor }, :optional => true },
|
|
252
|
-
TUPLEDESCRIPTORS => { :type => ::Thrift::Types::LIST, :name => 'tupleDescriptors', :element => { :type => ::Thrift::Types::STRUCT, :class => Impala::Protocol::TTupleDescriptor } },
|
|
253
|
-
TABLEDESCRIPTORS => { :type => ::Thrift::Types::LIST, :name => 'tableDescriptors', :element => { :type => ::Thrift::Types::STRUCT, :class => Impala::Protocol::TTableDescriptor }, :optional => true }
|
|
254
|
-
}
|
|
255
|
-
|
|
256
|
-
def struct_fields; FIELDS; end
|
|
257
|
-
|
|
258
|
-
def validate
|
|
259
|
-
raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field tupleDescriptors is unset!') unless @tupleDescriptors
|
|
260
|
-
end
|
|
261
|
-
|
|
262
|
-
::Thrift::Struct.generate_accessors self
|
|
263
|
-
end
|
|
264
|
-
|
|
265
|
-
end
|
|
266
|
-
end
|