History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: QB-1532
Type: Improvement Improvement
Status: Open Open
Priority: Major Major
Assignee: Robin Shen
Reporter: Andrey
Votes: 1
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
QuickBuild

Restrict fields returned through REST API (search builds)

Created: 26/Jan/13 04:56 PM   Updated: 22/Aug/13 02:10 AM
Component/s: None
Affects Version/s: 4.0.50
Fix Version/s: None

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown


 Description  « Hide
I'm going to download information for processing locally about builds through REST API using /rest/builds?<search criteria1>=<value1>..., but it returns all information about builds in returned xml, including all executed steps. My system has a lot of builds with many steps executed, so resulted xml is very large. Taking into account slow internet connection to server it require a lot of time to downlowd xml. Is it possible to restrict number of field returned through this API, at least turn off steps from returned xml?

BTW, just example - REST api in JIRA has such mechanism for /rest/api/2/search (http://docs.atlassian.com/jira/REST/latest/):

/rest/api/2/search?jql&startAt&maxResults&fields&expand
Searches for issues using JQL.
...
The fields param (which can be specified multiple times) gives a comma-separated list of fields to include in the response. This can be used to retrieve a subset of fields. A particular field can be excluded by prefixing it with a minus.
By default, only navigable (*navigable) fields are returned in this search resource. Note: the default is different in the get-issue resource -- the default there all fields (*all).
*all - include all fields
*navigable - include just navigable fields
summary,comment - include just the summary and comments
-description - include navigable fields except the description (the default is *navigable for search)
*all,-comment - include everything except comments

 All   Comments   Work Log   Change History      Sort Order:
Dmitry Ivanov [20/Aug/13 11:45 AM]
I would be happy too if you implemented this functionality

Robin Shen [21/Aug/13 01:37 AM]
Unlike JIRA issues, QB build does not contain much fields, so I guess the result XML might still be very large if you request many builds at a time. Or specifically, which fields you'd like to trim off in resulting XML?

Andrey [21/Aug/13 05:09 AM]
I talked about all executed steps - this is a very big portion of data, and we download they even if we need only general info about build that is located in other fields.

Robin Shen [22/Aug/13 02:10 AM]
Oh, that is quite big, so at the minimum we can add an option to exclude that portion of data. Will this be acceptable?