diff options
author | Emmanuel Vasilakis <mrzammler@mm.st> | 2023-01-13 17:51:56 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-13 17:51:56 +0200 |
commit | c5374729144d6c48c0792d5f6f796b1a6908b7ce (patch) | |
tree | b3ed61aefa2949d9bce38b39b0d07fdd5d5589ed /streaming | |
parent | 8315a8e9f5d83eccbdafffe3c9f1c120780ff66c (diff) |
Enable retries for SSL_ERROR_WANT_READ (#14120)
* enable retries for SSL_ERROR_WANT_READ
* only when bytes is <= 0
* treat ERROR_WANT_READ/WRITE as 0 bytes
* dont close connection on zero bytes
* reuse ssl connection
* treat zero bytes
* ifdef for old openssl
* revert check
Diffstat (limited to 'streaming')
-rw-r--r-- | streaming/sender.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/streaming/sender.c b/streaming/sender.c index 92182226c7..dd76389462 100644 --- a/streaming/sender.c +++ b/streaming/sender.c @@ -818,8 +818,10 @@ static ssize_t attempt_read(struct sender_state *s) { return ret; } - worker_is_busy(WORKER_SENDER_JOB_DISCONNECT_SSL_ERROR); - rrdpush_sender_thread_close_socket(s->host); + if (ret == -1) { + worker_is_busy(WORKER_SENDER_JOB_DISCONNECT_SSL_ERROR); + rrdpush_sender_thread_close_socket(s->host); + } return ret; } #endif |