Model.prototype.batch does not clone with options
eternalmatt opened this issue · comments
We are experiencing a bug where we set a timeout (for a slow historical rest service where caching is not possible), but the timeout is not carried forward after a batch() call to Model.
Offending source:
var clone = this._clone();
Model.prototype._clone = function cloneModel(opts)
https://github.com/Netflix/falcor/blob/v1.0.3/lib/Model.js#L482
So opts is undefined and we lose our timeout. In the short-term to fix this bug locally, we are going to override Model.prototype._clone to carry { timeout: 30000 } in all calls.
@eternalmatt could you post your override implementation of Model.prototype._clone
here? Trying to understand exactly how you worked around your issue.
A more descriptive sequence of steps to reproduce your issue would be helpful too!
This is embarrassing. After implementing our fix, we realized the timeout parameter is part of the falcor-http-datasource module, not falcor.Model. So we undid everything and just moved timeout to the right place.
awesome! glad your issue got resolved :)
on a separate note, would certainly love to know more about how you're using falcor and falcor-http-datasource for your projects. just for the purpose of observing usage patterns for the library..