Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compatibility with Maven 4? #46

Open
reckart opened this issue Sep 26, 2024 · 1 comment
Open

Compatibility with Maven 4? #46

reckart opened this issue Sep 26, 2024 · 1 comment

Comments

@reckart
Copy link
Contributor

reckart commented Sep 26, 2024

I have the impression that the p2-layout-resolver may not be compatible with Maven 4. I have been testing Maven 4 on several projects and my feeling is that the main difference between the project where it works and where it doesn't work is the presence of the p2-layout-resolver.

However, the error I get does not have the p2-layout-resolver on its stack trace:

[ERROR] Internal error: java.lang.IllegalArgumentException: Unknown extensible enum value 'xml' -> [Help 1]
org.apache.maven.InternalErrorException: Internal error: java.lang.IllegalArgumentException: Unknown extensible enum value 'xml'
    at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:157)
    at org.apache.maven.cli.MavenCli.execute(MavenCli.java:981)
    at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:291)
    at org.apache.maven.cli.MavenCli.main(MavenCli.java:208)
    at jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
    at java.lang.reflect.Method.invoke(Method.java:580)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:255)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:201)
    at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:361)
    at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:314)
Caused by: java.lang.IllegalArgumentException: Unknown extensible enum value 'xml'
    at org.apache.maven.api.services.ExtensibleEnumRegistry.lambda$require$0(ExtensibleEnumRegistry.java:33)
    at java.util.Optional.orElseThrow(Optional.java:403)
    at org.apache.maven.api.services.ExtensibleEnumRegistry.require(ExtensibleEnumRegistry.java:33)
    at org.apache.maven.internal.impl.DefaultTypeRegistry.lambda$require$1(DefaultTypeRegistry.java:94)
    at java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1708)
    at org.apache.maven.internal.impl.DefaultTypeRegistry.require(DefaultTypeRegistry.java:87)
    at org.apache.maven.internal.impl.DefaultTypeRegistry.lookup(DefaultTypeRegistry.java:80)
    at org.apache.maven.internal.impl.DefaultPackagingRegistry.lookup(DefaultPackagingRegistry.java:88)
    at org.apache.maven.internal.impl.model.DefaultLifecycleBindingsInjector.injectLifecycleBindings(DefaultLifecycleBindingsInjector.java:69)
    at org.apache.maven.internal.impl.model.DefaultModelBuilder.build(DefaultModelBuilder.java:575)
    at org.apache.maven.internal.impl.model.DefaultModelBuilder.build(DefaultModelBuilder.java:198)
    at org.apache.maven.project.DefaultProjectBuilder$BuildSession.doBuild(DefaultProjectBuilder.java:825)
    at org.apache.maven.project.DefaultProjectBuilder$BuildSession.lambda$build$6(DefaultProjectBuilder.java:794)
    at java.util.concurrent.FutureTask.run(FutureTask.java:317)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
    at java.lang.Thread.run(Thread.java:1583)

and also, I can successfully build the p2-layout-resolver - building the example fails, but not with the error above but rather saying it cannot resolve certain artifacts.

Has anybody tried p2-layout-resolver with Maven 4 (4.0.0-beta-4) or a clue what the error above might be?

@reckart reckart changed the title Compatibility with Maven 4 Compatibility with Maven 4? Sep 26, 2024
@jesse-gallagher
Copy link
Member

Hmm, that may very well be the case. I haven't tried Maven 4 yet, but I've been meaning to, and testing this out would certainly be a good impetus to do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants