[ https://issues.apache.org/jira/browse/HIVE-28063?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Stamatis Zampetakis resolved HIVE-28063. ---------------------------------------- Fix Version/s: 4.1.0 Resolution: Fixed Fixed in [https://github.com/apache/hive/commit/49e65bdd7fd47adffbc59091eaea1618d90c253a.] Thanks for the reviews [~abstractdog], [~aturoczy] ! > Drop PerfLogger#setPerfLogger method and unused fields/methods > -------------------------------------------------------------- > > Key: HIVE-28063 > URL: https://issues.apache.org/jira/browse/HIVE-28063 > Project: Hive > Issue Type: Task > Components: Hive, Standalone Metastore > Reporter: Stamatis Zampetakis > Assignee: Stamatis Zampetakis > Priority: Major > Labels: pull-request-available > Fix For: 4.1.0 > > > The PerfLogger#setPerfLogger is redundant and error-prone. > The small number of current uses could be replaced by simply calling the > respective getter (which implicitly changes the underlying ThreadLocal > variable). > Ideally thread local variable should never be set after obtaining the initial > value. Moreover, allowing any caller to change the thread local variable can > affect the correctness of the program. > Dropping this method improves the encapsulation and readability of the class. > The org.apache.hadoop.hive.metastore.metrics.PerfLogger has various unused > fields/methods that can be removed as well to improve encapsulation, > readability, and maintenance. -- This message was sent by Atlassian Jira (v8.20.10#820010)