Murtuza Akhtari

Ranch Hand
+ Follow
since Aug 07, 2004
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Murtuza Akhtari

I thought the case sensitivity worked only for the first letter. I guess I was wrong.
I had a attribute called "qAError" with its appropriate getter/setter viz getQAError() and setQAError()

However i kept getting the same error: No getter blah blah blah
Then I just changed my attribute name to "qaError"
Now my getter/setter looked like getQaError() and setQaError()
Everything seems to be working fine now !!!

forget the first letter....it also wants proper case for the second letter

Rule of thumb: define attributes with 1st 2(atleast) letters lower-case.
19 years ago
When you placed your log4j.jar in the MyEJBProject, did you try to use the logging in any classes outside the MyEJBProject, like for eg. in any servlet/filter/class residing in the MyWEBProject??

as long as you have ur log4j.jar in any project , u can use logging only within that project. If you want application level use of a particular jar, then you have to place it in the EAR

HTH
[ December 17, 2004: Message edited by: Murtuza Akhtari ]
19 years ago
Is there any way to access the WasReqURL cookie while using the form based login??

I want to put a default URL in tht cookie in case the user book-marks the login page.

So if the WasReqURL is null (meaning the user directly requests the login page) then we set a default URL in WasReqURL

Is there any way to do this???
19 years ago
Hi all,

I am using Struts validation. I have also enabled client side validations using JavaScript.

How-ever whn I perform validations, I get a javascript alert with

???en_US.errors.required???

which probably means tht my message resources are not being loaded properly. I have defined the default errors in the ApplicationResources.properties

and in the struts-config.xm, I invoke the message resources like so


Can somebody help me figure out wht I m doing wrong here???
Or can you tell me how to properly configure the message resources?
hey Shreeya,

Can we do something like that using Logger class since Category is deprecated in the version tht i m using (log4j-1.2.8)

Thanks,
I found that if i move my wrapper class to the WEBProject then the logging works for the classes/servlets in the WEBProject. I cannot import any classes from the WEBProject to my JAVAProject since the dependency hierarchy is not defined that way.

my JAVAProject cannot have any dependency on the EJB and WEB projects and anyway my Log-Wrapper should technically be in the JAVAProject. What would be the work-around? How should I put my classes/log4j.properties file/log4jjar file so that everything works fine?

Please Help !!
Hi all,

I have created a wrapper class for the log4j, so that my application remains oblivious of the logging API (which might change in the future for us).
My project structure is as such:
EJBProject -- ejb stuff
WEBProject -- web stuff
JAVAProject-- all other java classes.

I wanna implement logging across all of them. For this, I have copied the log4j.1.2.8.jar file into the WEB-INF/lib and I have the log4j.properties in the WEBProject/Java Source folder. My wrapper class is in JAVAProject.

Extra Questions : 1)What is the proper way to create dependencies in such a scenario?
2)Where would I put my log4j.properties file and the log4j1.2.8.jar file so that all projects can have access to it?
Currently I have added the log4j1.2.8.jar file in the JAVAProject's Libraries too.
When I execute my filter it gives me the following error :

Why would it even look for Category?? I thought that class was deprecated and replaced by Logger. BTW line no 34 where the error occurs in my filter is this


Please help