PPE Platform Erroring out on XPath queries
-
Wednesday, December 12, 2012 9:11 AM
Hi,
Some of the GetThings requests (which used to work previously) seem to constantly error out today. I think these are ones which has a XPath filter.
The error is just a Http 500 response from /Platform application
Can someone assist in getting this fixed? The application id we used was -
afc8707e-c160-4b7f-9856-69d5c790b1a9
Thanks
Rajesh
Raj HealthVault Developer Tool http://xray.getrealconsulting.com
All Replies
-
Wednesday, December 12, 2012 11:41 PMOwner
Hi,
The main issue causing a problem is the large number of application specific thing types in your record. The record contains 200,000+ current instances of application specific thing type. 150,000+ were created by application id C46FEC5C-F592-4249-95B1-ED8740EAE1CA.
The XPath filter you specified is very good at querying for things, but it finds too many of them. HealthVault then tries to filter out the instances your application does not have authorization to view (those created by a different app). By the time it finds instances you can view, the request has been killed for exceeding it's time limit.
XPath queries will help if your query has an XPath unique to your application. All instances located by HealthVault would then belong to your application, would not require further filtering and would not timeout.
There are ways HealthVault could improve the querying if 200,000+ instances are a common occurrence. As is, it's hard to know if the query will succeed or not in the time allotted.
--Rob
- Edited by robmayOwner Thursday, December 13, 2012 12:26 AM
- Marked As Answer by Rajesh CKR Thursday, December 13, 2012 8:03 AM
-
Thursday, December 13, 2012 8:05 AM
Thanks Rob for the report. We do not anticipate that much app specific instances on a real scenario - we should be good for now.
Rajesh
Raj HealthVault Developer Tool http://xray.getrealconsulting.com
-
Friday, December 14, 2012 1:46 AM
Just a quick add --- you can easily make this particular query speedy by adding your appid to the query (as in creating appid = XXX) ... since that will be executed in sql before the xpath gets applied. It's redundant to the actual results returned (since you only see app specifics you create) ... but cheats the engine into being much more efficient about it.
---S
- Marked As Answer by Rajesh CKR Friday, December 14, 2012 5:04 AM

