value of tempMap is some values it retrieves from the database, I was able to resolve this by getting the ServletContext using the ServletRe
Abiodun Adisa
Ranch Hand
Joined: Jan 17, 2002
Posts: 495
posted
0
Originally posted by Abiodun Adisa: value of tempMap is some values it retrieves from the database, I was able to resolve this by getting the ServletContext using the ServletRe
value of tempMap is some values it retrieves from the database, I was able to resolve this by getting the ServletContext using the ServletRequest of the filter
Ulf Dittmer
Marshal
Joined: Mar 22, 2005
Posts: 35230
7
posted
0
The difference is of course that now you're doing this every time the filter is called, instead of once at filter startup. Is that what you want/need to do?
You can get an instance of ServletContext by calling getServletContext() on the FilterConfig object that's passed to the init method.
Originally posted by Ulf Dittmer: The difference is of course that now you're doing this every time the filter is called, instead of once at filter startup. Is that what you want/need to do?
You can get an instance of ServletContext by calling getServletContext() on the FilterConfig object that's passed to the init method.
Thanks for your reply, I think i would want to do this once, please how do i obtain the ServletContext in the init method
Originally posted by Abiodun Adisa: Thanks for your reply, I think i would want to do this once, please how do i obtain the ServletContext in the init method