[jira] [Created] (FLINK-18076) Sql client uses wrong class loader when parsing queries

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[jira] [Created] (FLINK-18076) Sql client uses wrong class loader when parsing queries

Shang Yuanchun (Jira)
Dawid Wysakowicz created FLINK-18076:
----------------------------------------

             Summary: Sql client uses wrong class loader when parsing queries
                 Key: FLINK-18076
                 URL: https://issues.apache.org/jira/browse/FLINK-18076
             Project: Flink
          Issue Type: Bug
          Components: Table SQL / Client
    Affects Versions: 1.11.0, 1.12.0
            Reporter: Dawid Wysakowicz
             Fix For: 1.11.0


Sql-client when parsing queries does not use the user class loader from {{ExecutionContext}}. This makes it impossible to query any sources if the dependencies are added with {{-j}} flag.

In order to reproduce it try querying e.g. KafkaDynamicSource with
{code}
CREATE TABLE MyUserTable (
   f0 BIGINT
) WITH (
  'connector' = 'kafka',      

  'topic' = 'topic_name', -- required: topic name from which the table is read

 -- required: specify the Kafka server connection string
  'properties.bootstrap.servers' = 'localhost:9092',
  -- required for Kafka source, optional for Kafka sink, specify consumer group
  'properties.group.id' = 'testGroup',
  -- optional: valid modes are "earliest-offset", "latest-offset", "group-offsets", "specific-offsets" or "timestamp"
'scan.startup.mode' = 'earliest-offset',

   'format' = 'avro'
);


SELECT * FROM MyUserTable;
{code}



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