[jboss-dev-forums] [JCA Development] - Re: Design of ConnectionManager API

jesper.pedersen do-not-reply at jboss.com
Mon Oct 5 16:51:05 EDT 2009


The package

  | org.jboss.jca.core.api
  | 
represents the public API for our JCA implementation. Hence it is important that we only expose what we will support over time.

The package will mostly consist of interfaces - as the implementation details should be hidden from the caller.

I think for now that only the

  | org.jboss.jca.core.api.ConnectionManager
  | 
should remain in the package - without any methods defined. Just to define our top-level interface.

E.g. RealConnectionManager should be moved to the implementation package - it currently also creates a dependency on the implementation JAR, which an API JAR can't have. Its all or nothing ;)

Its better to start with the data structures in the implementation and move them out to the API if there are use-cases for it.

A good rule of thumb is to ask:

* Do I want users to call this method ?
* Do I want to expose this attribute as a bean property ?

HTH

View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4258748#4258748

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4258748



More information about the jboss-dev-forums mailing list