Alexey Serbin has uploaded this change for review. ( 
http://gerrit.cloudera.org:8080/23556


Change subject: KUDU-1261 introduce ARRAY_1D_COLUMN_TYPE feature for masters
......................................................................

KUDU-1261 introduce ARRAY_1D_COLUMN_TYPE feature for masters

This changelist introduces a new feature flag ARRAY_1D_COLUMN_TYPE
for Kudu masters to reflect whether one-dimensional array columns
are supported by the system catalog.  Also, the C++ client code
is updated to require the feature flag at the server side when sending
requests to create a table with array type columns or alter an array
type column in already existing table.

I didn't add tests to cover the new functionality since it's cumbersome
to simulate different Kudu versions in the test scaffolding, and there
is no control over the built-in feature flags in the result server-side
binary.  However, I manually verified that attempts to create a new
table with an array column using a kudu-master without the necessary
functionality (e.g., bits compiled from the 1.18.x branch) result in
proper behavior -- an actionable error is reported by the client, e.g.:

  Not implemented: Error creating table array_table on the master: cluster does 
not support CreateTable with feature(s) ARRAY_1D_COLUMN_TYPE

Without this patch, an attempt to create the same table would result
in an error as well, but it's quite cryptic and not actionable, e.g.:

  Remote error: Error creating table array_table on the master: Invalid 
argument: invalid parameter for call kudu.master.MasterService.CreateTable: 
missing fields: schema.columns[3].type, schema.columns[4].type

I'm planning to post a separate patch to update the Java client as well.

Change-Id: I61ab0d7446409ad924454d2d272bb02512bdffc8
---
M src/kudu/client/client-internal.cc
M src/kudu/client/client-internal.h
M src/kudu/client/client.cc
M src/kudu/client/table_alterer-internal.cc
M src/kudu/client/table_alterer-internal.h
M src/kudu/common/schema.cc
M src/kudu/common/schema.h
M src/kudu/master/master.proto
8 files changed, 47 insertions(+), 11 deletions(-)



  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/56/23556/1
--
To view, visit http://gerrit.cloudera.org:8080/23556
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I61ab0d7446409ad924454d2d272bb02512bdffc8
Gerrit-Change-Number: 23556
Gerrit-PatchSet: 1
Gerrit-Owner: Alexey Serbin <[email protected]>

Reply via email to