Skip to content

Make some java platform modules optional #2910

@XakepSDK

Description

@XakepSDK

Is your feature request related to a problem? Please describe.
Jackson module descriptor implicitly depends on these modules:

  1. requires java.desktop
  2. requires java.logging
  3. requires java.sql
  4. requires java.xml
    Can they become optional?

Describe the solution you'd like
Make these modules optional

  1. requires static java.desktop
  2. requires static java.logging
  3. requires static java.sql
  4. requires static java.xml
    This may require some code changes, since making module optional means that module may not be present at runtime.
    So code should check, if relevant classes are present.

Usage example
jlink and jpackage will produce smaller images. java.sql itself brings 10MB+ of dependencies, according to this google/gson#1707 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions