• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Code quality plugins in eclipse

 
Navneet Sharma
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Friends,

I write lot of java code everyday. Sometime in hurry I forget to close the resources (connection,file,etc,) in JAVA6 and this causes memory leak issues. I am looking for an eclipse plugin which can complain for these minor mistakes. Also I am looking for some more eclipse plugins which can improve my source code quality like naming conventions, code redundancy, complexity, too long code outside methods, etc,.

I found some plugins on google itself like FINDBUGS, CHECKSTYLE, PMD, etc,.

Please suggest me a best plugin which can perform all above mentioned activities. Also please post the URL to watch that plugin demo.

Thanks in advance !!

 
soundar rajan
Greenhorn
Posts: 16
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please try to use SONAR, this is one of the tool we can integrate with our normal build tool. It will be providing all connection file related issues and recommendations.
 
Luan Cestari
Ranch Hand
Posts: 163
C++ Redhat Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I agree, Sonar is the best tool for static code analysis. But some friend also consider a bit hard to setup it with their project and prefer plugins. I would recommend the following plugins:

http://findbugs.sourceforge.net/
http://pmd.sourceforge.net/
http://eclipse-cs.sourceforge.net/
http://en.wikipedia.org/wiki/Java_Code_Coverage_Tools
http://stackoverflow.com/questions/4080/what-code-analysis-tools-do-you-use-for-your-java-projects
http://marketplace.eclipse.org/search/site/Source%2520Code%2520Analyzer
 
Muhammad Khojaye
Ranch Hand
Posts: 449
IntelliJ IDE Java Scala
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sonar runs Findbugs, PMD and CheckStyle internally as well and shows graphs using these aggregate data. Moreover, one can easily integrate Sonar with CI servers like Jenkins and TeamCity to view these reports.
 
Winston Gutkowski
Bartender
Pie
Posts: 10102
56
Eclipse IDE Hibernate Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Navneet Sharma wrote:I write lot of java code everyday. Sometime in hurry I forget to close the resources (connection,file,etc,) in JAVA6 and this causes memory leak issues. I am looking for an eclipse plugin which can complain for these minor mistakes.

That statement is a contradiction. If these "minor mistakes" cause problems, then plainly they aren't "minor", are they?

The best way to stop problems, as any QA zealot will tell you, is prevention, not control.

Code checkers - even good ones - may be able to stop some problems, but they won't stop them all; and they certainly won't make you a better programmer. And my worry is that it will become a crutch.

So, my advice: Slow down, and stop making these mistakes. You must have heard about the Tortoise and the Hare; well, programming is thought, not code.

My two-penn'orth.

Winston
 
Niraj Jha
Ranch Hand
Posts: 63
Java Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Before writing error prone code first get some knowledge about how to write a good piece of code.You can discuss with QA people or follow some check list or get reviewed the code with senior.Make this thing a habit.

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic