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

enunciate 2.0.0.M1 failing to generate docs #103

Closed
Garagoth opened this issue Aug 13, 2015 · 3 comments
Closed

enunciate 2.0.0.M1 failing to generate docs #103

Garagoth opened this issue Aug 13, 2015 · 3 comments
Labels
Milestone

Comments

@Garagoth
Copy link

I tried running enunciate on several different projects, but I was not successfull.
mvn enunciate:assemble (or any other goal) first downloads tons of source jars, then fails as shown below:

[INFO] --- enunciate-maven-plugin:2.0.0-M.1:docs (default-cli) @ NewCRM ---
(... downloads lots of -source.jar ...)
[INFO] Reflections took 1760 ms to scan 94 urls, producing 9139 keys and 9139 values 
/home/garagoth/.m2/repository/net/sf/ehcache/ehcache/2.10.0/ehcache-2.10.0-sources.jar(net/sf/ehcache/statistics/extended/ExtendedStatisticsImpl.java):39: error: cannot access Query
import org.terracotta.context.query.Query;
                                   ^
  bad source file: /home/garagoth/.m2/repository/net/sf/ehcache/ehcache/2.10.0/ehcache-2.10.0-sources.jar(org/terracotta/context/query/Query.java)
    file does not contain class org.terracotta.context.query.Query
    Please remove or make sure it appears in the correct subdirectory of the sourcepath.
/home/garagoth/.m2/repository/net/sf/ehcache/ehcache/2.10.0/ehcache-2.10.0-sources.jar(net/sf/ehcache/util/concurrent/LongAdder.java):40: error: duplicate class: net.sf.ehcache.util.concurrent.LongAdder
public class LongAdder extends Striped64 implements Serializable {
       ^
/home/garagoth/.m2/repository/net/sf/ehcache/ehcache/2.10.0/ehcache-2.10.0-sources.jar(org/terracotta/statistics/derived/EventParameterSimpleMovingAverage.java):27: error: cannot access LongAdder
import org.terracotta.statistics.jsr166e.LongAdder;
                                        ^
  bad source file: /home/garagoth/.m2/repository/net/sf/ehcache/ehcache/2.10.0/ehcache-2.10.0-sources.jar(org/terracotta/statistics/jsr166e/LongAdder.java)
    file does not contain class org.terracotta.statistics.jsr166e.LongAdder
    Please remove or make sure it appears in the correct subdirectory of the sourcepath.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.webcohesion.enunciate:enunciate-maven-plugin:2.0.0-M.1:docs (default-cli) on project NewCRM: Execution default-cli of goal com.webcohesion.enunciate:enunciate-maven-plugin:2.0.0-M.1:docs failed: Enunciate compile failed. -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal com.webcohesion.enunciate:enunciate-maven-plugin:2.0.0-M.1:docs (default-cli) on project NewCRM: Execution default-cli of goal com.webcohesion.enunciate:enunciate-maven-plugin:2.0.0-M.1:docs failed: Enunciate compile failed.
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:224)
        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:116)
        at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
        at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)
        at org.apache.maven.cli.MavenCli.execute(MavenCli.java:862)
        at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:286)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:197)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:497)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: org.apache.maven.plugin.PluginExecutionException: Execution default-cli of goal com.webcohesion.enunciate:enunciate-maven-plugin:2.0.0-M.1:docs failed: Enunciate compile failed.
        at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:145)
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
        ... 20 more
Caused by: com.webcohesion.enunciate.EnunciateException: Enunciate compile failed.
        at com.webcohesion.enunciate.Enunciate.run(Enunciate.java:586)
        at com.webcohesion.enunciate.mojo.ConfigMojo.execute(ConfigMojo.java:304)
        at com.webcohesion.enunciate.mojo.DocsBaseMojo.execute(DocsBaseMojo.java:62)
        at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
        ... 21 more

For different projects, it fails on different classes, but pattern is the same.

Regards,
Garagoth.

@stoicflame stoicflame modified the milestones: v2.0.0, v2.0.0.M2 Aug 14, 2015
stoicflame added a commit that referenced this issue Aug 17, 2015
@stoicflame
Copy link
Owner

Please retry with Milestone 2; I believe this issue might have been fixed.

Feel free to re-open if the issue persists.

@Garagoth
Copy link
Author

With .M2 following happens:

[INFO] Reflections took 1975 ms to scan 209 urls, producing 13523 keys and 13523 values 
[INFO] [ENUNCIATE] Skipping generation of Java client sources as everything appears up-to-date...
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 10.213 s
[INFO] Finished at: 2015-08-20T15:22:22+02:00
[INFO] Final Memory: 99M/340M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.webcohesion.enunciate:enunciate-maven-plugin:2.0.0-M.2:assemble (default-cli) on project API: Execution default-cli of goal com.webcohesion.enunciate:enunciate-maven-plugin:2.0.0-M.2:assemble failed: java.lang.IllegalStateException: OnError while emitting onNext value: com.webcohesion.enunciate.EnunciateContext.class -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutionException
Exception in thread "pool-1-thread-1" java.lang.NoClassDefFoundError: com/webcohesion/enunciate/modules/java_xml_client/EnunciateJavaXMLClientModule$2
        at com.webcohesion.enunciate.modules.java_xml_client.EnunciateJavaXMLClientModule.processTemplate(EnunciateJavaXMLClientModule.java:299)
        at com.webcohesion.enunciate.modules.java_xml_client.EnunciateJavaXMLClientModule.generateClientSources(EnunciateJavaXMLClientModule.java:169)
        at com.webcohesion.enunciate.modules.java_xml_client.EnunciateJavaXMLClientModule.call(EnunciateJavaXMLClientModule.java:117)
        at com.webcohesion.enunciate.io.InvokeEnunciateModule.onNext(InvokeEnunciateModule.java:31)
        at com.webcohesion.enunciate.io.InvokeEnunciateModule.onNext(InvokeEnunciateModule.java:10)
        at rx.internal.operators.OperatorDoOnEach$1.onNext(OperatorDoOnEach.java:79)
        at rx.internal.operators.OperatorSingle$ParentSubscriber.onCompleted(OperatorSingle.java:109)
        at rx.internal.operators.NotificationLite.accept(NotificationLite.java:140)
        at rx.internal.operators.TakeLastQueueProducer.emit(TakeLastQueueProducer.java:100)
        at rx.internal.operators.TakeLastQueueProducer.startEmitting(TakeLastQueueProducer.java:45)
        at rx.internal.operators.OperatorTakeLast$1.onCompleted(OperatorTakeLast.java:59)
        at rx.internal.operators.OperatorMerge$MergeSubscriber.drainAndComplete(OperatorMerge.java:521)
        at rx.internal.operators.OperatorMerge$MergeSubscriber.completeInner(OperatorMerge.java:486)
        at rx.internal.operators.OperatorMerge$InnerSubscriber.emit(OperatorMerge.java:658)
        at rx.internal.operators.OperatorMerge$InnerSubscriber.onCompleted(OperatorMerge.java:600)
        at rx.internal.operators.OperatorMerge$MergeSubscriber.drainAndComplete(OperatorMerge.java:521)
        at rx.internal.operators.OperatorMerge$MergeSubscriber.completeInner(OperatorMerge.java:486)
        at rx.internal.operators.OperatorMerge$InnerSubscriber.emit(OperatorMerge.java:673)
        at rx.internal.operators.OperatorMerge$InnerSubscriber.onCompleted(OperatorMerge.java:600)
        at rx.internal.operators.OperatorMerge$MergeSubscriber.drainAndComplete(OperatorMerge.java:521)
        at rx.internal.operators.OperatorMerge$MergeSubscriber.completeInner(OperatorMerge.java:486)
        at rx.internal.operators.OperatorMerge$InnerSubscriber.emit(OperatorMerge.java:673)
        at rx.internal.operators.OperatorMerge$InnerSubscriber.onCompleted(OperatorMerge.java:600)
        at rx.internal.util.ScalarSynchronousObservable$ScalarSynchronousAction.call(ScalarSynchronousObservable.java:117)
        at rx.schedulers.ExecutorScheduler$ExecutorAction.run(ExecutorScheduler.java:173)
        at rx.schedulers.ExecutorScheduler$ExecutorSchedulerWorker.run(ExecutorScheduler.java:99)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.ClassNotFoundException: com.webcohesion.enunciate.modules.java_xml_client.EnunciateJavaXMLClientModule$2
        at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:50)
        at org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass(ClassRealm.java:271)
        at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:247)
        at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:239)
        ... 29 more

@Garagoth
Copy link
Author

And with another project this happens:

[INFO] --- enunciate-maven-plugin:2.0.0-M.2:assemble (default-cli) @ NewCRM ---
Downloading: http://10.10.20.11:8081/nexus/content/groups/public/com/google/code/findbugs/annotations/2.0.1/annotations-2.0.1-sources.jar
Downloading: https://repo.maven.apache.org/maven2/com/google/code/findbugs/annotations/2.0.1/annotations-2.0.1-sources.jar
[INFO] Reflections took 1087 ms to scan 94 urls, producing 9139 keys and 9139 values 
[WARNING] [ENUNCIATE] Java source file com/fasterxml/jackson/databind/introspect/VisibilityChecker.java will not be included on the classpath because it is found in multiple locations: 
/home/garagoth/.m2/repository/net/sf/ehcache/ehcache/2.10.0/ehcache-2.10.0-sources.jar(net/sf/ehcache/statistics/extended/ExtendedStatisticsImpl.java):39: error: cannot access Query
import org.terracotta.context.query.Query;
                                   ^
  bad source file: /home/garagoth/.m2/repository/net/sf/ehcache/ehcache/2.10.0/ehcache-2.10.0-sources.jar(org/terracotta/context/query/Query.java)
    file does not contain class org.terracotta.context.query.Query
    Please remove or make sure it appears in the correct subdirectory of the sourcepath.
/home/garagoth/.m2/repository/net/sf/ehcache/ehcache/2.10.0/ehcache-2.10.0-sources.jar(net/sf/ehcache/util/concurrent/LongAdder.java):40: error: duplicate class: net.sf.ehcache.util.concurrent.LongAdder
public class LongAdder extends Striped64 implements Serializable {
       ^
/home/garagoth/.m2/repository/net/sf/ehcache/ehcache/2.10.0/ehcache-2.10.0-sources.jar(org/terracotta/statistics/derived/EventParameterSimpleMovingAverage.java):27: error: cannot access LongAdder
import org.terracotta.statistics.jsr166e.LongAdder;
                                        ^
  bad source file: /home/garagoth/.m2/repository/net/sf/ehcache/ehcache/2.10.0/ehcache-2.10.0-sources.jar(org/terracotta/statistics/jsr166e/LongAdder.java)
    file does not contain class org.terracotta.statistics.jsr166e.LongAdder
    Please remove or make sure it appears in the correct subdirectory of the sourcepath.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.681 s
[INFO] Finished at: 2015-08-20T15:25:24+02:00
[INFO] Final Memory: 28M/241M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.webcohesion.enunciate:enunciate-maven-plugin:2.0.0-M.2:assemble (default-cli) on project NewCRM: Execution default-cli of goal com.webcohesion.enunciate:enunciate-maven-plugin:2.0.0-M.2:assemble failed: Enunciate compile failed. -> [Help 1]

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

No branches or pull requests

2 participants