Pros and cons of using a shared library and fully encapsulated EAR

Our team builds and owns the webservices infrastructure. Other teams that actually create web services use our infrastructure for some common features. There are two packaging options for EAR. Option 1 is for all wireframes to be embedded in the EAR. Option 2 is to configure a shared library on the application server and force all applications to use the library. We have the potential to deploy up to 100 EARS that will use this structure. What are some of the pros and cons of this approach in terms of construction, management and development. We use websphere.

+5
source share
5 answers

The main tradeoff is memory consumption and version control.

If you package libraries in an EAR, each application will create its own instances of the class, consuming a certain number of constants (or equivalent), and also taking up a lot of space for static data.

If you store the library in the lib application directory, there will be only one instance of each class. However, this means that each of the applications using this library must use the same version, and (if backward compatibility is not guaranteed) must be updated simultaneously.

, 100 EAR, , , . ( , 64- , ) ( ), EAR.

+8

: EAR, . dynacache websphere, . ( , /, )

" EAR", , , JAR.

+2

EAR. Ad kdgregory , , , ; .

0

, lib/app, WebSphere. , msnsging.

, , , .

, , EAR. , Java EE. .

Keys Botzum .

0

() , : , EAR , EAR.

, , , EAR . Log4J. Log4J . , Log4J EAR, , Log4J JAR EAR. Log4J JAR , EAR, ( ) , , Log4J.

0

All Articles