[jboss-dev] How do you split your classes?
Adrian Brock
abrock at redhat.com
Thu Sep 4 06:08:38 EDT 2008
On Thu, 2008-09-04 at 11:47 +0200, Sacha Labourey wrote:
> Team,
>
> I am interesting in better understanding how you take decisions when
> splitting classes between JARs. Let me be more accurate...
>
> Ideally, each macro-service (Tomcat, WS, EJB3, etc.) would have its own
> MyService.sar file/directory in /deploy (or better, /deploy/system/).
Another issue is the splitting out metadata models so we don't have
to deploy the full jar including all the implementation details
in server/[config]/lib, instead the meta model can be included in
whatever.deployer
> This
> SAR would contain all required implementation classes, services definition,
> etc. and would also list its dependencies in one of its jboss-services.xml
> <depends> tags. Then, if for some reasons this service needed to share some
> API classes with other services AND it was using some separate unified
> classloader, it could "pollute" the AS at large by putting these classes in
> the /lib folder of the AS. The outcome of this is that it would be very easy
> to remove a service: simply drop its folder from /deploy and that's it
> (modulo the potential pollution taking place in /lib).
>
> Now, we all know this is NOT how it happens in real-life. Hence, my
> question: WHY? What leads you to do things differently? I'd like to
> understand it better so we can potentially improve things.
>
> It is worth mentioning that this is the pre-AS5 situation. With AS5 and its
> new classloaders à la OSGI, it is going to be possible to put EVERYTHING in
> specific directories in /deploy thanks to the import/export features Adrian
> has implemented. Consequently, outside of core services (specific deployers
> or any bootstrap code à la VFS, etc.), no JAR should be needed in /lib.
>
> Thanks for your feedback. Cheers,
>
>
>
> sacha
>
>
> _______________________________________________
> jboss-development mailing list
> jboss-development at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/jboss-development
--
xxxxxxxxxxxxxxxxxxxxxxxxxxxx
Adrian Brock
Chief Scientist
JBoss, a division of Red Hat
xxxxxxxxxxxxxxxxxxxxxxxxxxxx
More information about the jboss-development
mailing list