Skip to content

Commit

Permalink
Omit VirtualThreadSchedulerMXBean in builds for valuetypes
Browse files Browse the repository at this point in the history
Signed-off-by: Keith W. Campbell <[email protected]>
  • Loading branch information
keithc-ca committed Oct 17, 2024
1 parent 64cb0db commit 4978707
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@
import com.sun.management.HotSpotDiagnosticMXBean;
/*[ENDIF] JAVA_SPEC_VERSION >= 21 */

/*[IF JAVA_SPEC_VERSION >= 24]*/
/*[IF (JAVA_SPEC_VERSION >= 24) & !INLINE-TYPES]*/
import com.sun.management.internal.VirtualThreadSchedulerImpls;
import jdk.management.VirtualThreadSchedulerMXBean;
/*[ENDIF] JAVA_SPEC_VERSION >= 24 */
/*[ENDIF] (JAVA_SPEC_VERSION >= 24) & !INLINE-TYPES */

/**
* This class implements the service-provider interface to make OpenJ9-specific
Expand Down Expand Up @@ -123,11 +123,11 @@ public final class PlatformMBeanProvider extends sun.management.spi.PlatformMBea
.register(allComponents);
/*[ENDIF] JAVA_SPEC_VERSION >= 21 */

/*[IF JAVA_SPEC_VERSION >= 24]*/
/*[IF (JAVA_SPEC_VERSION >= 24) & !INLINE-TYPES]*/
ComponentBuilder.create("jdk.management:type=VirtualThreadScheduler", VirtualThreadSchedulerImpls.create()) //$NON-NLS-1$
.addInterface(VirtualThreadSchedulerMXBean.class)
.register(allComponents);
/*[ENDIF] JAVA_SPEC_VERSION >= 24 */
/*[ENDIF] (JAVA_SPEC_VERSION >= 24) & !INLINE-TYPES */

// register beans with zero or more instances

Expand Down

0 comments on commit 4978707

Please sign in to comment.