You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 01b307e
Browse filesBrowse the repository at this point in the historyBrowse files
fix: avoid deadlock when changeNamespaces joins a populated shared informer (#3655)
Fabric8 replays an already populated informer's cache to a newly added
handler synchronously, on the registering thread. changeNamespaces
registered the handler on an informer starter thread while the event
source held its monitor waiting for that thread, so the replay blocked
on the monitor and deadlocked. Register the handlers on the calling
thread and only start the informers in parallel.
Fixes#3650
Copy file name to clipboardExpand all lines: operator-framework-core/src/main/java/io/javaoperatorsdk/operator/processing/event/source/informer/InformerManager.java
+17-5Lines changed: 17 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -120,19 +120,31 @@ public void changeNamespaces(Set<String> namespaces) {
120
120
return;
121
121
}
122
122
123
+
// Registering the handler on an already populated shared informer replays its cache to the
124
+
// handler synchronously, on the registering thread. The event source holds its monitor while
125
+
// waiting for the informers below to start, so the handler has to be registered on this thread:
126
+
// a replay from an informer starter thread would block on that monitor and deadlock.
Copy file name to clipboardExpand all lines: operator-framework-core/src/test/java/io/javaoperatorsdk/operator/processing/event/source/informer/ManagedInformerEventSourceNamespaceChangeTest.java
0 commit comments