ear包目录_EAR包结构

I am creating an EAR with 1 war file (appWeb.war is my web module) and several jar files.

These jar files are NOT EJBs. We have choosen to create different jar files based on logical separation of application like the model.jar (containing all model classes, DAO, DTO and hibernate files), BO.jar (containing business logic)etc...

I wanted to know the correct packaging structure for my EAR

application.ear

.

.

....lib (folder created by us)

.

.

...strus.jar

...spring3.jar (all the spring library files)

...BO.jar

...model.jar

I am adding appWeb.war as the web module to my EAR in the IDE (RAD 7.5)

Which creates the entry in application.ear/META-INF/application.xml

Environment details:

App server: Websphere app server 7.0

IDE: RAD 7.5

It's a Struts 2, Spring 3 and Hibernate 3.6 application

Questions:

1. Is this approach correct? Where does the application specific jar files kept in an EAR?

2. We want to move the library files to application.ear/lib folder.

Any dierctions/help/best practices on this will be appreciated.

thanks

解决方案

The one you've outlined above is one of the choices available. The folder name -- in this case, "lib", is pretty much up to you, as long as you properly reference it from the MANIFEST classpath settings of the WAR file. Personally, I prefer that solution as it keeps you from tinkering with container settings and having your files "scattered" across the container tree. Just my preference, I guess.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值