hostRegistration.registerReadOnlyAttribute(ServerRootResourceDefinition.SCHEMA_LOCATIONS, null); hostRegistration.registerReadWriteAttribute(HostResourceDefinition.NAME, environment.getProcessNameReadHandler(), environment.getProcessNameWriteHandler()); hostRegistration.registerReadOnlyAttribute(HostResourceDefinition.RUNTIME_CONFIGURATION_STATE, new ProcessStateAttributeHandler(processState)); hostRegistration.registerReadOnlyAttribute(HostResourceDefinition.HOST_STATE, new ProcessStateAttributeHandler(processState)); hostRegistration.registerReadOnlyAttribute(ServerRootResourceDefinition.RUNNING_MODE, new RunningModeReadHandler(runningModeControl)); hostRegistration.registerReadOnlyAttribute(ServerRootResourceDefinition.SUSPEND_STATE, SuspendStateReadHandler.INSTANCE);
hostRegistration.registerReadOnlyAttribute(ServerRootResourceDefinition.SCHEMA_LOCATIONS, null); hostRegistration.registerReadWriteAttribute(HostResourceDefinition.NAME, environment.getProcessNameReadHandler(), environment.getProcessNameWriteHandler()); hostRegistration.registerReadOnlyAttribute(HostResourceDefinition.RUNTIME_CONFIGURATION_STATE, new ProcessStateAttributeHandler(processState)); hostRegistration.registerReadOnlyAttribute(HostResourceDefinition.HOST_STATE, new ProcessStateAttributeHandler(processState)); hostRegistration.registerReadOnlyAttribute(ServerRootResourceDefinition.RUNNING_MODE, new RunningModeReadHandler(runningModeControl)); hostRegistration.registerReadOnlyAttribute(ServerRootResourceDefinition.SUSPEND_STATE, SuspendStateReadHandler.INSTANCE);
resourceRegistration.registerReadOnlyAttribute(RUNTIME_CONFIGURATION_STATE, new ProcessStateAttributeHandler(processState)); resourceRegistration.registerReadOnlyAttribute(SERVER_STATE, new ProcessStateAttributeHandler(processState)); resourceRegistration.registerReadOnlyAttribute(PROCESS_TYPE, ProcessTypeHandler.INSTANCE); resourceRegistration.registerReadOnlyAttribute(RUNNING_MODE, new RunningModeReadHandler(runningModeControl));
resourceRegistration.registerReadOnlyAttribute(RUNTIME_CONFIGURATION_STATE, new ProcessStateAttributeHandler(processState)); resourceRegistration.registerReadOnlyAttribute(SERVER_STATE, new ProcessStateAttributeHandler(processState)); resourceRegistration.registerReadOnlyAttribute(PROCESS_TYPE, ProcessTypeHandler.INSTANCE); resourceRegistration.registerReadOnlyAttribute(RUNNING_MODE, new RunningModeReadHandler(runningModeControl));
@Override public void registerAttributes(ManagementResourceRegistration hostRegistration) { super.registerAttributes(hostRegistration); hostRegistration.registerReadWriteAttribute(DIRECTORY_GROUPING, null, new ReloadRequiredWriteAttributeHandler(DIRECTORY_GROUPING)); hostRegistration.registerReadOnlyAttribute(PRODUCT_NAME, null); hostRegistration.registerReadOnlyAttribute(SERVER_STATE, null); hostRegistration.registerReadOnlyAttribute(RELEASE_VERSION, null); hostRegistration.registerReadOnlyAttribute(RELEASE_CODENAME, null); hostRegistration.registerReadOnlyAttribute(PRODUCT_VERSION, null); hostRegistration.registerReadOnlyAttribute(MANAGEMENT_MAJOR_VERSION, null); hostRegistration.registerReadOnlyAttribute(MANAGEMENT_MINOR_VERSION, null); hostRegistration.registerReadOnlyAttribute(MANAGEMENT_MICRO_VERSION, null); hostRegistration.registerReadOnlyAttribute(MASTER, IsMasterHandler.INSTANCE); hostRegistration.registerReadOnlyAttribute(DOMAIN_CONTROLLER, null); hostRegistration.registerReadOnlyAttribute(ServerRootResourceDefinition.NAMESPACES, null); hostRegistration.registerReadOnlyAttribute(ServerRootResourceDefinition.SCHEMA_LOCATIONS, null); hostRegistration.registerReadWriteAttribute(HostResourceDefinition.NAME, environment.getProcessNameReadHandler(), environment.getProcessNameWriteHandler()); hostRegistration.registerReadOnlyAttribute(HostResourceDefinition.HOST_STATE, new ProcessStateAttributeHandler(processState)); hostRegistration.registerReadOnlyAttribute(ServerRootResourceDefinition.RUNNING_MODE, new RunningModeReadHandler(runningModeControl)); }
@Override public void registerAttributes(ManagementResourceRegistration resourceRegistration) { if (serverEnvironment != null) { // TODO eliminate test cases that result in serverEnviroment == null if (isDomain) { resourceRegistration.registerReadOnlyAttribute(NAME, serverEnvironment.getProcessNameReadHandler()); resourceRegistration.registerReadWriteAttribute(PROFILE_NAME, null, new ModelOnlyWriteAttributeHandler(PROFILE_NAME)); } else { resourceRegistration.registerReadWriteAttribute(NAME, serverEnvironment.getProcessNameReadHandler(), serverEnvironment.getProcessNameWriteHandler()); // The legacy "undefined" profile-name resourceRegistration.registerReadOnlyAttribute(NULL_PROFILE_NAME, null); } resourceRegistration.registerReadOnlyAttribute(LAUNCH_TYPE, new LaunchTypeHandler(serverEnvironment.getLaunchType())); } resourceRegistration.registerReadOnlyAttribute(SERVER_STATE, new ProcessStateAttributeHandler(processState)); resourceRegistration.registerReadOnlyAttribute(PROCESS_TYPE, ProcessTypeHandler.INSTANCE); resourceRegistration.registerReadOnlyAttribute(RUNNING_MODE, new RunningModeReadHandler(runningModeControl)); resourceRegistration.registerReadOnlyAttribute(MANAGEMENT_MAJOR_VERSION, null); resourceRegistration.registerReadOnlyAttribute(MANAGEMENT_MINOR_VERSION, null); resourceRegistration.registerReadOnlyAttribute(MANAGEMENT_MICRO_VERSION, null); resourceRegistration.registerReadOnlyAttribute(RELEASE_VERSION, null); resourceRegistration.registerReadOnlyAttribute(RELEASE_CODENAME, null); resourceRegistration.registerReadOnlyAttribute(PRODUCT_NAME, null); resourceRegistration.registerReadOnlyAttribute(PRODUCT_VERSION, null); resourceRegistration.registerReadOnlyAttribute(NAMESPACES, DefaultEmptyListAttributeHandler.INSTANCE); resourceRegistration.registerReadOnlyAttribute(SCHEMA_LOCATIONS, DefaultEmptyListAttributeHandler.INSTANCE); }
@Override public void registerAttributes(ManagementResourceRegistration resourceRegistration) { if (serverEnvironment != null) { // TODO eliminate test cases that result in serverEnvironment == null if (isDomain) { resourceRegistration.registerReadOnlyAttribute(NAME, serverEnvironment.getProcessNameReadHandler()); resourceRegistration.registerReadWriteAttribute(PROFILE_NAME, null, new ModelOnlyWriteAttributeHandler(PROFILE_NAME)); } else { resourceRegistration.registerReadWriteAttribute(NAME, serverEnvironment.getProcessNameReadHandler(), serverEnvironment.getProcessNameWriteHandler()); // The legacy "undefined" profile-name resourceRegistration.registerReadOnlyAttribute(NULL_PROFILE_NAME, null); } resourceRegistration.registerReadOnlyAttribute(LAUNCH_TYPE, new LaunchTypeHandler(serverEnvironment.getLaunchType())); } resourceRegistration.registerReadOnlyAttribute(SERVER_STATE, new ProcessStateAttributeHandler(processState)); resourceRegistration.registerReadOnlyAttribute(PROCESS_TYPE, ProcessTypeHandler.INSTANCE); resourceRegistration.registerReadOnlyAttribute(RUNNING_MODE, new RunningModeReadHandler(runningModeControl)); resourceRegistration.registerReadOnlyAttribute(MANAGEMENT_MAJOR_VERSION, null); resourceRegistration.registerReadOnlyAttribute(MANAGEMENT_MINOR_VERSION, null); resourceRegistration.registerReadOnlyAttribute(MANAGEMENT_MICRO_VERSION, null); resourceRegistration.registerReadOnlyAttribute(RELEASE_VERSION, null); resourceRegistration.registerReadOnlyAttribute(RELEASE_CODENAME, null); resourceRegistration.registerReadOnlyAttribute(PRODUCT_NAME, null); resourceRegistration.registerReadOnlyAttribute(PRODUCT_VERSION, null); resourceRegistration.registerReadOnlyAttribute(NAMESPACES, DefaultEmptyListAttributeHandler.INSTANCE); resourceRegistration.registerReadOnlyAttribute(SCHEMA_LOCATIONS, DefaultEmptyListAttributeHandler.INSTANCE); if (isDomain) { resourceRegistration.registerReadOnlyAttribute(HOST, null); resourceRegistration.registerReadOnlyAttribute(SERVER_GROUP, null); } }