错误 "Uncaught Exception: Uncaught RestRequestError - Unexpected error when communicating with server." 是什么意思?

What does the error "Uncaught Exception: Uncaught RestRequestError - Unexpected error when communicating with server." mean?

我在 Bluemix.I 上使用混合 SDK 和移动数据服务对我的一个类执行 query.find() 方法并得到:

Uncaught Exception: Uncaught RestRequestError - Unexpected error when communicating with server

此错误的原因是什么?如何才能完成对 query.find() 的调用?

经过进一步测试,我发现只有当我对具有许多对象的 class 使用 query.find() 方法时才会发生这种情况。我已经测试了 1k 个对象、3k 个对象和 6k 个对象,但每次都出现错误。

当我用 500 个对象进行测试时,我没有收到错误,所以问题似乎与我正在查询的 class 关联的对象数量有关。

进一步调查显示,对于具有更多对象的 classes,query.find() 调用超时。

我最终在我的代码中实现了对 IBMBluemix.getConfig().setTimout() 的调用。这会增加超时值,以便 query.find() 调用可以完成。我不得不尝试价值观,里程会有所不同。

说实话,对于我最大的一些 classes,我正在考虑减少关联对象的数量。