[jira] [Work logged] (HIVE-25411) Don't parse zk path created by PrivilegeSynchronizer to get HiveServer2 URI

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25411?focusedWorklogId=684278=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684278
 ]

ASF GitHub Bot logged work on HIVE-25411:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2553:
URL: https://github.com/apache/hive/pull/2553#issuecomment-974730506


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684278)
Time Spent: 20m  (was: 10m)

> Don't parse zk path created by PrivilegeSynchronizer to get HiveServer2 URI 
> 
>
> Key: HIVE-25411
> URL: https://issues.apache.org/jira/browse/HIVE-25411
> Project: Hive
>  Issue Type: Bug
>Reporter: Chia-Ping Tsai
>Assignee: Chia-Ping Tsai
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> The zk path "/{hive.server2.zookeeper.namespace}/leader" is used by 
> PrivilegeSynchronizer so we should remove it from server hosts when parsing 
> HiveServer2 URI.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-21614) Derby does not support CLOB comparisons

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-21614?focusedWorklogId=684277=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684277
 ]

ASF GitHub Bot logged work on HIVE-21614:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2484:
URL: https://github.com/apache/hive/pull/2484#issuecomment-974730544


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684277)
Time Spent: 1h 20m  (was: 1h 10m)

> Derby does not support CLOB comparisons
> ---
>
> Key: HIVE-21614
> URL: https://issues.apache.org/jira/browse/HIVE-21614
> Project: Hive
>  Issue Type: Bug
>  Components: Metastore
>Affects Versions: 2.3.4, 3.0.0
>Reporter: Vlad Rozov
>Assignee: Hank Fanchiu
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 1h 20m
>  Remaining Estimate: 0h
>
> HiveMetaStoreClient.listTableNamesByFilter() with non empty filter causes 
> exception with Derby DB:
> {noformat}
> Caused by: ERROR 42818: Comparisons between 'CLOB (UCS_BASIC)' and 'CLOB 
> (UCS_BASIC)' are not supported. Types must be comparable. String types must 
> also have matching collation. If collation does not match, a possible 
> solution is to cast operands to force them to the default collation (e.g. 
> SELECT tablename FROM sys.systables WHERE CAST(tablename AS VARCHAR(128)) = 
> 'T1')
>   at org.apache.derby.iapi.error.StandardException.newException(Unknown 
> Source)
>   at org.apache.derby.iapi.error.StandardException.newException(Unknown 
> Source)
>   at 
> org.apache.derby.impl.sql.compile.BinaryComparisonOperatorNode.bindComparisonOperator(Unknown
>  Source)
>   at 
> org.apache.derby.impl.sql.compile.BinaryComparisonOperatorNode.bindExpression(Unknown
>  Source)
>   at 
> org.apache.derby.impl.sql.compile.BinaryOperatorNode.bindExpression(Unknown 
> Source)
>   at 
> org.apache.derby.impl.sql.compile.BinaryLogicalOperatorNode.bindExpression(Unknown
>  Source)
>   at org.apache.derby.impl.sql.compile.AndNode.bindExpression(Unknown 
> Source)
>   at org.apache.derby.impl.sql.compile.SelectNode.bindExpressions(Unknown 
> Source)
>   at 
> org.apache.derby.impl.sql.compile.DMLStatementNode.bindExpressions(Unknown 
> Source)
>   at org.apache.derby.impl.sql.compile.DMLStatementNode.bind(Unknown 
> Source)
>   at org.apache.derby.impl.sql.compile.CursorNode.bindStatement(Unknown 
> Source)
>   at org.apache.derby.impl.sql.GenericStatement.prepMinion(Unknown Source)
>   at org.apache.derby.impl.sql.GenericStatement.prepare(Unknown Source)
>   at 
> org.apache.derby.impl.sql.conn.GenericLanguageConnectionContext.prepareInternalStatement(Unknown
>  Source)
>   ... 42 more
> {noformat}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25346) cleanTxnToWriteIdTable breaks SNAPSHOT isolation

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25346?focusedWorklogId=684273=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684273
 ]

ASF GitHub Bot logged work on HIVE-25346:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2547:
URL: https://github.com/apache/hive/pull/2547#issuecomment-974730512


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684273)
Time Spent: 14.5h  (was: 14h 20m)

> cleanTxnToWriteIdTable breaks SNAPSHOT isolation
> 
>
> Key: HIVE-25346
> URL: https://issues.apache.org/jira/browse/HIVE-25346
> Project: Hive
>  Issue Type: Bug
>Reporter: Zoltan Chovan
>Assignee: Denys Kuzmenko
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 14.5h
>  Remaining Estimate: 0h
>




--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-24484) Upgrade Hadoop to 3.3.1

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-24484?focusedWorklogId=684282=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684282
 ]

ASF GitHub Bot logged work on HIVE-24484:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #1742:
URL: https://github.com/apache/hive/pull/1742#issuecomment-974730579


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684282)
Time Spent: 6.55h  (was: 6h 23m)

> Upgrade Hadoop to 3.3.1
> ---
>
> Key: HIVE-24484
> URL: https://issues.apache.org/jira/browse/HIVE-24484
> Project: Hive
>  Issue Type: Improvement
>Reporter: David Mollitor
>Assignee: David Mollitor
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 6.55h
>  Remaining Estimate: 0h
>




--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25158) Beeline/hive command can't get operation logs when hive.session.id is set

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25158?focusedWorklogId=684276=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684276
 ]

ASF GitHub Bot logged work on HIVE-25158:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2319:
URL: https://github.com/apache/hive/pull/2319#issuecomment-974730573


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684276)
Time Spent: 50m  (was: 40m)

> Beeline/hive command can't get operation logs when hive.session.id is set
> -
>
> Key: HIVE-25158
> URL: https://issues.apache.org/jira/browse/HIVE-25158
> Project: Hive
>  Issue Type: Bug
>Reporter: Robbie Zhang
>Assignee: Robbie Zhang
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 50m
>  Remaining Estimate: 0h
>
> Usually, we can see the operation logs when we run a query from beeline/hive. 
> For example, the query ID, the time taken in compiling/executing, the 
> application information, etc. But if we use "–hiveconf hive.session.id=" 
> to set the session ID, we can't see the operation logs any more. Here are 
> examples:
>  * Without hive.session.id
> {code:java}
> $ hive -e "select 1"
> SLF4J: Class path contains multiple SLF4J bindings.
> ...
> Connected to: Apache Hive (version 3.1.3000.7.1.6.0-297)
> Driver: Hive JDBC (version 3.1.3000.7.1.6.0-297)
> Transaction isolation: TRANSACTION_REPEATABLE_READ
> INFO  : Compiling 
> command(queryId=hive_20210524105207_9d0774b2-8108-4800-a5e4-3b950ae03198): 
> select 1
> INFO  : Semantic Analysis Completed (retrial = false)
> INFO  : Created Hive schema: Schema(fieldSchemas:[FieldSchema(name:_c0, 
> type:int, comment:null)], properties:null)
> INFO  : Completed compiling 
> command(queryId=hive_20210524105207_9d0774b2-8108-4800-a5e4-3b950ae03198); 
> Time taken: 0.122 seconds
> INFO  : Executing 
> command(queryId=hive_20210524105207_9d0774b2-8108-4800-a5e4-3b950ae03198): 
> select 1
> INFO  : Completed executing 
> command(queryId=hive_20210524105207_9d0774b2-8108-4800-a5e4-3b950ae03198); 
> Time taken: 0.016 seconds
> INFO  : OK
> +--+
> | _c0  |
> +--+
> | 1    |
> +--+
> 1 row selected (0.318 seconds)
> Beeline version 3.1.3000.7.1.6.0-297 by Apache Hive
> {code}
>  * With hive.session.id
> {code:java}
> $ hive --hiveconf hive.session.id=abcd -e "select 1"
> SLF4J: Class path contains multiple SLF4J bindings.
> ...
> Connected to: Apache Hive (version 3.1.3000.7.1.6.0-297)
> Driver: Hive JDBC (version 3.1.3000.7.1.6.0-297)
> Transaction isolation: TRANSACTION_REPEATABLE_READ
> +--+
> | _c0  |
> +--+
> | 1|
> +--+
> 1 row selected (5.862 seconds)
> Beeline version 3.1.3000.7.1.6.0-297 by Apache Hive
> {code}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-24830) Revise RowSchema mutability usage

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-24830?focusedWorklogId=684280=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684280
 ]

ASF GitHub Bot logged work on HIVE-24830:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2019:
URL: https://github.com/apache/hive/pull/2019#issuecomment-974730576


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684280)
Time Spent: 40m  (was: 0.5h)

> Revise RowSchema mutability usage
> -
>
> Key: HIVE-24830
> URL: https://issues.apache.org/jira/browse/HIVE-24830
> Project: Hive
>  Issue Type: Bug
>Reporter: Zoltan Haindrich
>Assignee: Zoltan Haindrich
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 40m
>  Remaining Estimate: 0h
>
> RowSchema is essentially a container class for a list of fields.
> * it can be constructed from a "list"
> * the list can be set
> * the list can be accessed
> none of the above methods try to protect the data inside; hence the following 
> could easily  happen:
> {code}
> s=o1.getSchema();
> col=s.getCol("favourite")
> col.setInternalName("asd"); // will modify o1 schema
> newSchema.add(col);
> o2.setSchema(newSchema);
> o2.getSchema().get("asd").setInternalName("xxx"); // will modify o1 and o2 
> schema
> [...]
> {code}
> not sure how much of this is actually cruical; exploratory testrun revealed 
> some cases
> https://github.com/apache/hive/pull/2019



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Updated] (HIVE-25251) Reduce overhead of adding partitions during batch loading of partitions.

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25251?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

ASF GitHub Bot updated HIVE-25251:
--
Labels: pull-request-available  (was: )

> Reduce overhead of adding partitions during batch loading of partitions.
> 
>
> Key: HIVE-25251
> URL: https://issues.apache.org/jira/browse/HIVE-25251
> Project: Hive
>  Issue Type: Sub-task
>Reporter: mahesh kumar behera
>Assignee: mahesh kumar behera
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> The add partitions call done to HMS does a serial execution of data nucleus 
> calls to add the partitions to backend DB. This can be further optimised by 
> batching those sql statements.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25174) HiveMetastoreAuthorizer didn't check URI permission for AlterTableEvent

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25174?focusedWorklogId=684283=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684283
 ]

ASF GitHub Bot logged work on HIVE-25174:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2327:
URL: https://github.com/apache/hive/pull/2327#issuecomment-974730567


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684283)
Time Spent: 50m  (was: 40m)

> HiveMetastoreAuthorizer didn't check URI permission for AlterTableEvent
> ---
>
> Key: HIVE-25174
> URL: https://issues.apache.org/jira/browse/HIVE-25174
> Project: Hive
>  Issue Type: Improvement
>Reporter: Janus Chow
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 50m
>  Remaining Estimate: 0h
>
> When Using Ranger on Hive MetaStore, we met an issue that users without 
> permission to table's HDFS path succeeded in running "msck repair table 
> TABLENAME".
> This command is not authorized when we use `StorageBasedAuthorizer`, after 
> checking the code, we found `StorageBasedAuthorizer` would check the 
> permission of table's HDFS path, while `HiveMetastoreAuthorizer` used by 
> Ranger won't when dealing with the event of `AlterTableEvent`.
> This ticket is to add the URI permission check on AlterTableEvent for 
> `HiveMetastoreAuthorizer`.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25340) Refactor UDFToByte to GenericUDFToByte

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25340?focusedWorklogId=684274=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684274
 ]

ASF GitHub Bot logged work on HIVE-25340:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2487:
URL: https://github.com/apache/hive/pull/2487#issuecomment-974730540


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684274)
Time Spent: 20m  (was: 10m)

> Refactor UDFToByte to GenericUDFToByte
> --
>
> Key: HIVE-25340
> URL: https://issues.apache.org/jira/browse/HIVE-25340
> Project: Hive
>  Issue Type: Sub-task
>Reporter: Ashish Sharma
>Assignee: Ashish Sharma
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Description
> Move implementation of UDFToByte from old UDF.class to GenericUDFToByte with 
> GenericUDF.class
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25251) Reduce overhead of adding partitions during batch loading of partitions.

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25251?focusedWorklogId=684279=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684279
 ]

ASF GitHub Bot logged work on HIVE-25251:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2399:
URL: https://github.com/apache/hive/pull/2399#issuecomment-974730563


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684279)
Remaining Estimate: 0h
Time Spent: 10m

> Reduce overhead of adding partitions during batch loading of partitions.
> 
>
> Key: HIVE-25251
> URL: https://issues.apache.org/jira/browse/HIVE-25251
> Project: Hive
>  Issue Type: Sub-task
>Reporter: mahesh kumar behera
>Assignee: mahesh kumar behera
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> The add partitions call done to HMS does a serial execution of data nucleus 
> calls to add the partitions to backend DB. This can be further optimised by 
> batching those sql statements.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25398) Converted external tables should be able to configure purge behaviour

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25398?focusedWorklogId=684269=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684269
 ]

ASF GitHub Bot logged work on HIVE-25398:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2541:
URL: https://github.com/apache/hive/pull/2541#issuecomment-974730531


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684269)
Time Spent: 20m  (was: 10m)

> Converted external tables should be able to configure purge behaviour
> -
>
> Key: HIVE-25398
> URL: https://issues.apache.org/jira/browse/HIVE-25398
> Project: Hive
>  Issue Type: Bug
>  Components: Standalone Metastore
>Reporter: Panagiotis Garefalakis
>Assignee: Panagiotis Garefalakis
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Creating non-ACID MANAGED tables is not allowed on Hive, which is instead 
> converting these tables to External: 
> https://issues.apache.org/jira/browse/HIVE-22158
> During table translation  both TRANSLATED_TO_EXTERNAL and 
> 'external.table.purge' are set to True. However, there could be the case that 
> the second parameter is already set in the table properties by the User. This 
> is ticket is adding an extra check to maintain that property if set.
> PS: A cleaner solution would be to create these Tables as External directly 
> but there could be the case the User is taking advantage of the translation 
> and is expecting the data NOT to be purged!
> Example:
> {code:java}
> -- Non-ACID table will be translated to EXTERNAL
> create table c(c int) LOCATION 'etp_1' 
> TBLPROPERTIES('transactional'='false','external.table.purge'='false');
> insert into c values(1);
> -- Maintain the purge=false property set above
> desc formatted c;
> select count(*) from c;
> drop table c;
> -- Create table in same location, data should still be there
> create table c(c int) LOCATION 'etp_1' 
> TBLPROPERTIES('transactional'='false','external.table.purge'='false');
> desc formatted c;
> select count(*) from c;
> {code}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-24546) Avoid unwanted cloud storage call during dynamic partition load

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-24546?focusedWorklogId=684281=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684281
 ]

ASF GitHub Bot logged work on HIVE-24546:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2545:
URL: https://github.com/apache/hive/pull/2545#issuecomment-974730521


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684281)
Time Spent: 20m  (was: 10m)

> Avoid unwanted cloud storage call during dynamic partition load
> ---
>
> Key: HIVE-24546
> URL: https://issues.apache.org/jira/browse/HIVE-24546
> Project: Hive
>  Issue Type: Improvement
>Reporter: Rajesh Balamohan
>Priority: Major
>  Labels: pull-request-available
> Attachments: simple_test.sql
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> {code:java}
>  private void createDpDirCheckSrc(final Path dpStagingPath, final Path 
> dpFinalPath) throws IOException {
> if (!fs.exists(dpStagingPath) && !fs.exists(dpFinalPath)) {
>   fs.mkdirs(dpStagingPath);
>   // move task will create dp final path
>   if (reporter != null) {
> reporter.incrCounter(counterGroup, 
> Operator.HIVE_COUNTER_CREATED_DYNAMIC_PARTITIONS, 1);
>   }
> }
>   }
>  {code}
>  
>  
> {noformat}
> at org.apache.hadoop.fs.s3a.Invoker.retryUntranslated(Invoker.java:370)
>   at 
> org.apache.hadoop.fs.s3a.S3AFileSystem.listObjects(S3AFileSystem.java:1960)
>   at 
> org.apache.hadoop.fs.s3a.S3AFileSystem.s3GetFileStatus(S3AFileSystem.java:3164)
>   at 
> org.apache.hadoop.fs.s3a.S3AFileSystem.innerGetFileStatus(S3AFileSystem.java:3031)
>   at 
> org.apache.hadoop.fs.s3a.S3AFileSystem.getFileStatus(S3AFileSystem.java:2899)
>   at org.apache.hadoop.fs.FileSystem.exists(FileSystem.java:1723)
>   at 
> org.apache.hadoop.fs.s3a.S3AFileSystem.exists(S3AFileSystem.java:4157)
>   at 
> org.apache.hadoop.hive.ql.exec.FileSinkOperator.createDpDir(FileSinkOperator.java:948)
>   at 
> org.apache.hadoop.hive.ql.exec.FileSinkOperator.updateDPCounters(FileSinkOperator.java:916)
>   at 
> org.apache.hadoop.hive.ql.exec.FileSinkOperator.createBucketForFileIdx(FileSinkOperator.java:849)
>   at 
> org.apache.hadoop.hive.ql.exec.FileSinkOperator.createBucketFiles(FileSinkOperator.java:814)
>   at 
> org.apache.hadoop.hive.ql.exec.FileSinkOperator.createNewPaths(FileSinkOperator.java:1200)
>   at 
> org.apache.hadoop.hive.ql.exec.FileSinkOperator.getDynOutPaths(FileSinkOperator.java:1324)
>   at 
> org.apache.hadoop.hive.ql.exec.FileSinkOperator.process(FileSinkOperator.java:1036)
>   at 
> org.apache.hadoop.hive.ql.exec.vector.VectorFileSinkOperator.process(VectorFileSinkOperator.java:111)
>   at 
> org.apache.hadoop.hive.ql.exec.Operator.vectorForward(Operator.java:969)
>  {noformat}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25401) Insert overwrite a table which location is on other cluster fail in kerberos cluster

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25401?focusedWorklogId=684270=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684270
 ]

ASF GitHub Bot logged work on HIVE-25401:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2544:
URL: https://github.com/apache/hive/pull/2544#issuecomment-974730527


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684270)
Time Spent: 50m  (was: 40m)

> Insert overwrite  a table which location is on other cluster fail  in 
> kerberos cluster
> --
>
> Key: HIVE-25401
> URL: https://issues.apache.org/jira/browse/HIVE-25401
> Project: Hive
>  Issue Type: Bug
>  Components: Hive
>Affects Versions: 2.3.0, 3.1.2
> Environment: hive 2.3 
> hadoop3 cluster with kerberos 
>Reporter: Max  Xie
>Assignee: Max  Xie
>Priority: Minor
>  Labels: pull-request-available
> Attachments: HIVE-25401.patch, image-2021-07-29-14-25-23-418.png
>
>  Time Spent: 50m
>  Remaining Estimate: 0h
>
> we have tow hdfs clusters with kerberos security,  it means that mapreduce 
> task need delegation tokens to authenticate namenode when hive on mapreduce 
> run.
> Insert overwrite a table which location is on other cluster fail in kerberos 
> cluster. For example, 
>  # yarn cluster's default fs is hdfs://cluster1
>  # tb1's location is hdfs://cluster1/tb1
>  # tb2's location is hdfs://cluster2/tb2 
>  #  sql `INSERT OVERWRITE TABLE  tb2 SELECT * from tb1` run on yarn cluster 
> will fail
>  
> reduce task error log:
> !image-2021-07-29-14-25-23-418.png!
> How to fix:
> After dig it, web found mapreduce job just obtain delegation tokens for input 
> files in FileInputFormat. But Hive context get extendal scratchDir base on 
> table's location, If the table 's location is on other cluster, the 
> delegation token will not be obtained. 
> So we need to obtaine delegation tokens for hive scratchDirs before hive 
> submit mapreduce job.
>  
> How to test:
> no test
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25048) Refine the start/end functions in HMSHandler

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25048?focusedWorklogId=684272=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684272
 ]

ASF GitHub Bot logged work on HIVE-25048:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2441:
URL: https://github.com/apache/hive/pull/2441#issuecomment-974730554


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684272)
Time Spent: 4h 10m  (was: 4h)

> Refine the start/end functions in HMSHandler
> 
>
> Key: HIVE-25048
> URL: https://issues.apache.org/jira/browse/HIVE-25048
> Project: Hive
>  Issue Type: Improvement
>  Components: Standalone Metastore
>Reporter: Zhihua Deng
>Assignee: Zhihua Deng
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 4h 10m
>  Remaining Estimate: 0h
>
> Some start/end functions are incomplete or wrong in the HMSHandler, these 
> functions audit actions, monitor the performance, and notify the end function 
> listeners. We have already measured the performance of the HMSHandler in 
> PerfLogger,  and covered more methods than these functions that have done, so 
> we can remove the monitoring from the start/end functions, move the end 
> function listeners to the RetryingHMSHandler to eliminate the try-finally 
> blocks that spread across many different methods. After these, we can try to 
> cleanup the functions to make HMSHandler be more simplified.
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25321) [HMS] Advance write Id during AlterTableDropPartition

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25321?focusedWorklogId=684275=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684275
 ]

ASF GitHub Bot logged work on HIVE-25321:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2465:
URL: https://github.com/apache/hive/pull/2465#issuecomment-974730548


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684275)
Time Spent: 1.5h  (was: 1h 20m)

> [HMS] Advance write Id during AlterTableDropPartition
> -
>
> Key: HIVE-25321
> URL: https://issues.apache.org/jira/browse/HIVE-25321
> Project: Hive
>  Issue Type: Sub-task
>Reporter: Kishen Das
>Assignee: Kishen Das
>Priority: Major
>  Labels: pull-request-available
> Fix For: 4.0.0
>
>  Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> All DDLs should advance the write ID, so that we can provide consistent data 
> from the cache, based on the validWriteIds. 
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25260) Provide tableId for AllocWriteIdEvent

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25260?focusedWorklogId=684271=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684271
 ]

ASF GitHub Bot logged work on HIVE-25260:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:12
Start Date: 21/Nov/21 00:12
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2403:
URL: https://github.com/apache/hive/pull/2403#issuecomment-974730559


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684271)
Time Spent: 20m  (was: 10m)

> Provide tableId for AllocWriteIdEvent
> -
>
> Key: HIVE-25260
> URL: https://issues.apache.org/jira/browse/HIVE-25260
> Project: Hive
>  Issue Type: Improvement
>Reporter: Yu-Wen Lai
>Assignee: Yu-Wen Lai
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> For event-based incremental refreshing in external cache, we need table ID to 
> make sure we don't update write ID on a wrong table.
> After this patch, we will check if the table exists for allocating write ids. 
> If the table doesn't exist, a MetaException will be thrown.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-24471) Add support for combiner in hash mode group aggregation

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-24471?focusedWorklogId=684267=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684267
 ]

ASF GitHub Bot logged work on HIVE-24471:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:11
Start Date: 21/Nov/21 00:11
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2611:
URL: https://github.com/apache/hive/pull/2611#issuecomment-974730493


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684267)
Time Spent: 2h 40m  (was: 2.5h)

> Add support for combiner in hash mode group aggregation 
> 
>
> Key: HIVE-24471
> URL: https://issues.apache.org/jira/browse/HIVE-24471
> Project: Hive
>  Issue Type: Bug
>  Components: Hive
>Reporter: mahesh kumar behera
>Assignee: mahesh kumar behera
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 2h 40m
>  Remaining Estimate: 0h
>
> In map side group aggregation, partial grouped aggregation is calculated to 
> reduce the data written to disk by map task. In case of hash aggregation, 
> where the input data is not sorted, hash table is used (with sorting also 
> being performed before flushing). If the hash table size increases beyond 
> configurable limit, data is flushed to disk and new hash table is generated. 
> If the reduction by hash table is less than min hash aggregation reduction 
> calculated during compile time, the map side aggregation is converted to 
> streaming mode. So if the first few batch of records does not result into 
> significant reduction, then the mode is switched to streaming mode. This may 
> have impact on performance, if the subsequent batch of records have less 
> number of distinct values. 
> To improve performance both in Hash and Streaming mode, a combiner can be 
> added to the map task after the keys are sorted. This will make sure that the 
> aggregation is done if possible and reduce the data written to disk.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-24742) Support router path or view fs path in Hive table location

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-24742?focusedWorklogId=684268=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684268
 ]

ASF GitHub Bot logged work on HIVE-24742:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:11
Start Date: 21/Nov/21 00:11
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2574:
URL: https://github.com/apache/hive/pull/2574#issuecomment-974730496


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684268)
Time Spent: 1.5h  (was: 1h 20m)

> Support router path or view fs path in Hive table location
> --
>
> Key: HIVE-24742
> URL: https://issues.apache.org/jira/browse/HIVE-24742
> Project: Hive
>  Issue Type: Improvement
>  Components: Hive
>Affects Versions: 3.1.2
>Reporter: Aihua Xu
>Assignee: Aihua Xu
>Priority: Major
>  Labels: pull-request-available
> Attachments: HIVE-24742.patch
>
>  Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> In 
> [FileUtils.java|https://github.com/apache/hive/blob/master/common/src/java/org/apache/hadoop/hive/common/FileUtils.java#L747],
>  equalsFileSystem function checks the base URL to determine if source and 
> destination are on the same cluster and decides copy or move the data. That 
> will not work for viewfs or router base file system since 
> viewfs://ns-default/a and viewfs://ns-default/b may be on different physical 
> clusters.
> FileSystem in HDFS supports resolvePath() function to resolve to the physical 
> path. We can support viewfs and router through such function.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25396) Improve Exception handling in Hive Server 2

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25396?focusedWorklogId=684266=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684266
 ]

ASF GitHub Bot logged work on HIVE-25396:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:11
Start Date: 21/Nov/21 00:11
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2572:
URL: https://github.com/apache/hive/pull/2572#issuecomment-974730501


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684266)
Time Spent: 2.5h  (was: 2h 20m)

> Improve Exception handling in Hive Server 2
> ---
>
> Key: HIVE-25396
> URL: https://issues.apache.org/jira/browse/HIVE-25396
> Project: Hive
>  Issue Type: Bug
>Reporter: Matt McCline
>Assignee: Matt McCline
>Priority: Major
>  Labels: pull-request-available
> Attachments: hive-improve-exception-handling-04-master.patch
>
>  Time Spent: 2.5h
>  Remaining Estimate: 0h
>
> Hive's org.apache.hive.service.thrift.ThriftHttpServlet.doPost method does 
> not handle all Exception kinds. This leaves uncaught Exception handling 
> choices to the Jetty HTTP library. We fix that.
> Also, a Thread.UncaughtExceptionHandler is added to Hive Server 2 so uncaught 
> Exception are handled uniformly, including making them logged and not just 
> printed to stderr.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25495) Upgrade to JLine3

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25495?focusedWorklogId=684265=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684265
 ]

ASF GitHub Bot logged work on HIVE-25495:
-

Author: ASF GitHub Bot
Created on: 21/Nov/21 00:11
Start Date: 21/Nov/21 00:11
Worklog Time Spent: 10m 
  Work Description: github-actions[bot] commented on pull request #2617:
URL: https://github.com/apache/hive/pull/2617#issuecomment-974730488


   This pull request has been automatically marked as stale because it has not 
had recent activity. It will be closed if no further activity occurs.
   Feel free to reach out on the d...@hive.apache.org list if the patch is in 
need of reviews.


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684265)
Time Spent: 20m  (was: 10m)

> Upgrade to JLine3
> -
>
> Key: HIVE-25495
> URL: https://issues.apache.org/jira/browse/HIVE-25495
> Project: Hive
>  Issue Type: Improvement
>Reporter: David Mollitor
>Assignee: David Mollitor
>Priority: Major
>  Labels: pull-request-available
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Jline 2 has been discontinued a long while ago.  Hadoop uses JLine3 so Hive 
> should match.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25680) Authorize #get_table_meta HiveMetastore Server API to use any of the HiveMetastore Authorization model

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25680?focusedWorklogId=684220=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684220
 ]

ASF GitHub Bot logged work on HIVE-25680:
-

Author: ASF GitHub Bot
Created on: 20/Nov/21 13:47
Start Date: 20/Nov/21 13:47
Worklog Time Spent: 10m 
  Work Description: shameersss1 commented on a change in pull request #2770:
URL: https://github.com/apache/hive/pull/2770#discussion_r753676946



##
File path: 
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/HMSHandler.java
##
@@ -5484,6 +5509,29 @@ private void fireReadTablePreEvent(String catName, 
String dbName, String tblName
 }
   }
 
+  /**
+   * Fire a pre-event for read database operation, if there are any
+   * pre-event listeners registered
+   */
+  private void fireReadDatabasePreEvent(final String name)
+  throws MetaException, NoSuchObjectException {
+if(preListeners.size() > 0) {
+  // do this only if there is a pre event listener registered (avoid 
unnecessary
+  // metastore api call)
+  String[] parsedDbName = parseDbName(name, conf);
+  Database db = null;
+  try {
+db = get_database_core(parsedDbName[CAT_NAME], parsedDbName[DB_NAME]);
+if (db == null) {
+  throw new NoSuchObjectException("Database: " + name + " not found");
+}
+  } catch(MetaException | NoSuchObjectException e) {
+throw new RuntimeException(e);

Review comment:
   Added tests




-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684220)
Time Spent: 2.5h  (was: 2h 20m)

> Authorize #get_table_meta HiveMetastore Server API to use any of the 
> HiveMetastore Authorization model
> --
>
> Key: HIVE-25680
> URL: https://issues.apache.org/jira/browse/HIVE-25680
> Project: Hive
>  Issue Type: Bug
>  Components: Standalone Metastore
>Affects Versions: All Versions
>Reporter: Syed Shameerur Rahman
>Assignee: Syed Shameerur Rahman
>Priority: Major
>  Labels: pull-request-available
> Fix For: 4.0.0
>
> Attachments: Screenshot 2021-11-08 at 2.39.30 PM.png
>
>  Time Spent: 2.5h
>  Remaining Estimate: 0h
>
> When Apache Hue or any other application which uses #get_table_meta API is 
> not gated to use any of the authorization model which HiveMetastore provides.
> For more information on Storage based Authorization Model : 
> https://cwiki.apache.org/confluence/display/Hive/HCatalog+Authorization
> You can easily reproduce this with Apache Hive + Apache Hue
> {code:java}
>   
> hive.security.metastore.authorization.manager
> 
> org.apache.hadoop.hive.ql.security.authorization.StorageBasedAuthorizationProvider
>   
> 
> hive.security.metastore.authenticator.manager
> 
> org.apache.hadoop.hive.ql.security.HadoopDefaultMetastoreAuthenticator
>   
> 
> hive.metastore.pre.event.listeners
> 
> org.apache.hadoop.hive.ql.security.authorization.AuthorizationPreEventListener
>   
> {code}
> {code:java}
> #!/bin/bash
> set -x
> hdfs dfs -mkdir /datasets
> hdfs dfs -mkdir /datasets/database1
> hdfs dfs -mkdir /datasets/database1/table1
> echo "stefano,1992" | hdfs dfs -put - /datasets/database1/table1/file1.csv
> hdfs dfs -chmod -R 700 /datasets/database1
> sudo tee -a setup.hql > /dev/null < CREATE DATABASE IF NOT EXISTS database1 LOCATION "/datasets/database1";
> CREATE EXTERNAL TABLE IF NOT EXISTS database1.table1 (
>   name string, 
>   year int)
> ROW FORMAT DELIMITED
> FIELDS TERMINATED BY ','
> LOCATION
>   '/datasets/database1/table1';
> EOT
> hive -f setup.hql
> {code}
> 1. Login to Hue => create the first user called "admin" and provide a 
> password Access the Hive Editor
> 2. On the SQL section on the left under Databases you should see default and 
> database1 listed. Click on database1
> 3. As you can see a table called table1 is listed => this should not be 
> possible as our admin user has no HDFS grants on /datasets/database1
> 4. run from the Hive editor the following query SHOW TABLES; The output shows 
> a Permission denied error => this is the expected behavior



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Work logged] (HIVE-25680) Authorize #get_table_meta HiveMetastore Server API to use any of the HiveMetastore Authorization model

2021-11-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/HIVE-25680?focusedWorklogId=684219=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-684219
 ]

ASF GitHub Bot logged work on HIVE-25680:
-

Author: ASF GitHub Bot
Created on: 20/Nov/21 13:46
Start Date: 20/Nov/21 13:46
Worklog Time Spent: 10m 
  Work Description: shameersss1 commented on pull request #2770:
URL: https://github.com/apache/hive/pull/2770#issuecomment-974652694


   @kgyrtkirk - I have added tests for the same. Could you please re-review it?


-- 
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: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 684219)
Time Spent: 2h 20m  (was: 2h 10m)

> Authorize #get_table_meta HiveMetastore Server API to use any of the 
> HiveMetastore Authorization model
> --
>
> Key: HIVE-25680
> URL: https://issues.apache.org/jira/browse/HIVE-25680
> Project: Hive
>  Issue Type: Bug
>  Components: Standalone Metastore
>Affects Versions: All Versions
>Reporter: Syed Shameerur Rahman
>Assignee: Syed Shameerur Rahman
>Priority: Major
>  Labels: pull-request-available
> Fix For: 4.0.0
>
> Attachments: Screenshot 2021-11-08 at 2.39.30 PM.png
>
>  Time Spent: 2h 20m
>  Remaining Estimate: 0h
>
> When Apache Hue or any other application which uses #get_table_meta API is 
> not gated to use any of the authorization model which HiveMetastore provides.
> For more information on Storage based Authorization Model : 
> https://cwiki.apache.org/confluence/display/Hive/HCatalog+Authorization
> You can easily reproduce this with Apache Hive + Apache Hue
> {code:java}
>   
> hive.security.metastore.authorization.manager
> 
> org.apache.hadoop.hive.ql.security.authorization.StorageBasedAuthorizationProvider
>   
> 
> hive.security.metastore.authenticator.manager
> 
> org.apache.hadoop.hive.ql.security.HadoopDefaultMetastoreAuthenticator
>   
> 
> hive.metastore.pre.event.listeners
> 
> org.apache.hadoop.hive.ql.security.authorization.AuthorizationPreEventListener
>   
> {code}
> {code:java}
> #!/bin/bash
> set -x
> hdfs dfs -mkdir /datasets
> hdfs dfs -mkdir /datasets/database1
> hdfs dfs -mkdir /datasets/database1/table1
> echo "stefano,1992" | hdfs dfs -put - /datasets/database1/table1/file1.csv
> hdfs dfs -chmod -R 700 /datasets/database1
> sudo tee -a setup.hql > /dev/null < CREATE DATABASE IF NOT EXISTS database1 LOCATION "/datasets/database1";
> CREATE EXTERNAL TABLE IF NOT EXISTS database1.table1 (
>   name string, 
>   year int)
> ROW FORMAT DELIMITED
> FIELDS TERMINATED BY ','
> LOCATION
>   '/datasets/database1/table1';
> EOT
> hive -f setup.hql
> {code}
> 1. Login to Hue => create the first user called "admin" and provide a 
> password Access the Hive Editor
> 2. On the SQL section on the left under Databases you should see default and 
> database1 listed. Click on database1
> 3. As you can see a table called table1 is listed => this should not be 
> possible as our admin user has no HDFS grants on /datasets/database1
> 4. run from the Hive editor the following query SHOW TABLES; The output shows 
> a Permission denied error => this is the expected behavior



--
This message was sent by Atlassian Jira
(v8.20.1#820001)