Quantcast

GET /api/violations limited up to 5.000 results

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

GET /api/violations limited up to 5.000 results

Roberto Vietti

 

Hi community,

                I’m trying to download XML violation list using the “GET /api/violations service” -  (see http://docs.codehaus.org/display/SONAR/Web+Service+API#WebServiceAPI-Violations)

 

This is my url

<a href="http://mysonarserver:port/sonar/api/violations?resource=KEYPROJECT&amp;depth=-1&amp;limit=20000&amp;format=xml">http://mysonarserver:port/sonar/api/violations?resource=KEYPROJECT&depth=-1&limit=20000&format=xml

 

Even though I specified the parameter limit=20000,  there’s no way to download more than 5.000 results – (5000 is the default value).

 

Am’I missing something?  Is there any workaround to get the whole list?

 

Any help will be appreciated

 

Ps,

I’m running sonar 3.1.1  on  MySql 5.5.24

 

ciao

Roberto Vietti

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: GET /api/violations limited up to 5.000 results

Jesús Badenas Martínez
Hi Roberto,

I had the same problem because I was trying to obtain the whole list of violations in a widget (through Ruby code). My solution was to read data directly from the database with the Ruby API.

I didn't find documentation, but looking examples from Sonar code you can use the Ruby method "find" to obtain values from the database.

Anyway, I would like to know the best way to do this, so we can wait for a new answer.

Regards.

2012/7/12 Roberto Vietti <[hidden email]>

 

Hi community,

                I’m trying to download XML violation list using the “GET /api/violations service” -  (see http://docs.codehaus.org/display/SONAR/Web+Service+API#WebServiceAPI-Violations)

 

This is my url

<a href="http://mysonarserver:port/sonar/api/violations?resource=KEYPROJECT&amp;depth=-1&amp;limit=20000&amp;format=xml" target="_blank">http://mysonarserver:port/sonar/api/violations?resource=KEYPROJECT&depth=-1&limit=20000&format=xml

 

Even though I specified the parameter limit=20000,  there’s no way to download more than 5.000 results – (5000 is the default value).

 

Am’I missing something?  Is there any workaround to get the whole list?

 

Any help will be appreciated

 

Ps,

I’m running sonar 3.1.1  on  MySql 5.5.24

 

ciao

Roberto Vietti


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: GET /api/violations limited up to 5.000 results

Julien HENRY-3
Hi,

You can have a look at the following issues:
http://jira.codehaus.org/browse/SONAR-1428
http://jira.codehaus.org/browse/SONAR-2920


Regards,

Julien

>________________________________
> De : Jesús Badenas Martínez <[hidden email]>
>À : [hidden email]
>Envoyé le : Jeudi 12 juillet 2012 16h31
>Objet : Re: [sonar-user] GET /api/violations limited up to 5.000 results
>
>
>Hi Roberto,
>
>
>I had the same problem because I was trying to obtain the whole list of violations in a widget (through Ruby code). My solution was to read data directly from the database with the Ruby API.
>
>
>I didn't find documentation, but looking examples from Sonar code you can use the Ruby method "find" to obtain values from the database.
>
>
>Anyway, I would like to know the best way to do this, so we can wait for a new answer.
>
>
>Regards.
>
>
>2012/7/12 Roberto Vietti <[hidden email]>
>

>>Hi community,
>>                I’m trying to download XML violation list using the “GET /api/violations service” -  (see http://docs.codehaus.org/display/SONAR/Web+Service+API#WebServiceAPI-Violations)
>> 
>>This is my url
>><a href="http://mysonarserver:port/sonar/api/violations?resource=KEYPROJECT&depth=-1&limit=20000&format=xml">http://mysonarserver:port/sonar/api/violations?resource=KEYPROJECT&depth=-1&limit=20000&format=xml
>> 
>>Even though I specified the parameter limit=20000,  there’s no way to download more than 5.000 results – (5000 is the default value).
>> 
>>Am’I missing something?  Is there any workaround to get the whole list?
>> 
>>Any help will be appreciated
>> 
>>Ps,
>>I’m running sonar 3.1.1  on  MySql 5.5.24
>> 
>>ciaoRoberto Vietti
>
>
>

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Loading...