简体   繁体   中英

Java EE 6 WAR packaging for pure server application?

I currently set up a Java EE project for a new business application using CDI. The application is a pure server application (using jms, webservices and such, but has no frontend).

Since we are using Java EE 6, I would like to use the new WAR packaging instead of the former EAR, which seems to be a simpler packaging mechanism to me and was recommended to use if one has no special modularization needs.

My problem in understanding is now, that I am still thinking of a WAR as a web application. How is the project layout in my case, do I still have for example a WEB-INF folder even though I don't have any frontend and there's no need to publish the application under a context? Or is there a better way to structure a pure server application?

The 'new WAR' has the same layout as the 'old WAR', the only difference is that the EJB JAR(s) can now be placed inside the WEB-INF/lib folder of the WAR. In the 'old WAR' you could not place EJBs inside the WAR.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM