hive-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vihang Karajgaonkar (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HIVE-20258) Should Syncronize getInstance in ReplChangeManager
Date Fri, 24 Aug 2018 17:33:00 GMT

    [ https://issues.apache.org/jira/browse/HIVE-20258?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16591958#comment-16591958
] 

Vihang Karajgaonkar commented on HIVE-20258:
--------------------------------------------

+1

cc: [~thejas] [~vgumashta] who are more familiar with ReplManager.

> Should Syncronize getInstance in ReplChangeManager
> --------------------------------------------------
>
>                 Key: HIVE-20258
>                 URL: https://issues.apache.org/jira/browse/HIVE-20258
>             Project: Hive
>          Issue Type: Bug
>          Components: Metastore
>    Affects Versions: 3.0.0, 4.0.0
>            Reporter: BELUGA BEHR
>            Assignee: BELUGA BEHR
>            Priority: Minor
>         Attachments: HIVE-20258.1.patch
>
>
> {code:java}
>   public static ReplChangeManager getInstance(Configuration conf) throws MetaException
{
>     if (instance == null) {
>       instance = new ReplChangeManager(conf);
>     }
>     return instance;
>   }
> {code}
> This method needs to be synchronized or two different threads may see a 'null' value
and each create their own manager.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message