Closes#6108
Pull request #6180
Test is included, as is updated documentation.
All tests in ddp-client package (including new test for #6108) pass.
Implemented as simply a noRetry flag on apply which triggers it to fail with a
Meteor.Error('invocation-failed') instead of retrying on reconnect.
Test passes, methods which are marked as noRetry get an error in case of reset,
only if they've sent at least once, and this happens before messageSent flag is
cleared. This results in it getting it's callback as soon as quiescence
triggers, and the callback is called with an Error 'invocation-failed'.
[stubailo: changed error code, fixed docs, squashed commits]
On re-connect, clients re-try methods that haven't received a response, which means that methods might be called multiple times. This is important to document so users know to guard against this behavior if a method has dangerous side-effects.
See issue #2407.