Files
impala/common/thrift/Descriptors.thrift
Nong Li 69fe1c6c10 Change FE to use ColumnType instead of PrimitiveType.
PrimitiveType is an enum and cannot be used for more complex types. The change
touches a lot of files but very mechanically.

A similar change needs to be done in the BE which will be a subsequent patch.

The version as I have it breaks rolling upgrade due to the thrift changes. If
this is not okay, we can work around that but it will be annoying.

Change-Id: If3838bb27377bfc436afd6d90a327de2ead0af54
Reviewed-on: http://gerrit.ent.cloudera.com:8080/1287
Reviewed-by: Nong Li <nong@cloudera.com>
Tested-by: jenkins
Reviewed-on: http://gerrit.ent.cloudera.com:8080/1304
Reviewed-by: Henry Robinson <henry@cloudera.com>
Tested-by: Henry Robinson <henry@cloudera.com>
2014-01-17 14:32:55 -08:00

64 lines
1.9 KiB
Thrift

// Copyright 2012 Cloudera Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
namespace cpp impala
namespace java com.cloudera.impala.thrift
include "CatalogObjects.thrift"
include "Types.thrift"
include "Exprs.thrift"
struct TSlotDescriptor {
1: required Types.TSlotId id
2: required Types.TTupleId parent
3: required Types.TColumnType slotType
4: required i32 columnPos // in originating table
5: required i32 byteOffset // into tuple
6: required i32 nullIndicatorByte
7: required i32 nullIndicatorBit
9: required i32 slotIdx
10: required bool isMaterialized
}
// "Union" of all table types.
struct TTableDescriptor {
1: required Types.TTableId id
2: required CatalogObjects.TTableType tableType
3: required i32 numCols
4: required i32 numClusteringCols
5: optional CatalogObjects.THdfsTable hdfsTable
6: optional CatalogObjects.THBaseTable hbaseTable
// Unqualified name of table
7: required string tableName;
// Name of the database that the table belongs to
8: required string dbName;
}
struct TTupleDescriptor {
1: required Types.TTupleId id
2: required i32 byteSize
3: required i32 numNullBytes
4: optional Types.TTableId tableId
}
struct TDescriptorTable {
1: optional list<TSlotDescriptor> slotDescriptors;
2: required list<TTupleDescriptor> tupleDescriptors;
// all table descriptors referenced by tupleDescriptors
3: optional list<TTableDescriptor> tableDescriptors;
}