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

ASF GitHub Bot commented on DRILL-5533:
---------------------------------------

GitHub user arina-ielchiieva opened a pull request:

    https://github.com/apache/drill/pull/843

    DRILL-5533: Fix flag assignment in FunctionInitializer.checkInit() method

    Changes:
    1. Fixed DCL in FunctionInitializer.checkInit() method (update flag 
parameter when function body is loaded).
    2. Fixed ImportGrabber.getImports() method to return the list with imports.
    3. Added unit tests for FunctionInitializer.
    4, Minor refactoring (renamed methods, added javadoc).

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/arina-ielchiieva/drill DRILL-5533

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/drill/pull/843.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #843
    
----
commit 69e911a37115a4b6d98db88f33557ca5cf2b4e85
Author: Arina Ielchiieva <[email protected]>
Date:   2017-05-22T14:49:31Z

    DRILL-5533: Fix flag assignment in FunctionInitializer.checkInit() method
    
    Changes:
    1. Fixed DCL in FunctionInitializer.checkInit() method (update flag 
parameter when function body is loaded).
    2. Fixed ImportGrabber.getImports() method to return the list with imports.
    3. Added unit tests for FunctionInitializer.
    4, Minor refactoring (renamed methods, added javadoc).

----


> Fix flag assignment in FunctionInitializer.checkInit() method
> -------------------------------------------------------------
>
>                 Key: DRILL-5533
>                 URL: https://issues.apache.org/jira/browse/DRILL-5533
>             Project: Apache Drill
>          Issue Type: Bug
>    Affects Versions: 1.10.0
>            Reporter: Arina Ielchiieva
>            Assignee: Arina Ielchiieva
>            Priority: Minor
>
> FunctionInitializer.checkInit() method uses DCL to ensure that function body 
> is loaded only once. But flag parameter is never updated and all threads are 
> entering synchronized block.
> Also FunctionInitializer.getImports() always returns empty list.
> https://github.com/apache/drill/blob/3e8b01d5b0d3013e3811913f0fd6028b22c1ac3f/exec/java-exec/src/main/java/org/apache/drill/exec/expr/fn/FunctionInitializer.java
> Changes:
> 1. Fix DCL in FunctionInitializer.checkInit() method (update flag parameter  
> when function body is loaded).
> 2. Fix ImportGrabber.getImports() method to return list with imports.
> 3. Add unit tests for FunctionInitializer.
> 4, Minor refactoring (rename methods, add javadoc).



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to