[jboss-jira] [JBoss JIRA] (WFLY-3955) Non-persistent overlay gets persisted later
Stan Silvert (JIRA)
issues at jboss.org
Wed Oct 8 14:57:11 EDT 2014
[ https://issues.jboss.org/browse/WFLY-3955?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Stan Silvert updated WFLY-3955:
-------------------------------
Description:
In an add handler at startup, I have code that creates a non-persistent overlay like this:
{code}
private void addOverlay(OperationContext context) throws OperationFailedException {
PathAddress overlayAddress = PathAddress.pathAddress(PathElement.pathElement(DEPLOYMENT_OVERLAY, overlayName));
ModelNode addOp = Util.createOperation(ADD, overlayAddress);
addOp.get(PERSISTENT).set(false);
context.addStep(addOp, getAddHandler(context, overlayAddress), OperationContext.Stage.MODEL);
}
private OperationStepHandler getAddHandler(OperationContext context, PathAddress address) {
ImmutableManagementResourceRegistration rootResourceRegistration = context.getRootResourceRegistration();
return rootResourceRegistration.getOperationHandler(address, ADD);
}
{code}
addOverlay() is called from the populateModel() method of my Add Handler. This works fine and creates the overlay without persisting to standalone.xml.
However, if I deploy any WAR then the overlay is written out to standalone.xml.
I can get you some better test code if you need it later.
was:
In an add handler at startup, I have code that creates a non-persistent overlay like this:
{code}
private void addOverlay(OperationContext context) throws OperationFailedException {
PathAddress overlayAddress = PathAddress.pathAddress(PathElement.pathElement(DEPLOYMENT_OVERLAY, overlayName));
ModelNode addOp = Util.createOperation(ADD, overlayAddress);
addOp.get(PERSISTENT).set(false);
context.addStep(addOp, getAddHandler(context, overlayAddress), OperationContext.Stage.MODEL);
}
private OperationStepHandler getAddHandler(OperationContext context, PathAddress address) {
ImmutableManagementResourceRegistration rootResourceRegistration = context.getRootResourceRegistration();
return rootResourceRegistration.getOperationHandler(address, ADD);
}
{code}
This works fine and creates the overlay without persisting to standalone.xml.
However, if I deploy any WAR then the overlay is written out to standalone.xml.
I can get you some better test code if you need it later.
> Non-persistent overlay gets persisted later
> -------------------------------------------
>
> Key: WFLY-3955
> URL: https://issues.jboss.org/browse/WFLY-3955
> Project: WildFly
> Issue Type: Bug
> Components: Domain Management
> Affects Versions: 8.1.0.Final, 9.0.0.Alpha1
> Reporter: Stan Silvert
> Assignee: Stuart Douglas
>
> In an add handler at startup, I have code that creates a non-persistent overlay like this:
> {code}
> private void addOverlay(OperationContext context) throws OperationFailedException {
> PathAddress overlayAddress = PathAddress.pathAddress(PathElement.pathElement(DEPLOYMENT_OVERLAY, overlayName));
> ModelNode addOp = Util.createOperation(ADD, overlayAddress);
> addOp.get(PERSISTENT).set(false);
> context.addStep(addOp, getAddHandler(context, overlayAddress), OperationContext.Stage.MODEL);
> }
> private OperationStepHandler getAddHandler(OperationContext context, PathAddress address) {
> ImmutableManagementResourceRegistration rootResourceRegistration = context.getRootResourceRegistration();
> return rootResourceRegistration.getOperationHandler(address, ADD);
> }
> {code}
> addOverlay() is called from the populateModel() method of my Add Handler. This works fine and creates the overlay without persisting to standalone.xml.
> However, if I deploy any WAR then the overlay is written out to standalone.xml.
> I can get you some better test code if you need it later.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
More information about the jboss-jira
mailing list