• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 542
  • Last Modified:

Is it a good practice to place all static files out of a WAR/EAR file?

0
 
down vote
favorite  For all my business applications, I place my css files, images, javascript (jquery, plugins, functions JS files, etc.) within my project.

I am using jBoss as my application server, fronted by an Apache server and mod_jk (using the AJP protocol). By looking at the jBoss tomcat status page, I am seeing a lot of current threads on stuffs like JS files, css files, etc... So, my thought is that if these static files were hosted somewhere else, it would not have to be managed by jBoss, resulting in less work required by jBoss.

The reason why I am concerned by that is that my application has a lot of concurrent connections, and sometimes it hits the maximum number of current threads (250). Before adding new jBoss instances to the load balancing mechanism, I want to make sure my application is properly set up in its structure.

Am I wrong? What is the best practice for building web business application?

Thank you!
0
SolutionsTI
Asked:
SolutionsTI
  • 2
  • 2
2 Solutions
 
ValeriCommented:
0
 
CEHJCommented:
Is it a good practice to place all static files out of a WAR/EAR file?
Simple answer is yes - that's what Apache is optimised for so they should be served by it where possible. It must be said though that unless the client is badly constructed, that type of content should be cached client-side anyway
0
 
SolutionsTIAuthor Commented:
Is there any efficient or standard way to "cache" these things on the client-side?

Thanks
0
 
CEHJCommented:
That, as i said, should really happen automatically. e.g. you should see that if you examine your browser cache
0
 
SolutionsTIAuthor Commented:
Okay, I thought you were recommending a third party caching way.

Thank you guys
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now