HBASE-12137 Alter table add cf doesn't do compression test (Virag Kothari)
This commit is contained in:
parent
ef35182f1f
commit
7972ae764b
|
@ -1376,18 +1376,19 @@ public class HMaster extends HRegionServer implements MasterServices, Server {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void addColumn(final TableName tableName, final HColumnDescriptor column)
|
public void addColumn(final TableName tableName, final HColumnDescriptor columnDescriptor)
|
||||||
throws IOException {
|
throws IOException {
|
||||||
checkInitialized();
|
checkInitialized();
|
||||||
|
checkCompression(columnDescriptor);
|
||||||
if (cpHost != null) {
|
if (cpHost != null) {
|
||||||
if (cpHost.preAddColumn(tableName, column)) {
|
if (cpHost.preAddColumn(tableName, columnDescriptor)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//TODO: we should process this (and some others) in an executor
|
//TODO: we should process this (and some others) in an executor
|
||||||
new TableAddFamilyHandler(tableName, column, this, this).prepare().process();
|
new TableAddFamilyHandler(tableName, columnDescriptor, this, this).prepare().process();
|
||||||
if (cpHost != null) {
|
if (cpHost != null) {
|
||||||
cpHost.postAddColumn(tableName, column);
|
cpHost.postAddColumn(tableName, columnDescriptor);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue