ikxeno commented on code in PR #13602:
URL: https://github.com/apache/maven/pull/13602#discussion_r4304989946


##########
impl/maven-di/src/main/java/org/apache/maven/di/impl/InjectorImpl.java:
##########
@@ -515,6 +561,91 @@ public T get() {
         }
     }
 
+    /**
+     * Captures a human-readable snapshot of the current native registry for 
Maven internals,
+     * including direct binding map and metadata changes, without resolving 
components.
+     * Registration must not run concurrently with this method.
+     */
+    public String dumpBindings() {
+        return BindingSnapshot.render(
+                this, registryRevision, "explicit", false, 
BindingSnapshot.capture(bindings, scopes));

Review Comment:
   diagnosticLock protects diagnostic state; registry writes do not acquire it. 
Locking dumpBindings() alone would not make concurrent registration safe. The 
existing Javadoc already prohibits concurrent registration.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to