@Override protected boolean requiresRuntime(OperationContext context) { return context.getProcessType().isServer(); } }
@Override protected boolean requiresRuntime(OperationContext context) { return context.getProcessType().isServer(); } }
@Override protected void populateModel(final OperationContext context, final ModelNode operation, final Resource resource) throws OperationFailedException { if (context.getProcessType().isServer()) { DataSourceStatisticsService.registerStatisticsResources(resource); } super.populateModel(context, operation, resource); }
@Override protected void validateUpdatedModel(final OperationContext context, final Resource resource) throws OperationFailedException { final ModelNode model = resource.getModel(); if (!context.getProcessType().equals(ProcessType.HOST_CONTROLLER)) { final List<String> propertiesToReject = new LinkedList<String>(); for (final AttributeDefinition attribute : JacORBSubsystemDefinitions.ON_OFF_ATTRIBUTES_TO_REJECT) { if (model.hasDefined(attribute.getName()) && model.get(attribute.getName()).equals(JacORBSubsystemDefinitions.DEFAULT_ENABLED_PROPERTY)) { propertiesToReject.add(attribute.getName()); } } for (final AttributeDefinition attribute : JacORBSubsystemDefinitions.ATTRIBUTES_TO_REJECT) { if (model.hasDefined(attribute.getName())) { propertiesToReject.add(attribute.getName()); } } if (!propertiesToReject.isEmpty()) { throw JacORBLogger.ROOT_LOGGER.cannotEmulateProperties(propertiesToReject); } } }
removeJacorbSubsystem(jacorbAddress, migrateOperations, context.getProcessType() == ProcessType.STANDALONE_SERVER);
SecurityLogger.ROOT_LOGGER.activatingSecuritySubsystem(); if(context.getProcessType() != ProcessType.APPLICATION_CLIENT) {
if (context.getProcessType().isServer() && !context.isBooting() && name.equals("ejb")) { PathElement ejbPath = PathElement.pathElement(ModelDescriptionConstants.SUBSYSTEM, "ejb3"); Resource ejbResource = safeGetResource(context, ejbPath);
if (context.getProcessType().isServer() && !context.isBooting()) { if (context.readResourceFromRoot(address.getParent(),false).hasChild(PathElement.pathElement(ModelDescriptionConstants.SUBSYSTEM, "infinispan"))) {
@Override protected void populateModel(final OperationContext context, final ModelNode operation, final Resource resource) throws OperationFailedException { final ModelNode model = resource.getModel(); for (AttributeDefinition attr : attributes) { attr.validateAndSet(operation, model); } ConfigValidator.validateConfig(context, TransformUtils.transformModel(model)); final boolean adminOnly = context.getRunningMode() == RunningMode.ADMIN_ONLY; final boolean hostController = context.getProcessType().equals(ProcessType.HOST_CONTROLLER); // in case of unsupported configuration parameters: // in admin mode they are all logged as warning to enable fixes before migrate operation // standalone server in normal mode is shutted down with exception as it is unable to run with specified configuration // domain controller in normal mode works normally - it may send old parameters to legacy hosts - such configuration is // valid if (adminOnly || !hostController) { final List<String> unsupportedProperites = TransformUtils.validateDeprecatedProperites(model); if(!unsupportedProperites.isEmpty()) { if (adminOnly) { final String warning = JacORBLogger.ROOT_LOGGER.cannotEmulatePropertiesWarning(unsupportedProperites); JacORBLogger.ROOT_LOGGER.warn(warning); } else { throw JacORBLogger.ROOT_LOGGER.cannotEmulateProperties(unsupportedProperites); } } } }
if (context.getProcessType() == ProcessType.STANDALONE_SERVER) { final ConsoleRedirectService redirectService = new ConsoleRedirectService(); final ServiceBuilder<ConsoleRedirectService> redirectBuilder = context.getServiceTarget().addService(consoleRedirectName, redirectService)
final boolean appclient = context.getProcessType() == ProcessType.APPLICATION_CLIENT;
.install(); final boolean appclient = context.getProcessType() == ProcessType.APPLICATION_CLIENT;
protected void performBoottime(OperationContext context, ModelNode operation, ModelNode model) { final boolean appclient = context.getProcessType() == ProcessType.APPLICATION_CLIENT; final RaDeploymentActivator raDeploymentActivator = new RaDeploymentActivator(appclient); context.addStep(new AbstractDeploymentChainStep() {
processorTarget.addDeploymentProcessor(EeExtension.SUBSYSTEM_NAME, Phase.STRUCTURE, Phase.STRUCTURE_MANAGED_BEAN_JAR_IN_EAR, new ManagedBeanSubDeploymentMarkingProcessor()); processorTarget.addDeploymentProcessor(EeExtension.SUBSYSTEM_NAME, Phase.STRUCTURE, Phase.STRUCTURE_EAR_SUB_DEPLYOMENTS_ISOLATED, isolationProcessor); processorTarget.addDeploymentProcessor(EeExtension.SUBSYSTEM_NAME, Phase.STRUCTURE, Phase.STRUCTURE_EE_MODULE_INIT, new EEModuleInitialProcessor(context.getProcessType() == ProcessType.APPLICATION_CLIENT)); processorTarget.addDeploymentProcessor(EeExtension.SUBSYSTEM_NAME, Phase.STRUCTURE, Phase.STRUCTURE_EE_RESOURCE_INJECTION_REGISTRY, new ResourceReferenceRegistrySetupProcessor()); processorTarget.addDeploymentProcessor(EeExtension.SUBSYSTEM_NAME, Phase.STRUCTURE, Phase.STRUCTURE_GLOBAL_MODULES, moduleDependencyProcessor);
@Override protected boolean requiresRuntime(OperationContext context) { return context.getProcessType() != ProcessType.EMBEDDED_SERVER || context.getRunningMode() != RunningMode.ADMIN_ONLY; } }
/** * Gets whether this operation needs to update the runtime. The default implementation returns {@code true} * if {@link OperationContext#getProcessType()#isHostController()} is false. * * @param context the operation context * @return {@code true} if the operation should update the runtime; {@code false} if it only updates the configuration * model */ protected boolean requiresRuntime(OperationContext context) { return !context.getProcessType().isHostController(); }
static boolean isVisible(OperationEntry operationEntry, OperationContext context) { Set<OperationEntry.Flag> flags = operationEntry.getFlags(); return operationEntry.getType() == OperationEntry.EntryType.PUBLIC && !flags.contains(OperationEntry.Flag.HIDDEN) && (context.getProcessType() != ProcessType.DOMAIN_SERVER || flags.contains(OperationEntry.Flag.RUNTIME_ONLY) || flags.contains(OperationEntry.Flag.READ_ONLY)); } }
@Override protected boolean requiresRuntime(OperationContext context) { return super.requiresRuntime(context) && (context.getProcessType() != ProcessType.EMBEDDED_SERVER || context.getRunningMode() != RunningMode.ADMIN_ONLY); }
/** * Creates a new {@code TransformationInputs} from the given operation context. * @param context the operation context. Cannot be {@code null} */ public TransformationInputs(OperationContext context) { this.originalModel = context.readResourceFromRoot(PathAddress.EMPTY_ADDRESS, true); this.registration = context.getRootResourceRegistration(); this.processType = context.getProcessType(); this.runningMode = context.getRunningMode(); this.transformerOperationAttachment = context.getAttachment(TransformerOperationAttachment.KEY); }
@Override protected boolean requiresRuntime(OperationContext context) { if (context.getProcessType().isServer()) { return super.requiresRuntime(context); } //Check if we are a host's socket binding and install the service if we are PathAddress pathAddress = context.getCurrentAddress(); return pathAddress.size() > 0 && pathAddress.getElement(0).getKey().equals(HOST); }