I am using nodenv to manage my node versions.
On my jhipster project, when I package my app on my terminal with :
mvn package -Pprod -Dmaven.test.skip=true
It works fine
But when I package the app from Intellij with the same mvn command, I am getting :
[INFO]
[INFO] --- yeoman-maven-plugin:0.5:build (run-frontend-build) # tecfel ---
[INFO] node version :
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 5.429 s
[INFO] Finished at: 2018-03-14T14:12:04+01:00
[INFO] Final Memory: 47M/541M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.github.trecloux:yeoman-maven-plugin:0.5:build (run-frontend-build) on project tecfel: Error during : node --version: Cannot run program "node" (in directory "/home/myApp/Documents/workspace/tecfel"): error=2, Aucun fichier ou dossier de ce type -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal com.github.trecloux:yeoman-maven-plugin:0.5:build (run-frontend-build) on project tecfel: Error during : node --version
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:212)
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:863)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)
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:498)
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)
at org.codehaus.classworlds.Launcher.main(Launcher.java:47)
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:498)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:147)
Caused by: org.apache.maven.plugin.MojoExecutionException: Error during : node --version
at com.github.trecloux.yeoman.YeomanMojo.executeCommand(YeomanMojo.java:129)
at com.github.trecloux.yeoman.YeomanMojo.logToolVersion(YeomanMojo.java:105)
at com.github.trecloux.yeoman.YeomanMojo.npmInstall(YeomanMojo.java:84)
at com.github.trecloux.yeoman.YeomanMojo.execute(YeomanMojo.java:68)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)
Does any one knows why?
Your problem is that IntelliJ does not use nodenv.
You seem to run a very old version of JHipster build process as we have stopped using yeoman-maven-plugin a long time ago, consider updating your project or at least copy/inspire from a recent generated project that use https://github.com/eirslett/frontend-maven-plugin The main benefit from using this plugin is that in prod profile it uses its own copy of node/npm binaries installed in your project and so is completely isolated from your running context.
Related
I've use Apache Zeppelin 0.8.1.
I want user Groovy interpreter. And use #Grape dep menagement:
%groovy
#Grapes([
#Grab('com.github.twosigma.beakerx:beaker-kernel-groovy:0.9.0')
])
import com.twosigma.beakerx.widget.IntSlider
But got error:
java.lang.RuntimeException: Failed to parse groovy script: java.lang.NoClassDefFoundError: org/apache/ivy/Ivy
at org.apache.zeppelin.groovy.GroovyInterpreter.getGroovyScript(GroovyInterpreter.java:140)
Reasonable. By official documentation of Dependency Management for Interpreter I've provide artifact dep: org.apache.ivy:ivy:2.5.0-rc1:
In repositories I have enabled Central (http://repo1.maven.org/maven2/) which have that artifact:
But on interpreter restarting and notebook reload I just got error: Error setting properties for interpreter 'groovy.groovy': Cannot fetch dependencies for org.apache.ivy:ivy:2.5.0-rc1:
I have tried (as experiment, not long-term solution) enter into zeppelin docker container and download http://repo1.maven.org/maven2/org/apache/ivy/ivy/2.5.0-rc1/ivy-2.5.0-rc1.jar into /zeppelin/interpreter/groovy, restart interpreter, reload nootebook and it looks like groovy try resolve deps - i see progress-bar for second, but then again got error:
java.lang.RuntimeException: Failed to parse groovy script: org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed: General error during conversion: Error grabbing Grapes -- [unresolved dependency: com.github.twosigma.beakerx#beaker-kernel-groovy;0.9.0: not found] java.lang.RuntimeException: Error grabbing Grapes -- [unresolved dependency: com.github.twosigma.beakerx#beaker-kernel-groovy;0.9.0: not found] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:423) at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:83) at org.codehaus.groovy.reflection.CachedConstructor.doConstructorInvoke(CachedConstructor.java:77) at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrap.callConstructor(ConstructorSite.java:84) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallConstructor(CallSiteArray.java:60) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:235) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:247) at groovy.grape.GrapeIvy.getDependencies(GrapeIvy.groovy:426) 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:498) at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite$PogoCachedMethodSite.invoke(PogoMetaMethodSite.java:169) at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite.callCurrent(PogoMetaMethodSite.java:59) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:52) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:154) at groovy.grape.GrapeIvy.resolve(GrapeIvy.groovy:573) at groovy.grape.GrapeIvy$resolve$1.callCurrent(Unknown Source) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:52) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:154) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:190) at groovy.grape.GrapeIvy.resolve(GrapeIvy.groovy:540) at groovy.grape.GrapeIvy$resolve$0.callCurrent(Unknown Source) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:52) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:154) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:182) at groovy.grape.GrapeIvy.grab(GrapeIvy.groovy:258) at groovy.grape.Grape.grab(Grape.java:167) at groovy.grape.GrabAnnotationTransformation.visit(GrabAnnotationTransformation.java:378) at org.codehaus.groovy.transform.ASTTransformationVisitor$3.call(ASTTransformationVisitor.java:321) at org.codehaus.groovy.control.CompilationUnit.applyToSourceUnits(CompilationUnit.java:931) at org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:593) at org.codehaus.groovy.control.CompilationUnit.processPhaseOperations(CompilationUnit.java:569) at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:546) at groovy.lang.GroovyClassLoader.doParseClass(GroovyClassLoader.java:298) at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:268) at groovy.lang.GroovyShell.parseClass(GroovyShell.java:688) at groovy.lang.GroovyShell.parse(GroovyShell.java:700) at groovy.lang.GroovyShell.parse(GroovyShell.java:736) at org.apache.zeppelin.groovy.GroovyInterpreter.getGroovyScript(GroovyInterpreter.java:133) at org.apache.zeppelin.groovy.GroovyInterpreter.interpret(GroovyInterpreter.java:155) at org.apache.zeppelin.interpreter.LazyOpenInterpreter.interpret(LazyOpenInterpreter.java:103) at org.apache.zeppelin.interpreter.remote.RemoteInterpreterServer$InterpretJob.jobRun(RemoteInterpreterServer.java:632) at org.apache.zeppelin.scheduler.Job.run(Job.java:188) at org.apache.zeppelin.scheduler.ParallelScheduler$JobRunner.run(ParallelScheduler.java:162) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748) 1 error at org.apache.zeppelin.groovy.GroovyInterpreter.getGroovyScript(GroovyInterpreter.java:140)
It looks like groovy does not see repository configurations and try resolve dependencies only locally.
What I should setup to change that?
groovy in zeppelin not designed to support #Grab
your artifact is present in a specific repository
http://maven.imagej.net/content/repositories/public/
check this artifact search engine:
https://mvnrepository.com/artifact/com.github.twosigma.beakerx/beaker-kernel-groovy/0.9.0
so, just add a new repo to zeppelin
UPD:
for org.apache.ivy:ivy:2.5.0-rc1 there are a lot of dependencies downloaded
and one of them fails. Here is what I see in console:
Error while downloading repos for interpreter group : groovy,
go to interpreter setting page click on edit and save it again
to make this interpreter work properly:
Cannot fetch dependencies for org.apache.ivy:ivy:2.5.0-rc1
...
Caused by: org.sonatype.aether.resolution.DependencyResolutionException:
Could not find artifact com.jcraft:jsch.agentproxy:jar:0.0.9 in central
(http://repo1.maven.org/maven2/)
...
(IHMO it's a bug of zeppelin)
but to make it work set
artifact= org.apache.ivy:ivy:2.4.0
exclude= com.jcraft:jsch.agentproxy
this is error text: I using windows an xampp server
*****2017-05-31 14:33:41,401 ERROR restartedMain o.s.b.SpringApplication:815 - Application startup failed
org.springframework.context.ApplicationContextException: Failed to
start bean 'outputBindingLifecycle'; nested exception is
org.springframework.cloud.stream.binder.BinderException: E xception
thrown while building outbound endpoint at
org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:178)
at
org.springframework.context.support.DefaultLifecycleProcessor.access$200(DefaultLifecycleProcessor.java:50)
at
org.springframework.context.support.DefaultLifecycleProcessor$LifecycleGroup.start(DefaultLifecycleProcessor.java:348)
at
org.springframework.context.support.DefaultLifecycleProcessor.startBeans(DefaultLifecycleProcessor.java:151)
at
org.springframework.context.support.DefaultLifecycleProcessor.onRefresh(DefaultLifecycleProcessor.java:114)
at
org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:879)
at
org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.finishRefresh(EmbeddedWebApplicationContext.java:144)
at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:545)
at
org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:122)
at
org.springframework.boot.SpringApplication.refresh(SpringApplication.java:737)
at
org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:370)
at
org.springframework.boot.SpringApplication.run(SpringApplication.java:314)
at
com.mgm.example.easysample.EasysampleApp.main(EasysampleApp.java:68)
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:483) at
org.springframework.boot.devtools.restart.RestartLauncher.run(RestartLauncher.java:49)
Caused by: org.springframework.cloud.stream.binder.BinderException:
Exception thrown while building outbound endpoint at
org.springframework.cloud.stream.binder.AbstractMessageChannelBinder.doBindProducer(AbstractMessageChannelBinder.java:122)
at
org.springframework.cloud.stream.binder.AbstractMessageChannelBinder.doBindProducer(AbstractMessageChannelBinder.java:55)
at
org.springframework.cloud.stream.binder.AbstractBinder.bindProducer(AbstractBinder.java:152)
at
org.springframework.cloud.stream.binding.BindingService.bindProducer(BindingService.java:125)
at
org.springframework.cloud.stream.binding.BindableProxyFactory.bindOutputs(BindableProxyFactory.java:238)
at
org.springframework.cloud.stream.binding.OutputBindingLifecycle.start(OutputBindingLifecycle.java:57)
at
org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:175)
... 17 common frames omitted Caused by:
org.I0Itec.zkclient.exception.ZkTimeoutException: Unable to connect to
zookeeper server within timeout: 10000 at
org.I0Itec.zkclient.ZkClient.connect(ZkClient.java:1232) at
org.I0Itec.zkclient.ZkClient.(ZkClient.java:156) at
org.I0Itec.zkclient.ZkClient.(ZkClient.java:130) at
kafka.utils.ZkUtils$.createZkClientAndConnection(ZkUtils.scala:76) at
kafka.utils.ZkUtils$.apply(ZkUtils.scala:58) at
kafka.utils.ZkUtils.apply(ZkUtils.scala) at
org.springframework.cloud.stream.binder.kafka.provisioning.KafkaTopicProvisioner.createTopicAndPartitions(KafkaTopicProvisioner.java:169)
at
org.springframework.cloud.stream.binder.kafka.provisioning.KafkaTopicProvisioner.createTopicsIfAutoCreateEnabledAndAdminUtilsPresent(KafkaTopicProvisioner.java:153)
at
org.springframework.cloud.stream.binder.kafka.provisioning.KafkaTopicProvisioner.provisionProducerDestination(KafkaTopicProvisioner.java:109)
at
org.springframework.cloud.stream.binder.kafka.provisioning.KafkaTopicProvisioner.provisionProducerDestination(KafkaTopicProvisioner.java:60)
at
org.springframework.cloud.stream.binder.AbstractMessageChannelBinder.doBindProducer(AbstractMessageChannelBinder.java:108)
... 23 common frames omitted [INFO]
------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO]
------------------------------------------------------------------------ [INFO] Total time: 01:30 min [INFO] Finished at:
2017-05-31T14:33:42+04:30 [INFO] Final Memory: 66M/533M [INFO]
------------------------------------------------------------------------ enter code here*****
Based on the main error of org.I0Itec.zkclient.exception.ZkTimeoutException: Unable to connect to zookeeper server within timeout: 10000, you haven't started Zookeeper. This is a requirement if you selected the Kafka option (see JHipster's Kafka docs for more info).
The first option is to use Docker. JHipster provides docker-compose files for Zookeeper and Kafka in src/main/docker/. You can start them up by running:
docker-compose -f src/main/docker/kafka.yml up -d
The second option is to manually set up and install Kafka and Zookeeper.
Can some one tell me how to import broadleaf-commerce portlet in liferay / integration of broadleaf with liferay. I have a sample of broadleaf portlet as i see the folder structure it looks like maven project.
I am importing the project as maven project. Is this approach correct..I am newbie to liferay and starting to learn.
Project Structure After importing
Error Log After Importing the project
Keystore file 'E:\Software Backups\Coding Zone\liferayworkspace\DemoSite-Portlet-develop\admin\target\admin\WEB-INF\blc-example.keystore' doesn't exist.
[INFO]
[INFO] --- keytool-maven-plugin:1.2:genkey (genkey) # admin ---
[WARNING] Error injecting: org.codehaus.mojo.keytool.DefaultKeyTool
com.google.inject.ProvisionException: Unable to provision, see the following errors:
1) No implementation for org.codehaus.mojo.keytool.KeyToolCommandLineBuilder was bound.
while locating org.codehaus.mojo.keytool.DefaultKeyTool
1 error
at com.google.inject.internal.InjectorImpl$2.get(InjectorImpl.java:1018)
at com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1044)
at org.eclipse.sisu.space.AbstractDeferredClass.get(AbstractDeferredClass.java:48)
at com.google.inject.internal.ProviderInternalFactory.provision(ProviderInternalFactory.java:86)
at com.google.inject.internal.InternalFactoryToInitializableAdapter.provision(InternalFactoryToInitializableAdapter.java:54)
at com.google.inject.internal.ProviderInternalFactory$1.call(ProviderInternalFactory.java:70)
at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:115)
at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:133)
at com.google.inject.internal.ProvisionListenerStackCallback.provision(ProvisionListenerStackCallback.java:68)
at com.google.inject.internal.ProviderInternalFactory.circularGet(ProviderInternalFactory.java:68)
at com.google.inject.internal.InternalFactoryToInitializableAdapter.get(InternalFactoryToInitializableAdapter.java:46)
at com.google.inject.internal.ProviderToInternalFactoryAdapter$1.call(ProviderToInternalFactoryAdapter.java:46)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1066)
at com.google.inject.internal.ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:40)
at com.google.inject.internal.SingletonScope$1.get(SingletonScope.java:36)
at com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:41)
at com.google.inject.internal.InjectorImpl$2$1.call(InjectorImpl.java:1009)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1066)
at com.google.inject.internal.InjectorImpl$2.get(InjectorImpl.java:1005)
at org.eclipse.sisu.inject.LazyBeanEntry.getValue(LazyBeanEntry.java:81)
at org.eclipse.sisu.plexus.LazyPlexusBean.getValue(LazyPlexusBean.java:51)
at org.eclipse.sisu.plexus.PlexusRequirements$RequirementProvider.get(PlexusRequirements.java:250)
at org.eclipse.sisu.plexus.ProvidedPropertyBinding.injectProperty(ProvidedPropertyBinding.java:48)
at org.eclipse.sisu.bean.BeanInjector.injectMembers(BeanInjector.java:52)
at com.google.inject.internal.MembersInjectorImpl.injectMembers(MembersInjectorImpl.java:140)
at com.google.inject.internal.ConstructorInjector.provision(ConstructorInjector.java:117)
at com.google.inject.internal.ConstructorInjector.access$000(ConstructorInjector.java:32)
at com.google.inject.internal.ConstructorInjector$1.call(ConstructorInjector.java:92)
at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:115)
at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:133)
at com.google.inject.internal.ProvisionListenerStackCallback.provision(ProvisionListenerStackCallback.java:68)
at com.google.inject.internal.ConstructorInjector.construct(ConstructorInjector.java:90)
at com.google.inject.internal.ConstructorBindingImpl$Factory.get(ConstructorBindingImpl.java:269)
at com.google.inject.internal.InjectorImpl$2$1.call(InjectorImpl.java:1009)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1066)
at com.google.inject.internal.InjectorImpl$2.get(InjectorImpl.java:1005)
at com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1044)
at org.eclipse.sisu.space.AbstractDeferredClass.get(AbstractDeferredClass.java:48)
at com.google.inject.internal.ProviderInternalFactory.provision(ProviderInternalFactory.java:86)
at com.google.inject.internal.InternalFactoryToInitializableAdapter.provision(InternalFactoryToInitializableAdapter.java:54)
at com.google.inject.internal.ProviderInternalFactory$1.call(ProviderInternalFactory.java:70)
at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:115)
at org.eclipse.sisu.bean.BeanScheduler$Activator.onProvision(BeanScheduler.java:176)
at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:126)
at com.google.inject.internal.ProvisionListenerStackCallback.provision(ProvisionListenerStackCallback.java:68)
at com.google.inject.internal.ProviderInternalFactory.circularGet(ProviderInternalFactory.java:68)
at com.google.inject.internal.InternalFactoryToInitializableAdapter.get(InternalFactoryToInitializableAdapter.java:46)
at com.google.inject.internal.InjectorImpl$2$1.call(InjectorImpl.java:1009)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1059)
at com.google.inject.internal.InjectorImpl$2.get(InjectorImpl.java:1005)
at com.google.inject.internal.SingletonScope$1.get(SingletonScope.java:36)
at org.eclipse.sisu.inject.LazyBeanEntry.getValue(LazyBeanEntry.java:81)
at org.eclipse.sisu.plexus.LazyPlexusBean.getValue(LazyPlexusBean.java:51)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:263)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:255)
at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getConfiguredMojo(DefaultMavenPluginManager.java:546)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:121)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
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:498)
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)
[WARNING] Error injecting: org.codehaus.mojo.keytool.GenkeyMojo
com.google.inject.ProvisionException: Unable to provision, see the following errors:
1) No implementation for org.codehaus.mojo.keytool.KeyToolCommandLineBuilder was bound.
while locating org.codehaus.mojo.keytool.DefaultKeyTool
at ClassRealm[plugin>org.codehaus.mojo:keytool-maven-plugin:1.2, parent: sun.misc.Launcher$AppClassLoader#18b4aac2] (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
at ClassRealm[plugin>org.codehaus.mojo:keytool-maven-plugin:1.2, parent: sun.misc.Launcher$AppClassLoader#18b4aac2] (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
while locating org.codehaus.mojo.keytool.KeyTool
while locating org.codehaus.mojo.keytool.GenkeyMojo
1 error
at com.google.inject.internal.InjectorImpl$2.get(InjectorImpl.java:1018)
at com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1044)
at org.eclipse.sisu.space.AbstractDeferredClass.get(AbstractDeferredClass.java:48)
at com.google.inject.internal.ProviderInternalFactory.provision(ProviderInternalFactory.java:86)
at com.google.inject.internal.InternalFactoryToInitializableAdapter.provision(InternalFactoryToInitializableAdapter.java:54)
at com.google.inject.internal.ProviderInternalFactory$1.call(ProviderInternalFactory.java:70)
at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:115)
at org.eclipse.sisu.bean.BeanScheduler$Activator.onProvision(BeanScheduler.java:176)
at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:126)
at com.google.inject.internal.ProvisionListenerStackCallback.provision(ProvisionListenerStackCallback.java:68)
at com.google.inject.internal.ProviderInternalFactory.circularGet(ProviderInternalFactory.java:68)
at com.google.inject.internal.InternalFactoryToInitializableAdapter.get(InternalFactoryToInitializableAdapter.java:46)
at com.google.inject.internal.InjectorImpl$2$1.call(InjectorImpl.java:1009)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1059)
at com.google.inject.internal.InjectorImpl$2.get(InjectorImpl.java:1005)
at com.google.inject.internal.SingletonScope$1.get(SingletonScope.java:36)
at org.eclipse.sisu.inject.LazyBeanEntry.getValue(LazyBeanEntry.java:81)
at org.eclipse.sisu.plexus.LazyPlexusBean.getValue(LazyPlexusBean.java:51)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:263)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:255)
at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getConfiguredMojo(DefaultMavenPluginManager.java:546)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:121)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
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:498)
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] Reactor Summary:
[INFO]
[INFO] ecommerce .......................................... SUCCESS [ 0.633 s]
[INFO] core ............................................... SUCCESS [ 5.568 s]
[INFO] admin .............................................. FAILURE [ 1.691 s]
[INFO] portlet ............................................ SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 8.205 s
[INFO] Finished at: 2017-01-24T20:33:22+05:30
[INFO] Final Memory: 18M/208M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:keytool-maven-plugin:1.2:genkey (genkey) on project admin: Execution genkey of goal org.codehaus.mojo:keytool-maven-plugin:1.2:genkey failed: Unable to load the mojo 'genkey' (or one of its required components) from the plugin 'org.codehaus.mojo:keytool-maven-plugin:1.2': com.google.inject.ProvisionException: Unable to provision, see the following errors:
[ERROR]
[ERROR] 1) No implementation for org.codehaus.mojo.keytool.KeyToolCommandLineBuilder was bound.
[ERROR] while locating org.codehaus.mojo.keytool.DefaultKeyTool
[ERROR] at ClassRealm[plugin>org.codehaus.mojo:keytool-maven-plugin:1.2, parent: sun.misc.Launcher$AppClassLoader#18b4aac2] (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
[ERROR] at ClassRealm[plugin>org.codehaus.mojo:keytool-maven-plugin:1.2, parent: sun.misc.Launcher$AppClassLoader#18b4aac2] (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
[ERROR] while locating org.codehaus.mojo.keytool.KeyTool
[ERROR] while locating org.codehaus.mojo.keytool.GenkeyMojo
[ERROR] at ClassRealm[plugin>org.codehaus.mojo:keytool-maven-plugin:1.2, parent: sun.misc.Launcher$AppClassLoader#18b4aac2] (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
[ERROR] while locating org.apache.maven.plugin.Mojo annotated with #com.google.inject.name.Named(value=org.codehaus.mojo:keytool-maven-plugin:1.2:genkey)
[ERROR]
[ERROR] 1 error
[ERROR] role: org.apache.maven.plugin.Mojo
[ERROR] roleHint: org.codehaus.mojo:keytool-maven-plugin:1.2:genkey
[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
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn <goals> -rf :admin
While installing a node project through Maven-yeoman plugin I am getting this issue(in windows+eclipse) environment. I am doing clean install from Maven.
Below is stacktrace:
[ERROR] Failed to execute goal com.github.trecloux:yeoman-maven-plugin:0.4:build (default) on project myapp-web: Error during : cmd /c grunt buil
olor: Process exited with an error: 6 (Exit value: 6) -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal com.github.trecloux:yeoman-maven-plugin:0.4:build (default) on p
pf-web: Error during : cmd /c grunt build --no-color
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: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:120)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:355)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:155)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:584)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:216)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:160)
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: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.MojoExecutionException: Error during : cmd /c grunt build --no-color
at com.github.trecloux.yeoman.YeomanMojo.executeCommand(YeomanMojo.java:127)
at com.github.trecloux.yeoman.YeomanMojo.logAndExecuteCommand(YeomanMojo.java:108)
at com.github.trecloux.yeoman.YeomanMojo.build(YeomanMojo.java:97)
at com.github.trecloux.yeoman.YeomanMojo.execute(YeomanMojo.java:68)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:132)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
... 19 more
Caused by: org.apache.commons.exec.ExecuteException: Process exited with an error: 6 (Exit value: 6)
at org.apache.commons.exec.DefaultExecutor.executeInternal(DefaultExecutor.java:377)
at org.apache.commons.exec.DefaultExecutor.execute(DefaultExecutor.java:160)
at org.apache.commons.exec.DefaultExecutor.execute(DefaultExecutor.java:147)
at com.github.trecloux.yeoman.YeomanMojo.executeCommand(YeomanMojo.java:125)
... 24 more
I am trying to build Pi4J on Raspberry Pi2 model B with Arch linux ARM installed. Everything works fine, except for the build of the JNI natural libraries. Here is the error message (and part of the log):
[INFO] --- maven-antrun-plugin:1.3:run (build-native-so) # pi4j-native ---
[INFO] Executing tasks
build-libpi4j.so:
[echo] Building native libpi4j shared library for ABI: hard-float
[sshexec] Connecting to 192.168.178.94:22
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] Pi4J :: Parent POM ................................. SUCCESS [01:04 min]
[INFO] Pi4J :: JNI Native Library ......................... FAILURE [ 18.906 s]
[INFO] Pi4J :: Java Library (Core) ........................ SKIPPED
[INFO] Pi4J :: GPIO Extension ............................. SKIPPED
[INFO] Pi4J :: Device Abstractions ........................ SKIPPED
[INFO] Pi4J :: Java Examples .............................. SKIPPED
[INFO] Pi4J :: OSGi Service ............................... SKIPPED
[INFO] Pi4J :: Distribution ............................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:50 min
[INFO] Finished at: 2015-08-11T20:50:37+00:00
[INFO] Final Memory: 11M/29M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-antrun-plugin:1.3:run (build-native-so) on project pi4j-native: An Ant BuildException has occured: The following error occurred while executing this line:
[ERROR] /media/temp/pi4j-arch/pi4j-native/build.xml:10: com.jcraft.jsch.JSchException: Algorithm negotiation fail
[ERROR] -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-antrun-plugin:1.3:run (build-native-so) on project pi4j-native: An Ant BuildException has occured: The following error occurred while executing this line:
/media/temp/pi4j-arch/pi4j-native/build.xml:10: com.jcraft.jsch.JSchException: Algorithm negotiation fail
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: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.MojoExecutionException: An Ant BuildException has occured: The following error occurred while executing this line:
/media/temp/pi4j-arch/pi4j-native/build.xml:10: com.jcraft.jsch.JSchException: Algorithm negotiation fail
at org.apache.maven.plugin.antrun.AbstractAntMojo.executeTasks(AbstractAntMojo.java:131)
at org.apache.maven.plugin.antrun.AntRunMojo.execute(AntRunMojo.java:98)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
... 20 more
Caused by: The following error occurred while executing this line:
/media/temp/pi4j-arch/pi4j-native/build.xml:10: com.jcraft.jsch.JSchException: Algorithm negotiation fail
at org.apache.tools.ant.ProjectHelper.addLocationToBuildException(ProjectHelper.java:508)
at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:418)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
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.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:62)
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.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at net.sf.antcontrib.logic.IfTask.execute(Unknown Source)
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.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.TaskAdapter.execute(TaskAdapter.java:154)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
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.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:357)
at org.apache.maven.plugin.antrun.AbstractAntMojo.executeTasks(AbstractAntMojo.java:118)
... 23 more
Caused by: /media/temp/pi4j-arch/pi4j-native/build.xml:10: com.jcraft.jsch.JSchException: Algorithm negotiation fail
at org.apache.tools.ant.taskdefs.optional.ssh.SSHExec.execute(SSHExec.java:188)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
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.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:357)
at org.apache.tools.ant.Target.performTasks(Target.java:385)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
at org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:38)
at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:416)
... 53 more
Caused by: com.jcraft.jsch.JSchException: Algorithm negotiation fail
at com.jcraft.jsch.Session.receive_kexinit(Session.java:520)
at com.jcraft.jsch.Session.connect(Session.java:286)
at com.jcraft.jsch.Session.connect(Session.java:150)
at org.apache.tools.ant.taskdefs.optional.ssh.SSHBase.openSession(SSHBase.java:212)
at org.apache.tools.ant.taskdefs.optional.ssh.SSHExec.execute(SSHExec.java:158)
... 66 more
I tried everything I could figure out, but I cannot make it work. Please help :)
EDIT:
After some further investigation, I am starting to have an idea about what these messages mean and how it works. This is the part of the build.xml that gives the error:
<!-- ensure the target directory is empty on the Raspberry Pi -->
<sshexec host="${pi-host}" port="${pi-port}" username="${pi-user}"
password="${pi-password}" trust="true" failonerror="true"
verbose="true" command="rm --recursive --force ${pi-dirBuildTemp}" />
And to be exact, it is the line starting with "verbose". I tried editing the command, removing parts of it... Nothing helps. I tried removing the whole block of code, leaving the others (that look really like that) and the error then is on the last line of the next block. Here is the whole /media/temp/pi4j-arch/pi4j-native/build.xml :
<?xml version="1.0" encoding="UTF-8"?>
<project name="pi4j-native" default="build-libpi4j.so" basedir=".">
<target name="build-libpi4j.so">
<echo message="Building native libpi4j shared library for ABI: ${pi-abi}"/>
<!-- ensure the target directory is empty on the Raspberry Pi -->
<sshexec host="${pi-host}" port="${pi-port}" username="${pi-user}"
password="${pi-password}" trust="true" failonerror="true"
verbose="true" command="rm --recursive --force ${pi-dirBuildTemp}" />
<!-- ensure the target directory exists on the Raspberry Pi -->
<sshexec host="${pi-host}" port="${pi-port}" username="${pi-user}"
password="${pi-password}" trust="true" failonerror="false"
verbose="true" command="mkdir --parents ${pi-dirBuildTemp}" />
<!-- copy all the necessary source files to the Raspberry Pi -->
<scp todir="${pi-user}:${pi-password}#${pi-host}:${pi-dirBuildTemp}"
port="${pi-port}" trust="true" verbose="true" failonerror="true">
<fileset dir="src/main/native" />
</scp>
<!-- download and compile the 'wiringPi.a' native static library on the Raspberry
Pi platform -->
<sshexec host="${pi-host}" port="${pi-port}" username="${pi-user}"
password="${pi-password}" trust="true" failonerror="true"
verbose="true" command="cd ${pi-dirBuildTemp}; sudo chmod +x wiringpi-build.sh; ./wiringpi-build.sh" />
<!-- compile the 'lib4j.so' JNI native shared library on the Raspberry
Pi platform -->
<sshexec host="${pi-host}" port="${pi-port}" username="${pi-user}"
password="${pi-password}" trust="true" failonerror="true"
verbose="true" command="cd ${pi-dirBuildTemp}; make clean; make all" />
<!-- copy the compiled 'lib4j.so' JNI native shared library back -->
<scp
file="${pi-user}:${pi-password}#${pi-host}:${pi-dirBuildTemp}/libpi4j.so"
todir="${project-build-directory}/${pi-abi}/" port="${pi-port}" trust="true"
verbose="true" failonerror="true">
</scp>
<!-- remove the temporary target directory from the Raspberry Pi -->
<sshexec host="${pi-host}" port="${pi-port}" username="${pi-user}"
password="${pi-password}" trust="true" failonerror="true"
verbose="true" command="rm --recursive --force ${pi-dirBuildTemp}" />
</target>
</project>
Maybe the problem is not in the code itself, but in the sshexec command. But I still haven't understood how exactly it works and what might be the problem. Tomorrow I will try to remove the variables and put the values there, just for the sake of the experiment.
EDIT2: I tested it... Still the same error at the same place...
If anyone has any ideas, please share.
EDIT3:
Thank you very much, prunge! Now I am a few steps ahead! I did both of the things you suggested, as with the first one it didn't work (But I forgot to restart SSH when trying, so maybe it would work).
Now I get another error, on another step... I get only one result when googled it, but I couldn't find the file they were talking about:
https://github.com/rm-hull/wiringPi/issues/2
And I am not sure if this is exactly the same issue.
Here is the error:
fatal: destination path 'wiringPi' already exists and is not an empty directory.
[UnInstall]
wiringPi Build script
=====================
The wiringPi I2C helper libraries will not be built.
WiringPi library
[UnInstall]
make: Nothing to be done for 'all'.
[Install]
GPIO Utility
[Link]
gpio.o: In function `main':
gpio.c:(.text.startup+0x194): undefined reference to `wiringPiSetupPiFaceForGpioProg'
gpio.c:(.text.startup+0x670): undefined reference to `gertboardSPISetup'
gpio.c:(.text.startup+0x684): undefined reference to `gertboardAnalogWrite'
gpio.c:(.text.startup+0x884): undefined reference to `gertboardSPISetup'
gpio.c:(.text.startup+0x894): undefined reference to `gertboardAnalogRead'
collect2: error: ld returned 1 exit status
Makefile:45: recipe for target 'gpio' failed
make: *** [gpio] Error 1
Make Failed...
Please check the messages and fix any problems. If you're still stuck,
then please email all the output and as many details as you can to
projects#drogon.net
[ant] Exiting /media/temp/pi4j-arch/pi4j-native/build.xml.
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] Pi4J :: Parent POM ................................. SUCCESS [01:07 min]
[INFO] Pi4J :: JNI Native Library ......................... FAILURE [04:05 min]
[INFO] Pi4J :: Java Library (Core) ........................ SKIPPED
[INFO] Pi4J :: GPIO Extension ............................. SKIPPED
[INFO] Pi4J :: Device Abstractions ........................ SKIPPED
[INFO] Pi4J :: Java Examples .............................. SKIPPED
[INFO] Pi4J :: OSGi Service ............................... SKIPPED
[INFO] Pi4J :: Distribution ............................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 05:41 min
[INFO] Finished at: 2015-08-13T17:01:08+00:00
[INFO] Final Memory: 12M/30M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-antrun-plugin:1.3:run (build-native-so) on project pi4j-native: An Ant BuildException has occured: The following error occurred while executing this line:
[ERROR] /media/temp/pi4j-arch/pi4j-native/build.xml:27: Remote command failed with exit status 1
[ERROR] -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-antrun-plugin:1.3:run (build-native-so) on project pi4j-native: An Ant BuildException has occured: The following error occurred while executing this line:
/media/temp/pi4j-arch/pi4j-native/build.xml:27: Remote command failed with exit status 1
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: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.MojoExecutionException: An Ant BuildException has occured: The following error occurred while executing this line:
/media/temp/pi4j-arch/pi4j-native/build.xml:27: Remote command failed with exit status 1
at org.apache.maven.plugin.antrun.AbstractAntMojo.executeTasks(AbstractAntMojo.java:131)
at org.apache.maven.plugin.antrun.AntRunMojo.execute(AntRunMojo.java:98)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
... 20 more
Caused by: The following error occurred while executing this line:
/media/temp/pi4j-arch/pi4j-native/build.xml:27: Remote command failed with exit status 1
at org.apache.tools.ant.ProjectHelper.addLocationToBuildException(ProjectHelper.java:508)
at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:418)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
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.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:62)
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.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at net.sf.antcontrib.logic.IfTask.execute(Unknown Source)
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.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.TaskAdapter.execute(TaskAdapter.java:154)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
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.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:357)
at org.apache.maven.plugin.antrun.AbstractAntMojo.executeTasks(AbstractAntMojo.java:118)
... 23 more
Caused by: /media/temp/pi4j-arch/pi4j-native/build.xml:27: Remote command failed with exit status 1
at org.apache.tools.ant.taskdefs.optional.ssh.SSHExec.executeCommand(SSHExec.java:250)
at org.apache.tools.ant.taskdefs.optional.ssh.SSHExec.execute(SSHExec.java:162)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
at sun.reflect.GeneratedMethodAccessor7.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:357)
at org.apache.tools.ant.Target.performTasks(Target.java:385)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
at org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:38)
at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:416)
... 53 more
I really don't get how this works, I don't see anywhere the things written in the comments (in the build.xml file)... Here is the part of build.xml that is causing the error:
<!-- download and compile the 'wiringPi.a' native static library on the Raspberry
Pi platform -->
<sshexec host="${pi-host}" port="${pi-port}" username="${pi-user}"
password="${pi-password}" trust="true" failonerror="true"
verbose="true" command="cd ${pi-dirBuildTemp}; sudo chmod +x wiringpi-build.sh; ./wiringpi-build.sh" />
I can't find the wiringpi-build.sh ...
Thanks and regards,
Krum
It's failing to talk to your Pi via SSH protocol.
If you haven't already, you might want to try installing the unlimited strength encryption policy files into your JDK/JRE you are running Maven from. This will allow more algorithms to be negotiated when connecting via SSH.
An alternative is to change SSHD configuration files on you Pi to allow some algorithms JSCH from your JDK/JRE supports. Details for doing this is in this answer.