[prev in list] [next in list] [prev in thread] [next in thread] 

List:       sonar-dev
Subject:    [sonar-dev] RE: [Eclipse plugin] Resource not found with API call
From:       "Schulz, Christian" <Christian.Schulz () astrium ! eads ! net>
Date:       2013-05-24 12:49:07
Message-ID: 43DBE62975E8DB45B539A4B3AAA27C9AB2F024 () ffwexmc2 ! de ! astrium ! corp
[Download RAW message or body]

[Attachment #2 (text/plain)]

Hello,

Okay some more investigation offered more details. I have tested it with
the lastest snapshot and it
Seems that eclipse is using the wrong seperators.
Instead of : it uses /.

api/resources?resource=K4_py%3ABasicComponents%2FDM%2FDataManagement.c&v
erbose=false&
*	Resource [K4_py:BasicComponents/DM/DataManagement.c] not found

So finally no problem of the API that it doesn't perform percent
decoding.

I am using the CDT variant.
I think the multi-module support is missing.
In my opinion the start point would be the
SonarElementsAdapterFactory.getSonarResource/
createSonarResource. Additional we should Introduce the module as
resource type. Furthermore the
ISonarProject have to handle sub modules and so on.


Best Regards,

Christian Schulz
_____________________________________________
From: Schulz, Christian 
Sent: Wednesday, May 22, 2013 6:13 PM
To: user@sonar.codehaus.org
Subject: [Eclipse plugin] Resource not found with API call


Hello,

I have noticed that the eclipse plugin doesn't load any violations in
remote mode.
The jetty log shows up following:
... -  -  [22/May/2013:15:56:31 +0000] "GET
/sonar/api/resources?resource=K4%3AMissionSoftware%2FPayloadControl%2FMM
FU%2FMMFU.c&verbose=true& HTTP/1.1" 404 108 "-" "Mozilla/5.0 (Windows NT
6.1; WOW64) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1300.0
Iron/23.0.1300.0 Safari/537.11"

I have checked the table projects for the kee and
K4:MissionSoftware:PayloadControl:
MMFU:MMFU.c is contained.
I tried the call manually with my browser and voila it works:
... -  -  [22/May/2013:16:01:13 +0000] "GET
/sonar/api/resources?resource=K4:MissionSoftware:PayloadControl:MMFU:MMF
U.c&verbose=true& HTTP/1.1" 200 286 "-" "Mozilla/5.0 (Windows NT 6.1;
WOW64) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1300.0
Iron/23.0.1300.0 Safari/537.11"

It seems that the percent-encoding makes some trouble. I have checked
the
resources_controller.rb and didn't found any decoding of the parameter.

(Yes it is a multi-module project.)

Best Regards,

Christian Schulz


This email (including any attachments) may contain confidential and/or
privileged information or information otherwise protected from disclosure.
If you are not the intended recipient, please notify the sender immediately,
do not copy this message or any attachments and do not use it for any
purpose or disclose its content to any person, but delete this message and
any attachments from your system.
Astrium disclaims any and all liability if this email transmission
was virus corrupted, altered or falsified.
----------------------------------------------------------------------------
Astrium GmbH
Vorsitzender des Aufsichtsrates:  Günter Stamerjohanns
Geschäftsführung: Evert Dudok (Vorsitzender), Jens Schomburgk,
Dr. Johannes von Thadden
Sitz der Gesellschaft: München -
Registergericht: Amtsgericht München, HRB Nr. 107647
----------------------------------------------------------------------------
Weitere Informationen über EADS Astrium unter www.astrium.eads.net
[Attachment #3 (text/html)]

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7654.12">
<TITLE>RE: [Eclipse plugin] Resource not found with API call</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/rtf format -->

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT COLOR="#1F497D" \
FACE="Calibri">Hello,</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT COLOR="#1F497D" FACE="Calibri">Okay some more \
investigation offered more details. I have tested it with the lastest \
snapshot</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"> <FONT \
COLOR="#1F497D" FACE="Calibri">and it</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT COLOR="#1F497D" FACE="Calibri">Seems that eclipse \
is using the wrong seperators.</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT COLOR="#1F497D" FACE="Calibri">Instead of : it \
uses /.</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT COLOR="#1F497D" \
FACE="Calibri">api/resources?resource=K4_py%3ABasicComponents%2FDM%2FDataManagement.c&amp;verbose=false&amp;</FONT></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"><FONT COLOR="#1F497D" FACE="Wingdings">&#240;<FONT FACE="Courier \
New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</FONT></FONT></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"> <FONT COLOR="#1F497D" FACE="Calibri">Resource \
[K4_py:BasicComponents/DM/DataManagement.c] not found</FONT></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT COLOR="#1F497D" FACE="Calibri">So finally no \
problem of the API that it</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"> \
<FONT COLOR="#1F497D" FACE="Calibri">doesn&#8217;t perform percent \
decoding.</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT COLOR="#1F497D" \
FACE="Calibri">I am using the CDT variant</FONT></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT COLOR="#1F497D" \
FACE="Calibri">.</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT COLOR="#1F497D" \
FACE="Calibri">I think the multi-module</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"><FONT COLOR="#1F497D" FACE="Calibri"></FONT></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"> <FONT COLOR="#1F497D" \
FACE="Calibri">support</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"> \
<FONT COLOR="#1F497D" FACE="Calibri">is missing</FONT></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT COLOR="#1F497D" \
FACE="Calibri">.</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT COLOR="#1F497D" \
FACE="Calibri">In my opinion the start point would be the</FONT></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT COLOR="#1F497D" \
FACE="Calibri"></FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"> <FONT \
COLOR="#1F497D" FACE="Calibri">SonarElementsAdapterFactory</FONT></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT COLOR="#1F497D" \
FACE="Calibri">.</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT \
COLOR="#1F497D" FACE="Calibri">getSonarResource</FONT></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT COLOR="#1F497D" \
FACE="Calibri">/</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT COLOR="#1F497D" \
FACE="Calibri">createSonarResource</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"><FONT COLOR="#1F497D" FACE="Calibri">. Additional we \
should</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT \
COLOR="#1F497D" FACE="Calibri"> Introduce the module as resource type. Furthermore \
the</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT COLOR="#1F497D" \
FACE="Calibri">ISonarProject</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"><FONT COLOR="#1F497D" FACE="Calibri"> have to handle sub \
modules</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT \
COLOR="#1F497D" FACE="Calibri"></FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"> <FONT COLOR="#1F497D" FACE="Calibri">and so on.</FONT></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT COLOR="#1F497D" FACE="Calibri">Best \
Regards,</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT COLOR="#1F497D" FACE="Calibri">Christian \
Schulz</FONT></SPAN><SPAN LANG="en-us"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT SIZE=2 \
FACE="Tahoma">_____________________________________________<BR> </FONT></SPAN><SPAN \
LANG="en-us"><B></B></SPAN><SPAN LANG="en-us"><B></B></SPAN><SPAN \
LANG="en-us"><B></B></SPAN><B><SPAN LANG="en-us"><FONT SIZE=2 \
FACE="Tahoma">From:</FONT></SPAN></B><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT SIZE=2 \
FACE="Tahoma"> Schulz, Christian<BR> </FONT></SPAN><SPAN \
LANG="en-us"><B></B></SPAN><SPAN LANG="en-us"><B></B></SPAN><SPAN \
LANG="en-us"><B></B></SPAN><B><SPAN LANG="en-us"><FONT SIZE=2 \
FACE="Tahoma">Sent:</FONT></SPAN></B><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT SIZE=2 \
FACE="Tahoma"> Wednesday, May 22, 2013 6:13 PM<BR> </FONT></SPAN><SPAN \
LANG="en-us"><B></B></SPAN><SPAN LANG="en-us"><B></B></SPAN><SPAN \
LANG="en-us"><B></B></SPAN><B><SPAN LANG="en-us"><FONT SIZE=2 \
FACE="Tahoma">To:</FONT></SPAN></B><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT SIZE=2 \
FACE="Tahoma"> user@sonar.codehaus.org<BR> </FONT></SPAN><SPAN \
LANG="en-us"><B></B></SPAN><SPAN LANG="en-us"><B></B></SPAN><SPAN \
LANG="en-us"><B></B></SPAN><B><SPAN LANG="en-us"><FONT SIZE=2 \
FACE="Tahoma">Subject:</FONT></SPAN></B><SPAN LANG="en-us"></SPAN><SPAN \
LANG="en-us"></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="en-us"><FONT SIZE=2 \
FACE="Tahoma"> [Eclipse plugin] Resource not found with API call</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">Hello,</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">I have noticed that the eclipse \
plugin doesn&#8217;t load any violations in remote mode.</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">The jetty log shows up \
following:</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">&#8230; -&nbsp; -&nbsp; \
[22/May/2013:15:56:31 +0000] &quot;GET \
/sonar/api/resources?resource=K4%3AMissionSoftware%2FPayloadControl%2FMMFU%2FMMFU.c&amp;verbose=true&amp; \
HTTP/1.1&quot; 404 108 &quot;-&quot; &quot;Mozilla/5.0 (Windows NT 6.1; WOW64) \
AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1300.0 Iron/23.0.1300.0 \
Safari/537.11&quot;</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">I have checked the table projects \
for the kee and K4:MissionSoftware:PayloadControl:</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">MMFU:MMFU.c is \
contained.</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">I tried the call manually with my \
browser and voila it works:</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">&#8230; -&nbsp; -&nbsp; \
[22/May/2013:16:01:13 +0000] &quot;GET \
/sonar/api/resources?resource=K4:MissionSoftware:PayloadControl:MMFU:MMFU.c&amp;verbose=true&amp; \
HTTP/1.1&quot; 200 286 &quot;-&quot; &quot;Mozilla/5.0 (Windows NT 6.1; WOW64) \
AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1300.0 Iron/23.0.1300.0 \
Safari/537.11&quot;</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">It seems that the percent-encoding \
makes some trouble. I have checked the</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">resources_controller.rb and \
didn&#8217;t found any decoding of the parameter.</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">(Yes it is a multi-module \
project.)</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">Best Regards,</FONT></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"><FONT FACE="Calibri">Christian \
Schulz</FONT></SPAN><SPAN LANG="en-us"></SPAN><SPAN LANG="de-de"></SPAN></P>

<P DIR=LTR><SPAN LANG="en-us"></SPAN><SPAN LANG="de"></SPAN></P>

</BODY>
</HTML>
<table><tr><td bgcolor=#ffffff><font color=#000000><pre>This email (including any \
attachments) may contain confidential and/or privileged information or information \
otherwise protected from disclosure. If you are not the intended recipient, please \
notify the sender immediately, do not copy this message or any attachments and do not \
use it for any purpose or disclose its content to any person, but delete this message \
and any attachments from your system.
Astrium disclaims any and all liability if this email transmission
was virus corrupted, altered or falsified.
----------------------------------------------------------------------------
Astrium GmbH
Vorsitzender des Aufsichtsrates:  Günter Stamerjohanns
Geschäftsführung: Evert Dudok (Vorsitzender), Jens Schomburgk,
Dr. Johannes von Thadden
Sitz der Gesellschaft: München -
Registergericht: Amtsgericht München, HRB Nr. 107647
----------------------------------------------------------------------------
Weitere Informationen über EADS Astrium unter \
www.astrium.eads.net</pre></font></td></tr></table>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic