That's strange. Are we talking about the same thing? When you are over an issue and press CMD-F1 to get more details? Because I haven't seen one issue where that doesn't fail, and, yet, if I go to Sonar and look up the REST api by hand, I always get a valid JSON return. For instance, calling printStackTrace, which is squid:S1148, and I go to
Whereas doing CMD-F1 will complain about 401s, like
401 Unauthorized
retrofit.RetrofitError: 401 Unauthorized
at retrofit.RetrofitError.httpError(RetrofitError.java:39)
at retrofit.RestAdapter$RestHandler.invokeRequest(RestAdapter.java:382)
at retrofit.RestAdapter$RestHandler.invoke(RestAdapter.java:240)
at org.intellij.sonar.sonarserver.$Proxy184.show(Unknown Source)
at org.intellij.sonar.sonarserver.SonarServer.getRule(SonarServer.java:200)
at org.intellij.sonar.analysis.IssueDescriptionLinkHandler.getDescription(IssueDescriptionLinkHandler.java:79)
at com.intellij.codeInsight.hint.TooltipLinkHandlerEP.getDescription(TooltipLinkHandlerEP.java:62)
at com.intellij.codeInsight.daemon.impl.DaemonTooltipRendererProvider$MyRenderer.dressDescription(DaemonTooltipRendererProvider.java:145)
at com.intellij.codeInsight.hint.LineTooltipRenderer.show(LineTooltipRenderer.java:75)
at com.intellij.codeInsight.hint.TooltipController.showTooltip(TooltipController.java:139)
at com.intellij.codeInsight.hint.LineTooltipRenderer.a(LineTooltipRenderer.java:208)
at com.intellij.codeInsight.hint.LineTooltipRenderer.access$000(LineTooltipRenderer.java:48)
at com.intellij.codeInsight.hint.LineTooltipRenderer$2.actionPerformed(LineTooltipRenderer.java:126)
at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher$3.performAction(IdeKeyEventDispatcher.java:576)
at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.processAction(IdeKeyEventDispatcher.java:625)
at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.d(IdeKeyEventDispatcher.java:475)
at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.dispatchKeyEvent(IdeKeyEventDispatcher.java:211)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:538)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:382)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
and
401 Unauthorized
retrofit.RetrofitError: 401 Unauthorized
at retrofit.RetrofitError.httpError(RetrofitError.java:39)
at retrofit.RestAdapter$RestHandler.invokeRequest(RestAdapter.java:382)
at retrofit.RestAdapter$RestHandler.invoke(RestAdapter.java:240)
at org.intellij.sonar.sonarserver.$Proxy184.show(Unknown Source)
at org.intellij.sonar.sonarserver.SonarServer.getRule(SonarServer.java:200)
at org.intellij.sonar.analysis.IssueDescriptionLinkHandler.getDescription(IssueDescriptionLinkHandler.java:79)
at com.intellij.codeInsight.hint.TooltipLinkHandlerEP.getDescription(TooltipLinkHandlerEP.java:62)
at com.intellij.codeInsight.daemon.impl.DaemonTooltipRendererProvider$MyRenderer.dressDescription(DaemonTooltipRendererProvider.java:145)
at com.intellij.codeInsight.hint.LineTooltipRenderer.show(LineTooltipRenderer.java:75)
at com.intellij.codeInsight.hint.TooltipController.showTooltip(TooltipController.java:139)
at com.intellij.codeInsight.hint.TooltipController.showTooltip(TooltipController.java:113)
at com.intellij.codeInsight.daemon.impl.DaemonTooltipUtil.showInfoTooltip(DaemonTooltipUtil.java:59)
at com.intellij.codeInsight.daemon.impl.ShowErrorDescriptionHandler.invoke(ShowErrorDescriptionHandler.java:39)
at com.intellij.codeInsight.actions.CodeInsightAction$1$1.run(CodeInsightAction.java:62)
at com.intellij.codeInsight.actions.CodeInsightAction$1.run(CodeInsightAction.java:69)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:124)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:99)
at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:85)
at com.intellij.codeInsight.actions.CodeInsightAction.actionPerformedImpl(CodeInsightAction.java:54)
at com.intellij.codeInsight.actions.CodeInsightAction.actionPerformed(CodeInsightAction.java:40)
at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher$3.performAction(IdeKeyEventDispatcher.java:576)
at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.processAction(IdeKeyEventDispatcher.java:625)
at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.d(IdeKeyEventDispatcher.java:475)
at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.dispatchKeyEvent(IdeKeyEventDispatcher.java:211)
at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:538)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:382)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
Nothing else gives any trouble, and I find it suspicious that this seems to be the only usage of RestAdapter on the code.
Mmmmm, on the other hand, it complains about 401, not 404. Mistyping the path by hand gives me 404, not 401. So maybe the credentials are not being passed to the RestAdapter? It seems you'd need a RequestInterceptor configured to do that, but I don't see anything in the code to handle it.