Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ddtrace/tracer: reset payload after every transport attempt (#319)
Previously, we were attempting to save the payload as long as the size allows it in order to attempt and send it again on subsequent retries to minimize the loss of traces. This has proven to be a bad approach because there were cases were the trace agent did only partial reads from the payload before failing, leaving the payload in a state where it was impossible to decode using msgpack (part of the buffer was already read). This fix is an intermediary easy solution to the problem (we have experimented with different approaches too, see #275). We can experiment later on with retry policies.
- Loading branch information