Skip to content

Commit

Permalink
[HUDI-2676] Hudi should synchronize owner information to hudi _rt/_ro…
Browse files Browse the repository at this point in the history
… table. (#3911)
  • Loading branch information
xiarixiaoyao authored Nov 3, 2021
1 parent f2fb1aa commit acc4062
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

package org.apache.hudi.hive.ddl;

import org.apache.hadoop.security.UserGroupInformation;
import org.apache.hudi.common.fs.FSUtils;
import org.apache.hudi.common.fs.StorageSchemes;
import org.apache.hudi.hive.HiveSyncConfig;
Expand Down Expand Up @@ -101,6 +102,7 @@ public void createTable(String tableName, MessageType storageSchema, String inpu
Table newTb = new Table();
newTb.setDbName(syncConfig.databaseName);
newTb.setTableName(tableName);
newTb.setOwner(UserGroupInformation.getCurrentUser().getShortUserName());
newTb.setCreateTime((int) System.currentTimeMillis());
StorageDescriptor storageDescriptor = new StorageDescriptor();
storageDescriptor.setCols(fieldSchema);
Expand Down

0 comments on commit acc4062

Please sign in to comment.