Uploaded image for project: 'WildFly Core'
  1. WildFly Core
  2. WFCORE-5240

Add a ManagementResourceRegistration.registerSubModelIfAbsent method

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Won't Do
    • Icon: Major Major
    • None
    • None
    • Management
    • None

      Subsystems, particularly datasources and resource-adapters, have code like this that's called from service start methods:

      https://github.com/wildfly/wildfly/blob/master/connector/src/main/java/org/jboss/as/connector/services/datasources/statistics/DataSourceStatisticsService.java#L84-L86

      This is basically trying for a quasi putIfAbsent semantic. But it's not really reliable, particularly if multiple services are doing the same thing during boot.

      So, add a proper putIfAbsent-type submodel registration method to ManagementResourceRegistration.

              bstansbe@redhat.com Brian Stansberry
              bstansbe@redhat.com Brian Stansberry
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: