You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@eventmesh.apache.org by "Alonexc (via GitHub)" <gi...@apache.org> on 2023/06/09 01:47:39 UTC

[GitHub] [eventmesh] Alonexc opened a new issue, #4096: [Enhancement] InterruptedExceptions should never be ignored in the code.[EtcdRegistryService]

Alonexc opened a new issue, #4096:
URL: https://github.com/apache/eventmesh/issues/4096

   ### Search before asking
   
   - [X] I had searched in the [issues](https://github.com/apache/eventmesh/issues?q=is%3Aissue) and found no similar issues.
   
   
   ### Enhancement Request
   
   ![image](https://github.com/apache/eventmesh/assets/91315508/85e56333-0ff4-401e-b05d-cd2c18c0ee18)
   ![image](https://github.com/apache/eventmesh/assets/91315508/33ae4f41-4eb6-46e0-94a6-4bc6d418798e)
   located at:
   eventmesh-registry-plugin/eventmesh-registry-etcd/src/main/java/org/apache/eventmesh/registry/etcd/service/EtcdRegistryService.java line 165,265
   analysis and explanation:
   InterruptedExceptions should never be ignored in the code, and simply logging the exception counts in this case as "ignoring". The throwing of the InterruptedException clears the interrupted state of the Thread, so if the exception is not handled properly the information that the thread was interrupted will be lost. Instead, InterruptedExceptions should either be rethrown - immediately or after cleaning up the method’s state - or the thread should be re-interrupted by calling Thread.interrupt() even if this is supposed to be a single-threaded application. Any other course of action risks delaying thread shutdown and loses the information that the thread was interrupted - probably without finishing its task.
   
   
   ### Describe the solution you'd like
   
   restore interrupted state
   ![image](https://github.com/apache/eventmesh/assets/91315508/4bf6ec36-3686-4af3-a1d2-f51126ac7072)
   ![image](https://github.com/apache/eventmesh/assets/91315508/b09e225b-3cd1-4cfe-9ac1-155761c2a33f)
   
   
   ### Are you willing to submit PR?
   
   - [ ] Yes I am willing to submit a PR!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@eventmesh.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@eventmesh.apache.org
For additional commands, e-mail: issues-help@eventmesh.apache.org


Re: [I] [Enhancement] InterruptedExceptions should never be ignored in the code.[EtcdMetaService] (eventmesh)

Posted by "HarshSawarkar (via GitHub)" <gi...@apache.org>.
HarshSawarkar commented on issue #4096:
URL: https://github.com/apache/eventmesh/issues/4096#issuecomment-1849576032

   Hi all, I have raised a PR for this issue.Can anyone please review it? Here's the link https://github.com/apache/eventmesh/pull/4636


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@eventmesh.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@eventmesh.apache.org
For additional commands, e-mail: issues-help@eventmesh.apache.org


Re: [I] [Enhancement] InterruptedExceptions should never be ignored in the code.[EtcdMetaService] (eventmesh)

Posted by "xwm1992 (via GitHub)" <gi...@apache.org>.
xwm1992 closed issue #4096: [Enhancement] InterruptedExceptions should never be ignored in the code.[EtcdMetaService]
URL: https://github.com/apache/eventmesh/issues/4096


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@eventmesh.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@eventmesh.apache.org
For additional commands, e-mail: issues-help@eventmesh.apache.org


Re: [I] [Enhancement] InterruptedExceptions should never be ignored in the code.[EtcdMetaService] (eventmesh)

Posted by "HarshSawarkar (via GitHub)" <gi...@apache.org>.
HarshSawarkar commented on issue #4096:
URL: https://github.com/apache/eventmesh/issues/4096#issuecomment-1849599809

   Also can someone please add me to ASF slack.Here's my email id: harshsawarkar111@gmail.com


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@eventmesh.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@eventmesh.apache.org
For additional commands, e-mail: issues-help@eventmesh.apache.org