Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Junilu Lacar
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Knute Snortum
  • Tim Cooke
  • Devaka Cooray
Saloon Keepers:
  • Ron McLeod
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Ganesh Patekar

Struts 1.x configurations doubt

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi every one...

Iam using struts 1.3 based web application and have more than 20 action classes(all belongs to same module) configured in the struts-config.xml.

My doubt is whether all of these action classes get loaded by the ActionServlet when it reads struts-config.xml file on server start up.

I've tried with one sample application having 3 action classes with static blocks. I observed each action class get loaded only when it requested for.

Is my observation correct?
Also please suggest me any website to understand struts internals a little deeper.


Thanks.
 
Bartender
Posts: 9584
13
Mac OS X Linux Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the JavaRanch. If you can at all help it, do not use Struts 1. See here for why.
If you must use Struts 1, there is a discussion of the loading of actions here
 
Tayyeb Ahmad
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Joe,
That means, Struts follows lazy loading and each action class will get loaded only when it is requested for.

Correct me, if i am getting wrong.
 
No, tomorrow we rule the world! With this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!