saihemanth-cloudera commented on code in PR #3247:
URL: https://github.com/apache/hive/pull/3247#discussion_r912033165


##########
itests/util/src/main/java/org/apache/hadoop/hive/ql/hooks/VerifyOutputTableLocationSchemeIsFileHook.java:
##########
@@ -24,10 +24,10 @@ public class VerifyOutputTableLocationSchemeIsFileHook 
implements ExecuteWithHoo
 
   @Override
   public void run(HookContext hookContext) {
-    for (WriteEntity output : hookContext.getOutputs()) {
-      if (output.getType() == WriteEntity.Type.TABLE) {
-        String scheme = 
output.getTable().getDataLocation().toUri().getScheme();
-        Assert.assertTrue(output.getTable().getTableName() + " has a location 
which has a " +
+    for (ReadEntity input : hookContext.getInputs()) {

Review Comment:
   I changed it for the following reason:
   The output list now has a source table(old table name) and destination 
table(renamed table name). This class is used in the alter_table_location.q to 
check the schema of renamed table file location. 
   renamed table's getDataLocation() would be null at this stage because we'll 
be setting the table's location in the MetaStoreDefaultTransformer class in the 
HMS during execution. HMS will set the new location with the same schema. 
That's the reason why I have changed from outputs to inputs. 
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to