• Post Reply Bookmark Topic Watch Topic
  • New Topic

running JSPs during application server startup

 
Jai Sund
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
We're creating an appication using JSP.
Making tag library calls (from a packaged application) is significantly degrading the performance of my application. I tried storing all the data I need (which is about 2 HashMaps worth) in a session scope variable.
However, performance still seems be very unacceptable. I want to store my variables in 'application' scope. How do I use WebLogic6.1 to run my JSP page to do my initialization?
Thanks,
-Jai
 
Sateesh Kumar K
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
You can place any object in the Application scope by using the following syntax of jsp:useBean tag..
<jsp:useBean id="myObj" scope="application" class="com.mycomp.myapp.MyClassName"/>
-Sateesh
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65516
105
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A JSP is clearly not the place to perform web application initialization. I'd suggest creating a setup servlet and set its load order such that it is the first to load.
Then, set up your servlet context variables in the init() method of that servlet.
hth,
bear
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!