kafka-jira mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (KAFKA-5953) Connect classloader isolation may be broken for JDBC drivers
Date Thu, 05 Oct 2017 21:26:00 GMT

    [ https://issues.apache.org/jira/browse/KAFKA-5953?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16193739#comment-16193739

ASF GitHub Bot commented on KAFKA-5953:

GitHub user kkonstantine opened a pull request:


    KAFKA-5953: Register all jdbc drivers available in plugin and class paths


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

    $ git pull https://github.com/kkonstantine/kafka KAFKA-5953-Connect-classloader-isolation-may-be-broken-for-JDBC-drivers

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


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

    This closes #4030


> Connect classloader isolation may be broken for JDBC drivers
> ------------------------------------------------------------
>                 Key: KAFKA-5953
>                 URL: https://issues.apache.org/jira/browse/KAFKA-5953
>             Project: Kafka
>          Issue Type: Bug
>          Components: KafkaConnect
>    Affects Versions:
>            Reporter: Jiri Pechanec
>            Priority: Critical
> Let's suppose there are two connectors deployed
> # using JDBC driver (Debezium MySQL connector)
> # using PostgreSQL JDBC driver (JDBC sink).
> Connector 1 is started first - it executes a statement
> {code:java}
> Connection conn = DriverManager.getConnection(url, props);
> {code}
> As a result a {{DriverManager}} calls {{ServiceLoader}} and searches for all JDBC drivers.
The postgres driver from connector 2) is found associated with classloader from connector
> Connector 2 is started after that - it executes a statement
> {code:java}
> connection = DriverManager.getConnection(url, username, password);
> {code}
> DriverManager finds the connector that was loaded in step before but becuase the classloader
is different - now we use classloader 2) so it refuses to load the class and no JDBC driver
is found.

This message was sent by Atlassian JIRA

View raw message