Red Hat Bugzilla – Bug 848779
RFE: Reduce the size of the server remote client jar
Last modified: 2012-08-16 07:58:12 EDT
Description of problem:
Currently our server client jar only excludes the EJB bean implementations but leaves the numerous other classes in the jar that do not belong there (like the local interfaces, various support classes etc). We should look at removing those classes from the client jar to reduce its size (which is currently over 1.2MB).
I believe that 99% of our remote API uses only basic java types or our domain objects (that live in a separate jar) and so our server client jar could theoretically only contain the remote EJB interfaces which should represent a decrease in the JAR size on a order of at least a magnitude (instead of 940 classes there should remain only 35).
The risk is of course that we would introduce some runtime linkage errors if we excluded some classes that are otherwise required by the remote ifaces.
The more complex solution is to break out the remote interfaces into their own maven module. This would both reduce the size and prevent the linkage errors but requires slightly more drastic changes to the build.