1 Reply Latest reply on Nov 29, 2016 5:09 AM by Tomaz Cerar

    how to disable an https listener via jboss-cli

    Joshua Zhu Newbie

      Recently we upgraded from JBoss 7.1 to Wildfly 10, and running into an issue.

       

      There are two https connectors (listeners), call them "foo" and "bar, respectively, and depending on a certain mode, we would enable only "foo", only "bar", or both "foo" and "bar" dynamically.

       

      In JBoss 7.1, we were able to accomplish this using jboss-cli to set the value of attribute "enabled" and reload the server:

       

      /subsystem=web/connector=foo:write-attribute(name=enabled,value=true/false)

      /subsystem=web/connector=bar:write-attribute(name=enabled,value=true/false)

       

      In Wildfly, we do the same thing, only with appropriate configuration path change:

       

      /subsystem=undertow/server=default-server/https-listeners=foo:write-attribute(name=enabled,value=true/false)

      /subsystem=undertow/server=default-server/https-listeners=bar:write-attribute(name=enabled,value=true/false)

       

      When both "foo" and "bar" are enabled, server would  startup correctly. However, if either "foo" or "bar" is disabled, server would not startup correctly. There is no error message in the log file, only clue being that there are a lot fewer log entries during startup, and at the end, complaining a few "services failed or missing dependencies", but not specifically which services failed.

       

      Any advice on what we may not do correctly, or suggestion on an alternative way to enable/disable an https listener (short of adding/removing them)?

       

      Thanks in advance