apache / apache/maven

[MNG-8343] Use OSGi Converter instead of Plexus for Mojo parameter conversion

Open
#10,285 0 comments 0 reactions 0 assignees View on GitHub
enhancement priority:major
Dominant language
Java
Stars
5.3k
Forks
3.1k
Avg merge
20h 42m
Merged PRs (30d)
297

Description

**[Konrad Windszus](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=kwin)** opened **[MNG-8343](https://issues.apache.org/jira/browse/MNG-8343?redirect=false)** and commented

Currently (even in Maven 4) the API being used for converting from a String to another type for Mojo parameters is the [Plexus Configurator API](https://eclipse.dev/sisu/org.eclipse.sisu.plexus/configuration.html). I propose to switch to something which is better maintained and documented.
There is the [OSGi Converter Specification](https://docs.osgi.org/specification/osgi.cmpn/7.0.0/util.converter.html) and a default implementation at https://central.sonatype.com/artifact/org.osgi/org.osgi.util.converter/1.0.9 which supports most of the conversions already supported by Plexus Configuration API out of the box.
The implementation does not require any additional dependencies.
In addition it supports [custom converters](https://docs.osgi.org/specification/osgi.cmpn/7.0.0/util.converter.html#util.converter-customizing.converters).

---
No further details from [MNG-8343](https://issues.apache.org/jira/browse/MNG-8343?redirect=false)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.