You are viewing a plain text version of this content. The canonical link for it is here.
Posted to apps-dev@avalon.apache.org by Paul Hammant <Pa...@yahoo.com> on 2002/05/04 10:19:06 UTC
Apps developers - separation of interface and impl
Folks,
Even though we cannot separate them yet inside phoenix, could teams try
to put their blocks/interfaces/support classes in one jar and their
implementation in another jar. This will also mean that different
packages are required :
thing.ThingBlock -> goes to thing-api.jar
think.refimpl.DefaultThingBlock - > goes to thing-ri.jar
It is not mandatory, just hoped for...
Cheers,
- Paul
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Apps developers - separation of interface and impl
Posted by Jeff Turner <je...@socialchange.net.au>.
On Sat, May 04, 2002 at 09:19:06AM +0100, Paul Hammant wrote:
> Folks,
>
> Even though we cannot separate them yet inside phoenix, could teams try
> to put their blocks/interfaces/support classes in one jar and their
> implementation in another jar. This will also mean that different
> packages are required :
>
> thing.ThingBlock -> goes to thing-api.jar
> think.refimpl.DefaultThingBlock - > goes to thing-ri.jar
>
> It is not mandatory, just hoped for...
It also prevents circular dependencies. Eg, if A and B depend on each
other's public APIs, then we can compile them as follows:
a-interface.jar
b-interface.jar
a-impl.jar
b-impl.jar
Not possible if API and implementation are in one jar.
--Jeff
> Cheers,
>
> - Paul
>
>
> --
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Apps developers - separation of interface and impl
Posted by Paul Hammant <Pa...@yahoo.com>.
Stephen,
> Looks to me that you are beingh shot down not on the grounds of
> seperate jar files - but on the grounds on the introduction of seperation
> at the level of package names. Why do you need different package names
> anyway?
1) package sealing.
2) implementation hiding : ye olde K/HC/CAPI :-
CAPI-Impl HostedComp1 HostedComp2
| | |
--------------------------
|
Client API
|
Kernel
As is with servlet (a standard for class visibility defined by sun)....
Container.jar App1.war App2.war
| | |
---------------------------
|
servlet.jar
|
ContianerBootStrap.jar + rt.jar
The point is that the K/HC/CAPI "pattern" exists in may places. Sun
defined an example with the servlet spec. With Phoenix we see multiple
K/HC/CAPIs in one tree of classloaders (in itself an advanced Java topic).
e.g. Phoenix mounts a SAR file that is a web server. It mounts a web
app. That is two K/HC/CAPI separtions in one JVM. With JAMES (and
Mailets), FtpServer (and Ftplets) and EOB (with beans) there could be
many more in one JVM.
-ph
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Apps developers - separation of interface and impl
Posted by Stephen McConnell <mc...@osm.net>.
Paul:
Looks to me that you are beingh shot down not on the grounds of
seperate jar files - but on the grounds on the introduction of seperation
at the level of package names. Why do you need different package names
anyway?
Cheers, Steve.
Paul Hammant wrote:
> Leo, Jeff,
>
>>> It is not mandatory, just hoped for...
>>>
>>
>>
>> If I get my way, it will be mandatory wherever possible, in time...
>>
>> I have yet to see a single argument _against_ separation if interface
>> and impl. This is not to start a discussion BTW. If there is one, please
>> update the xdocs =)
>>
>
> Me too, but I was shot down in Tomcat...
>
> http://w6.metronet.com/~wjm/tomcat/2001/Oct/msg00615.html (and
> other threads in Jan).
>
> - Paul
>
>
>
>
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Apps developers - separation of interface and impl
Posted by Paul Hammant <Pa...@yahoo.com>.
Leo, Jeff,
>>It is not mandatory, just hoped for...
>>
>>
>
>If I get my way, it will be mandatory wherever possible, in time...
>
>I have yet to see a single argument _against_ separation if interface
>and impl. This is not to start a discussion BTW. If there is one, please
>update the xdocs =)
>
Me too, but I was shot down in Tomcat...
http://w6.metronet.com/~wjm/tomcat/2001/Oct/msg00615.html (and other
threads in Jan).
- Paul
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Apps developers - separation of interface and impl
Posted by Leo Simons <le...@apache.org>.
> Even though we cannot separate them yet inside phoenix, could teams try
> to put their blocks/interfaces/support classes in one jar and their
> implementation in another jar. This will also mean that different
> packages are required :
>
> thing.ThingBlock -> goes to thing-api.jar
> think.refimpl.DefaultThingBlock - > goes to thing-ri.jar
>
> It is not mandatory, just hoped for...
If I get my way, it will be mandatory wherever possible, in time...
I have yet to see a single argument _against_ separation if interface
and impl. This is not to start a discussion BTW. If there is one, please
update the xdocs =)
- Leo
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>