rbhive 0.2.95 → 0.5.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.
@@ -1,8 +1,9 @@
1
1
  #
2
- # Autogenerated by Thrift
2
+ # Autogenerated by Thrift Compiler (0.9.0)
3
3
  #
4
4
  # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
5
  #
6
6
 
7
- require File.join(File.dirname(__FILE__), *%w[fb303_types])
7
+ require 'thrift'
8
+ require_relative 'fb303_types'
8
9
 
@@ -1,9 +1,10 @@
1
1
  #
2
- # Autogenerated by Thrift
2
+ # Autogenerated by Thrift Compiler (0.9.0)
3
3
  #
4
4
  # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
5
  #
6
6
 
7
+ require 'thrift'
7
8
 
8
9
  module Fb_status
9
10
  DEAD = 0
@@ -1,11 +1,11 @@
1
1
  #
2
- # Autogenerated by Thrift
2
+ # Autogenerated by Thrift Compiler (0.9.0)
3
3
  #
4
4
  # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
5
  #
6
6
 
7
- require File.join(File.dirname(__FILE__), *%w[hive_metastore_types])
8
-
7
+ require 'thrift'
8
+ require_relative 'hive_metastore_types'
9
9
 
10
10
  DDL_TIME = %q"transient_lastDdlTime"
11
11
 
@@ -1,12 +1,31 @@
1
1
  #
2
- # Autogenerated by Thrift
2
+ # Autogenerated by Thrift Compiler (0.9.0)
3
3
  #
4
4
  # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
5
  #
6
6
 
7
- require File.join(File.dirname(__FILE__), *%w[fb303_types])
7
+ require 'thrift'
8
+ require_relative 'fb303_types'
8
9
 
9
10
 
11
+ module HiveObjectType
12
+ GLOBAL = 1
13
+ DATABASE = 2
14
+ TABLE = 3
15
+ PARTITION = 4
16
+ COLUMN = 5
17
+ VALUE_MAP = {1 => "GLOBAL", 2 => "DATABASE", 3 => "TABLE", 4 => "PARTITION", 5 => "COLUMN"}
18
+ VALID_VALUES = Set.new([GLOBAL, DATABASE, TABLE, PARTITION, COLUMN]).freeze
19
+ end
20
+
21
+ module PrincipalType
22
+ USER = 1
23
+ ROLE = 2
24
+ GROUP = 3
25
+ VALUE_MAP = {1 => "USER", 2 => "ROLE", 3 => "GROUP"}
26
+ VALID_VALUES = Set.new([USER, ROLE, GROUP]).freeze
27
+ end
28
+
10
29
  class Version
11
30
  include ::Thrift::Struct, ::Thrift::Struct_Union
12
31
  VERSION = 1
@@ -56,7 +75,142 @@ class Type
56
75
  NAME => {:type => ::Thrift::Types::STRING, :name => 'name'},
57
76
  TYPE1 => {:type => ::Thrift::Types::STRING, :name => 'type1', :optional => true},
58
77
  TYPE2 => {:type => ::Thrift::Types::STRING, :name => 'type2', :optional => true},
59
- FIELDS => {:type => ::Thrift::Types::LIST, :name => 'fields', :element => {:type => ::Thrift::Types::STRUCT, :class => FieldSchema}, :optional => true}
78
+ FIELDS => {:type => ::Thrift::Types::LIST, :name => 'fields', :element => {:type => ::Thrift::Types::STRUCT, :class => ::FieldSchema}, :optional => true}
79
+ }
80
+
81
+ def struct_fields; FIELDS; end
82
+
83
+ def validate
84
+ end
85
+
86
+ ::Thrift::Struct.generate_accessors self
87
+ end
88
+
89
+ class HiveObjectRef
90
+ include ::Thrift::Struct, ::Thrift::Struct_Union
91
+ OBJECTTYPE = 1
92
+ DBNAME = 2
93
+ OBJECTNAME = 3
94
+ PARTVALUES = 4
95
+ COLUMNNAME = 5
96
+
97
+ FIELDS = {
98
+ OBJECTTYPE => {:type => ::Thrift::Types::I32, :name => 'objectType', :enum_class => ::HiveObjectType},
99
+ DBNAME => {:type => ::Thrift::Types::STRING, :name => 'dbName'},
100
+ OBJECTNAME => {:type => ::Thrift::Types::STRING, :name => 'objectName'},
101
+ PARTVALUES => {:type => ::Thrift::Types::LIST, :name => 'partValues', :element => {:type => ::Thrift::Types::STRING}},
102
+ COLUMNNAME => {:type => ::Thrift::Types::STRING, :name => 'columnName'}
103
+ }
104
+
105
+ def struct_fields; FIELDS; end
106
+
107
+ def validate
108
+ unless @objectType.nil? || ::HiveObjectType::VALID_VALUES.include?(@objectType)
109
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field objectType!')
110
+ end
111
+ end
112
+
113
+ ::Thrift::Struct.generate_accessors self
114
+ end
115
+
116
+ class PrivilegeGrantInfo
117
+ include ::Thrift::Struct, ::Thrift::Struct_Union
118
+ PRIVILEGE = 1
119
+ CREATETIME = 2
120
+ GRANTOR = 3
121
+ GRANTORTYPE = 4
122
+ GRANTOPTION = 5
123
+
124
+ FIELDS = {
125
+ PRIVILEGE => {:type => ::Thrift::Types::STRING, :name => 'privilege'},
126
+ CREATETIME => {:type => ::Thrift::Types::I32, :name => 'createTime'},
127
+ GRANTOR => {:type => ::Thrift::Types::STRING, :name => 'grantor'},
128
+ GRANTORTYPE => {:type => ::Thrift::Types::I32, :name => 'grantorType', :enum_class => ::PrincipalType},
129
+ GRANTOPTION => {:type => ::Thrift::Types::BOOL, :name => 'grantOption'}
130
+ }
131
+
132
+ def struct_fields; FIELDS; end
133
+
134
+ def validate
135
+ unless @grantorType.nil? || ::PrincipalType::VALID_VALUES.include?(@grantorType)
136
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field grantorType!')
137
+ end
138
+ end
139
+
140
+ ::Thrift::Struct.generate_accessors self
141
+ end
142
+
143
+ class HiveObjectPrivilege
144
+ include ::Thrift::Struct, ::Thrift::Struct_Union
145
+ HIVEOBJECT = 1
146
+ PRINCIPALNAME = 2
147
+ PRINCIPALTYPE = 3
148
+ GRANTINFO = 4
149
+
150
+ FIELDS = {
151
+ HIVEOBJECT => {:type => ::Thrift::Types::STRUCT, :name => 'hiveObject', :class => ::HiveObjectRef},
152
+ PRINCIPALNAME => {:type => ::Thrift::Types::STRING, :name => 'principalName'},
153
+ PRINCIPALTYPE => {:type => ::Thrift::Types::I32, :name => 'principalType', :enum_class => ::PrincipalType},
154
+ GRANTINFO => {:type => ::Thrift::Types::STRUCT, :name => 'grantInfo', :class => ::PrivilegeGrantInfo}
155
+ }
156
+
157
+ def struct_fields; FIELDS; end
158
+
159
+ def validate
160
+ unless @principalType.nil? || ::PrincipalType::VALID_VALUES.include?(@principalType)
161
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field principalType!')
162
+ end
163
+ end
164
+
165
+ ::Thrift::Struct.generate_accessors self
166
+ end
167
+
168
+ class PrivilegeBag
169
+ include ::Thrift::Struct, ::Thrift::Struct_Union
170
+ PRIVILEGES = 1
171
+
172
+ FIELDS = {
173
+ PRIVILEGES => {:type => ::Thrift::Types::LIST, :name => 'privileges', :element => {:type => ::Thrift::Types::STRUCT, :class => ::HiveObjectPrivilege}}
174
+ }
175
+
176
+ def struct_fields; FIELDS; end
177
+
178
+ def validate
179
+ end
180
+
181
+ ::Thrift::Struct.generate_accessors self
182
+ end
183
+
184
+ class PrincipalPrivilegeSet
185
+ include ::Thrift::Struct, ::Thrift::Struct_Union
186
+ USERPRIVILEGES = 1
187
+ GROUPPRIVILEGES = 2
188
+ ROLEPRIVILEGES = 3
189
+
190
+ FIELDS = {
191
+ USERPRIVILEGES => {:type => ::Thrift::Types::MAP, :name => 'userPrivileges', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::LIST, :element => {:type => ::Thrift::Types::STRUCT, :class => ::PrivilegeGrantInfo}}},
192
+ GROUPPRIVILEGES => {:type => ::Thrift::Types::MAP, :name => 'groupPrivileges', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::LIST, :element => {:type => ::Thrift::Types::STRUCT, :class => ::PrivilegeGrantInfo}}},
193
+ ROLEPRIVILEGES => {:type => ::Thrift::Types::MAP, :name => 'rolePrivileges', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::LIST, :element => {:type => ::Thrift::Types::STRUCT, :class => ::PrivilegeGrantInfo}}}
194
+ }
195
+
196
+ def struct_fields; FIELDS; end
197
+
198
+ def validate
199
+ end
200
+
201
+ ::Thrift::Struct.generate_accessors self
202
+ end
203
+
204
+ class Role
205
+ include ::Thrift::Struct, ::Thrift::Struct_Union
206
+ ROLENAME = 1
207
+ CREATETIME = 2
208
+ OWNERNAME = 3
209
+
210
+ FIELDS = {
211
+ ROLENAME => {:type => ::Thrift::Types::STRING, :name => 'roleName'},
212
+ CREATETIME => {:type => ::Thrift::Types::I32, :name => 'createTime'},
213
+ OWNERNAME => {:type => ::Thrift::Types::STRING, :name => 'ownerName'}
60
214
  }
61
215
 
62
216
  def struct_fields; FIELDS; end
@@ -72,11 +226,15 @@ class Database
72
226
  NAME = 1
73
227
  DESCRIPTION = 2
74
228
  LOCATIONURI = 3
229
+ PARAMETERS = 4
230
+ PRIVILEGES = 5
75
231
 
76
232
  FIELDS = {
77
233
  NAME => {:type => ::Thrift::Types::STRING, :name => 'name'},
78
234
  DESCRIPTION => {:type => ::Thrift::Types::STRING, :name => 'description'},
79
- LOCATIONURI => {:type => ::Thrift::Types::STRING, :name => 'locationUri'}
235
+ LOCATIONURI => {:type => ::Thrift::Types::STRING, :name => 'locationUri'},
236
+ PARAMETERS => {:type => ::Thrift::Types::MAP, :name => 'parameters', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}},
237
+ PRIVILEGES => {:type => ::Thrift::Types::STRUCT, :name => 'privileges', :class => ::PrincipalPrivilegeSet, :optional => true}
80
238
  }
81
239
 
82
240
  def struct_fields; FIELDS; end
@@ -139,15 +297,15 @@ class StorageDescriptor
139
297
  PARAMETERS = 10
140
298
 
141
299
  FIELDS = {
142
- COLS => {:type => ::Thrift::Types::LIST, :name => 'cols', :element => {:type => ::Thrift::Types::STRUCT, :class => FieldSchema}},
300
+ COLS => {:type => ::Thrift::Types::LIST, :name => 'cols', :element => {:type => ::Thrift::Types::STRUCT, :class => ::FieldSchema}},
143
301
  LOCATION => {:type => ::Thrift::Types::STRING, :name => 'location'},
144
302
  INPUTFORMAT => {:type => ::Thrift::Types::STRING, :name => 'inputFormat'},
145
303
  OUTPUTFORMAT => {:type => ::Thrift::Types::STRING, :name => 'outputFormat'},
146
304
  COMPRESSED => {:type => ::Thrift::Types::BOOL, :name => 'compressed'},
147
305
  NUMBUCKETS => {:type => ::Thrift::Types::I32, :name => 'numBuckets'},
148
- SERDEINFO => {:type => ::Thrift::Types::STRUCT, :name => 'serdeInfo', :class => SerDeInfo},
306
+ SERDEINFO => {:type => ::Thrift::Types::STRUCT, :name => 'serdeInfo', :class => ::SerDeInfo},
149
307
  BUCKETCOLS => {:type => ::Thrift::Types::LIST, :name => 'bucketCols', :element => {:type => ::Thrift::Types::STRING}},
150
- SORTCOLS => {:type => ::Thrift::Types::LIST, :name => 'sortCols', :element => {:type => ::Thrift::Types::STRUCT, :class => Order}},
308
+ SORTCOLS => {:type => ::Thrift::Types::LIST, :name => 'sortCols', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Order}},
151
309
  PARAMETERS => {:type => ::Thrift::Types::MAP, :name => 'parameters', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}}
152
310
  }
153
311
 
@@ -173,6 +331,7 @@ class Table
173
331
  VIEWORIGINALTEXT = 10
174
332
  VIEWEXPANDEDTEXT = 11
175
333
  TABLETYPE = 12
334
+ PRIVILEGES = 13
176
335
 
177
336
  FIELDS = {
178
337
  TABLENAME => {:type => ::Thrift::Types::STRING, :name => 'tableName'},
@@ -181,12 +340,13 @@ class Table
181
340
  CREATETIME => {:type => ::Thrift::Types::I32, :name => 'createTime'},
182
341
  LASTACCESSTIME => {:type => ::Thrift::Types::I32, :name => 'lastAccessTime'},
183
342
  RETENTION => {:type => ::Thrift::Types::I32, :name => 'retention'},
184
- SD => {:type => ::Thrift::Types::STRUCT, :name => 'sd', :class => StorageDescriptor},
185
- PARTITIONKEYS => {:type => ::Thrift::Types::LIST, :name => 'partitionKeys', :element => {:type => ::Thrift::Types::STRUCT, :class => FieldSchema}},
343
+ SD => {:type => ::Thrift::Types::STRUCT, :name => 'sd', :class => ::StorageDescriptor},
344
+ PARTITIONKEYS => {:type => ::Thrift::Types::LIST, :name => 'partitionKeys', :element => {:type => ::Thrift::Types::STRUCT, :class => ::FieldSchema}},
186
345
  PARAMETERS => {:type => ::Thrift::Types::MAP, :name => 'parameters', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}},
187
346
  VIEWORIGINALTEXT => {:type => ::Thrift::Types::STRING, :name => 'viewOriginalText'},
188
347
  VIEWEXPANDEDTEXT => {:type => ::Thrift::Types::STRING, :name => 'viewExpandedText'},
189
- TABLETYPE => {:type => ::Thrift::Types::STRING, :name => 'tableType'}
348
+ TABLETYPE => {:type => ::Thrift::Types::STRING, :name => 'tableType'},
349
+ PRIVILEGES => {:type => ::Thrift::Types::STRUCT, :name => 'privileges', :class => ::PrincipalPrivilegeSet, :optional => true}
190
350
  }
191
351
 
192
352
  def struct_fields; FIELDS; end
@@ -206,6 +366,7 @@ class Partition
206
366
  LASTACCESSTIME = 5
207
367
  SD = 6
208
368
  PARAMETERS = 7
369
+ PRIVILEGES = 8
209
370
 
210
371
  FIELDS = {
211
372
  VALUES => {:type => ::Thrift::Types::LIST, :name => 'values', :element => {:type => ::Thrift::Types::STRING}},
@@ -213,8 +374,9 @@ class Partition
213
374
  TABLENAME => {:type => ::Thrift::Types::STRING, :name => 'tableName'},
214
375
  CREATETIME => {:type => ::Thrift::Types::I32, :name => 'createTime'},
215
376
  LASTACCESSTIME => {:type => ::Thrift::Types::I32, :name => 'lastAccessTime'},
216
- SD => {:type => ::Thrift::Types::STRUCT, :name => 'sd', :class => StorageDescriptor},
217
- PARAMETERS => {:type => ::Thrift::Types::MAP, :name => 'parameters', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}}
377
+ SD => {:type => ::Thrift::Types::STRUCT, :name => 'sd', :class => ::StorageDescriptor},
378
+ PARAMETERS => {:type => ::Thrift::Types::MAP, :name => 'parameters', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}},
379
+ PRIVILEGES => {:type => ::Thrift::Types::STRUCT, :name => 'privileges', :class => ::PrincipalPrivilegeSet, :optional => true}
218
380
  }
219
381
 
220
382
  def struct_fields; FIELDS; end
@@ -246,7 +408,7 @@ class Index
246
408
  CREATETIME => {:type => ::Thrift::Types::I32, :name => 'createTime'},
247
409
  LASTACCESSTIME => {:type => ::Thrift::Types::I32, :name => 'lastAccessTime'},
248
410
  INDEXTABLENAME => {:type => ::Thrift::Types::STRING, :name => 'indexTableName'},
249
- SD => {:type => ::Thrift::Types::STRUCT, :name => 'sd', :class => StorageDescriptor},
411
+ SD => {:type => ::Thrift::Types::STRUCT, :name => 'sd', :class => ::StorageDescriptor},
250
412
  PARAMETERS => {:type => ::Thrift::Types::MAP, :name => 'parameters', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}},
251
413
  DEFERREDREBUILD => {:type => ::Thrift::Types::BOOL, :name => 'deferredRebuild'}
252
414
  }
@@ -265,7 +427,7 @@ class Schema
265
427
  PROPERTIES = 2
266
428
 
267
429
  FIELDS = {
268
- FIELDSCHEMAS => {:type => ::Thrift::Types::LIST, :name => 'fieldSchemas', :element => {:type => ::Thrift::Types::STRUCT, :class => FieldSchema}},
430
+ FIELDSCHEMAS => {:type => ::Thrift::Types::LIST, :name => 'fieldSchemas', :element => {:type => ::Thrift::Types::STRUCT, :class => ::FieldSchema}},
269
431
  PROPERTIES => {:type => ::Thrift::Types::MAP, :name => 'properties', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}}
270
432
  }
271
433
 
@@ -1,8 +1,13 @@
1
1
  #
2
- # Autogenerated by Thrift
2
+ # Autogenerated by Thrift Compiler (0.9.0)
3
3
  #
4
4
  # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
5
  #
6
6
 
7
- require File.join(File.dirname(__FILE__), *%w[hive_service_types])
7
+ require 'thrift'
8
+ require_relative 'hive_service_types'
8
9
 
10
+ module Hive
11
+ module Thrift
12
+ end
13
+ end
@@ -1,67 +1,72 @@
1
1
  #
2
- # Autogenerated by Thrift
2
+ # Autogenerated by Thrift Compiler (0.9.0)
3
3
  #
4
4
  # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
5
  #
6
6
 
7
- require File.join(File.dirname(__FILE__), *%w[fb303_types])
8
- require File.join(File.dirname(__FILE__), *%w[hive_metastore_types])
9
- require File.join(File.dirname(__FILE__), *%w[queryplan_types])
7
+ require 'thrift'
8
+ require_relative 'fb303_types'
9
+ require_relative 'hive_metastore_types'
10
+ require_relative 'queryplan_types'
10
11
 
11
12
 
12
- module JobTrackerState
13
- INITIALIZING = 1
14
- RUNNING = 2
15
- VALUE_MAP = {1 => "INITIALIZING", 2 => "RUNNING"}
16
- VALID_VALUES = Set.new([INITIALIZING, RUNNING]).freeze
17
- end
13
+ module Hive
14
+ module Thrift
15
+ module JobTrackerState
16
+ INITIALIZING = 1
17
+ RUNNING = 2
18
+ VALUE_MAP = {1 => "INITIALIZING", 2 => "RUNNING"}
19
+ VALID_VALUES = Set.new([INITIALIZING, RUNNING]).freeze
20
+ end
21
+
22
+ class HiveClusterStatus
23
+ include ::Thrift::Struct, ::Thrift::Struct_Union
24
+ TASKTRACKERS = 1
25
+ MAPTASKS = 2
26
+ REDUCETASKS = 3
27
+ MAXMAPTASKS = 4
28
+ MAXREDUCETASKS = 5
29
+ STATE = 6
18
30
 
19
- class HiveClusterStatus
20
- include ::Thrift::Struct, ::Thrift::Struct_Union
21
- TASKTRACKERS = 1
22
- MAPTASKS = 2
23
- REDUCETASKS = 3
24
- MAXMAPTASKS = 4
25
- MAXREDUCETASKS = 5
26
- STATE = 6
31
+ FIELDS = {
32
+ TASKTRACKERS => {:type => ::Thrift::Types::I32, :name => 'taskTrackers'},
33
+ MAPTASKS => {:type => ::Thrift::Types::I32, :name => 'mapTasks'},
34
+ REDUCETASKS => {:type => ::Thrift::Types::I32, :name => 'reduceTasks'},
35
+ MAXMAPTASKS => {:type => ::Thrift::Types::I32, :name => 'maxMapTasks'},
36
+ MAXREDUCETASKS => {:type => ::Thrift::Types::I32, :name => 'maxReduceTasks'},
37
+ STATE => {:type => ::Thrift::Types::I32, :name => 'state', :enum_class => ::Hive::Thrift::JobTrackerState}
38
+ }
27
39
 
28
- FIELDS = {
29
- TASKTRACKERS => {:type => ::Thrift::Types::I32, :name => 'taskTrackers'},
30
- MAPTASKS => {:type => ::Thrift::Types::I32, :name => 'mapTasks'},
31
- REDUCETASKS => {:type => ::Thrift::Types::I32, :name => 'reduceTasks'},
32
- MAXMAPTASKS => {:type => ::Thrift::Types::I32, :name => 'maxMapTasks'},
33
- MAXREDUCETASKS => {:type => ::Thrift::Types::I32, :name => 'maxReduceTasks'},
34
- STATE => {:type => ::Thrift::Types::I32, :name => 'state', :enum_class => JobTrackerState}
35
- }
40
+ def struct_fields; FIELDS; end
36
41
 
37
- def struct_fields; FIELDS; end
42
+ def validate
43
+ unless @state.nil? || ::Hive::Thrift::JobTrackerState::VALID_VALUES.include?(@state)
44
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field state!')
45
+ end
46
+ end
38
47
 
39
- def validate
40
- unless @state.nil? || JobTrackerState::VALID_VALUES.include?(@state)
41
- raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field state!')
48
+ ::Thrift::Struct.generate_accessors self
42
49
  end
43
- end
44
50
 
45
- ::Thrift::Struct.generate_accessors self
46
- end
51
+ class HiveServerException < ::Thrift::Exception
52
+ include ::Thrift::Struct, ::Thrift::Struct_Union
53
+ MESSAGE = 1
54
+ ERRORCODE = 2
55
+ SQLSTATE = 3
47
56
 
48
- class HiveServerException < ::Thrift::Exception
49
- include ::Thrift::Struct, ::Thrift::Struct_Union
50
- MESSAGE = 1
51
- ERRORCODE = 2
52
- SQLSTATE = 3
57
+ FIELDS = {
58
+ MESSAGE => {:type => ::Thrift::Types::STRING, :name => 'message'},
59
+ ERRORCODE => {:type => ::Thrift::Types::I32, :name => 'errorCode'},
60
+ SQLSTATE => {:type => ::Thrift::Types::STRING, :name => 'SQLState'}
61
+ }
53
62
 
54
- FIELDS = {
55
- MESSAGE => {:type => ::Thrift::Types::STRING, :name => 'message'},
56
- ERRORCODE => {:type => ::Thrift::Types::I32, :name => 'errorCode'},
57
- SQLSTATE => {:type => ::Thrift::Types::STRING, :name => 'SQLState'}
58
- }
63
+ def struct_fields; FIELDS; end
59
64
 
60
- def struct_fields; FIELDS; end
65
+ def validate
66
+ end
61
67
 
62
- def validate
63
- end
68
+ ::Thrift::Struct.generate_accessors self
69
+ end
64
70
 
65
- ::Thrift::Struct.generate_accessors self
71
+ end
66
72
  end
67
-
@@ -1,8 +1,13 @@
1
1
  #
2
- # Autogenerated by Thrift
2
+ # Autogenerated by Thrift Compiler (0.9.0)
3
3
  #
4
4
  # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
5
  #
6
6
 
7
- require File.join(File.dirname(__FILE__), *%w[queryplan_types])
7
+ require 'thrift'
8
+ require_relative 'queryplan_types'
8
9
 
10
+ module Hive
11
+ module Thrift
12
+ end
13
+ end