Skip to content

Add ability to manage start modules by java feature #5492

Closed
@joakime

Description

@joakime

Jetty version
9.4.x

Description
When writing optional modules that depend on Java features (like alpn or loom) you currently have to rely on the ${java.version.platform} start property.
Which means you wind up having multiple *.mod files, one for each major version of java, just to enable/disable modules based on a feature in java.

Proposal is to add new "features" properties to start.jar

aka:

// features built into java.
properties.setProperty("java.feature.alpn", Boolean.toString(ver.getPlatform() >= 9), source);
properties.setProperty("java.feature.jpms", Boolean.toString(ver.getPlatform() >= 9), source);
properties.setProperty("java.feature.loom", Boolean.toString(ver.getPlatform() >= 16), source);

That way we can simplify the maintenance of optional modules.

Metadata

Metadata

Assignees

No one assigned

    Labels

    EnhancementStaleFor auto-closed stale issues and pull requests

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions