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

Jason Dere commented on HIVE-9095:
----------------------------------

Have you seen an actual issue caused by this?
During query compilation, the session will attempt to resolve the permanent 
function's class name (see FunctionRegistry.checkFunctionClass()).  If this 
fails, it assumes that this session has not loaded the resources specified for 
the permanent function, and will attempt to load them and try again.

If this is not working properly, please mention what error you are seeing.

> permanent functions' ClassLoader should be global instead of per-session
> ------------------------------------------------------------------------
>
>                 Key: HIVE-9095
>                 URL: https://issues.apache.org/jira/browse/HIVE-9095
>             Project: Hive
>          Issue Type: Improvement
>          Components: HiveServer2, UDF
>    Affects Versions: 0.14.0, 0.13.1
>            Reporter: Nemon Lou
>
> FunctionRegistry.mFunctions is static. That means that in HS2 case, all users 
> will share the same UDF class object from  mFunctions ,which lead to share 
> the same classloader that load this class. 
> First,this will make the per-session classloader useless.Because only the 
> first classLoader will be used to initailize the instances of the permanent 
> UDF class.
> Second, it's will cause class not found exception,when the classLoader 
> created by the first session has been closed before load all the classes that 
> need.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to