void addStepToUploadServerWar(OperationContext context) throws OperationFailedException { PathAddress deploymentAddress = deploymentAddress(deploymentName); ModelNode op = Util.createOperation(ADD, deploymentAddress); // this is required for deployment to take place op.get(ENABLED).set(true); // prevents writing this deployment out to standalone.xml op.get(PERSISTENT).set(false); // Owner attribute is valid starting with WidlFly 9. Ignored in WildFly 8 op.get("owner").set(new ModelNode().add("subsystem", KeycloakExtension.SUBSYSTEM_NAME)); if (serverWar == null) { throw new OperationFailedException("Keycloak Server WAR not found in keycloak-server-subsystem module"); } op.get(CONTENT).add(makeContentItem()); context.addStep(op, getHandler(context, deploymentAddress, ADD), OperationContext.Stage.MODEL); }
void addStepToUploadServerWar(OperationContext context) throws OperationFailedException { PathAddress deploymentAddress = deploymentAddress(deploymentName); ModelNode op = Util.createOperation(ADD, deploymentAddress); // this is required for deployment to take place op.get(ENABLED).set(true); // prevents writing this deployment out to standalone.xml op.get(PERSISTENT).set(false); // Owner attribute is valid starting with WidlFly 9. Ignored in WildFly 8 op.get("owner").set(new ModelNode().add("subsystem", KeycloakExtension.SUBSYSTEM_NAME)); if (serverWar == null) { throw new OperationFailedException("Keycloak Server WAR not found in keycloak-server-subsystem module"); } op.get(CONTENT).add(makeContentItem()); context.addStep(op, getHandler(context, deploymentAddress, ADD), OperationContext.Stage.MODEL); }
private static void addDeploymentAction(OperationContext context, String operation, String deploymentName) { if (!context.isNormalServer()) { return; } PathAddress deploymentAddress = deploymentAddress(deploymentName); ModelNode op = Util.createOperation(operation, deploymentAddress); op.get(RUNTIME_NAME).set(deploymentName); context.addStep(op, getHandler(context, deploymentAddress, operation), OperationContext.Stage.MODEL); }
private static void addDeploymentAction(OperationContext context, String operation, String deploymentName) { if (!context.isNormalServer()) { return; } PathAddress deploymentAddress = deploymentAddress(deploymentName); ModelNode op = Util.createOperation(operation, deploymentAddress); op.get(RUNTIME_NAME).set(deploymentName); context.addStep(op, getHandler(context, deploymentAddress, operation), OperationContext.Stage.MODEL); }