maven-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Petar Tahchiev <paranoia...@gmail.com>
Subject ParseException when compiling a MOJO
Date Sat, 03 May 2014 16:36:00 GMT
Hi guys,

I'm working on a maven plugin here, and I have a spring configuration that
looks like this:
-------------------------
@Configuration
@ComponentScan(basePackages = { "com.test"})
public class MyMavenPluginConfig extends WebSecurityConfigurerAdapter {
}
-------------------------

This all compiles fine. Then what I do is I add a filter type:
-------------------------
@Configuration
@ComponentScan(basePackages = { "com.test"}, includeFilters =
{@ComponentScan.Filter(type = FilterType.REGEX, pattern = "*.core.*")})
public class MyMavenPluginConfig extends WebSecurityConfigurerAdapter {
}
-------------------------

and I try to compile it, but I get this exception:

[ERROR] Failed to execute goal
org.codehaus.plexus:plexus-maven-plugin:1.3.8:descriptor (default) on
project my-maven-plugin: Failed to extract descriptors: syntax error
@[34,95] in
file:/C:/workspace/test/platform/my-maven-plugin/src/main/java/com/test/maven/plugin/config/MyMavenPluginConfig.java
-> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute
goal org.codehaus.plexus:plexus-maven-plugin:1.3.8:descriptor (default) on
project my-maven-plug
in: Failed to extract descriptors
        at
org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:216)
        at
org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
        at
org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
        at
org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
        at
org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
        at
org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
        at
org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:318)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:153)
        at org.apache.maven.cli.MavenCli.execute(MavenCli.java:555)
        at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:214)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:158)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:606)
        at
org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
        at
org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
        at
org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:414)
        at
org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:357)
Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to
extract descriptors
        at
org.codehaus.plexus.maven.plugin.AbstractDescriptorMojo.generateDescriptor(AbstractDescriptorMojo.java:137)
        at
org.codehaus.plexus.maven.plugin.PlexusDescriptorMojo.execute(PlexusDescriptorMojo.java:60)
        at
org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:106)
        at
org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
        ... 19 more
Caused by: com.thoughtworks.qdox.parser.ParseException: syntax error
@[34,95] in
file:/C:/workspace/test/platform/my-maven-plugin/src/main/java/com/test/maven/plugi
n/config/MyMavenPluginConfig.java
        at com.thoughtworks.qdox.parser.impl.Parser.yyerror(Parser.java:716)
        at com.thoughtworks.qdox.parser.impl.Parser.yyparse(Parser.java:826)
        at com.thoughtworks.qdox.parser.impl.Parser.parse(Parser.java:697)
        at
com.thoughtworks.qdox.JavaDocBuilder.addSource(JavaDocBuilder.java:300)
        at
com.thoughtworks.qdox.JavaDocBuilder.addSource(JavaDocBuilder.java:316)
        at
com.thoughtworks.qdox.JavaDocBuilder.addSource(JavaDocBuilder.java:312)
        at
com.thoughtworks.qdox.JavaDocBuilder$1.visitFile(JavaDocBuilder.java:369)
        at
com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:43)
        at
com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
        at
com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
        at
com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
        at
com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
        at
com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
        at
com.thoughtworks.qdox.directorywalker.DirectoryScanner.walk(DirectoryScanner.java:34)
        at
com.thoughtworks.qdox.directorywalker.DirectoryScanner.scan(DirectoryScanner.java:52)
        at
com.thoughtworks.qdox.JavaDocBuilder.addSourceTree(JavaDocBuilder.java:366)
        at
org.codehaus.plexus.maven.plugin.SourceComponentDescriptorExtractor.extract(SourceComponentDescriptorExtractor.java:91)
        at
org.codehaus.plexus.maven.plugin.SourceComponentDescriptorExtractor.extract(SourceComponentDescriptorExtractor.java:74)
        at
org.codehaus.plexus.maven.plugin.AbstractDescriptorMojo.generateDescriptor(AbstractDescriptorMojo.java:131)
        ... 22 more
[ERROR]
[ERROR] Re-run Maven using the -X switch to enable full debug logging.



-- 
Regards, Petar!
Karlovo, Bulgaria.
---
Public PGP Key at:
https://keyserver1.pgp.com/vkd/DownloadKey.event?keyid=0x19658550C3110611
Key Fingerprint: A369 A7EE 61BC 93A3 CDFF  55A5 1965 8550 C311 0611

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message