feroult / yawp

Kotlin/Java API framework for Google Appengine
http://yawp.io
MIT License
131 stars 19 forks source link

Error while mvn yawp:devserver #94

Closed thusithathilina closed 7 years ago

thusithathilina commented 8 years ago

When try to run using mvn yawp:devserver I'm getting below exception

[INFO] --- yawp-maven-plugin:1.6.3:devserver (default-cli) @ testyawp --- Jul 07, 2016 12:18:49 PM org.sonatype.guice.bean.reflect.Logs$JULSink warn WARNING: Error injecting: io.yawp.plugin.mojos.devserver.DevServerMojo com.google.inject.ProvisionException: Guice provision errors:

1) No implementation for org.eclipse.aether.RepositorySystem was bound. while locating io.yawp.plugin.mojos.devserver.DevServerMojo

1 error at com.google.inject.internal.InjectorImpl$3.get(InjectorImpl.java:999) at com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1025) at org.sonatype.guice.bean.reflect.AbstractDeferredClass.get(AbstractDeferredClass.java:45) at com.google.inject.internal.ProviderInternalFactory.provision(ProviderInternalFactory.java:84) at com.google.inject.internal.InternalFactoryToInitializableAdapter.provision(InternalFactoryToInitializableAdapter.java:52) at com.google.inject.internal.ProviderInternalFactory$1.call(ProviderInternalFactory.java:70) at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:100) at org.sonatype.guice.plexus.lifecycles.PlexusLifecycleManager.onProvision(PlexusLifecycleManager.java:138) at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:108) at com.google.inject.internal.ProvisionListenerStackCallback.provision(ProvisionListenerStackCallback.java:55) at com.google.inject.internal.ProviderInternalFactory.circularGet(ProviderInternalFactory.java:68) at com.google.inject.internal.InternalFactoryToInitializableAdapter.get(InternalFactoryToInitializableAdapter.java:45) at com.google.inject.internal.InjectorImpl$3$1.call(InjectorImpl.java:990) at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1036) at com.google.inject.internal.InjectorImpl$3.get(InjectorImpl.java:986) at com.google.inject.Scopes$1$1.get(Scopes.java:59) at org.sonatype.guice.bean.locators.LazyBeanEntry.getValue(LazyBeanEntry.java:83) at org.sonatype.guice.plexus.locators.LazyPlexusBean.getValue(LazyPlexusBean.java:49) at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:253) at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:245) at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getConfiguredMojo(DefaultMavenPluginManager.java:455) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:92) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209) 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:320) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156) at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537) at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196) at org.apache.maven.cli.MavenCli.main(MavenCli.java:141) 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)

[INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 0.893s [INFO] Finished at: Thu Jul 07 12:18:49 IST 2016 [INFO] Final Memory: 14M/981M [INFO] ------------------------------------------------------------------------ [ERROR] Failed to execute goal io.yawp:yawp-maven-plugin:1.6.3:devserver (default-cli) on project testyawp: Execution default-cli of goal io.yawp:yawp-maven-plugin:1.6.3:devserver failed: Unable to load the mojo 'devserver' (or one of its required components) from the plugin 'io.yawp:yawp-maven-plugin:1.6.3': com.google.inject.ProvisionException: Guice provision errors: [ERROR] [ERROR] 1) No implementation for org.eclipse.aether.RepositorySystem was bound. [ERROR] while locating io.yawp.plugin.mojos.devserver.DevServerMojo [ERROR] at ClassRealm[plugin>io.yawp:yawp-maven-plugin:1.6.3, parent: sun.misc.Launcher$AppClassLoader@4e25154f] [ERROR] while locating org.apache.maven.plugin.Mojo annotated with @com.google.inject.name.Named(value=io.yawp:yawp-maven-plugin:1.6.3:devserver) [ERROR] [ERROR] 1 error [ERROR] role: org.apache.maven.plugin.Mojo [ERROR] roleHint: io.yawp:yawp-maven-plugin:1.6.3:devserver [ERROR] -> [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/PluginContainerException

feroult commented 8 years ago

@thusithathilina thank you for your report!

Can you provide some info about your environment?

Did you run mvn clean install before running the devserver?

As an workaround untill we solve this, you may run mvn appengine:devserver to use the regular Google devserver plugin, which won't give some hot deploy features and it will be a little bit slower, but works as well.

thusithathilina commented 8 years ago

@feroult OS - Ubuntu 14.04 JDK - 1.8.0 Maven - 3.0.5 Yeah i tried mvn clean install before running. But getting the same error.

I couldn't try mvn appengine:devserver since I need to upgrade my mvn version to 3.1.0.

feroult commented 8 years ago

Hi @thusithathilina,

Except for the maven version, I believe this is a nice and pretty tested environment. Our continuous integration runs on a setup really close to this.

Since the yawp and appengine devserver plugins need some maven features to detect where the Appengine SDK is located in the filesystem, I'm afraid you will have to upgrade to maven 3.3 or newer.

Actually, this is the class that does the trick: SdkResolver.java

Is it possible to test it and give us a feedback if it works?

Thank you again,

Regards

feroult commented 7 years ago

Hi @thusithathilina, I'm closing this issue. If you still have the problem, please feel free to re-open it again.