Publishing Sonar analysis on SonarQube Dashboard - java

We have Eclipse Java EE IDE for Web Developers.
Version: Luna Release (4.4.0)
Build id: 20140612-0600
I have installed SonarQube Plugin in my eclipse and have configured the SonarQube Server. Tested the Server connection in Eclipse.
Windows>Preferences>Sonar>Servers. Connection is successful.
I am able to associate my project to Sonar in eclipse and get the report locally.
After fixing the violated issues , Is there a way we can publish the new report from our Local to the SonarQbe server dashboard.?

First, you appear to be using an old version of the plugin; the most recent version of SonarLint for Eclipse has not yet re-established the connected experience (although that's coming soon). You may be interested in upgrading because SonarLint checks your code as you work; there's no longer a need to trigger the analysis. This way, issues are brought to your attention immediately instead of your having to remember to look for them.
Now to your question: there is not a way to push your updated results from Eclipse directly into the SonarQube platform; you'll need to perform a full analysis. Keep in mind that in-IDE analysis runs most but not all rules. I.e. you're not going to get issues in Eclipse from the rule about too-low coverage thresholds, for instance. Ditto duplicatons. Those are only run as part of the full analysis.

Related

Gradle sync fail for a Grails project in IntelliJ IDEA

I'm using IntelliJ IDEA 2017.3 and having trouble with a basic project in Grails in it - when Gradle starts syncing the project after starting up the IDE, all the checkmarks are green and labeled as "OK", my Messages tab is empty but still I get an alert on top of the editing pane reading "Gradle project sync failed. Basic functionality (e.g. editting, debugging) will not work properly".
I've tried removing the .gradle folder, the Restart and Invalidate option, giving IntelliJ a local path to Gradle as opposed to just telling it to use the default - all to no avail. I'm behind a corporate proxy but it is set up in IntelliJ so it shouldn't be blocking anything (especially since all the syncing seems to be working just fine).
What could be the problem? Versions of my stack:
Grails Version: 3.3.8
Groovy Version: 2.4.15
JVM Version: 1.8.0_181
Gradle Version: 3.5
I've tried ensuring that proxy's not the problem according to #dkb suggestion but it does not seem to be malfunctioning - I did Invalidate and Restart again and after running bootRun, Gradle correctly downloaded Apache Ant to run the application so it doesn't seem likely to be the culprit here.
IntelliJ also kept nagging me for Android SDK (who knows why but OK) which I could not install "normally" in the corporate setting but in the end I did provide it through IDEA's Settings -> System Settings -> Android SDK -> Edit and downloading some arbitrary API and the SDK tools through there so it shouldn't be the problem either (or at least I presume it shouldn't).
In line with #y.bedrov's suggestion, I am attaching the log after reproducing the issue (external link cause it exceeds SO's post character limits).

SonarQube won't find every rule violations

I'm using SonarQube 6.3.1 with default profile Sonar way. I have the newest SonarJava plugin installed (4.8.0.9441).
I can see that the rule SQL binding mechanisms should be used is activated.
I have installed SonarLint 2.9.0 plugin for Intellij and connected to running SonarQube server.
After copying example violation from Sonar page I can see in my IDE that plugin works fine. Everything seemed perfect up to this moment.
Unfortunately, analysis on SonarQube server doesn't find this vulnerability. The same goes for another owasp-a6 rule Cookies should be secure (also found by Sonarlint). But on the other hand, some owasp rules work (i.e. Console logging should not be used).
Is this a known Sonar issue that some rules are omitted? Exclusions are not a problem, I'm pretty sure that those files are being analyzed because some other issues have been found.

Sonarqube difference between sonar way profile and sonarqube java rules repository

What is the difference between the Sonarqube java plugin repository under rules>repository> Sonarqube Java rules and the default profile Sonar way under quality profiles. The first one has 322 rules, while the second one has 229. What is missing from the Sonar way profile? I am using Sonarqube 5.2 server.
First, the version of your Java Plugin is more relevant than the version of your SonarQube server. The server ships with a copy of the Java plugin, but the two are versioned independently, and it can never be assumed that you're running the version of the plugin that ships with the server.
To answer your question, the Sonar Way profiles are designed to be absolutely non-controversial out of the box. So rules about what line '{' should be on, for instance, aren't included. There are also rules that are desirable only in certain coding situations. For instance, not everyone is going to be interested in the proper use of Struts, so those get left off too.

Windows Service starting Java not working since Java Upgrade to 8

We've updated our buildserver (Atlassian Bamboo) to Java 8 (JDK).
Since then our integrationtests are failing because our started product does not open any port.
We are building with maven and as part of the integrationtest we are starting our builded product. Our product is a Rest-Api based in an OSGI (equinox) and Jetty.
I tried a lot of things, but nothing helped me to get the product start properly in the maven build.
When I log in on my remote machine and start the product manually everything works fine.
Some more information:
Our buildserver runs as a windows service and our product is written in plain Java.
Presumably you are affected by one or more of the issues discussed in Custom AMIs will not start anymore in Bamboo Cloud (BAM-16291), notably that Bamboo is not compatible with JDK8u60 yet:
Joda-time, one of the libraries used by Bamboo is not compatible with
8u60. We've fixed this problem, but the fix has not been rolled out
yet. Known breakages include S3 interaction and CodeDeploy plugin.
Most/All participants got things working again by downgrading to JDK8u45, as also recommended in Atlassian's most recent update:
Use JDK 8u45. The latest JDKs are incompatible with some 3rd party libraries we're using.
Try to match the layout and scripts of our stock images as closely as possible. This will make it easier for us to provide help if
anything goes wrong.
Choose Oracle if you have the choice between Oracle and OpenJDK flavor of JDK.

Error message while trying to install the mase plugin in eclipse

I installed agent tool3 on my eclipse and proceeds to install the MASE plug in for analysis and design. I really need the plug in for a design and analysis but unfortunately, after the installation of the agent tool3 the next step towards installing the MASE pugin I got this error message below.
Plug-in org.eclipse.epf.authoring.ui was unable to load class org.eclipse.epf.authoring.ui.views.LibraryView.
I have done everything within my knowledge but cant seem to get a solution. below are pictures of the errors
Most likely you have this class loading errors because agentTool III and MaSE are for Eclipse 3.4 (Ganymede). Usually eclipse tools have open range for dependencies to prevent blocking users from installing it into newer Eclipse release. It works sometimes, if tools do not use restricted/none public API which tends to have many changes between major Eclipse releases.
I cannot see details on your screenshots but it feels like some classes were removed/refactored in Eclipse Mars since Ganymede release.

Categories

Resources