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

Improve error message if a parent profile references a child profile's value

    • Icon: Enhancement Enhancement
    • Resolution: Obsolete
    • Icon: Major Major
    • None
    • 3.1.0.Final, 4.0.0.Final, 5.0.0.Alpha3
    • Management

      EAP 7.1 CP1 boot up fails with the following error message when a profile extension is used

      14:13:39,201 ERROR [org.jboss.as.controller] (Controller Boot Thread) WFLYCTL0362: Capabilities required by resource '/profile=temp-full-ha/subsystem=infinispan/cache-container=hibernate/transport=jgroups' are not available: [Host Controller] org.wildfly.clustering.jgroups.default-channel-factory in context 'profile=temp-full-ha'; Possible registration points for this capability: [Host Controller] /profile=*/subsystem=jgroups [Host Controller]
      14:13:39,202 ERROR [org.jboss.as.controller] (Controller Boot Thread) WFLYCTL0362: Capabilities required by resource '/profile=temp-full-ha/subsystem=messaging-activemq/server=default/broadcast-group=bg-group1' are not available: [Host Controller] org.wildfly.clustering.jgroups.default-channel-factory in context 'profile=temp-full-ha'; Possible registration points for this capability: [Host Controller] /profile=*/subsystem=jgroups [Host Controller]
      14:13:39,202 ERROR [org.jboss.as.controller] (Controller Boot Thread) WFLYCTL0362: Capabilities required by resource '/profile=temp-full-ha/subsystem=infinispan/cache-container=web/transport=jgroups' are not available: [Host Controller] org.wildfly.clustering.jgroups.default-channel-factory in context 'profile=temp-full-ha'; Possible registration points for this capability: [Host Controller] /profile=*/subsystem=jgroups [Host Controller]
      14:13:39,202 ERROR [org.jboss.as.controller] (Controller Boot Thread) WFLYCTL0362: Capabilities required by resource '/profile=temp-full-ha/subsystem=messaging-activemq/server=default/discovery-group=dg-group1' are not available: [Host Controller] org.wildfly.clustering.jgroups.default-channel-factory in context 'profile=temp-full-ha'; Possible registration points for this capability: [Host Controller] /profile=*/subsystem=jgroups [Host Controller]
      14:13:39,203 ERROR [org.jboss.as.controller] (Controller Boot Thread) WFLYCTL0362: Capabilities required by resource '/profile=temp-full-ha/subsystem=infinispan/cache-container=server/transport=jgroups' are not available: [Host Controller] org.wildfly.clustering.jgroups.default-channel-factory in context 'profile=temp-full-ha'; Possible registration points for this capability: [Host Controller] /profile=*/subsystem=jgroups [Host Controller]
      14:13:39,203 ERROR [org.jboss.as.controller] (Controller Boot Thread) WFLYCTL0362: Capabilities required by resource '/profile=temp-full-ha/subsystem=infinispan/cache-container=ejb/transport=jgroups' are not available: [Host Controller] org.wildfly.clustering.jgroups.default-channel-factory in context 'profile=temp-full-ha'; Possible registration points for this capability: [Host Controller] /profile=*/subsystem=jgroups [Host Controller]
      14:13:39,215 FATAL [org.jboss.as.host.controller] (Controller Boot Thread) WFLYHC0034: Host Controller boot has failed in an unrecoverable manner; exiting. See previous messages for details. [Host Controller]
      14:13:39,217 FATAL [org.jboss.as.host.controller] (Controller Boot Thread) WFLYHC0178: Aborting with exit code 99 [Host Controller]
      14:13:39,265 INFO [org.jboss.as] (MSC service thread 1-3) WFLYSRV0050: JBoss EAP 7.1.1.GA (WildFly Core 3.0.12.Final-redhat-1) stopped in 26ms [Host Controller]
      14:13:39,611 INFO [org.jboss.as.process.Host Controller.status] (reaper for Host Controller) WFLYPC0011: Process 'Host Controller' finished with an exit status of 99
      14:13:39,613 INFO [org.jboss.as.process] (Thread-8) WFLYPC0017: Shutting down process controller 14:13:39,613 INFO [org.jboss.as.process] (Thread-8) WFLYPC0016: All processes finished; exiting
      

      Can this error be improved to better direct the user to the issue?

            [WFCORE-3766] Improve error message if a parent profile references a child profile's value

            Moulali Shikalwadi added a comment - HI rhn-support-bmaxwell  Thanks, Could you please https://issues.redhat.com/browse/JBEAP-14681 as well?

            Brad Maxwell added a comment - - edited

            mshikalw  The reason this particular example fails is the profile used is full-ha which defines the jgroups / infinispan subsystem, the base-full-ha defines the messaging subsystem which needs jgroups / infinispan which is not defined in that profile.  So one fix for this config is to copy the jgroups / infinispan subsystem into the base-full-ha profile.

            So the enhancement is to see if we can better indicate to the user what the issue is.

                 <profile name="full-ha" includes="base-full-ha">
                        <subsystem xmlns="urn:jboss:domain:jgroups:7.0">
                        <subsystem xmlns="urn:jboss:domain:infinispan:9.0">
                    <profile name="base-full-ha">
                        <subsystem xmlns="urn:jboss:domain:messaging-activemq:8.0">

             

            I ran the example with CD20 and the error has improved , it no longer says temp

            [Host Controller] 10:48:45,897 ERROR [org.jboss.as.controller] (Controller Boot Thread) WFLYCTL0362: Capabilities required by resource '/profile=base-full-ha/subsystem=messaging-activemq/server=default/jgroups-broadcast-group=bg-group1' are not available:
            [Host Controller]     org.wildfly.clustering.default-command-dispatcher-factory in context 'profile=base-full-ha'; Possible registration points for this capability: 
            [Host Controller] 		/profile=*/subsystem=infinispan
            [Host Controller] 		/profile=*/subsystem=jgroups
            [Host Controller] 10:48:45,897 ERROR [org.jboss.as.controller] (Controller Boot Thread) WFLYCTL0362: Capabilities required by resource '/profile=base-full-ha/subsystem=messaging-activemq/server=default/jgroups-discovery-group=dg-group1' are not available:
            [Host Controller]     org.wildfly.clustering.default-command-dispatcher-factory in context 'profile=base-full-ha'; Possible registration points for this capability: 
            [Host Controller] 		/profile=*/subsystem=infinispan
            [Host Controller] 		/profile=*/subsystem=jgroups
            [Host Controller] 10:48:45,898 ERROR [org.jboss.as.controller] (Controller Boot Thread) WFLYCTL0362: Capabilities required by resource '/profile=base-full-ha/subsystem=singleton/singleton-policy=default' are not available:
            [Host Controller]     org.wildfly.clustering.cache.default-singleton-service-configurator-factory.server in context 'profile=base-full-ha'; Possible registration points for this capability: 
            [Host Controller] 		/profile=*/subsystem=infinispan/cache-container=*  

             

            Brad Maxwell added a comment - - edited mshikalw   The reason this particular example fails is the profile used is full-ha which defines the jgroups / infinispan subsystem, the base-full-ha defines the messaging subsystem which needs jgroups / infinispan which is not defined in that profile.  So one fix for this config is to copy the jgroups / infinispan subsystem into the base-full-ha profile. So the enhancement is to see if we can better indicate to the user what the issue is.     <profile name= "full-ha" includes= "base-full-ha" >             <subsystem xmlns= "urn:jboss:domain:jgroups:7.0" >             <subsystem xmlns= "urn:jboss:domain:infinispan:9.0" >         <profile name= "base-full-ha" >             <subsystem xmlns= "urn:jboss:domain:messaging-activemq:8.0" >   I ran the example with CD20 and the error has improved , it no longer says temp [Host Controller] 10:48:45,897 ERROR [org.jboss.as.controller] (Controller Boot Thread ) WFLYCTL0362: Capabilities required by resource '/profile=base-full-ha/subsystem=messaging-activemq/server= default /jgroups-broadcast-group=bg-group1' are not available: [Host Controller]     org.wildfly.clustering. default -command-dispatcher-factory in context 'profile=base-full-ha' ; Possible registration points for this capability: [Host Controller] /profile=*/subsystem=infinispan [Host Controller] /profile=*/subsystem=jgroups [Host Controller] 10:48:45,897 ERROR [org.jboss.as.controller] (Controller Boot Thread ) WFLYCTL0362: Capabilities required by resource '/profile=base-full-ha/subsystem=messaging-activemq/server= default /jgroups-discovery-group=dg-group1' are not available: [Host Controller]     org.wildfly.clustering. default -command-dispatcher-factory in context 'profile=base-full-ha' ; Possible registration points for this capability: [Host Controller] /profile=*/subsystem=infinispan [Host Controller] /profile=*/subsystem=jgroups [Host Controller] 10:48:45,898 ERROR [org.jboss.as.controller] (Controller Boot Thread ) WFLYCTL0362: Capabilities required by resource '/profile=base-full-ha/subsystem=singleton/singleton-policy= default ' are not available: [Host Controller]     org.wildfly.clustering.cache. default -singleton-service-configurator-factory.server in context 'profile=base-full-ha' ; Possible registration points for this capability: [Host Controller] /profile=*/subsystem=infinispan/cache-container=*  

            The weakness is this:

            Possible registration points for this capability: 
                 /profile=*/subsystem=jgroups
            

            That can be misinterpreted as meaning any old profile will do. But actually only certain profiles will suffice. Listing those in some way would be good.

            This needs thorough discussion before any work should begin; the above does not capture subtle points about how capability resolution works and what data is available. Not discussing first is likely to lead to unacceptable solutions.

            Brian Stansberry added a comment - The weakness is this: Possible registration points for this capability: /profile=*/subsystem=jgroups That can be misinterpreted as meaning any old profile will do. But actually only certain profiles will suffice. Listing those in some way would be good. This needs thorough discussion before any work should begin; the above does not capture subtle points about how capability resolution works and what data is available. Not discussing first is likely to lead to unacceptable solutions.

              mshikalw Moulali Shikalwadi
              rhn-support-bmaxwell Brad Maxwell
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: