Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

druid 对了hive jdbc 不支持 conn.getHoldability() 兼容处理问题 #1386

Open
maxid opened this issue Aug 25, 2016 · 1 comment
Open

Comments

@maxid
Copy link

maxid commented Aug 25, 2016

DruidConnectionHolder.java (v1.0.20)中,对getHoldability兼容处进只配置了sybase和db2

    {
        boolean initUnderlyHoldability = !holdabilityUnsupported;
        if (JdbcConstants.SYBASE.equals(dataSource.getDbType()) //
            || JdbcConstants.DB2.equals(dataSource.getDbType()) //
        ) {
            initUnderlyHoldability = false;
        }
        if (initUnderlyHoldability) {
            try {
                this.underlyingHoldability = conn.getHoldability();
            } catch (UnsupportedOperationException e) {
                holdabilityUnsupported = true;
                LOG.warn("getHoldability unsupported", e);
            } catch (SQLFeatureNotSupportedException e) {
                holdabilityUnsupported = true;
                LOG.warn("getHoldability unsupported", e);
            } catch (SQLException e) {
                // bug fixed for hive jdbc-driver
                if ("Method not supported".equals(e.getMessage())) {
                    holdabilityUnsupported = true;
                }
                LOG.warn("getHoldability error", e);
            }
        }
    }
@Danier-Evens
Copy link

您好,问下这个bug 版本什么时候发。因为看了下最新版还是只配置了sybase和db2
https://github.com/alibaba/druid/blob/1.0.25/src/main/java/com/alibaba/druid/pool/DruidConnectionHolder.java

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants