Skip to content

Error in doc on JCA CCI - ConnectionSpecConnectionFactoryAdapter [SPR-9466] #14101

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

Closed
spring-projects-issues opened this issue Jun 4, 2012 · 0 comments
Assignees
Labels
status: backported An issue that has been backported to maintenance branches type: documentation A documentation task
Milestone

Comments

@spring-projects-issues
Copy link
Collaborator

Sylvain LAURENT opened SPR-9466 and commented

In the documentation, in chapter about JCA CCI, section "Configuring CCI connections", when explaining ConnectionSpecConnectionFactoryAdapter it is said that

If the adapter's connectionSpec property is specified, the adapter uses the getConnection variant without argument, else the one with the ConnectionSpec argument.

I think that's erroneous : when the connectionSpec is specified the adapter uses the javax.resource.cci.ConnectionFactory.getConnection(ConnectionSpec) method else it uses javax.resource.cci.ConnectionFactory.getConnection()

That seems to be the behavior of the method org.springframework.jca.cci.connection.ConnectionSpecConnectionFactoryAdapter.doGetConnection(ConnectionSpec) :

protected Connection doGetConnection(ConnectionSpec spec) throws ResourceException {
     if (getTargetConnectionFactory() == null) {
          throw new IllegalStateException("targetConnectionFactory is required");
     }
     if (spec != null) {
          return getTargetConnectionFactory().getConnection(spec);
     }
     else {
          return getTargetConnectionFactory().getConnection();
     }
}

please fix this sentence in the doc.


Affects: 3.0.7, 3.1.1

Backported to: 3.1.4

@spring-projects-issues spring-projects-issues added status: backported An issue that has been backported to maintenance branches type: documentation A documentation task labels Jan 11, 2019
@spring-projects-issues spring-projects-issues added this to the 3.2.1 milestone Jan 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: backported An issue that has been backported to maintenance branches type: documentation A documentation task
Projects
None yet
Development

No branches or pull requests

2 participants