What do you like most with ant
Memory leaks are caused by writting poor program design where Object reference are long lived and the garbage collector is unable to reclaim those objects..
I guess the best thing about ANT is that it's easier to learn and works cross platform and cross programming language - which is a real bonus.
Explain servlet and JSP life cycle
A Servlet is a Java class which faclitates a web developer to write dynemic web pages. JSP is the presentation componant that used with Servlets to make a page dynamic. Generally a JSP is a HTML docum...
Life cycles are pretty same, as the JSP will be translated into a servlet during the translation phase, the important point to be considered here is if we include another JSP by making use o...
Editorial / Best Answer
Answered by: Faisal Ghauri
Answered On : Jul 24th, 2005Performance does take a hit when using synchronization. I think the way to reduce this hit is to synchronize only a block of code that will be accessed by threads and not synchronize the entire method.
There is degradation in performance when you make a method synchronized. Even when a program contains only a single thread running on a single processor, a synchronized method call is still slow...
The Synchronization may be useful in avoiding the deadlock, helpful in maintaining the consistent object state etc,. Only one thread will be accessed at a time by acquiring lock on the synchronized bl...