Maven 2 & 3

Pom Extensions not supported for Toolchains

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Minor Minor
  • Resolution: Fixed
  • Affects Version/s: 2.0.9
  • Fix Version/s: 2.0.9
  • Component/s: None
  • Labels:
    None
  • Number of attachments :
    0

Description

When I add a pom extension referening a jar containing an implementation of a toolchain and toolchain factory, the toolchain plugin does not pick up my extensions. I get an exception on mvn install:

Caused by: java.lang.ClassNotFoundException: org.apache.maven.dotnet.extensions.toolchain.DotnetToolchainFactory

Activity

Hide
Shane Isbell added a comment -

I tried the toolchain in 2.1 and it looks as though the extensions work in that version but then I get:

java.lang.ClassCastException: org.apache.maven.dotnet.extensions.toolchain.DotnetToolchain cannot be cast to org.apache.maven.dotnet.extensions.toolchain.Dotnet
Toolchain at org.apache.maven.dotnet.plugin.compiler.CompilerMojo.execute(CompilerMojo.java:127)

I get the same exception in 2.0.9 if I put my jar containing the dotnet toolchain directly in the maven/lib directory.

Show
Shane Isbell added a comment - I tried the toolchain in 2.1 and it looks as though the extensions work in that version but then I get: java.lang.ClassCastException: org.apache.maven.dotnet.extensions.toolchain.DotnetToolchain cannot be cast to org.apache.maven.dotnet.extensions.toolchain.Dotnet Toolchain at org.apache.maven.dotnet.plugin.compiler.CompilerMojo.execute(CompilerMojo.java:127) I get the same exception in 2.0.9 if I put my jar containing the dotnet toolchain directly in the maven/lib directory.
Hide
Shane Isbell added a comment -

Using a scope of provided for my dotnet toolchain extension jar, solves the class cast exception (comment above). So everything works in 2.1. I'm just left with the original problem of getting the extension picked up for 2.0.9.

Show
Shane Isbell added a comment - Using a scope of provided for my dotnet toolchain extension jar, solves the class cast exception (comment above). So everything works in 2.1. I'm just left with the original problem of getting the extension picked up for 2.0.9.
Hide
Milos Kleint added a comment -

MNG-3464 should fix this one as well.

Show
Milos Kleint added a comment - MNG-3464 should fix this one as well.

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: