Stop eclipse formatter putting all enums in one line

While working with eclipse you would have experienced that if one tries to put enums on different lines and by chance someone formats the code using eclipse formatter( ctrl+shift+f), all the manual formatting is removed. Of course you can undo it. But what if someone else working on your code removes your manual formatting and adds … Read more

Remote debugging of tomcat using eclipse

If you are running tomcat on a remote machine and you want to debug the application running on the remote tomcat using eclipse on your local machine then this is the guide for you. Tomcat remote debug Configure tomcat The first step would be to add the following properties to the setenv.sh in the tomcat/bin/ … Read more

SEVERE: The web application [/mywar] created a ThreadLocal with key of type [java.lang.ThreadLocal] (value [java.lang.ThreadLocal@75af844e]) and a value of type [com.sun.xml.messaging.saaj.util.transform.EfficientStreamingTransformer] (value [com.sun.xml.messaging.saaj.util.transform.EfficientStreamingTransformer@5617593e]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak.

I have been debugging this issue using jvisiualvm and eclipse MAT. I had the below error when I was undeploying the war file. And after 10 deployments the tomcat was running out of memory After doing some research i found that this issue existed with the version 1.3 of saaj-impl https://java.net/jira/si/jira.issueviews:issue-html/SAAJ-46/SAAJ-46.html Since I use maven … Read more

Eclipse Tips

Here are eclipse tips and tricks that I find useful in everyday use of eclipse. Eclipse shortcuts: Shortcuts I use everyday Ctrl+1 seems to be the most useful shortcut of eclipse. It shows the quick help. e.g. create getter and setter on a property or rename a property. If you see an error or warning … Read more