[ 
https://issues.apache.org/jira/browse/DERBY-2582?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12491122
 ] 

Stan Bradbury commented on DERBY-2582:
--------------------------------------

Being new to issues of API specs and all I don't know.  The words used are 
those of the development lead I spoke to about the topic.  They are using the 
metadata call as described.  I do not recall if the word compliance was used, 
however, I don't want that to detract from the problem presented here.  The 
situation for this developer is as described.  The metadata call is used to 
determine what is supported in code using the datasource.  His comment upon 
finding that the datasource did not implement this JDBC 4 interfaces was: 

 "For non JDBC4.0 providers we expect JDBC3.0 to be returned (or JDBC2.0 
depending on the spec version), otherwise, we would break."

Upon looking at the JSR221 sections cited above this seemed like a reasonable 
use of the call so I raised this issue so others in the community familiar with 
implementing datasources in complex environments could give there assessment of 
whether this might be a problem in other development efforts as well.


> EmbeddedConnectionPoolDataSource does not implement java.sql.Wrapper but 
> reports JDBC 4 compliance when run with JDK 6 
> -----------------------------------------------------------------------------------------------------------------------
>
>                 Key: DERBY-2582
>                 URL: https://issues.apache.org/jira/browse/DERBY-2582
>             Project: Derby
>          Issue Type: Sub-task
>          Components: JDBC
>    Affects Versions: 10.2.2.1
>         Environment: JDK 6
>            Reporter: Stan Bradbury
>
> Software that checks the value returned by the dataseMetadata method 
> getJDBCMajorVersion for JDBC compliance level and, based on the value, takes 
> different paths in the code will fail unexpectedly accessing java.sql.Wrapper 
> when loading EmbeddedConnectionPoolDataSource in a JDK 6 environment.  
> EmbeddedConnectionPoolDataSource reports a compliance level of 4 when loaded 
> in a JDK 6 environment.  It returns JDBC 4 objects but the Datasource itself 
> does NOT satify  the JDBC 4.0 interface Wrapper and so, not being fully 
> compliant, should not report JDBC 4 compliance.  
> JSR 221 does not detail the behavior of the dataseMetadata method 
> getJDBCMajorVersion but the description in Section 6.3, JDBC 4.0 API 
> Compliance, states: "A driver that is compliant with the JDBC 4.0 
> specification must .. Fully implement .. java.sql.Wrapper".  As Dan stated in 
> his comment on DERBY-2488,  
> (http://issues.apache.org/jira/browse/DERBY-2488#action_12485033) 
> EmbeddedConnectionPoolDataSource does not implement Wrapper. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to