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
Over 2 million developers have joined DZone.
Log In / Join
Refcards Trend Reports Events Over 2 million developers have joined DZone. Join Today! Thanks for visiting DZone today,
Edit Profile Manage Email Subscriptions Moderation Admin Console How to Post to DZone Article Submission Guidelines
View Profile
Sign Out
Refcards
Trend Reports
Events
Zones
Culture and Methodologies Agile Career Development Methodologies Team Management
Data Engineering AI/ML Big Data Data Databases IoT
Software Design and Architecture Cloud Architecture Containers Integration Microservices Performance Security
Coding Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
Partner Zones AWS Cloud
by AWS Developer Relations
Culture and Methodologies
Agile Career Development Methodologies Team Management
Data Engineering
AI/ML Big Data Data Databases IoT
Software Design and Architecture
Cloud Architecture Containers Integration Microservices Performance Security
Coding
Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance
Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
Partner Zones
AWS Cloud
by AWS Developer Relations
  1. DZone
  2. Testing, Deployment, and Maintenance
  3. Deployment
  4. Sonar and QAPlug integration

Sonar and QAPlug integration

Lukasz Chudy user avatar by
Lukasz Chudy
·
Sep. 22, 11 · Interview
Like (0)
Save
Tweet
Share
11.04K Views

Join the DZone community and get the full member experience.

Join For Free

Have you ever think about using coding rules configured in the Sonar in the real-time analysis? Now, it is possible. It's really quick and easy. Just import the permalinks from the Sonar into the QAPlug.


The Sonar is an open source quality management platform, dedicated to continuously analyze and measure source code quality. It has several tools which allow to analyze code using the most popular coding rules like: Checkstyle, Findbugs and PMD. The Sonar violations utility provides a deep and extended code analysis and also gives the user a possibility to modify every checking rule. It is designed to scan the code of the project every time when it is rebuilded to keep user informed about the code condition. According to this characteristic, Sonar should be perceived more as a post diagnostic tool. It doesn't allow to check the code quality during the code development. So, what can you do when there is a need to scan code on-the-fly in the real-time mode?

The simpliest way is to use the QAPlug.

The QAPlug is a free and fully integrated Intellij IDEA plugin which helps to manage the code quality. It is really intuitive and user friendly tool, in which most of the operations can be performed with just a few mouse clicks. The plugin allows user to select a different code quality tools such as PMD, Checkstyle and Findbugs and offers extended scan reports. Moreover, it also gives the user a possibility to configure almost everything, from coding rules to exporting analysis profiles. But the most important feature of that plugin is the QAPlug Real-Time Analysis tool which allows the user to check the code quality in the real-time mode.

But what about the situation when you store a lot of customized coding rules in Sonar and want to use them in on-the-fly checks?

As it was mentioned before, QAPlug is fully configurable, so it also allows to define coding rules through an import from Sonar. By doing this, it is possible to activate the Sonar rules in the QAPlug Real-Time Analysis tool and check the written code on-the-fly. Real-time analysis marks the inappropriate lines of code and after placing mouse cursor on the highlighted line, it also shows the bug description.


QAPlug Real-Time Analysis tool.

Importing the Sonar rules into the QAPlug is very simple. All customized coding settings can be exported from Sonar using permalinks functionality.


Permalinks in Sonar.
  

It means that there is no need to perform any complicated file export operations. Just right-click on the permalink and save it as an .xml file. After that, simply open the IntelliJ IDEA, go to the QAPlug settings and import .xml file to an existing or a new profile.

To see detailed instruction of how to import the Sonar rules into the QAPlug, go to this tutorial on the QAPlug website: Integrating Sonar with QAPlug

So, give your code a chance to be in the top league of quality and scan the code all the time using the Sonar rules in the QAPlug Real-Time Analysis tool!

For more information about QAPlug features please look at its website: qaplug.com

intellij Integration

Opinions expressed by DZone contributors are their own.

Popular on DZone

  • Chaos Engineering Tutorial: Comprehensive Guide With Best Practices
  • Multi-Tenant Architecture for a SaaS Application on AWS
  • Integrate AWS Secrets Manager in Spring Boot Application
  • Create CloudWatch Custom Log Metric Alarm Notification Email Solution Using Terraform

Comments

Partner Resources

X

ABOUT US

  • About DZone
  • Send feedback
  • Careers
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

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

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 600 Park Offices Drive
  • Suite 300
  • Durham, NC 27709
  • support@dzone.com
  • +1 (919) 678-0300

Let's be friends: