feathub
feathub copied to clipboard
Avoid tracking class loader for each table environment
PyFlink 1.16 and 1.17 have problem working with multiple StreamTableEnvironment. Creating a StreamTableEnvironment will overwrite the context class loader that belongs to the previous StreamTableEnvironment, which can cause class loading problem to the previous table environment. Therefore, we need to keep track of the classloader of each table environment. And set the context class loader accordingly when running operation on the table environment. This can be remove once https://issues.apache.org/jira/browse/FLINK-31943 is resolved.