SSLEOFError

969 views
Skip to first unread message

Akilesh K

unread,
Jun 3, 2021, 12:16:44 PM6/3/21
to rabbitmq-users
Hi,
While running a test case for a multi threaded application I get the below error. As can be seen the test starts and sends a few messages from different threads and then crashes after a while. Each of  my thread uses its own connection and channel.

What does this error mean and how do I get it fixed? I am using pika==1.2.0.


2021-06-03 21:37:12,579 - DEBUG - MainThread - Starting all operations
2021-06-03 21:37:12,579 - DEBUG - B_pub_sub_test_stubA - B_pub_sub_test_stubA sending 1
2021-06-03 21:37:12,580 - DEBUG - C_pub_sub_test_stubA - C_pub_sub_test_stubA sending 1
2021-06-03 21:37:23,938 - DEBUG - B_pub_sub_test_stubA - B_pub_sub_test_stubA sending 2
2021-06-03 21:37:24,858 - DEBUG - C_pub_sub_test_stubA - C_pub_sub_test_stubA sending 2
2021-06-03 21:37:28,092 - DEBUG - B_pub_sub_test_stubA - B_pub_sub_test_stubA sending 3
2021-06-03 21:37:28,880 - DEBUG - C_pub_sub_test_stubA - C_pub_sub_test_stubA sending 3
2021-06-03 21:37:36,296 - DEBUG - B_pub_sub_test_stubA - B_pub_sub_test_stubA sending 4
2021-06-03 21:37:37,080 - DEBUG - C_pub_sub_test_stubA - C_pub_sub_test_stubA sending 4
2021-06-03 21:37:42,488 - DEBUG - C_pub_sub_test_stubA - C_pub_sub_test_stubA sending 5
2021-06-03 21:37:43,408 - DEBUG - B_pub_sub_test_stubA - B_pub_sub_test_stubA sending 5
<class 'pika.exceptions.StreamLostError'>: Stream connection lost: SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:2472)'), retrying in 5 seconds...
Exception in thread C_pub_sub_test_stubA:
Traceback (most recent call last):
 File "/home/akandavelu/python_venv/ehmrabbit/lib/python3.8/site-packages/pika/adapters/utils/io_services_utils.py", line 1211, in _on_socket_writable
   self._ssl_writable_action()
 File "/home/akandavelu/python_venv/ehmrabbit/lib/python3.8/site-packages/pika/diagnostic_utils.py", line 53, in log_exception_func_wrap
   return func(*args, **kwargs)
 File "/home/akandavelu/python_venv/ehmrabbit/lib/python3.8/site-packages/pika/adapters/utils/io_services_utils.py", line 1308, in _produce
   super(_AsyncSSLTransport, self)._produce()
 File "/home/akandavelu/python_venv/ehmrabbit/lib/python3.8/site-packages/pika/adapters/utils/io_services_utils.py", line 819, in _produce
   num_bytes_sent = self._sigint_safe_send(self._sock,
 File "/home/akandavelu/python_venv/ehmrabbit/lib/python3.8/site-packages/pika/adapters/utils/io_services_utils.py", line 79, in retry_sigint_wrap
   return func(*args, **kwargs)
 File "/home/akandavelu/python_venv/ehmrabbit/lib/python3.8/site-packages/pika/adapters/utils/io_services_utils.py", line 861, in _sigint_safe_send
   return sock.send(data)
 File "/usr/lib/python3.8/ssl.py", line 1173, in send
   return self._sslobj.write(data)
ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:2472)

Regards

Yong Hua Peng

unread,
Jun 3, 2021, 10:23:00 PM6/3/21
to rabbitm...@googlegroups.com
This seems the SSL connection issue. You may try to use the correct SSL client library.

Thanks 

--
Sent from mobile

04.06.2021, 00:16, "Akilesh K" <akile...@gmail.com>:
--
You received this message because you are subscribed to the Google Groups "rabbitmq-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rabbitmq-user...@googlegroups.com.
To view this discussion on the web, visit https://groups.google.com/d/msgid/rabbitmq-users/7dfc0742-9dd3-497e-ad65-15a91359da4en%40googlegroups.com.

Akilesh K

unread,
Jun 4, 2021, 2:20:43 AM6/4/21
to rabbitmq-users
Somehow I doubt its related to SSL . It only happens when there are more than one thread and also the first few messages are published perfectly well.

John Pfersich

unread,
Jun 9, 2021, 2:55:59 AM6/9/21
to rabbitm...@googlegroups.com
as a thread on stackoverflow says:

There are threading issues with Pika, but as long as you create one connection per thread it shouldn't be a problem.

/—————————————————————/
For encrypted mail use jgpfe...@protonmail.com - Free account at ProtonMail.com


On Jun 3, 2021, at 09:16, Akilesh K <akile...@gmail.com> wrote:


--
Reply all
Reply to author
Forward
0 new messages