Does Intellij Message Bus infra executes Synchronously ?

Answered

Upon actionPerformed, I am publishing to a topic.
On the subscriber side(for that topic), It's making a HTTP request. And i'm facing this error. I used to believe that the intellij's messaging Infra is async in nature and this should not block the “actionPerformed” thread.
```
java.lang.Throwable: Assertion failed: Network must not be accessed in EDT or inside read action, because this may take considerable amount of time, and write actions will be blocked during that time so user won't be able to perform tasks in the IDE
    at com.intellij.openapi.diagnostic.Logger.assertTrue(Logger.java:465)
    at com.intellij.util.io.HttpRequests.process(HttpRequests.java:497)

0
1 comment

Hi,

Yes, it is mentioned in the MessageBus documentation:

* **Thread-safety.**
* All subscribers are notified sequentially from the calling thread.

0

Please sign in to leave a comment.