Win a copy of Head First Android this week in the Android forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Tim Cooke
  • Junilu Lacar
Sheriffs:
  • Rob Spoor
  • Devaka Cooray
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
  • Tim Holloway
Bartenders:
  • Jj Roberts
  • Al Hobbs
  • Piet Souris

Project Design discussion

 
Ranch Hand
Posts: 817
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I don't know where to put this question as its regarding architecture discussion of my project, its impt thread for me so you can put in forum where it best suits...

These are following component of my project

External GUI (visible to client externally) but invoked from some other external application via link
Internal GUI ( visible to operation team / customer care dept)
Webservices (exposed internally)
some common util Jar files having common logic

I want to package eternal GUI/Internal GUI and webservices as war file along with jar file in one EAR file

I am going to put interceptor which will monitor from which link the request is coming and we will be doing role based security and data is available from siteminder session .
Instead of putting separate ear for each gui and webservicces I opted for one ear to better utilize code and since every thing will be developed simultaneously
by different developer code maintainability will be better

I need the following input :
How realastic it is to package many war file in one EAR ?
can code in war file still access the jar file having common logic put inside EAR file but outside war file ? so it can be shared among GUI and webservices... ?

Thanks
Amit
 
author & internet detective
Posts: 40795
828
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I've moved this to our design forum. (The OCMJEA forum is about Oracle's architecture certification. Which has more constraints than real life architecture/design discussions.

amit taneja wrote:How realastic it is to package many war file in one EAR ?


Very. This is common. It allows you to split up your application logically. It also allows different parts of your application to have different context roots (aka different parts of the URL)

amit taneja wrote:can code in war file still access the jar file having common logic put inside EAR file but outside war file ? so it can be shared among GUI and webservices... ?


Yes. It is common for war files to refer to jar files within the ear.

It sounds like you are on the road to a good design since both your questions are good practices.
 
amit taneja
Ranch Hand
Posts: 817
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for reply appreciate

I read some articles like https://coderanch.com/t/309491/EJB-JEE/java/utility-JAR-EAR-WAR
incomplete discussion on war/jar


which are incomplete discussion .... I would like to get some guidance whatever kind (reference to article/detail explaination)

how we will achieve and established rule to access jar files without any diffuclty ..

I hope some experience folks will help me
 
Jeanne Boyarsky
author & internet detective
Posts: 40795
828
Eclipse IDE VI Editor Java
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If the jar is inside the ear, it is perfectly normal. It is common to put them in a lib directory in the ear.

Also, make sure the web project's manifest points to the jar file.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic