Reputation: 628
I'm somewhat new to the java landscape and have some questions about best practices for architecting a web portal. So my question is really is there any advantage to breaking a gigantic war file into smaller war files. The only ones I could come up with:
Modularity: it allows for separate developers to work on separate parts of your site and deploy them separately.
Organization: it's easier to find portions of your site if they aren't in the same code base.
Scalability: This only makes sense to me if you are going to be deploying portions of your site on different web servers. If they are all being deployed to the same front-end servers is there any advantage?
From what I have read, it seems most folks seem to think one big war file is the best way to go: avoid redundancy, one step deployment, etc. So are there reasons to break it up? Maybe anonymous/brochure version of site vs authenticated?
Upvotes: 2
Views: 1091
Reputation: 2417
Few things you need to consider that can highly influence your decision:
Upvotes: 0
Reputation: 2635
If there are separate scalability, security and reliability requirements for certain modules then you can break them up. Ideally your security can be separate if needed.
Upvotes: 1
Reputation: 425023
Operations folk prefer one big .war
, because it means there's just one thing to deploy.
However, if you can comfortably break up your web site into separate .war
s, and honestly deploy and un-deploy them without affecting the other deployed artefacts, and are certain you need this granularity (see YAGNI), then break it up.
Upvotes: 1