Forum Discussion
VSTS odata refresh issue
One bit of information that I find interesting is that if I change VSTS.Feed([URL]) to VSTS.Contents([URL]), the dataset will refresh
with no issues. However, the values returned by VSTS.Feed() are binary and much more difficult to transform into useful rows and
columns.
Hi,
Looks like you are trying to view work item snapshots monthly. Have you tried new Analytics views? It has a feature to return history (which is what workitemsnapshot is) at monthly intervals.
- gaccardo8 years agoAdvocate II
The data sources shown are from the analytics view feature. We are accessing it via the odata feed using the VSTS.Feed() method to get complete work item histories over a 6 month period. The reason for multiple queries is because a single query with 6 months of data returns >300K rows.
As best I can tell, the problem seems to be an issue in the VSTS.Feed() method itself.
- A single call to VSTS.Feed() in a query works properly in apps.powerbi.com.
- Multiple, sequential calls to VSTS.Feed() in a query work
- Multiple calls to VSTS.Feed() in an each loop cannot be refreshed in apps.powerbi.com. They fail as shown
in the original message. - Using VSTS.Contents() in an each loop refreshs without issue. However, this method is deprecated, doesn't return
all of the data (it provides a continuation token), and also returns a binary object which is harder to process. - Using VSTS.AccountContents()--which replaces VSTS.Contents()--fails the same way that VSTS.Feed() does.
- Using OData.Feed()--which was replaced by VSTS.Feed()--fails the same way that VSTS.Feed() does. It also
doesn't return all of the data, but instead returns a continuation token.
Given the number of options provided to run a query, it would be nice if one of them worked.
- arsaveli8 years agoHelper I
There are two things going on here:
The reason VSTS.Feed is breaking is because of dynamic URL generation and how that works with PowerBI - PowerBI has data source code analysis that doesn't support this kind of flow.
You are also trying to download complete WorkItemSnapshot data via this method and aggregate it in Powerbi.
VSTS specifically blocks complete WorkItemSnapshot download for performance reasons:
You should instead use Analytics views - which will pre-aggregate your data on VSTS side.