private final boolean xa;
public DataSourceDisable(boolean xa) {
super();
this.xa = xa;
}
<BUG>public void execute(OperationContext context, ModelNode operation) {
final ModelNode model = context.readResourceForUpdate(PathAddress.EMPTY_ADDRESS).getModel();

model.get(ENABLED).set(false);
if (context.isNormalServer()) {
if (context.isResourceServiceRestartAllowed()) {</BUG>
context.addStep(new OperationStepHandler() {

private final boolean xa;
public DataSourceDisable(boolean xa) {
super();
this.xa = xa;
}
public void execute(OperationContext context, ModelNode operation) {
final ManagementResourceRegistration datasourceRegistration = context.getResourceRegistrationForUpdate();
final Resource resource = context.readResourceForUpdate(PathAddress.EMPTY_ADDRESS);
final ModelNode model = resource.getModel();
model.get(ENABLED).set(false);
if (context.isNormalServer()) {
DataSourceStatisticsListener.removeStatisticsResources(resource);
if (context.isResourceServiceRestartAllowed()) {
context.addStep(new OperationStepHandler() {
