sequel_impala 1.1.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.
Files changed (129) hide show
  1. checksums.yaml +7 -0
  2. data/CHANGELOG.md +50 -0
  3. data/LICENSE +463 -0
  4. data/README.md +45 -0
  5. data/Rakefile +39 -0
  6. data/lib/driver/commons-collections-3.2.1.jar +0 -0
  7. data/lib/driver/commons-configuration-1.10.jar +0 -0
  8. data/lib/driver/commons-logging-1.2.jar +0 -0
  9. data/lib/driver/hadoop-auth-2.9.0.jar +0 -0
  10. data/lib/driver/hadoop-common-2.9.0.jar +0 -0
  11. data/lib/driver/hadoop-core-2.6.0.jar +0 -0
  12. data/lib/driver/hive-exec-1.1.0.jar +0 -0
  13. data/lib/driver/hive-jdbc-1.1.0.jar +0 -0
  14. data/lib/driver/hive-metastore-1.1.0.jar +0 -0
  15. data/lib/driver/hive-service-1.1.0.jar +0 -0
  16. data/lib/driver/httpclient-4.3.jar +0 -0
  17. data/lib/driver/httpcore-4.3.jar +0 -0
  18. data/lib/driver/libfb303-0.9.0.jar +0 -0
  19. data/lib/driver/log4j-1.2.17.jar +0 -0
  20. data/lib/driver/slf4j-api-1.7.5.jar +0 -0
  21. data/lib/driver/stax2-api-3.1.4.jar +0 -0
  22. data/lib/driver/woodstox-core-asl-4.4.1.jar +0 -0
  23. data/lib/impala.rb +55 -0
  24. data/lib/impala/connection.rb +180 -0
  25. data/lib/impala/cursor.rb +200 -0
  26. data/lib/impala/progress_reporter.rb +40 -0
  27. data/lib/impala/protocol.rb +8 -0
  28. data/lib/impala/protocol/beeswax_constants.rb +15 -0
  29. data/lib/impala/protocol/beeswax_service.rb +747 -0
  30. data/lib/impala/protocol/beeswax_types.rb +193 -0
  31. data/lib/impala/protocol/exec_stats_constants.rb +13 -0
  32. data/lib/impala/protocol/exec_stats_types.rb +133 -0
  33. data/lib/impala/protocol/facebook_service.rb +706 -0
  34. data/lib/impala/protocol/fb303_constants.rb +15 -0
  35. data/lib/impala/protocol/fb303_types.rb +25 -0
  36. data/lib/impala/protocol/hive_metastore_constants.rb +53 -0
  37. data/lib/impala/protocol/hive_metastore_types.rb +698 -0
  38. data/lib/impala/protocol/impala_hive_server2_service.rb +137 -0
  39. data/lib/impala/protocol/impala_service.rb +443 -0
  40. data/lib/impala/protocol/impala_service_constants.rb +13 -0
  41. data/lib/impala/protocol/impala_service_types.rb +192 -0
  42. data/lib/impala/protocol/status_constants.rb +13 -0
  43. data/lib/impala/protocol/status_types.rb +46 -0
  44. data/lib/impala/protocol/t_c_l_i_service.rb +1108 -0
  45. data/lib/impala/protocol/t_c_l_i_service_constants.rb +72 -0
  46. data/lib/impala/protocol/t_c_l_i_service_types.rb +1802 -0
  47. data/lib/impala/protocol/thrift_hive_metastore.rb +4707 -0
  48. data/lib/impala/protocol/types_constants.rb +13 -0
  49. data/lib/impala/protocol/types_types.rb +332 -0
  50. data/lib/impala/sasl_transport.rb +117 -0
  51. data/lib/impala/thrift_patch.rb +31 -0
  52. data/lib/impala/version.rb +3 -0
  53. data/lib/jdbc/hive2.rb +52 -0
  54. data/lib/jdbc/impala.rb +50 -0
  55. data/lib/rbhive.rb +8 -0
  56. data/lib/rbhive/connection.rb +150 -0
  57. data/lib/rbhive/explain_result.rb +46 -0
  58. data/lib/rbhive/result_set.rb +37 -0
  59. data/lib/rbhive/schema_definition.rb +86 -0
  60. data/lib/rbhive/t_c_l_i_connection.rb +466 -0
  61. data/lib/rbhive/t_c_l_i_result_set.rb +3 -0
  62. data/lib/rbhive/t_c_l_i_schema_definition.rb +87 -0
  63. data/lib/rbhive/table_schema.rb +122 -0
  64. data/lib/rbhive/version.rb +3 -0
  65. data/lib/sequel/adapters/impala.rb +220 -0
  66. data/lib/sequel/adapters/jdbc/hive2.rb +36 -0
  67. data/lib/sequel/adapters/jdbc/impala.rb +38 -0
  68. data/lib/sequel/adapters/rbhive.rb +177 -0
  69. data/lib/sequel/adapters/shared/impala.rb +808 -0
  70. data/lib/sequel/extensions/csv_to_parquet.rb +166 -0
  71. data/lib/thrift/facebook_service.rb +700 -0
  72. data/lib/thrift/fb303_constants.rb +9 -0
  73. data/lib/thrift/fb303_types.rb +19 -0
  74. data/lib/thrift/hive_metastore_constants.rb +41 -0
  75. data/lib/thrift/hive_metastore_types.rb +630 -0
  76. data/lib/thrift/hive_service_constants.rb +13 -0
  77. data/lib/thrift/hive_service_types.rb +72 -0
  78. data/lib/thrift/queryplan_constants.rb +13 -0
  79. data/lib/thrift/queryplan_types.rb +261 -0
  80. data/lib/thrift/sasl_client_transport.rb +161 -0
  81. data/lib/thrift/serde_constants.rb +92 -0
  82. data/lib/thrift/serde_types.rb +7 -0
  83. data/lib/thrift/t_c_l_i_service.rb +1054 -0
  84. data/lib/thrift/t_c_l_i_service_constants.rb +72 -0
  85. data/lib/thrift/t_c_l_i_service_types.rb +1768 -0
  86. data/lib/thrift/thrift_hive.rb +508 -0
  87. data/lib/thrift/thrift_hive_metastore.rb +3856 -0
  88. data/spec/database_test.rb +56 -0
  89. data/spec/dataset_test.rb +1268 -0
  90. data/spec/files/bad_down_migration/001_create_alt_basic.rb +4 -0
  91. data/spec/files/bad_down_migration/002_create_alt_advanced.rb +4 -0
  92. data/spec/files/bad_timestamped_migrations/1273253849_create_sessions.rb +9 -0
  93. data/spec/files/bad_timestamped_migrations/1273253851_create_nodes.rb +9 -0
  94. data/spec/files/bad_timestamped_migrations/1273253853_3_create_users.rb +3 -0
  95. data/spec/files/bad_up_migration/001_create_alt_basic.rb +4 -0
  96. data/spec/files/bad_up_migration/002_create_alt_advanced.rb +3 -0
  97. data/spec/files/convert_to_timestamp_migrations/001_create_sessions.rb +9 -0
  98. data/spec/files/convert_to_timestamp_migrations/002_create_nodes.rb +9 -0
  99. data/spec/files/convert_to_timestamp_migrations/003_3_create_users.rb +4 -0
  100. data/spec/files/convert_to_timestamp_migrations/1273253850_create_artists.rb +9 -0
  101. data/spec/files/convert_to_timestamp_migrations/1273253852_create_albums.rb +9 -0
  102. data/spec/files/duplicate_timestamped_migrations/1273253849_create_sessions.rb +9 -0
  103. data/spec/files/duplicate_timestamped_migrations/1273253853_create_nodes.rb +9 -0
  104. data/spec/files/duplicate_timestamped_migrations/1273253853_create_users.rb +4 -0
  105. data/spec/files/integer_migrations/001_create_sessions.rb +9 -0
  106. data/spec/files/integer_migrations/002_create_nodes.rb +9 -0
  107. data/spec/files/integer_migrations/003_3_create_users.rb +4 -0
  108. data/spec/files/interleaved_timestamped_migrations/1273253849_create_sessions.rb +9 -0
  109. data/spec/files/interleaved_timestamped_migrations/1273253850_create_artists.rb +9 -0
  110. data/spec/files/interleaved_timestamped_migrations/1273253851_create_nodes.rb +9 -0
  111. data/spec/files/interleaved_timestamped_migrations/1273253852_create_albums.rb +9 -0
  112. data/spec/files/interleaved_timestamped_migrations/1273253853_3_create_users.rb +4 -0
  113. data/spec/files/reversible_migrations/001_reversible.rb +5 -0
  114. data/spec/files/reversible_migrations/002_reversible.rb +5 -0
  115. data/spec/files/reversible_migrations/003_reversible.rb +5 -0
  116. data/spec/files/reversible_migrations/004_reversible.rb +5 -0
  117. data/spec/files/reversible_migrations/005_reversible.rb +10 -0
  118. data/spec/files/timestamped_migrations/1273253849_create_sessions.rb +9 -0
  119. data/spec/files/timestamped_migrations/1273253851_create_nodes.rb +9 -0
  120. data/spec/files/timestamped_migrations/1273253853_3_create_users.rb +4 -0
  121. data/spec/impala_test.rb +290 -0
  122. data/spec/migrator_test.rb +240 -0
  123. data/spec/plugin_test.rb +91 -0
  124. data/spec/prepared_statement_test.rb +327 -0
  125. data/spec/schema_test.rb +356 -0
  126. data/spec/spec_helper.rb +19 -0
  127. data/spec/timezone_test.rb +86 -0
  128. data/spec/type_test.rb +99 -0
  129. metadata +294 -0
@@ -0,0 +1,72 @@
1
+ #
2
+ # Autogenerated by Thrift Compiler (0.9.3)
3
+ #
4
+ # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
+ #
6
+
7
+ require 'thrift'
8
+ require 't_c_l_i_service_types'
9
+
10
+ module Impala
11
+ module Protocol
12
+ PRIMITIVE_TYPES = Set.new([
13
+ 0,
14
+ 1,
15
+ 2,
16
+ 3,
17
+ 4,
18
+ 5,
19
+ 6,
20
+ 7,
21
+ 8,
22
+ 9,
23
+ 15,
24
+ 16,
25
+ 17,
26
+ 18,
27
+ 19,
28
+ ])
29
+
30
+ COMPLEX_TYPES = Set.new([
31
+ 10,
32
+ 11,
33
+ 12,
34
+ 13,
35
+ 14,
36
+ ])
37
+
38
+ COLLECTION_TYPES = Set.new([
39
+ 10,
40
+ 11,
41
+ ])
42
+
43
+ TYPE_NAMES = {
44
+ 0 => %q"BOOLEAN",
45
+ 1 => %q"TINYINT",
46
+ 2 => %q"SMALLINT",
47
+ 3 => %q"INT",
48
+ 4 => %q"BIGINT",
49
+ 5 => %q"FLOAT",
50
+ 6 => %q"DOUBLE",
51
+ 7 => %q"STRING",
52
+ 8 => %q"TIMESTAMP",
53
+ 9 => %q"BINARY",
54
+ 10 => %q"ARRAY",
55
+ 11 => %q"MAP",
56
+ 12 => %q"STRUCT",
57
+ 13 => %q"UNIONTYPE",
58
+ 15 => %q"DECIMAL",
59
+ 16 => %q"NULL",
60
+ 17 => %q"DATE",
61
+ 18 => %q"VARCHAR",
62
+ 19 => %q"CHAR",
63
+ }
64
+
65
+ CHARACTER_MAXIMUM_LENGTH = %q"characterMaximumLength"
66
+
67
+ PRECISION = %q"precision"
68
+
69
+ SCALE = %q"scale"
70
+
71
+ end
72
+ end
@@ -0,0 +1,1802 @@
1
+ #
2
+ # Autogenerated by Thrift Compiler (0.9.3)
3
+ #
4
+ # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
+ #
6
+
7
+ require 'thrift'
8
+
9
+ module Impala
10
+ module Protocol
11
+ module TProtocolVersion
12
+ HIVE_CLI_SERVICE_PROTOCOL_V1 = 0
13
+ HIVE_CLI_SERVICE_PROTOCOL_V2 = 1
14
+ HIVE_CLI_SERVICE_PROTOCOL_V3 = 2
15
+ HIVE_CLI_SERVICE_PROTOCOL_V4 = 3
16
+ HIVE_CLI_SERVICE_PROTOCOL_V5 = 4
17
+ HIVE_CLI_SERVICE_PROTOCOL_V6 = 5
18
+ HIVE_CLI_SERVICE_PROTOCOL_V7 = 6
19
+ VALUE_MAP = {0 => "HIVE_CLI_SERVICE_PROTOCOL_V1", 1 => "HIVE_CLI_SERVICE_PROTOCOL_V2", 2 => "HIVE_CLI_SERVICE_PROTOCOL_V3", 3 => "HIVE_CLI_SERVICE_PROTOCOL_V4", 4 => "HIVE_CLI_SERVICE_PROTOCOL_V5", 5 => "HIVE_CLI_SERVICE_PROTOCOL_V6", 6 => "HIVE_CLI_SERVICE_PROTOCOL_V7"}
20
+ VALID_VALUES = Set.new([HIVE_CLI_SERVICE_PROTOCOL_V1, HIVE_CLI_SERVICE_PROTOCOL_V2, HIVE_CLI_SERVICE_PROTOCOL_V3, HIVE_CLI_SERVICE_PROTOCOL_V4, HIVE_CLI_SERVICE_PROTOCOL_V5, HIVE_CLI_SERVICE_PROTOCOL_V6, HIVE_CLI_SERVICE_PROTOCOL_V7]).freeze
21
+ end
22
+
23
+ module TTypeId
24
+ BOOLEAN_TYPE = 0
25
+ TINYINT_TYPE = 1
26
+ SMALLINT_TYPE = 2
27
+ INT_TYPE = 3
28
+ BIGINT_TYPE = 4
29
+ FLOAT_TYPE = 5
30
+ DOUBLE_TYPE = 6
31
+ STRING_TYPE = 7
32
+ TIMESTAMP_TYPE = 8
33
+ BINARY_TYPE = 9
34
+ ARRAY_TYPE = 10
35
+ MAP_TYPE = 11
36
+ STRUCT_TYPE = 12
37
+ UNION_TYPE = 13
38
+ USER_DEFINED_TYPE = 14
39
+ DECIMAL_TYPE = 15
40
+ NULL_TYPE = 16
41
+ DATE_TYPE = 17
42
+ VARCHAR_TYPE = 18
43
+ CHAR_TYPE = 19
44
+ VALUE_MAP = {0 => "BOOLEAN_TYPE", 1 => "TINYINT_TYPE", 2 => "SMALLINT_TYPE", 3 => "INT_TYPE", 4 => "BIGINT_TYPE", 5 => "FLOAT_TYPE", 6 => "DOUBLE_TYPE", 7 => "STRING_TYPE", 8 => "TIMESTAMP_TYPE", 9 => "BINARY_TYPE", 10 => "ARRAY_TYPE", 11 => "MAP_TYPE", 12 => "STRUCT_TYPE", 13 => "UNION_TYPE", 14 => "USER_DEFINED_TYPE", 15 => "DECIMAL_TYPE", 16 => "NULL_TYPE", 17 => "DATE_TYPE", 18 => "VARCHAR_TYPE", 19 => "CHAR_TYPE"}
45
+ VALID_VALUES = Set.new([BOOLEAN_TYPE, TINYINT_TYPE, SMALLINT_TYPE, INT_TYPE, BIGINT_TYPE, FLOAT_TYPE, DOUBLE_TYPE, STRING_TYPE, TIMESTAMP_TYPE, BINARY_TYPE, ARRAY_TYPE, MAP_TYPE, STRUCT_TYPE, UNION_TYPE, USER_DEFINED_TYPE, DECIMAL_TYPE, NULL_TYPE, DATE_TYPE, VARCHAR_TYPE, CHAR_TYPE]).freeze
46
+ end
47
+
48
+ module TStatusCode
49
+ SUCCESS_STATUS = 0
50
+ SUCCESS_WITH_INFO_STATUS = 1
51
+ STILL_EXECUTING_STATUS = 2
52
+ ERROR_STATUS = 3
53
+ INVALID_HANDLE_STATUS = 4
54
+ remove_const(:VALUE_MAP) if const_defined?(:VALUE_MAP)
55
+ VALUE_MAP = {0 => "SUCCESS_STATUS", 1 => "SUCCESS_WITH_INFO_STATUS", 2 => "STILL_EXECUTING_STATUS", 3 => "ERROR_STATUS", 4 => "INVALID_HANDLE_STATUS"}
56
+ remove_const(:VALID_VALUES) if const_defined?(:VALID_VALUES)
57
+ VALID_VALUES = Set.new([SUCCESS_STATUS, SUCCESS_WITH_INFO_STATUS, STILL_EXECUTING_STATUS, ERROR_STATUS, INVALID_HANDLE_STATUS]).freeze
58
+ end
59
+
60
+ module TOperationState
61
+ INITIALIZED_STATE = 0
62
+ RUNNING_STATE = 1
63
+ FINISHED_STATE = 2
64
+ CANCELED_STATE = 3
65
+ CLOSED_STATE = 4
66
+ ERROR_STATE = 5
67
+ UKNOWN_STATE = 6
68
+ PENDING_STATE = 7
69
+ VALUE_MAP = {0 => "INITIALIZED_STATE", 1 => "RUNNING_STATE", 2 => "FINISHED_STATE", 3 => "CANCELED_STATE", 4 => "CLOSED_STATE", 5 => "ERROR_STATE", 6 => "UKNOWN_STATE", 7 => "PENDING_STATE"}
70
+ VALID_VALUES = Set.new([INITIALIZED_STATE, RUNNING_STATE, FINISHED_STATE, CANCELED_STATE, CLOSED_STATE, ERROR_STATE, UKNOWN_STATE, PENDING_STATE]).freeze
71
+ end
72
+
73
+ module TOperationType
74
+ EXECUTE_STATEMENT = 0
75
+ GET_TYPE_INFO = 1
76
+ GET_CATALOGS = 2
77
+ GET_SCHEMAS = 3
78
+ GET_TABLES = 4
79
+ GET_TABLE_TYPES = 5
80
+ GET_COLUMNS = 6
81
+ GET_FUNCTIONS = 7
82
+ UNKNOWN = 8
83
+ VALUE_MAP = {0 => "EXECUTE_STATEMENT", 1 => "GET_TYPE_INFO", 2 => "GET_CATALOGS", 3 => "GET_SCHEMAS", 4 => "GET_TABLES", 5 => "GET_TABLE_TYPES", 6 => "GET_COLUMNS", 7 => "GET_FUNCTIONS", 8 => "UNKNOWN"}
84
+ VALID_VALUES = Set.new([EXECUTE_STATEMENT, GET_TYPE_INFO, GET_CATALOGS, GET_SCHEMAS, GET_TABLES, GET_TABLE_TYPES, GET_COLUMNS, GET_FUNCTIONS, UNKNOWN]).freeze
85
+ end
86
+
87
+ module TGetInfoType
88
+ CLI_MAX_DRIVER_CONNECTIONS = 0
89
+ CLI_MAX_CONCURRENT_ACTIVITIES = 1
90
+ CLI_DATA_SOURCE_NAME = 2
91
+ CLI_FETCH_DIRECTION = 8
92
+ CLI_SERVER_NAME = 13
93
+ CLI_SEARCH_PATTERN_ESCAPE = 14
94
+ CLI_DBMS_NAME = 17
95
+ CLI_DBMS_VER = 18
96
+ CLI_ACCESSIBLE_TABLES = 19
97
+ CLI_ACCESSIBLE_PROCEDURES = 20
98
+ CLI_CURSOR_COMMIT_BEHAVIOR = 23
99
+ CLI_DATA_SOURCE_READ_ONLY = 25
100
+ CLI_DEFAULT_TXN_ISOLATION = 26
101
+ CLI_IDENTIFIER_CASE = 28
102
+ CLI_IDENTIFIER_QUOTE_CHAR = 29
103
+ CLI_MAX_COLUMN_NAME_LEN = 30
104
+ CLI_MAX_CURSOR_NAME_LEN = 31
105
+ CLI_MAX_SCHEMA_NAME_LEN = 32
106
+ CLI_MAX_CATALOG_NAME_LEN = 34
107
+ CLI_MAX_TABLE_NAME_LEN = 35
108
+ CLI_SCROLL_CONCURRENCY = 43
109
+ CLI_TXN_CAPABLE = 46
110
+ CLI_USER_NAME = 47
111
+ CLI_TXN_ISOLATION_OPTION = 72
112
+ CLI_INTEGRITY = 73
113
+ CLI_GETDATA_EXTENSIONS = 81
114
+ CLI_NULL_COLLATION = 85
115
+ CLI_ALTER_TABLE = 86
116
+ CLI_ORDER_BY_COLUMNS_IN_SELECT = 90
117
+ CLI_SPECIAL_CHARACTERS = 94
118
+ CLI_MAX_COLUMNS_IN_GROUP_BY = 97
119
+ CLI_MAX_COLUMNS_IN_INDEX = 98
120
+ CLI_MAX_COLUMNS_IN_ORDER_BY = 99
121
+ CLI_MAX_COLUMNS_IN_SELECT = 100
122
+ CLI_MAX_COLUMNS_IN_TABLE = 101
123
+ CLI_MAX_INDEX_SIZE = 102
124
+ CLI_MAX_ROW_SIZE = 104
125
+ CLI_MAX_STATEMENT_LEN = 105
126
+ CLI_MAX_TABLES_IN_SELECT = 106
127
+ CLI_MAX_USER_NAME_LEN = 107
128
+ CLI_OJ_CAPABILITIES = 115
129
+ CLI_XOPEN_CLI_YEAR = 10000
130
+ CLI_CURSOR_SENSITIVITY = 10001
131
+ CLI_DESCRIBE_PARAMETER = 10002
132
+ CLI_CATALOG_NAME = 10003
133
+ CLI_COLLATION_SEQ = 10004
134
+ CLI_MAX_IDENTIFIER_LEN = 10005
135
+ VALUE_MAP = {0 => "CLI_MAX_DRIVER_CONNECTIONS", 1 => "CLI_MAX_CONCURRENT_ACTIVITIES", 2 => "CLI_DATA_SOURCE_NAME", 8 => "CLI_FETCH_DIRECTION", 13 => "CLI_SERVER_NAME", 14 => "CLI_SEARCH_PATTERN_ESCAPE", 17 => "CLI_DBMS_NAME", 18 => "CLI_DBMS_VER", 19 => "CLI_ACCESSIBLE_TABLES", 20 => "CLI_ACCESSIBLE_PROCEDURES", 23 => "CLI_CURSOR_COMMIT_BEHAVIOR", 25 => "CLI_DATA_SOURCE_READ_ONLY", 26 => "CLI_DEFAULT_TXN_ISOLATION", 28 => "CLI_IDENTIFIER_CASE", 29 => "CLI_IDENTIFIER_QUOTE_CHAR", 30 => "CLI_MAX_COLUMN_NAME_LEN", 31 => "CLI_MAX_CURSOR_NAME_LEN", 32 => "CLI_MAX_SCHEMA_NAME_LEN", 34 => "CLI_MAX_CATALOG_NAME_LEN", 35 => "CLI_MAX_TABLE_NAME_LEN", 43 => "CLI_SCROLL_CONCURRENCY", 46 => "CLI_TXN_CAPABLE", 47 => "CLI_USER_NAME", 72 => "CLI_TXN_ISOLATION_OPTION", 73 => "CLI_INTEGRITY", 81 => "CLI_GETDATA_EXTENSIONS", 85 => "CLI_NULL_COLLATION", 86 => "CLI_ALTER_TABLE", 90 => "CLI_ORDER_BY_COLUMNS_IN_SELECT", 94 => "CLI_SPECIAL_CHARACTERS", 97 => "CLI_MAX_COLUMNS_IN_GROUP_BY", 98 => "CLI_MAX_COLUMNS_IN_INDEX", 99 => "CLI_MAX_COLUMNS_IN_ORDER_BY", 100 => "CLI_MAX_COLUMNS_IN_SELECT", 101 => "CLI_MAX_COLUMNS_IN_TABLE", 102 => "CLI_MAX_INDEX_SIZE", 104 => "CLI_MAX_ROW_SIZE", 105 => "CLI_MAX_STATEMENT_LEN", 106 => "CLI_MAX_TABLES_IN_SELECT", 107 => "CLI_MAX_USER_NAME_LEN", 115 => "CLI_OJ_CAPABILITIES", 10000 => "CLI_XOPEN_CLI_YEAR", 10001 => "CLI_CURSOR_SENSITIVITY", 10002 => "CLI_DESCRIBE_PARAMETER", 10003 => "CLI_CATALOG_NAME", 10004 => "CLI_COLLATION_SEQ", 10005 => "CLI_MAX_IDENTIFIER_LEN"}
136
+ VALID_VALUES = Set.new([CLI_MAX_DRIVER_CONNECTIONS, CLI_MAX_CONCURRENT_ACTIVITIES, CLI_DATA_SOURCE_NAME, CLI_FETCH_DIRECTION, CLI_SERVER_NAME, CLI_SEARCH_PATTERN_ESCAPE, CLI_DBMS_NAME, CLI_DBMS_VER, CLI_ACCESSIBLE_TABLES, CLI_ACCESSIBLE_PROCEDURES, CLI_CURSOR_COMMIT_BEHAVIOR, CLI_DATA_SOURCE_READ_ONLY, CLI_DEFAULT_TXN_ISOLATION, CLI_IDENTIFIER_CASE, CLI_IDENTIFIER_QUOTE_CHAR, CLI_MAX_COLUMN_NAME_LEN, CLI_MAX_CURSOR_NAME_LEN, CLI_MAX_SCHEMA_NAME_LEN, CLI_MAX_CATALOG_NAME_LEN, CLI_MAX_TABLE_NAME_LEN, CLI_SCROLL_CONCURRENCY, CLI_TXN_CAPABLE, CLI_USER_NAME, CLI_TXN_ISOLATION_OPTION, CLI_INTEGRITY, CLI_GETDATA_EXTENSIONS, CLI_NULL_COLLATION, CLI_ALTER_TABLE, CLI_ORDER_BY_COLUMNS_IN_SELECT, CLI_SPECIAL_CHARACTERS, CLI_MAX_COLUMNS_IN_GROUP_BY, CLI_MAX_COLUMNS_IN_INDEX, CLI_MAX_COLUMNS_IN_ORDER_BY, CLI_MAX_COLUMNS_IN_SELECT, CLI_MAX_COLUMNS_IN_TABLE, CLI_MAX_INDEX_SIZE, CLI_MAX_ROW_SIZE, CLI_MAX_STATEMENT_LEN, CLI_MAX_TABLES_IN_SELECT, CLI_MAX_USER_NAME_LEN, CLI_OJ_CAPABILITIES, CLI_XOPEN_CLI_YEAR, CLI_CURSOR_SENSITIVITY, CLI_DESCRIBE_PARAMETER, CLI_CATALOG_NAME, CLI_COLLATION_SEQ, CLI_MAX_IDENTIFIER_LEN]).freeze
137
+ end
138
+
139
+ module TFetchOrientation
140
+ FETCH_NEXT = 0
141
+ FETCH_PRIOR = 1
142
+ FETCH_RELATIVE = 2
143
+ FETCH_ABSOLUTE = 3
144
+ FETCH_FIRST = 4
145
+ FETCH_LAST = 5
146
+ VALUE_MAP = {0 => "FETCH_NEXT", 1 => "FETCH_PRIOR", 2 => "FETCH_RELATIVE", 3 => "FETCH_ABSOLUTE", 4 => "FETCH_FIRST", 5 => "FETCH_LAST"}
147
+ VALID_VALUES = Set.new([FETCH_NEXT, FETCH_PRIOR, FETCH_RELATIVE, FETCH_ABSOLUTE, FETCH_FIRST, FETCH_LAST]).freeze
148
+ end
149
+
150
+ class TTypeQualifierValue < ::Thrift::Union
151
+ include ::Thrift::Struct_Union
152
+ class << self
153
+ def i32Value(val)
154
+ TTypeQualifierValue.new(:i32Value, val)
155
+ end
156
+
157
+ def stringValue(val)
158
+ TTypeQualifierValue.new(:stringValue, val)
159
+ end
160
+ end
161
+
162
+ I32VALUE = 1
163
+ STRINGVALUE = 2
164
+
165
+ FIELDS = {
166
+ I32VALUE => {:type => ::Thrift::Types::I32, :name => 'i32Value', :optional => true},
167
+ STRINGVALUE => {:type => ::Thrift::Types::STRING, :name => 'stringValue', :optional => true}
168
+ }
169
+
170
+ def struct_fields; FIELDS; end
171
+
172
+ def validate
173
+ raise(StandardError, 'Union fields are not set.') if get_set_field.nil? || get_value.nil?
174
+ end
175
+
176
+ ::Thrift::Union.generate_accessors self
177
+ end
178
+
179
+ class TTypeQualifiers
180
+ include ::Thrift::Struct, ::Thrift::Struct_Union
181
+ QUALIFIERS = 1
182
+
183
+ FIELDS = {
184
+ QUALIFIERS => {:type => ::Thrift::Types::MAP, :name => 'qualifiers', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRUCT, :class => ::Impala::Protocol::TTypeQualifierValue}}
185
+ }
186
+
187
+ def struct_fields; FIELDS; end
188
+
189
+ def validate
190
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field qualifiers is unset!') unless @qualifiers
191
+ end
192
+
193
+ ::Thrift::Struct.generate_accessors self
194
+ end
195
+
196
+ class TPrimitiveTypeEntry
197
+ include ::Thrift::Struct, ::Thrift::Struct_Union
198
+ TYPE = 1
199
+ TYPEQUALIFIERS = 2
200
+
201
+ FIELDS = {
202
+ TYPE => {:type => ::Thrift::Types::I32, :name => 'type', :enum_class => ::Impala::Protocol::TTypeId},
203
+ TYPEQUALIFIERS => {:type => ::Thrift::Types::STRUCT, :name => 'typeQualifiers', :class => ::Impala::Protocol::TTypeQualifiers, :optional => true}
204
+ }
205
+
206
+ def struct_fields; FIELDS; end
207
+
208
+ def validate
209
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field type is unset!') unless @type
210
+ unless @type.nil? || ::Impala::Protocol::TTypeId::VALID_VALUES.include?(@type)
211
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field type!')
212
+ end
213
+ end
214
+
215
+ ::Thrift::Struct.generate_accessors self
216
+ end
217
+
218
+ class TArrayTypeEntry
219
+ include ::Thrift::Struct, ::Thrift::Struct_Union
220
+ OBJECTTYPEPTR = 1
221
+
222
+ FIELDS = {
223
+ OBJECTTYPEPTR => {:type => ::Thrift::Types::I32, :name => 'objectTypePtr'}
224
+ }
225
+
226
+ def struct_fields; FIELDS; end
227
+
228
+ def validate
229
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field objectTypePtr is unset!') unless @objectTypePtr
230
+ end
231
+
232
+ ::Thrift::Struct.generate_accessors self
233
+ end
234
+
235
+ class TMapTypeEntry
236
+ include ::Thrift::Struct, ::Thrift::Struct_Union
237
+ KEYTYPEPTR = 1
238
+ VALUETYPEPTR = 2
239
+
240
+ FIELDS = {
241
+ KEYTYPEPTR => {:type => ::Thrift::Types::I32, :name => 'keyTypePtr'},
242
+ VALUETYPEPTR => {:type => ::Thrift::Types::I32, :name => 'valueTypePtr'}
243
+ }
244
+
245
+ def struct_fields; FIELDS; end
246
+
247
+ def validate
248
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field keyTypePtr is unset!') unless @keyTypePtr
249
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field valueTypePtr is unset!') unless @valueTypePtr
250
+ end
251
+
252
+ ::Thrift::Struct.generate_accessors self
253
+ end
254
+
255
+ class TStructTypeEntry
256
+ include ::Thrift::Struct, ::Thrift::Struct_Union
257
+ NAMETOTYPEPTR = 1
258
+
259
+ FIELDS = {
260
+ NAMETOTYPEPTR => {:type => ::Thrift::Types::MAP, :name => 'nameToTypePtr', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::I32}}
261
+ }
262
+
263
+ def struct_fields; FIELDS; end
264
+
265
+ def validate
266
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nameToTypePtr is unset!') unless @nameToTypePtr
267
+ end
268
+
269
+ ::Thrift::Struct.generate_accessors self
270
+ end
271
+
272
+ class TUnionTypeEntry
273
+ include ::Thrift::Struct, ::Thrift::Struct_Union
274
+ NAMETOTYPEPTR = 1
275
+
276
+ FIELDS = {
277
+ NAMETOTYPEPTR => {:type => ::Thrift::Types::MAP, :name => 'nameToTypePtr', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::I32}}
278
+ }
279
+
280
+ def struct_fields; FIELDS; end
281
+
282
+ def validate
283
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nameToTypePtr is unset!') unless @nameToTypePtr
284
+ end
285
+
286
+ ::Thrift::Struct.generate_accessors self
287
+ end
288
+
289
+ class TUserDefinedTypeEntry
290
+ include ::Thrift::Struct, ::Thrift::Struct_Union
291
+ TYPECLASSNAME = 1
292
+
293
+ FIELDS = {
294
+ TYPECLASSNAME => {:type => ::Thrift::Types::STRING, :name => 'typeClassName'}
295
+ }
296
+
297
+ def struct_fields; FIELDS; end
298
+
299
+ def validate
300
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field typeClassName is unset!') unless @typeClassName
301
+ end
302
+
303
+ ::Thrift::Struct.generate_accessors self
304
+ end
305
+
306
+ class TTypeEntry < ::Thrift::Union
307
+ include ::Thrift::Struct_Union
308
+ class << self
309
+ def primitiveEntry(val)
310
+ TTypeEntry.new(:primitiveEntry, val)
311
+ end
312
+
313
+ def arrayEntry(val)
314
+ TTypeEntry.new(:arrayEntry, val)
315
+ end
316
+
317
+ def mapEntry(val)
318
+ TTypeEntry.new(:mapEntry, val)
319
+ end
320
+
321
+ def structEntry(val)
322
+ TTypeEntry.new(:structEntry, val)
323
+ end
324
+
325
+ def unionEntry(val)
326
+ TTypeEntry.new(:unionEntry, val)
327
+ end
328
+
329
+ def userDefinedTypeEntry(val)
330
+ TTypeEntry.new(:userDefinedTypeEntry, val)
331
+ end
332
+ end
333
+
334
+ PRIMITIVEENTRY = 1
335
+ ARRAYENTRY = 2
336
+ MAPENTRY = 3
337
+ STRUCTENTRY = 4
338
+ UNIONENTRY = 5
339
+ USERDEFINEDTYPEENTRY = 6
340
+
341
+ FIELDS = {
342
+ PRIMITIVEENTRY => {:type => ::Thrift::Types::STRUCT, :name => 'primitiveEntry', :class => ::Impala::Protocol::TPrimitiveTypeEntry},
343
+ ARRAYENTRY => {:type => ::Thrift::Types::STRUCT, :name => 'arrayEntry', :class => ::Impala::Protocol::TArrayTypeEntry},
344
+ MAPENTRY => {:type => ::Thrift::Types::STRUCT, :name => 'mapEntry', :class => ::Impala::Protocol::TMapTypeEntry},
345
+ STRUCTENTRY => {:type => ::Thrift::Types::STRUCT, :name => 'structEntry', :class => ::Impala::Protocol::TStructTypeEntry},
346
+ UNIONENTRY => {:type => ::Thrift::Types::STRUCT, :name => 'unionEntry', :class => ::Impala::Protocol::TUnionTypeEntry},
347
+ USERDEFINEDTYPEENTRY => {:type => ::Thrift::Types::STRUCT, :name => 'userDefinedTypeEntry', :class => ::Impala::Protocol::TUserDefinedTypeEntry}
348
+ }
349
+
350
+ def struct_fields; FIELDS; end
351
+
352
+ def validate
353
+ raise(StandardError, 'Union fields are not set.') if get_set_field.nil? || get_value.nil?
354
+ end
355
+
356
+ ::Thrift::Union.generate_accessors self
357
+ end
358
+
359
+ class TTypeDesc
360
+ include ::Thrift::Struct, ::Thrift::Struct_Union
361
+ TYPES = 1
362
+
363
+ FIELDS = {
364
+ TYPES => {:type => ::Thrift::Types::LIST, :name => 'types', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Impala::Protocol::TTypeEntry}}
365
+ }
366
+
367
+ def struct_fields; FIELDS; end
368
+
369
+ def validate
370
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field types is unset!') unless @types
371
+ end
372
+
373
+ ::Thrift::Struct.generate_accessors self
374
+ end
375
+
376
+ class TColumnDesc
377
+ include ::Thrift::Struct, ::Thrift::Struct_Union
378
+ COLUMNNAME = 1
379
+ TYPEDESC = 2
380
+ POSITION = 3
381
+ COMMENT = 4
382
+
383
+ FIELDS = {
384
+ COLUMNNAME => {:type => ::Thrift::Types::STRING, :name => 'columnName'},
385
+ TYPEDESC => {:type => ::Thrift::Types::STRUCT, :name => 'typeDesc', :class => ::Impala::Protocol::TTypeDesc},
386
+ POSITION => {:type => ::Thrift::Types::I32, :name => 'position'},
387
+ COMMENT => {:type => ::Thrift::Types::STRING, :name => 'comment', :optional => true}
388
+ }
389
+
390
+ def struct_fields; FIELDS; end
391
+
392
+ def validate
393
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field columnName is unset!') unless @columnName
394
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field typeDesc is unset!') unless @typeDesc
395
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field position is unset!') unless @position
396
+ end
397
+
398
+ ::Thrift::Struct.generate_accessors self
399
+ end
400
+
401
+ class TTableSchema
402
+ include ::Thrift::Struct, ::Thrift::Struct_Union
403
+ COLUMNS = 1
404
+
405
+ FIELDS = {
406
+ COLUMNS => {:type => ::Thrift::Types::LIST, :name => 'columns', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Impala::Protocol::TColumnDesc}}
407
+ }
408
+
409
+ def struct_fields; FIELDS; end
410
+
411
+ def validate
412
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field columns is unset!') unless @columns
413
+ end
414
+
415
+ ::Thrift::Struct.generate_accessors self
416
+ end
417
+
418
+ class TBoolValue
419
+ include ::Thrift::Struct, ::Thrift::Struct_Union
420
+ VALUE = 1
421
+
422
+ FIELDS = {
423
+ VALUE => {:type => ::Thrift::Types::BOOL, :name => 'value', :optional => true}
424
+ }
425
+
426
+ def struct_fields; FIELDS; end
427
+
428
+ def validate
429
+ end
430
+
431
+ ::Thrift::Struct.generate_accessors self
432
+ end
433
+
434
+ class TByteValue
435
+ include ::Thrift::Struct, ::Thrift::Struct_Union
436
+ VALUE = 1
437
+
438
+ FIELDS = {
439
+ VALUE => {:type => ::Thrift::Types::BYTE, :name => 'value', :optional => true}
440
+ }
441
+
442
+ def struct_fields; FIELDS; end
443
+
444
+ def validate
445
+ end
446
+
447
+ ::Thrift::Struct.generate_accessors self
448
+ end
449
+
450
+ class TI16Value
451
+ include ::Thrift::Struct, ::Thrift::Struct_Union
452
+ VALUE = 1
453
+
454
+ FIELDS = {
455
+ VALUE => {:type => ::Thrift::Types::I16, :name => 'value', :optional => true}
456
+ }
457
+
458
+ def struct_fields; FIELDS; end
459
+
460
+ def validate
461
+ end
462
+
463
+ ::Thrift::Struct.generate_accessors self
464
+ end
465
+
466
+ class TI32Value
467
+ include ::Thrift::Struct, ::Thrift::Struct_Union
468
+ VALUE = 1
469
+
470
+ FIELDS = {
471
+ VALUE => {:type => ::Thrift::Types::I32, :name => 'value', :optional => true}
472
+ }
473
+
474
+ def struct_fields; FIELDS; end
475
+
476
+ def validate
477
+ end
478
+
479
+ ::Thrift::Struct.generate_accessors self
480
+ end
481
+
482
+ class TI64Value
483
+ include ::Thrift::Struct, ::Thrift::Struct_Union
484
+ VALUE = 1
485
+
486
+ FIELDS = {
487
+ VALUE => {:type => ::Thrift::Types::I64, :name => 'value', :optional => true}
488
+ }
489
+
490
+ def struct_fields; FIELDS; end
491
+
492
+ def validate
493
+ end
494
+
495
+ ::Thrift::Struct.generate_accessors self
496
+ end
497
+
498
+ class TDoubleValue
499
+ include ::Thrift::Struct, ::Thrift::Struct_Union
500
+ VALUE = 1
501
+
502
+ FIELDS = {
503
+ VALUE => {:type => ::Thrift::Types::DOUBLE, :name => 'value', :optional => true}
504
+ }
505
+
506
+ def struct_fields; FIELDS; end
507
+
508
+ def validate
509
+ end
510
+
511
+ ::Thrift::Struct.generate_accessors self
512
+ end
513
+
514
+ class TStringValue
515
+ include ::Thrift::Struct, ::Thrift::Struct_Union
516
+ VALUE = 1
517
+
518
+ FIELDS = {
519
+ VALUE => {:type => ::Thrift::Types::STRING, :name => 'value', :optional => true}
520
+ }
521
+
522
+ def struct_fields; FIELDS; end
523
+
524
+ def validate
525
+ end
526
+
527
+ ::Thrift::Struct.generate_accessors self
528
+ end
529
+
530
+ class TColumnValue < ::Thrift::Union
531
+ include ::Thrift::Struct_Union
532
+ class << self
533
+ def boolVal(val)
534
+ TColumnValue.new(:boolVal, val)
535
+ end
536
+
537
+ def byteVal(val)
538
+ TColumnValue.new(:byteVal, val)
539
+ end
540
+
541
+ def i16Val(val)
542
+ TColumnValue.new(:i16Val, val)
543
+ end
544
+
545
+ def i32Val(val)
546
+ TColumnValue.new(:i32Val, val)
547
+ end
548
+
549
+ def i64Val(val)
550
+ TColumnValue.new(:i64Val, val)
551
+ end
552
+
553
+ def doubleVal(val)
554
+ TColumnValue.new(:doubleVal, val)
555
+ end
556
+
557
+ def stringVal(val)
558
+ TColumnValue.new(:stringVal, val)
559
+ end
560
+ end
561
+
562
+ BOOLVAL = 1
563
+ BYTEVAL = 2
564
+ I16VAL = 3
565
+ I32VAL = 4
566
+ I64VAL = 5
567
+ DOUBLEVAL = 6
568
+ STRINGVAL = 7
569
+
570
+ FIELDS = {
571
+ BOOLVAL => {:type => ::Thrift::Types::STRUCT, :name => 'boolVal', :class => ::Impala::Protocol::TBoolValue},
572
+ BYTEVAL => {:type => ::Thrift::Types::STRUCT, :name => 'byteVal', :class => ::Impala::Protocol::TByteValue},
573
+ I16VAL => {:type => ::Thrift::Types::STRUCT, :name => 'i16Val', :class => ::Impala::Protocol::TI16Value},
574
+ I32VAL => {:type => ::Thrift::Types::STRUCT, :name => 'i32Val', :class => ::Impala::Protocol::TI32Value},
575
+ I64VAL => {:type => ::Thrift::Types::STRUCT, :name => 'i64Val', :class => ::Impala::Protocol::TI64Value},
576
+ DOUBLEVAL => {:type => ::Thrift::Types::STRUCT, :name => 'doubleVal', :class => ::Impala::Protocol::TDoubleValue},
577
+ STRINGVAL => {:type => ::Thrift::Types::STRUCT, :name => 'stringVal', :class => ::Impala::Protocol::TStringValue}
578
+ }
579
+
580
+ def struct_fields; FIELDS; end
581
+
582
+ def validate
583
+ raise(StandardError, 'Union fields are not set.') if get_set_field.nil? || get_value.nil?
584
+ end
585
+
586
+ ::Thrift::Union.generate_accessors self
587
+ end
588
+
589
+ class TRow
590
+ include ::Thrift::Struct, ::Thrift::Struct_Union
591
+ COLVALS = 1
592
+
593
+ FIELDS = {
594
+ COLVALS => {:type => ::Thrift::Types::LIST, :name => 'colVals', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Impala::Protocol::TColumnValue}}
595
+ }
596
+
597
+ def struct_fields; FIELDS; end
598
+
599
+ def validate
600
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field colVals is unset!') unless @colVals
601
+ end
602
+
603
+ ::Thrift::Struct.generate_accessors self
604
+ end
605
+
606
+ class TBoolColumn
607
+ include ::Thrift::Struct, ::Thrift::Struct_Union
608
+ VALUES = 1
609
+ NULLS = 2
610
+
611
+ FIELDS = {
612
+ VALUES => {:type => ::Thrift::Types::LIST, :name => 'values', :element => {:type => ::Thrift::Types::BOOL}},
613
+ NULLS => {:type => ::Thrift::Types::STRING, :name => 'nulls', :binary => true}
614
+ }
615
+
616
+ def struct_fields; FIELDS; end
617
+
618
+ def validate
619
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field values is unset!') unless @values
620
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nulls is unset!') unless @nulls
621
+ end
622
+
623
+ ::Thrift::Struct.generate_accessors self
624
+ end
625
+
626
+ class TByteColumn
627
+ include ::Thrift::Struct, ::Thrift::Struct_Union
628
+ VALUES = 1
629
+ NULLS = 2
630
+
631
+ FIELDS = {
632
+ VALUES => {:type => ::Thrift::Types::LIST, :name => 'values', :element => {:type => ::Thrift::Types::BYTE}},
633
+ NULLS => {:type => ::Thrift::Types::STRING, :name => 'nulls', :binary => true}
634
+ }
635
+
636
+ def struct_fields; FIELDS; end
637
+
638
+ def validate
639
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field values is unset!') unless @values
640
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nulls is unset!') unless @nulls
641
+ end
642
+
643
+ ::Thrift::Struct.generate_accessors self
644
+ end
645
+
646
+ class TI16Column
647
+ include ::Thrift::Struct, ::Thrift::Struct_Union
648
+ VALUES = 1
649
+ NULLS = 2
650
+
651
+ FIELDS = {
652
+ VALUES => {:type => ::Thrift::Types::LIST, :name => 'values', :element => {:type => ::Thrift::Types::I16}},
653
+ NULLS => {:type => ::Thrift::Types::STRING, :name => 'nulls', :binary => true}
654
+ }
655
+
656
+ def struct_fields; FIELDS; end
657
+
658
+ def validate
659
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field values is unset!') unless @values
660
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nulls is unset!') unless @nulls
661
+ end
662
+
663
+ ::Thrift::Struct.generate_accessors self
664
+ end
665
+
666
+ class TI32Column
667
+ include ::Thrift::Struct, ::Thrift::Struct_Union
668
+ VALUES = 1
669
+ NULLS = 2
670
+
671
+ FIELDS = {
672
+ VALUES => {:type => ::Thrift::Types::LIST, :name => 'values', :element => {:type => ::Thrift::Types::I32}},
673
+ NULLS => {:type => ::Thrift::Types::STRING, :name => 'nulls', :binary => true}
674
+ }
675
+
676
+ def struct_fields; FIELDS; end
677
+
678
+ def validate
679
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field values is unset!') unless @values
680
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nulls is unset!') unless @nulls
681
+ end
682
+
683
+ ::Thrift::Struct.generate_accessors self
684
+ end
685
+
686
+ class TI64Column
687
+ include ::Thrift::Struct, ::Thrift::Struct_Union
688
+ VALUES = 1
689
+ NULLS = 2
690
+
691
+ FIELDS = {
692
+ VALUES => {:type => ::Thrift::Types::LIST, :name => 'values', :element => {:type => ::Thrift::Types::I64}},
693
+ NULLS => {:type => ::Thrift::Types::STRING, :name => 'nulls', :binary => true}
694
+ }
695
+
696
+ def struct_fields; FIELDS; end
697
+
698
+ def validate
699
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field values is unset!') unless @values
700
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nulls is unset!') unless @nulls
701
+ end
702
+
703
+ ::Thrift::Struct.generate_accessors self
704
+ end
705
+
706
+ class TDoubleColumn
707
+ include ::Thrift::Struct, ::Thrift::Struct_Union
708
+ VALUES = 1
709
+ NULLS = 2
710
+
711
+ FIELDS = {
712
+ VALUES => {:type => ::Thrift::Types::LIST, :name => 'values', :element => {:type => ::Thrift::Types::DOUBLE}},
713
+ NULLS => {:type => ::Thrift::Types::STRING, :name => 'nulls', :binary => true}
714
+ }
715
+
716
+ def struct_fields; FIELDS; end
717
+
718
+ def validate
719
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field values is unset!') unless @values
720
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nulls is unset!') unless @nulls
721
+ end
722
+
723
+ ::Thrift::Struct.generate_accessors self
724
+ end
725
+
726
+ class TStringColumn
727
+ include ::Thrift::Struct, ::Thrift::Struct_Union
728
+ VALUES = 1
729
+ NULLS = 2
730
+
731
+ FIELDS = {
732
+ VALUES => {:type => ::Thrift::Types::LIST, :name => 'values', :element => {:type => ::Thrift::Types::STRING}},
733
+ NULLS => {:type => ::Thrift::Types::STRING, :name => 'nulls', :binary => true}
734
+ }
735
+
736
+ def struct_fields; FIELDS; end
737
+
738
+ def validate
739
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field values is unset!') unless @values
740
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nulls is unset!') unless @nulls
741
+ end
742
+
743
+ ::Thrift::Struct.generate_accessors self
744
+ end
745
+
746
+ class TBinaryColumn
747
+ include ::Thrift::Struct, ::Thrift::Struct_Union
748
+ VALUES = 1
749
+ NULLS = 2
750
+
751
+ FIELDS = {
752
+ VALUES => {:type => ::Thrift::Types::LIST, :name => 'values', :element => {:type => ::Thrift::Types::STRING, :binary => true}},
753
+ NULLS => {:type => ::Thrift::Types::STRING, :name => 'nulls', :binary => true}
754
+ }
755
+
756
+ def struct_fields; FIELDS; end
757
+
758
+ def validate
759
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field values is unset!') unless @values
760
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field nulls is unset!') unless @nulls
761
+ end
762
+
763
+ ::Thrift::Struct.generate_accessors self
764
+ end
765
+
766
+ class TColumn < ::Thrift::Union
767
+ include ::Thrift::Struct_Union
768
+ class << self
769
+ def boolVal(val)
770
+ TColumn.new(:boolVal, val)
771
+ end
772
+
773
+ def byteVal(val)
774
+ TColumn.new(:byteVal, val)
775
+ end
776
+
777
+ def i16Val(val)
778
+ TColumn.new(:i16Val, val)
779
+ end
780
+
781
+ def i32Val(val)
782
+ TColumn.new(:i32Val, val)
783
+ end
784
+
785
+ def i64Val(val)
786
+ TColumn.new(:i64Val, val)
787
+ end
788
+
789
+ def doubleVal(val)
790
+ TColumn.new(:doubleVal, val)
791
+ end
792
+
793
+ def stringVal(val)
794
+ TColumn.new(:stringVal, val)
795
+ end
796
+
797
+ def binaryVal(val)
798
+ TColumn.new(:binaryVal, val)
799
+ end
800
+ end
801
+
802
+ BOOLVAL = 1
803
+ BYTEVAL = 2
804
+ I16VAL = 3
805
+ I32VAL = 4
806
+ I64VAL = 5
807
+ DOUBLEVAL = 6
808
+ STRINGVAL = 7
809
+ BINARYVAL = 8
810
+
811
+ FIELDS = {
812
+ BOOLVAL => {:type => ::Thrift::Types::STRUCT, :name => 'boolVal', :class => ::Impala::Protocol::TBoolColumn},
813
+ BYTEVAL => {:type => ::Thrift::Types::STRUCT, :name => 'byteVal', :class => ::Impala::Protocol::TByteColumn},
814
+ I16VAL => {:type => ::Thrift::Types::STRUCT, :name => 'i16Val', :class => ::Impala::Protocol::TI16Column},
815
+ I32VAL => {:type => ::Thrift::Types::STRUCT, :name => 'i32Val', :class => ::Impala::Protocol::TI32Column},
816
+ I64VAL => {:type => ::Thrift::Types::STRUCT, :name => 'i64Val', :class => ::Impala::Protocol::TI64Column},
817
+ DOUBLEVAL => {:type => ::Thrift::Types::STRUCT, :name => 'doubleVal', :class => ::Impala::Protocol::TDoubleColumn},
818
+ STRINGVAL => {:type => ::Thrift::Types::STRUCT, :name => 'stringVal', :class => ::Impala::Protocol::TStringColumn},
819
+ BINARYVAL => {:type => ::Thrift::Types::STRUCT, :name => 'binaryVal', :class => ::Impala::Protocol::TBinaryColumn}
820
+ }
821
+
822
+ def struct_fields; FIELDS; end
823
+
824
+ def validate
825
+ raise(StandardError, 'Union fields are not set.') if get_set_field.nil? || get_value.nil?
826
+ end
827
+
828
+ ::Thrift::Union.generate_accessors self
829
+ end
830
+
831
+ class TRowSet
832
+ include ::Thrift::Struct, ::Thrift::Struct_Union
833
+ STARTROWOFFSET = 1
834
+ ROWS = 2
835
+ COLUMNS = 3
836
+
837
+ FIELDS = {
838
+ STARTROWOFFSET => {:type => ::Thrift::Types::I64, :name => 'startRowOffset'},
839
+ ROWS => {:type => ::Thrift::Types::LIST, :name => 'rows', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Impala::Protocol::TRow}},
840
+ COLUMNS => {:type => ::Thrift::Types::LIST, :name => 'columns', :element => {:type => ::Thrift::Types::STRUCT, :class => ::Impala::Protocol::TColumn}, :optional => true}
841
+ }
842
+
843
+ def struct_fields; FIELDS; end
844
+
845
+ def validate
846
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field startRowOffset is unset!') unless @startRowOffset
847
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field rows is unset!') unless @rows
848
+ end
849
+
850
+ ::Thrift::Struct.generate_accessors self
851
+ end
852
+
853
+ class TStatus
854
+ include ::Thrift::Struct, ::Thrift::Struct_Union
855
+ STATUSCODE = 1
856
+ INFOMESSAGES = 2
857
+ SQLSTATE = 3
858
+ ERRORCODE = 4
859
+ ERRORMESSAGE = 5
860
+
861
+ remove_const(:FIELDS) if const_defined?(:FIELDS)
862
+ FIELDS = {
863
+ STATUSCODE => {:type => ::Thrift::Types::I32, :name => 'statusCode', :enum_class => ::Impala::Protocol::TStatusCode},
864
+ INFOMESSAGES => {:type => ::Thrift::Types::LIST, :name => 'infoMessages', :element => {:type => ::Thrift::Types::STRING}, :optional => true},
865
+ SQLSTATE => {:type => ::Thrift::Types::STRING, :name => 'sqlState', :optional => true},
866
+ ERRORCODE => {:type => ::Thrift::Types::I32, :name => 'errorCode', :optional => true},
867
+ ERRORMESSAGE => {:type => ::Thrift::Types::STRING, :name => 'errorMessage', :optional => true}
868
+ }
869
+
870
+ def struct_fields; FIELDS; end
871
+
872
+ def validate
873
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field statusCode is unset!') unless @statusCode
874
+ unless @statusCode.nil? || ::Impala::Protocol::TStatusCode::VALID_VALUES.include?(@statusCode)
875
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field statusCode!')
876
+ end
877
+ end
878
+
879
+ ::Thrift::Struct.generate_accessors self
880
+ end
881
+
882
+ class THandleIdentifier
883
+ include ::Thrift::Struct, ::Thrift::Struct_Union
884
+ GUID = 1
885
+ SECRET = 2
886
+
887
+ FIELDS = {
888
+ GUID => {:type => ::Thrift::Types::STRING, :name => 'guid', :binary => true},
889
+ SECRET => {:type => ::Thrift::Types::STRING, :name => 'secret', :binary => true}
890
+ }
891
+
892
+ def struct_fields; FIELDS; end
893
+
894
+ def validate
895
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field guid is unset!') unless @guid
896
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field secret is unset!') unless @secret
897
+ end
898
+
899
+ ::Thrift::Struct.generate_accessors self
900
+ end
901
+
902
+ class TSessionHandle
903
+ include ::Thrift::Struct, ::Thrift::Struct_Union
904
+ SESSIONID = 1
905
+
906
+ FIELDS = {
907
+ SESSIONID => {:type => ::Thrift::Types::STRUCT, :name => 'sessionId', :class => ::Impala::Protocol::THandleIdentifier}
908
+ }
909
+
910
+ def struct_fields; FIELDS; end
911
+
912
+ def validate
913
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionId is unset!') unless @sessionId
914
+ end
915
+
916
+ ::Thrift::Struct.generate_accessors self
917
+ end
918
+
919
+ class TOperationHandle
920
+ include ::Thrift::Struct, ::Thrift::Struct_Union
921
+ OPERATIONID = 1
922
+ OPERATIONTYPE = 2
923
+ HASRESULTSET = 3
924
+ MODIFIEDROWCOUNT = 4
925
+
926
+ FIELDS = {
927
+ OPERATIONID => {:type => ::Thrift::Types::STRUCT, :name => 'operationId', :class => ::Impala::Protocol::THandleIdentifier},
928
+ OPERATIONTYPE => {:type => ::Thrift::Types::I32, :name => 'operationType', :enum_class => ::Impala::Protocol::TOperationType},
929
+ HASRESULTSET => {:type => ::Thrift::Types::BOOL, :name => 'hasResultSet'},
930
+ MODIFIEDROWCOUNT => {:type => ::Thrift::Types::DOUBLE, :name => 'modifiedRowCount', :optional => true}
931
+ }
932
+
933
+ def struct_fields; FIELDS; end
934
+
935
+ def validate
936
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field operationId is unset!') unless @operationId
937
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field operationType is unset!') unless @operationType
938
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field hasResultSet is unset!') if @hasResultSet.nil?
939
+ unless @operationType.nil? || ::Impala::Protocol::TOperationType::VALID_VALUES.include?(@operationType)
940
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field operationType!')
941
+ end
942
+ end
943
+
944
+ ::Thrift::Struct.generate_accessors self
945
+ end
946
+
947
+ class TOpenSessionReq
948
+ include ::Thrift::Struct, ::Thrift::Struct_Union
949
+ CLIENT_PROTOCOL = 1
950
+ USERNAME = 2
951
+ PASSWORD = 3
952
+ CONFIGURATION = 4
953
+
954
+ FIELDS = {
955
+ CLIENT_PROTOCOL => {:type => ::Thrift::Types::I32, :name => 'client_protocol', :default => 5, :enum_class => ::Impala::Protocol::TProtocolVersion},
956
+ USERNAME => {:type => ::Thrift::Types::STRING, :name => 'username', :optional => true},
957
+ PASSWORD => {:type => ::Thrift::Types::STRING, :name => 'password', :optional => true},
958
+ CONFIGURATION => {:type => ::Thrift::Types::MAP, :name => 'configuration', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}, :optional => true}
959
+ }
960
+
961
+ def struct_fields; FIELDS; end
962
+
963
+ def validate
964
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field client_protocol is unset!') unless @client_protocol
965
+ unless @client_protocol.nil? || ::Impala::Protocol::TProtocolVersion::VALID_VALUES.include?(@client_protocol)
966
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field client_protocol!')
967
+ end
968
+ end
969
+
970
+ ::Thrift::Struct.generate_accessors self
971
+ end
972
+
973
+ class TOpenSessionResp
974
+ include ::Thrift::Struct, ::Thrift::Struct_Union
975
+ STATUS = 1
976
+ SERVERPROTOCOLVERSION = 2
977
+ SESSIONHANDLE = 3
978
+ CONFIGURATION = 4
979
+
980
+ FIELDS = {
981
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
982
+ SERVERPROTOCOLVERSION => {:type => ::Thrift::Types::I32, :name => 'serverProtocolVersion', :default => 5, :enum_class => ::Impala::Protocol::TProtocolVersion},
983
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle, :optional => true},
984
+ CONFIGURATION => {:type => ::Thrift::Types::MAP, :name => 'configuration', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}, :optional => true}
985
+ }
986
+
987
+ def struct_fields; FIELDS; end
988
+
989
+ def validate
990
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
991
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field serverProtocolVersion is unset!') unless @serverProtocolVersion
992
+ unless @serverProtocolVersion.nil? || ::Impala::Protocol::TProtocolVersion::VALID_VALUES.include?(@serverProtocolVersion)
993
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field serverProtocolVersion!')
994
+ end
995
+ end
996
+
997
+ ::Thrift::Struct.generate_accessors self
998
+ end
999
+
1000
+ class TCloseSessionReq
1001
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1002
+ SESSIONHANDLE = 1
1003
+
1004
+ FIELDS = {
1005
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle}
1006
+ }
1007
+
1008
+ def struct_fields; FIELDS; end
1009
+
1010
+ def validate
1011
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1012
+ end
1013
+
1014
+ ::Thrift::Struct.generate_accessors self
1015
+ end
1016
+
1017
+ class TCloseSessionResp
1018
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1019
+ STATUS = 1
1020
+
1021
+ FIELDS = {
1022
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus}
1023
+ }
1024
+
1025
+ def struct_fields; FIELDS; end
1026
+
1027
+ def validate
1028
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1029
+ end
1030
+
1031
+ ::Thrift::Struct.generate_accessors self
1032
+ end
1033
+
1034
+ class TGetInfoValue < ::Thrift::Union
1035
+ include ::Thrift::Struct_Union
1036
+ class << self
1037
+ def stringValue(val)
1038
+ TGetInfoValue.new(:stringValue, val)
1039
+ end
1040
+
1041
+ def smallIntValue(val)
1042
+ TGetInfoValue.new(:smallIntValue, val)
1043
+ end
1044
+
1045
+ def integerBitmask(val)
1046
+ TGetInfoValue.new(:integerBitmask, val)
1047
+ end
1048
+
1049
+ def integerFlag(val)
1050
+ TGetInfoValue.new(:integerFlag, val)
1051
+ end
1052
+
1053
+ def binaryValue(val)
1054
+ TGetInfoValue.new(:binaryValue, val)
1055
+ end
1056
+
1057
+ def lenValue(val)
1058
+ TGetInfoValue.new(:lenValue, val)
1059
+ end
1060
+ end
1061
+
1062
+ STRINGVALUE = 1
1063
+ SMALLINTVALUE = 2
1064
+ INTEGERBITMASK = 3
1065
+ INTEGERFLAG = 4
1066
+ BINARYVALUE = 5
1067
+ LENVALUE = 6
1068
+
1069
+ FIELDS = {
1070
+ STRINGVALUE => {:type => ::Thrift::Types::STRING, :name => 'stringValue'},
1071
+ SMALLINTVALUE => {:type => ::Thrift::Types::I16, :name => 'smallIntValue'},
1072
+ INTEGERBITMASK => {:type => ::Thrift::Types::I32, :name => 'integerBitmask'},
1073
+ INTEGERFLAG => {:type => ::Thrift::Types::I32, :name => 'integerFlag'},
1074
+ BINARYVALUE => {:type => ::Thrift::Types::I32, :name => 'binaryValue'},
1075
+ LENVALUE => {:type => ::Thrift::Types::I64, :name => 'lenValue'}
1076
+ }
1077
+
1078
+ def struct_fields; FIELDS; end
1079
+
1080
+ def validate
1081
+ raise(StandardError, 'Union fields are not set.') if get_set_field.nil? || get_value.nil?
1082
+ end
1083
+
1084
+ ::Thrift::Union.generate_accessors self
1085
+ end
1086
+
1087
+ class TGetInfoReq
1088
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1089
+ SESSIONHANDLE = 1
1090
+ INFOTYPE = 2
1091
+
1092
+ FIELDS = {
1093
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle},
1094
+ INFOTYPE => {:type => ::Thrift::Types::I32, :name => 'infoType', :enum_class => ::Impala::Protocol::TGetInfoType}
1095
+ }
1096
+
1097
+ def struct_fields; FIELDS; end
1098
+
1099
+ def validate
1100
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1101
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field infoType is unset!') unless @infoType
1102
+ unless @infoType.nil? || ::Impala::Protocol::TGetInfoType::VALID_VALUES.include?(@infoType)
1103
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field infoType!')
1104
+ end
1105
+ end
1106
+
1107
+ ::Thrift::Struct.generate_accessors self
1108
+ end
1109
+
1110
+ class TGetInfoResp
1111
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1112
+ STATUS = 1
1113
+ INFOVALUE = 2
1114
+
1115
+ FIELDS = {
1116
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1117
+ INFOVALUE => {:type => ::Thrift::Types::STRUCT, :name => 'infoValue', :class => ::Impala::Protocol::TGetInfoValue}
1118
+ }
1119
+
1120
+ def struct_fields; FIELDS; end
1121
+
1122
+ def validate
1123
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1124
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field infoValue is unset!') unless @infoValue
1125
+ end
1126
+
1127
+ ::Thrift::Struct.generate_accessors self
1128
+ end
1129
+
1130
+ class TExecuteStatementReq
1131
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1132
+ SESSIONHANDLE = 1
1133
+ STATEMENT = 2
1134
+ CONFOVERLAY = 3
1135
+ RUNASYNC = 4
1136
+
1137
+ FIELDS = {
1138
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle},
1139
+ STATEMENT => {:type => ::Thrift::Types::STRING, :name => 'statement'},
1140
+ CONFOVERLAY => {:type => ::Thrift::Types::MAP, :name => 'confOverlay', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}, :optional => true},
1141
+ RUNASYNC => {:type => ::Thrift::Types::BOOL, :name => 'runAsync', :default => false, :optional => true}
1142
+ }
1143
+
1144
+ def struct_fields; FIELDS; end
1145
+
1146
+ def validate
1147
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1148
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field statement is unset!') unless @statement
1149
+ end
1150
+
1151
+ ::Thrift::Struct.generate_accessors self
1152
+ end
1153
+
1154
+ class TExecuteStatementResp
1155
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1156
+ STATUS = 1
1157
+ OPERATIONHANDLE = 2
1158
+
1159
+ FIELDS = {
1160
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1161
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle, :optional => true}
1162
+ }
1163
+
1164
+ def struct_fields; FIELDS; end
1165
+
1166
+ def validate
1167
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1168
+ end
1169
+
1170
+ ::Thrift::Struct.generate_accessors self
1171
+ end
1172
+
1173
+ class TGetTypeInfoReq
1174
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1175
+ SESSIONHANDLE = 1
1176
+
1177
+ FIELDS = {
1178
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle}
1179
+ }
1180
+
1181
+ def struct_fields; FIELDS; end
1182
+
1183
+ def validate
1184
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1185
+ end
1186
+
1187
+ ::Thrift::Struct.generate_accessors self
1188
+ end
1189
+
1190
+ class TGetTypeInfoResp
1191
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1192
+ STATUS = 1
1193
+ OPERATIONHANDLE = 2
1194
+
1195
+ FIELDS = {
1196
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1197
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle, :optional => true}
1198
+ }
1199
+
1200
+ def struct_fields; FIELDS; end
1201
+
1202
+ def validate
1203
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1204
+ end
1205
+
1206
+ ::Thrift::Struct.generate_accessors self
1207
+ end
1208
+
1209
+ class TGetCatalogsReq
1210
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1211
+ SESSIONHANDLE = 1
1212
+
1213
+ FIELDS = {
1214
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle}
1215
+ }
1216
+
1217
+ def struct_fields; FIELDS; end
1218
+
1219
+ def validate
1220
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1221
+ end
1222
+
1223
+ ::Thrift::Struct.generate_accessors self
1224
+ end
1225
+
1226
+ class TGetCatalogsResp
1227
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1228
+ STATUS = 1
1229
+ OPERATIONHANDLE = 2
1230
+
1231
+ FIELDS = {
1232
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1233
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle, :optional => true}
1234
+ }
1235
+
1236
+ def struct_fields; FIELDS; end
1237
+
1238
+ def validate
1239
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1240
+ end
1241
+
1242
+ ::Thrift::Struct.generate_accessors self
1243
+ end
1244
+
1245
+ class TGetSchemasReq
1246
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1247
+ SESSIONHANDLE = 1
1248
+ CATALOGNAME = 2
1249
+ SCHEMANAME = 3
1250
+
1251
+ FIELDS = {
1252
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle},
1253
+ CATALOGNAME => {:type => ::Thrift::Types::STRING, :name => 'catalogName', :optional => true},
1254
+ SCHEMANAME => {:type => ::Thrift::Types::STRING, :name => 'schemaName', :optional => true}
1255
+ }
1256
+
1257
+ def struct_fields; FIELDS; end
1258
+
1259
+ def validate
1260
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1261
+ end
1262
+
1263
+ ::Thrift::Struct.generate_accessors self
1264
+ end
1265
+
1266
+ class TGetSchemasResp
1267
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1268
+ STATUS = 1
1269
+ OPERATIONHANDLE = 2
1270
+
1271
+ FIELDS = {
1272
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1273
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle, :optional => true}
1274
+ }
1275
+
1276
+ def struct_fields; FIELDS; end
1277
+
1278
+ def validate
1279
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1280
+ end
1281
+
1282
+ ::Thrift::Struct.generate_accessors self
1283
+ end
1284
+
1285
+ class TGetTablesReq
1286
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1287
+ SESSIONHANDLE = 1
1288
+ CATALOGNAME = 2
1289
+ SCHEMANAME = 3
1290
+ TABLENAME = 4
1291
+ TABLETYPES = 5
1292
+
1293
+ FIELDS = {
1294
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle},
1295
+ CATALOGNAME => {:type => ::Thrift::Types::STRING, :name => 'catalogName', :optional => true},
1296
+ SCHEMANAME => {:type => ::Thrift::Types::STRING, :name => 'schemaName', :optional => true},
1297
+ TABLENAME => {:type => ::Thrift::Types::STRING, :name => 'tableName', :optional => true},
1298
+ TABLETYPES => {:type => ::Thrift::Types::LIST, :name => 'tableTypes', :element => {:type => ::Thrift::Types::STRING}, :optional => true}
1299
+ }
1300
+
1301
+ def struct_fields; FIELDS; end
1302
+
1303
+ def validate
1304
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1305
+ end
1306
+
1307
+ ::Thrift::Struct.generate_accessors self
1308
+ end
1309
+
1310
+ class TGetTablesResp
1311
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1312
+ STATUS = 1
1313
+ OPERATIONHANDLE = 2
1314
+
1315
+ FIELDS = {
1316
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1317
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle, :optional => true}
1318
+ }
1319
+
1320
+ def struct_fields; FIELDS; end
1321
+
1322
+ def validate
1323
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1324
+ end
1325
+
1326
+ ::Thrift::Struct.generate_accessors self
1327
+ end
1328
+
1329
+ class TGetTableTypesReq
1330
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1331
+ SESSIONHANDLE = 1
1332
+
1333
+ FIELDS = {
1334
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle}
1335
+ }
1336
+
1337
+ def struct_fields; FIELDS; end
1338
+
1339
+ def validate
1340
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1341
+ end
1342
+
1343
+ ::Thrift::Struct.generate_accessors self
1344
+ end
1345
+
1346
+ class TGetTableTypesResp
1347
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1348
+ STATUS = 1
1349
+ OPERATIONHANDLE = 2
1350
+
1351
+ FIELDS = {
1352
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1353
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle, :optional => true}
1354
+ }
1355
+
1356
+ def struct_fields; FIELDS; end
1357
+
1358
+ def validate
1359
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1360
+ end
1361
+
1362
+ ::Thrift::Struct.generate_accessors self
1363
+ end
1364
+
1365
+ class TGetColumnsReq
1366
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1367
+ SESSIONHANDLE = 1
1368
+ CATALOGNAME = 2
1369
+ SCHEMANAME = 3
1370
+ TABLENAME = 4
1371
+ COLUMNNAME = 5
1372
+
1373
+ FIELDS = {
1374
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle},
1375
+ CATALOGNAME => {:type => ::Thrift::Types::STRING, :name => 'catalogName', :optional => true},
1376
+ SCHEMANAME => {:type => ::Thrift::Types::STRING, :name => 'schemaName', :optional => true},
1377
+ TABLENAME => {:type => ::Thrift::Types::STRING, :name => 'tableName', :optional => true},
1378
+ COLUMNNAME => {:type => ::Thrift::Types::STRING, :name => 'columnName', :optional => true}
1379
+ }
1380
+
1381
+ def struct_fields; FIELDS; end
1382
+
1383
+ def validate
1384
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1385
+ end
1386
+
1387
+ ::Thrift::Struct.generate_accessors self
1388
+ end
1389
+
1390
+ class TGetColumnsResp
1391
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1392
+ STATUS = 1
1393
+ OPERATIONHANDLE = 2
1394
+
1395
+ FIELDS = {
1396
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1397
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle, :optional => true}
1398
+ }
1399
+
1400
+ def struct_fields; FIELDS; end
1401
+
1402
+ def validate
1403
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1404
+ end
1405
+
1406
+ ::Thrift::Struct.generate_accessors self
1407
+ end
1408
+
1409
+ class TGetFunctionsReq
1410
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1411
+ SESSIONHANDLE = 1
1412
+ CATALOGNAME = 2
1413
+ SCHEMANAME = 3
1414
+ FUNCTIONNAME = 4
1415
+
1416
+ FIELDS = {
1417
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle},
1418
+ CATALOGNAME => {:type => ::Thrift::Types::STRING, :name => 'catalogName', :optional => true},
1419
+ SCHEMANAME => {:type => ::Thrift::Types::STRING, :name => 'schemaName', :optional => true},
1420
+ FUNCTIONNAME => {:type => ::Thrift::Types::STRING, :name => 'functionName'}
1421
+ }
1422
+
1423
+ def struct_fields; FIELDS; end
1424
+
1425
+ def validate
1426
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1427
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field functionName is unset!') unless @functionName
1428
+ end
1429
+
1430
+ ::Thrift::Struct.generate_accessors self
1431
+ end
1432
+
1433
+ class TGetFunctionsResp
1434
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1435
+ STATUS = 1
1436
+ OPERATIONHANDLE = 2
1437
+
1438
+ FIELDS = {
1439
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1440
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle, :optional => true}
1441
+ }
1442
+
1443
+ def struct_fields; FIELDS; end
1444
+
1445
+ def validate
1446
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1447
+ end
1448
+
1449
+ ::Thrift::Struct.generate_accessors self
1450
+ end
1451
+
1452
+ class TGetOperationStatusReq
1453
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1454
+ OPERATIONHANDLE = 1
1455
+
1456
+ FIELDS = {
1457
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle}
1458
+ }
1459
+
1460
+ def struct_fields; FIELDS; end
1461
+
1462
+ def validate
1463
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field operationHandle is unset!') unless @operationHandle
1464
+ end
1465
+
1466
+ ::Thrift::Struct.generate_accessors self
1467
+ end
1468
+
1469
+ class TGetOperationStatusResp
1470
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1471
+ STATUS = 1
1472
+ OPERATIONSTATE = 2
1473
+ SQLSTATE = 3
1474
+ ERRORCODE = 4
1475
+ ERRORMESSAGE = 5
1476
+
1477
+ FIELDS = {
1478
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1479
+ OPERATIONSTATE => {:type => ::Thrift::Types::I32, :name => 'operationState', :optional => true, :enum_class => ::Impala::Protocol::TOperationState},
1480
+ SQLSTATE => {:type => ::Thrift::Types::STRING, :name => 'sqlState', :optional => true},
1481
+ ERRORCODE => {:type => ::Thrift::Types::I32, :name => 'errorCode', :optional => true},
1482
+ ERRORMESSAGE => {:type => ::Thrift::Types::STRING, :name => 'errorMessage', :optional => true}
1483
+ }
1484
+
1485
+ def struct_fields; FIELDS; end
1486
+
1487
+ def validate
1488
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1489
+ unless @operationState.nil? || ::Impala::Protocol::TOperationState::VALID_VALUES.include?(@operationState)
1490
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field operationState!')
1491
+ end
1492
+ end
1493
+
1494
+ ::Thrift::Struct.generate_accessors self
1495
+ end
1496
+
1497
+ class TCancelOperationReq
1498
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1499
+ OPERATIONHANDLE = 1
1500
+
1501
+ FIELDS = {
1502
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle}
1503
+ }
1504
+
1505
+ def struct_fields; FIELDS; end
1506
+
1507
+ def validate
1508
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field operationHandle is unset!') unless @operationHandle
1509
+ end
1510
+
1511
+ ::Thrift::Struct.generate_accessors self
1512
+ end
1513
+
1514
+ class TCancelOperationResp
1515
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1516
+ STATUS = 1
1517
+
1518
+ FIELDS = {
1519
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus}
1520
+ }
1521
+
1522
+ def struct_fields; FIELDS; end
1523
+
1524
+ def validate
1525
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1526
+ end
1527
+
1528
+ ::Thrift::Struct.generate_accessors self
1529
+ end
1530
+
1531
+ class TCloseOperationReq
1532
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1533
+ OPERATIONHANDLE = 1
1534
+
1535
+ FIELDS = {
1536
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle}
1537
+ }
1538
+
1539
+ def struct_fields; FIELDS; end
1540
+
1541
+ def validate
1542
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field operationHandle is unset!') unless @operationHandle
1543
+ end
1544
+
1545
+ ::Thrift::Struct.generate_accessors self
1546
+ end
1547
+
1548
+ class TCloseOperationResp
1549
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1550
+ STATUS = 1
1551
+
1552
+ FIELDS = {
1553
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus}
1554
+ }
1555
+
1556
+ def struct_fields; FIELDS; end
1557
+
1558
+ def validate
1559
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1560
+ end
1561
+
1562
+ ::Thrift::Struct.generate_accessors self
1563
+ end
1564
+
1565
+ class TGetResultSetMetadataReq
1566
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1567
+ OPERATIONHANDLE = 1
1568
+
1569
+ FIELDS = {
1570
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle}
1571
+ }
1572
+
1573
+ def struct_fields; FIELDS; end
1574
+
1575
+ def validate
1576
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field operationHandle is unset!') unless @operationHandle
1577
+ end
1578
+
1579
+ ::Thrift::Struct.generate_accessors self
1580
+ end
1581
+
1582
+ class TGetResultSetMetadataResp
1583
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1584
+ STATUS = 1
1585
+ SCHEMA = 2
1586
+
1587
+ FIELDS = {
1588
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1589
+ SCHEMA => {:type => ::Thrift::Types::STRUCT, :name => 'schema', :class => ::Impala::Protocol::TTableSchema, :optional => true}
1590
+ }
1591
+
1592
+ def struct_fields; FIELDS; end
1593
+
1594
+ def validate
1595
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1596
+ end
1597
+
1598
+ ::Thrift::Struct.generate_accessors self
1599
+ end
1600
+
1601
+ class TFetchResultsReq
1602
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1603
+ OPERATIONHANDLE = 1
1604
+ ORIENTATION = 2
1605
+ MAXROWS = 3
1606
+
1607
+ FIELDS = {
1608
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle},
1609
+ ORIENTATION => {:type => ::Thrift::Types::I32, :name => 'orientation', :default => 0, :enum_class => ::Impala::Protocol::TFetchOrientation},
1610
+ MAXROWS => {:type => ::Thrift::Types::I64, :name => 'maxRows'}
1611
+ }
1612
+
1613
+ def struct_fields; FIELDS; end
1614
+
1615
+ def validate
1616
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field operationHandle is unset!') unless @operationHandle
1617
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field orientation is unset!') unless @orientation
1618
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field maxRows is unset!') unless @maxRows
1619
+ unless @orientation.nil? || ::Impala::Protocol::TFetchOrientation::VALID_VALUES.include?(@orientation)
1620
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field orientation!')
1621
+ end
1622
+ end
1623
+
1624
+ ::Thrift::Struct.generate_accessors self
1625
+ end
1626
+
1627
+ class TFetchResultsResp
1628
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1629
+ STATUS = 1
1630
+ HASMOREROWS = 2
1631
+ RESULTS = 3
1632
+
1633
+ FIELDS = {
1634
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1635
+ HASMOREROWS => {:type => ::Thrift::Types::BOOL, :name => 'hasMoreRows', :optional => true},
1636
+ RESULTS => {:type => ::Thrift::Types::STRUCT, :name => 'results', :class => ::Impala::Protocol::TRowSet, :optional => true}
1637
+ }
1638
+
1639
+ def struct_fields; FIELDS; end
1640
+
1641
+ def validate
1642
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1643
+ end
1644
+
1645
+ ::Thrift::Struct.generate_accessors self
1646
+ end
1647
+
1648
+ class TGetDelegationTokenReq
1649
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1650
+ SESSIONHANDLE = 1
1651
+ OWNER = 2
1652
+ RENEWER = 3
1653
+
1654
+ FIELDS = {
1655
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle},
1656
+ OWNER => {:type => ::Thrift::Types::STRING, :name => 'owner'},
1657
+ RENEWER => {:type => ::Thrift::Types::STRING, :name => 'renewer'}
1658
+ }
1659
+
1660
+ def struct_fields; FIELDS; end
1661
+
1662
+ def validate
1663
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1664
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field owner is unset!') unless @owner
1665
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field renewer is unset!') unless @renewer
1666
+ end
1667
+
1668
+ ::Thrift::Struct.generate_accessors self
1669
+ end
1670
+
1671
+ class TGetDelegationTokenResp
1672
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1673
+ STATUS = 1
1674
+ DELEGATIONTOKEN = 2
1675
+
1676
+ FIELDS = {
1677
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1678
+ DELEGATIONTOKEN => {:type => ::Thrift::Types::STRING, :name => 'delegationToken', :optional => true}
1679
+ }
1680
+
1681
+ def struct_fields; FIELDS; end
1682
+
1683
+ def validate
1684
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1685
+ end
1686
+
1687
+ ::Thrift::Struct.generate_accessors self
1688
+ end
1689
+
1690
+ class TCancelDelegationTokenReq
1691
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1692
+ SESSIONHANDLE = 1
1693
+ DELEGATIONTOKEN = 2
1694
+
1695
+ FIELDS = {
1696
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle},
1697
+ DELEGATIONTOKEN => {:type => ::Thrift::Types::STRING, :name => 'delegationToken'}
1698
+ }
1699
+
1700
+ def struct_fields; FIELDS; end
1701
+
1702
+ def validate
1703
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1704
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field delegationToken is unset!') unless @delegationToken
1705
+ end
1706
+
1707
+ ::Thrift::Struct.generate_accessors self
1708
+ end
1709
+
1710
+ class TCancelDelegationTokenResp
1711
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1712
+ STATUS = 1
1713
+
1714
+ FIELDS = {
1715
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus}
1716
+ }
1717
+
1718
+ def struct_fields; FIELDS; end
1719
+
1720
+ def validate
1721
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1722
+ end
1723
+
1724
+ ::Thrift::Struct.generate_accessors self
1725
+ end
1726
+
1727
+ class TRenewDelegationTokenReq
1728
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1729
+ SESSIONHANDLE = 1
1730
+ DELEGATIONTOKEN = 2
1731
+
1732
+ FIELDS = {
1733
+ SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::TSessionHandle},
1734
+ DELEGATIONTOKEN => {:type => ::Thrift::Types::STRING, :name => 'delegationToken'}
1735
+ }
1736
+
1737
+ def struct_fields; FIELDS; end
1738
+
1739
+ def validate
1740
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field sessionHandle is unset!') unless @sessionHandle
1741
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field delegationToken is unset!') unless @delegationToken
1742
+ end
1743
+
1744
+ ::Thrift::Struct.generate_accessors self
1745
+ end
1746
+
1747
+ class TRenewDelegationTokenResp
1748
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1749
+ STATUS = 1
1750
+
1751
+ FIELDS = {
1752
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus}
1753
+ }
1754
+
1755
+ def struct_fields; FIELDS; end
1756
+
1757
+ def validate
1758
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1759
+ end
1760
+
1761
+ ::Thrift::Struct.generate_accessors self
1762
+ end
1763
+
1764
+ class TGetLogReq
1765
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1766
+ OPERATIONHANDLE = 1
1767
+
1768
+ FIELDS = {
1769
+ OPERATIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'operationHandle', :class => ::Impala::Protocol::TOperationHandle}
1770
+ }
1771
+
1772
+ def struct_fields; FIELDS; end
1773
+
1774
+ def validate
1775
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field operationHandle is unset!') unless @operationHandle
1776
+ end
1777
+
1778
+ ::Thrift::Struct.generate_accessors self
1779
+ end
1780
+
1781
+ class TGetLogResp
1782
+ include ::Thrift::Struct, ::Thrift::Struct_Union
1783
+ STATUS = 1
1784
+ LOG = 2
1785
+
1786
+ FIELDS = {
1787
+ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::TStatus},
1788
+ LOG => {:type => ::Thrift::Types::STRING, :name => 'log'}
1789
+ }
1790
+
1791
+ def struct_fields; FIELDS; end
1792
+
1793
+ def validate
1794
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status
1795
+ raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field log is unset!') unless @log
1796
+ end
1797
+
1798
+ ::Thrift::Struct.generate_accessors self
1799
+ end
1800
+
1801
+ end
1802
+ end