DZone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Newsletter
Log In / Join
Refcards Trend Reports
Events Video Library
Refcards
Trend Reports

Events

View Events Video Library

Related

  • Step-By-Step Tutorial: Installing Eclipse IDE
  • Remote Pair Programming with IntelliJ, Eclipse and VS Code
  • Spec-Driven Development Renamed an Old Problem; It Didn't Solve It
  • Amazon CodeWhisperer to Q Developer to Kiro: The Rise of Agentic Coding

Trending

  • The Context Window Trap: Why More Context Doesn’t Mean Better AI
  • Beyond @Transactional: Solving the Dual-Write Problem in Distributed Microservices
  • Going All In On the JVM 25 Virtual Threads
  • The Twelve-Factor Agents: Building Production-Ready LLM Applications

Draft This article hasn't been published, so readers can't see it.

In moderation This article is waiting for review, so readers can't see it yet.

Deleted This article has been deleted, so readers can't see it.

  1. DZone
  2. Software Design and Architecture
  3. Integration
  4. How to Setup Eclipse IDE for Sonar Analysis

How to Setup Eclipse IDE for Sonar Analysis

By 
Ajitesh Kumar
·
Sep. 29, 14 · Tutorial
Post on X (opens in a new tab) Share on LinkedIn (opens in a new tab)
89.6K Views

Join the DZone community Save articles, join the discussion, and download Refcards and Trend Reports with a free account.

Join for free Already a member? Log in

this article describes steps required to configure your eclipse for sonarqube such that developers are not required to leave the eclipse ide to manage their source code quality. please feel free to comment/suggest if i missed to mention one or more important points. also, sorry for the typos.

following are the key points described later in this article:
  • installing & configuraing sonarqube in eclipse
  • analyzing code using sonarqube

installing & configuraing sonarqube in eclipse

follow the steps given on following pages to install and configure sonarqube in your eclipse ide.

  • the page on installing sonarqube in eclipse consists of steps required to install sonarqube in the ide. once downloaded, it would prompt to restart the eclipse ide. for proceeding ahead, you must restart the eclipse ide.
  • the page on configuring sonarqube in eclipse consists of steps required to configure eclipse for sonarqube. the key thing to note is the fact that as you click on preferences > sonarqube > servers , you see the default server entry for http://localhost:9000. initially, as per instruction page, seeing the default entry, i went ahead to next step for linking the project to sonarqube server and run the analysis. however, it throw the error such as unknowb version of sonarqube server . after a little research, i figured out that the error was thrown as the sonarqube server was not reachable although i saw it configured as http://localhost:9000. the solution is to go to preferences > sonarqube > servers , click “edit” button and you would see sonarqube server url, username and password. the key is to give username and password and run the analysis once again.

analyzing code using sonarqube

once you are done with installation and configuration of sonarqube server in eclipse ide, for code analysis, all you need is right click on your project and click sonarqube > analyze and that is it. the violations would appear in sonarqube analysis as shown in the screenshot below.

sonarqube analysis in eclipse

sonarqube analysis in eclipse

however, do note that these issues may not appear if you try to access on the browser. for that to happen, you need to once again run “sonar-runner” from the project root.

Eclipse Integrated development environment

Published at DZone with permission of Ajitesh Kumar. See the original article here.

Opinions expressed by DZone contributors are their own.

Related

  • Step-By-Step Tutorial: Installing Eclipse IDE
  • Remote Pair Programming with IntelliJ, Eclipse and VS Code
  • Spec-Driven Development Renamed an Old Problem; It Didn't Solve It
  • Amazon CodeWhisperer to Q Developer to Kiro: The Rise of Agentic Coding

Partner Resources

×

Comments

Loading comments

The comments didn't load

Please try again in a moment.

Likes

Loading

The next likes didn't load. Please try again.

The likes didn't load

Please try again in a moment.

See who liked this

Log in or join DZone for free to see who liked this article.

Log in Join for free
  • RSS
  • X
  • Facebook

ABOUT US

  • About DZone
  • Support and feedback
  • Community research

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • Become a Contributor
  • Core Program
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 3343 Perimeter Hill Drive
  • Suite 215
  • Nashville, TN 37211
  • [email protected]

Let's be friends:

  • RSS
  • X
  • Facebook