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

RestartParent OperationStepHandler implementations are incompatible with service built via CapabilityServiceTarget

XMLWordPrintable

      Many subsystem utilize the RestartParentResourceAddHandler, RestartParentResourceRemoveHandler, and RestartParentWriteAttributeHandler to restart the services of the parent resource. Users typically override the following method:

          protected void recreateParentService(OperationContext context, PathAddress parentAddress, ModelNode parentModel) throws OperationFailedException{
          }
      

      However, in the cases:

      org.wildfly.extension.undertow.CrawlerSessionManagementDefinition
      org.wildfly.extension.undertow.JspDefinition
      org.wildfly.extension.undertow.PersistentSessionsDefinition
      org.wildfly.extension.undertow.AbstractSessionCookieDefinition
      org.wildfly.extension.undertow.WebsocketsDefinition
      

      ... the parent service is installed via the CapabilityServiceTarget, which generates its ServiceName using the PathAddress of the current OperationContext. However, the OperationContext parameter above refers to the operation of the child resource, not the parent. Consequently, these use cases will result in broken behavior, since the reinstalled parent service will be install with an incorrect ServiceName.

              pferraro@redhat.com Paul Ferraro
              pferraro@redhat.com Paul Ferraro
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: