Skip to content

p2MavenMetadataHandling is not configurable and always defaults to "validate" #6145

Description

@andrew-tram

The InjectP2MavenMetadataHandling option (values ignore, inject, validate) is fully implemented: the enum and TargetPlatformConfiguration.setP2MavenMetadataHandling(...) exist, and P2DependencyResolver honors each mode. However, DefaultTargetPlatformConfigurationReader never reads it from target-platform-configuration, so the setter has no callers and the value is permanently stuck on the default, validate.

In validate mode, P2DependencyResolver.resolveDescriptorWithValidation(...) calls dependenciesResolver.resolveArtifact(...) for every mapped p2 artifact. On a large target platform that is one remote Maven lookup per plugin and feature across all configured repositories, each miss logging Mapping P2 > Maven Coordinates failed: ... (and the related Unable to create Maven project for p2.eclipse.plugin:... warnings). This adds significant build time and log noise, with no way to turn it off.

Wire the existing <p2MavenMetadataHandling> option into DefaultTargetPlatformConfigurationReader (same pattern as referencedRepositoryMode) so users can set inject (map coordinates without remote resolution) or ignore. The default can stay validate for backward compatibility.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions