[jira] [Updated] (FLINK-20549) New ExecutionContext doesn't inherit classloader from previous context

2021-04-15 Thread Shengkai Fang (Jira)


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

Shengkai Fang updated FLINK-20549:
--
Attachment: image-2021-04-15-16-51-16-765.png

> New ExecutionContext doesn't inherit classloader from previous context
> --
>
> Key: FLINK-20549
> URL: https://issues.apache.org/jira/browse/FLINK-20549
> Project: Flink
>  Issue Type: Bug
>  Components: Table SQL / Client
>Reporter: Rui Li
>Assignee: Shengkai Fang
>Priority: Major
> Fix For: 1.13.0
>
> Attachments: image-2021-04-15-16-51-16-765.png
>
>
> When users change session properties from SQL client, {{LocalExecutor}} 
> creates a new {{ExecutionContext}}. The new {{ExecutionContext}} inherits 
> {{SessionState}} from previous session, which means the loaded Catalog/Module 
> instances are reused. Since Catalog/Module are pluggable, the classes may 
> come from user jars. However the new {{ExecutionContext}} doesn't inherit 
> classloader from previous session. That means when the Catalog/Module 
> instances are used, the thread context classloader and the defining 
> classloader are different.
> This can cause problems such as:
> # Define a {{HiveModule}} in yaml file. Don't put the hive connector jar 
> under lib folder, but add it through the {{"-l"}} option when launching the 
> SQL client.
> # Run some query using a hive built-in function.
> # Change some session property to trigger a re-creation of 
> {{ExecutionContext}}.
> # Run the same query again and it would fail because the hive built-in 
> function cannot be instantiated.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Updated] (FLINK-20549) New ExecutionContext doesn't inherit classloader from previous context

2021-04-01 Thread Jark Wu (Jira)


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

Jark Wu updated FLINK-20549:

Fix Version/s: 1.13.0

> New ExecutionContext doesn't inherit classloader from previous context
> --
>
> Key: FLINK-20549
> URL: https://issues.apache.org/jira/browse/FLINK-20549
> Project: Flink
>  Issue Type: Bug
>  Components: Table SQL / Client
>Reporter: Rui Li
>Priority: Major
> Fix For: 1.13.0
>
>
> When users change session properties from SQL client, {{LocalExecutor}} 
> creates a new {{ExecutionContext}}. The new {{ExecutionContext}} inherits 
> {{SessionState}} from previous session, which means the loaded Catalog/Module 
> instances are reused. Since Catalog/Module are pluggable, the classes may 
> come from user jars. However the new {{ExecutionContext}} doesn't inherit 
> classloader from previous session. That means when the Catalog/Module 
> instances are used, the thread context classloader and the defining 
> classloader are different.
> This can cause problems such as:
> # Define a {{HiveModule}} in yaml file. Don't put the hive connector jar 
> under lib folder, but add it through the {{"-l"}} option when launching the 
> SQL client.
> # Run some query using a hive built-in function.
> # Change some session property to trigger a re-creation of 
> {{ExecutionContext}}.
> # Run the same query again and it would fail because the hive built-in 
> function cannot be instantiated.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Updated] (FLINK-20549) New ExecutionContext doesn't inherit classloader from previous context

2020-12-09 Thread Rui Li (Jira)


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

Rui Li updated FLINK-20549:
---
Description: 
When users change session properties from SQL client, {{LocalExecutor}} creates 
a new {{ExecutionContext}}. The new {{ExecutionContext}} inherits 
{{SessionState}} from previous session, which means the loaded Catalog/Module 
instances are reused. Since Catalog/Module are pluggable, the classes may come 
from user jars. However the new {{ExecutionContext}} doesn't inherit 
classloader from previous session. That means when the Catalog/Module instances 
are used, the thread context classloader and the defining classloader are 
different.

This can cause problems such as:
# Define a {{HiveModule}} in yaml file. Don't put the hive connector jar under 
lib folder, but add it through the {{"-l"}} option when launching the SQL 
client.
# Run some query using a hive built-in function.
# Change some session property to trigger a re-creation of {{ExecutionContext}}.
# Run the same query again and it would fail because the hive built-in function 
cannot be instantiated.

> New ExecutionContext doesn't inherit classloader from previous context
> --
>
> Key: FLINK-20549
> URL: https://issues.apache.org/jira/browse/FLINK-20549
> Project: Flink
>  Issue Type: Bug
>  Components: Table SQL / Client
>Reporter: Rui Li
>Priority: Major
>
> When users change session properties from SQL client, {{LocalExecutor}} 
> creates a new {{ExecutionContext}}. The new {{ExecutionContext}} inherits 
> {{SessionState}} from previous session, which means the loaded Catalog/Module 
> instances are reused. Since Catalog/Module are pluggable, the classes may 
> come from user jars. However the new {{ExecutionContext}} doesn't inherit 
> classloader from previous session. That means when the Catalog/Module 
> instances are used, the thread context classloader and the defining 
> classloader are different.
> This can cause problems such as:
> # Define a {{HiveModule}} in yaml file. Don't put the hive connector jar 
> under lib folder, but add it through the {{"-l"}} option when launching the 
> SQL client.
> # Run some query using a hive built-in function.
> # Change some session property to trigger a re-creation of 
> {{ExecutionContext}}.
> # Run the same query again and it would fail because the hive built-in 
> function cannot be instantiated.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)