log4j Error in building Corda sample project - corda

When I build the sample corda project with gradle on windows (gradlew.bat deployNodes)
I see the error about DELETE command in log4j:
2019-10-28 16:30:47,207 main ERROR Delete contains invalid attributes "IfFileName", "IfLastModified"
2019-10-28 16:30:47,213 main ERROR Missing Delete conditions: unconditional Delete not supported
2019-10-28 16:30:47,217 main ERROR Unable to invoke factory method in class org.apache.logging.log4j.core.appender.rolling.action.DeleteAction for element Delete: java.lang.IllegalArgume
ntException: Unconditional Delete not supported java.lang.reflect.InvocationTargetException
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.apache.logging.log4j.core.config.plugins.util.PluginBuilder.build(PluginBuilder.java:136)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createPluginObject(AbstractConfiguration.java:964)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createConfiguration(AbstractConfiguration.java:904)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createConfiguration(AbstractConfiguration.java:896)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createConfiguration(AbstractConfiguration.java:896)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createConfiguration(AbstractConfiguration.java:896)
at org.apache.logging.log4j.core.config.AbstractConfiguration.doConfigure(AbstractConfiguration.java:514)
at org.apache.logging.log4j.core.config.AbstractConfiguration.initialize(AbstractConfiguration.java:238)
at org.apache.logging.log4j.core.config.AbstractConfiguration.start(AbstractConfiguration.java:250)
at org.apache.logging.log4j.core.LoggerContext.setConfiguration(LoggerContext.java:548)
at org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:620)
at org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:637)
at org.apache.logging.log4j.core.LoggerContext.start(LoggerContext.java:231)
at org.apache.logging.log4j.core.async.AsyncLoggerContext.start(AsyncLoggerContext.java:76)
at org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:153)
at org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:45)
at org.apache.logging.log4j.LogManager.getContext(LogManager.java:194)
at org.apache.logging.log4j.spi.AbstractLoggerAdapter.getContext(AbstractLoggerAdapter.java:121)
at org.apache.logging.slf4j.Log4jLoggerFactory.getContext(Log4jLoggerFactory.java:43)
at org.apache.logging.log4j.spi.AbstractLoggerAdapter.getLogger(AbstractLoggerAdapter.java:46)
at org.apache.logging.slf4j.Log4jLoggerFactory.getLogger(Log4jLoggerFactory.java:29)
at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:358)
at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:383)
at net.corda.core.utilities.KotlinUtilsKt.contextLogger(KotlinUtils.kt:42)
at net.corda.cliutils.CliWrapperBase$Companion$logger$2.invoke(CordaCliWrapper.kt:108)
at net.corda.cliutils.CliWrapperBase$Companion$logger$2.invoke(CordaCliWrapper.kt:107)
at kotlin.SynchronizedLazyImpl.getValue(LazyJVM.kt:74)
at net.corda.cliutils.CliWrapperBase$Companion.getLogger(CordaCliWrapper.kt:65535)
at net.corda.cliutils.CliWrapperBase$Companion.access$getLogger$p(CordaCliWrapper.kt:107)
at net.corda.cliutils.CliWrapperBase.call(CordaCliWrapper.kt:142)
at net.corda.cliutils.CliWrapperBase.call(CordaCliWrapper.kt:106)
at picocli.CommandLine.execute(CommandLine.java:1173)
at picocli.CommandLine.access$800(CommandLine.java:141)
at picocli.CommandLine$RunLast.handle(CommandLine.java:1367)
at picocli.CommandLine$RunLast.handle(CommandLine.java:1335)
at picocli.CommandLine$AbstractParseResultHandler.handleParseResult(CommandLine.java:1243)
at picocli.CommandLine.parseWithHandlers(CommandLine.java:1526)
at net.corda.cliutils.CordaCliWrapperKt.start(CordaCliWrapper.kt:73)
at net.corda.node.Corda.main(Corda.kt:13)
Caused by: java.lang.IllegalArgumentException: Unconditional Delete not supported
at org.apache.logging.log4j.core.appender.rolling.action.DeleteAction.(DeleteAction.java:71)
at org.apache.logging.log4j.core.appender.rolling.action.DeleteAction.createDeleteAction(DeleteAction.java:212)
... 43 more
2019-10-28 16:30:47,606 main ERROR Null object returned for Delete in DefaultRolloverStrategy.
2019-10-28 16:30:47,736 main ERROR Delete contains invalid attributes "IfFileName", "IfLastModified"
2019-10-28 16:30:47,737 main ERROR Missing Delete conditions: unconditional Delete not supported
2019-10-28 16:30:47,739 main ERROR Unable to invoke factory method in class org.apache.logging.log4j.core.appender.rolling.action.DeleteAction for element Delete: java.lang.IllegalArgume
ntException: Unconditional Delete not supported java.lang.reflect.InvocationTargetException
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.apache.logging.log4j.core.config.plugins.util.PluginBuilder.build(PluginBuilder.java:136)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createPluginObject(AbstractConfiguration.java:964)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createConfiguration(AbstractConfiguration.java:904)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createConfiguration(AbstractConfiguration.java:896)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createConfiguration(AbstractConfiguration.java:896)
at org.apache.logging.log4j.core.config.AbstractConfiguration.createConfiguration(AbstractConfiguration.java:896)
at org.apache.logging.log4j.core.config.AbstractConfiguration.doConfigure(AbstractConfiguration.java:514)
at org.apache.logging.log4j.core.config.AbstractConfiguration.initialize(AbstractConfiguration.java:238)
at org.apache.logging.log4j.core.config.AbstractConfiguration.start(AbstractConfiguration.java:250)
at org.apache.logging.log4j.core.LoggerContext.setConfiguration(LoggerContext.java:548)
at org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:620)
at org.apache.logging.log4j.core.LoggerContext.reconfigure(LoggerContext.java:637)
at org.apache.logging.log4j.core.LoggerContext.start(LoggerContext.java:231)
at org.apache.logging.log4j.core.async.AsyncLoggerContext.start(AsyncLoggerContext.java:76)
at org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:153)
at org.apache.logging.log4j.core.impl.Log4jContextFactory.getContext(Log4jContextFactory.java:45)
at org.apache.logging.log4j.LogManager.getContext(LogManager.java:194)
at org.apache.logging.log4j.spi.AbstractLoggerAdapter.getContext(AbstractLoggerAdapter.java:121)
at org.apache.logging.slf4j.Log4jLoggerFactory.getContext(Log4jLoggerFactory.java:43)
at org.apache.logging.log4j.spi.AbstractLoggerAdapter.getLogger(AbstractLoggerAdapter.java:46)
at org.apache.logging.slf4j.Log4jLoggerFactory.getLogger(Log4jLoggerFactory.java:29)
at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:358)
at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:383)
at net.corda.core.utilities.KotlinUtilsKt.contextLogger(KotlinUtils.kt:42)
at net.corda.cliutils.CliWrapperBase$Companion$logger$2.invoke(CordaCliWrapper.kt:108)
at net.corda.cliutils.CliWrapperBase$Companion$logger$2.invoke(CordaCliWrapper.kt:107)
at kotlin.SynchronizedLazyImpl.getValue(LazyJVM.kt:74)
at net.corda.cliutils.CliWrapperBase$Companion.getLogger(CordaCliWrapper.kt:65535)
at net.corda.cliutils.CliWrapperBase$Companion.access$getLogger$p(CordaCliWrapper.kt:107)
at net.corda.cliutils.CliWrapperBase.call(CordaCliWrapper.kt:142)
at net.corda.cliutils.CliWrapperBase.call(CordaCliWrapper.kt:106)
at picocli.CommandLine.execute(CommandLine.java:1173)
at picocli.CommandLine.access$800(CommandLine.java:141)
at picocli.CommandLine$RunLast.handle(CommandLine.java:1367)
at picocli.CommandLine$RunLast.handle(CommandLine.java:1335)
at picocli.CommandLine$AbstractParseResultHandler.handleParseResult(CommandLine.java:1243)
at picocli.CommandLine.parseWithHandlers(CommandLine.java:1526)
at net.corda.cliutils.CordaCliWrapperKt.start(CordaCliWrapper.kt:73)
at net.corda.node.Corda.main(Corda.kt:13)
Caused by: java.lang.IllegalArgumentException: Unconditional Delete not supported
at org.apache.logging.log4j.core.appender.rolling.action.DeleteAction.(DeleteAction.java:71)
at org.apache.logging.log4j.core.appender.rolling.action.DeleteAction.createDeleteAction(DeleteAction.java:212)
... 43 more
I got latest verison of corda samples. (from master branch). I encounter the same problem with other branches.
My jdk version is 1.8.0_212.
I used cordapp-examples project
How can I solve this problem?

It looks to me like you are pulling in JAR files from somewhere other than those specified by the Corda build.
The default branch for the samples is release-V4 and that is the one I'm using. I run the following and it works fine:
git clone https://github.com/corda/samples
cd cordapp-example
gradlew deployNodes
I'd check that your classpath variable isn't set (as this will cause additional JAR files in those directories to be included when running Corda) by running :
echo %CLASSPATH%
Additionally, from the command-line I'd run:
java -version
where java
To make sure the version of java you think you're picking up is the one you are picking up.

I had a similar issue related to log4j:
the log4j2 error unable to invoke factory method in class class RollingFileApender
Error while generating node info file
To fix this (on windows), I took the following steps:
Right click on MyPC
Click advanced system settings
Click environment variables
Change JAVA_HOME to point to same jdk directory being used in IntelliJ for corDapp. (I changed mine from OpenJDK\jdk-13.0.1 to C:\Program Files\Java\jdk1.8.0_231)
Restart IntelliJ and rerun ./gradlew deployNodes

The problem was about the regional settings of my computer.
By defining an Environment variable
JAVA_TOOL_OPTIONS=-Duser.language=en -Duser.country=US -Duser.region=US -Dfile.encoding=UTF-8 -Duser.variant=US
I solved the problem.
Thanks all for your attention.

Related

JavaFX deployment: Failed to launch JVM

Greetings
I have deployed a simple JavaFX application using msi installer that was created by jpackage. When double-clicking on the application icon installed in Windows 10 "program files" directory, it displays an error "Failed to launch JVM". Prior to deployment, I tested the application jar file from the command prompt without any problem. When checking the application installation directory (under "C:\Program files") it has all the runtime dlls and so on, so I am not sure what causes this error? Here is the japckage command I used to build the runtime image:
jpackage --type msi --name FileChooser -p "%JAVAFX_HOME%\lib;%M2_REPO%;org\openjfx\mavenfxfilechooser\mavenfxfilechooser.jar" --module "org.openjfx.mavenfxfilechooser/org.openjfx.mavenfxfilechooser.FileChooserApp"
Update
Following the recommendation given in the comment section, I installed the JMODS on my machine and issued a jpackage command line to point to the JMODS files instead of JAVAFX_HOME as follow:
jpackage --type msi --name FileChooser -p "%JMODS_HOME%;%M2_REPO%;C:\Users\hrh74\Downloads\Lib\file\org\openjfx\mavenfxfilechooser" --module "org.openjfx.mavenfxfilechooser/org.openjfx.mavenfxfilechooser.FileChooserApp"
I installed the application using the MSI runtime image and this certainly solved the" Failed to launch JVM" problem. The application started, however, I have a WebView component that should display content from https://us.yahoo.com when the user clicks on a "Yahoo" button and this doesn't seem to be working when the application run as a self-contained app but it works when I run the jar file from the command line. Do I need to add anything to the jpackage?
Please let me know if the source code and FXML file are needed.
Thanks
Your original problem has to do with missing native code. But you appear to have already solved that problem by using the JMOD files for JavaFX provided by Gluon. So I'll try to help solve your other issue regarding https://us.yahoo.com not loading in the WebView once you create a self-contained application.
When trying to load that website myself I was running into the same issue as you. Though sometimes I'd get a "we're working on the problem" page response, other times the entire application would become unresponsive, and yet other times nothing would happen (the load would just seem to fail "gracefully"). This happened with other websites as well, not just Yahoo. After some testing I was finally able to get the following error:
java.lang.Throwable: SSL handshake failed
at javafx.web/javafx.scene.web.WebEngine$LoadWorker.describeError(Unknown Source)
at javafx.web/javafx.scene.web.WebEngine$LoadWorker.dispatchLoadEvent(Unknown Source)
at javafx.web/javafx.scene.web.WebEngine$PageLoadListener.dispatchLoadEvent(Unknown Source)
at javafx.web/com.sun.webkit.WebPage.fireLoadEvent(Unknown Source)
at javafx.web/com.sun.webkit.WebPage.fwkFireLoadEvent(Unknown Source)
at javafx.web/com.sun.webkit.network.URLLoaderBase.twkDidFail(Native Method)
at javafx.web/com.sun.webkit.network.HTTP2Loader.notifyDidFail(Unknown Source)
at javafx.web/com.sun.webkit.network.HTTP2Loader.lambda$didFail$18(Unknown Source)
at javafx.web/com.sun.webkit.network.HTTP2Loader.lambda$callBackIfNotCanceled$10(Unknown Source)
at javafx.graphics/com.sun.javafx.application.PlatformImpl.lambda$runLater$10(Unknown Source)
at java.base/java.security.AccessController.doPrivileged(Unknown Source)
at javafx.graphics/com.sun.javafx.application.PlatformImpl.lambda$runLater$11(Unknown Source)
at javafx.graphics/com.sun.glass.ui.InvokeLaterDispatcher$Future.run(Unknown Source)
at javafx.graphics/com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
at javafx.graphics/com.sun.glass.ui.win.WinApplication.lambda$runLoop$3(Unknown Source)
at java.base/java.lang.Thread.run(Unknown Source)
That indicated to me the application created by jpackage was missing some crypto libraries. From here I just guessed, but inclulding:
--add-modules jdk.crypto.cryptoki,jdk.crypto.ec
When running jpackage seemed to solve the problem. I don't know if both modules are needed, or if only one is needed (or if adding either one implicitly adds the other).
Side note: When scrolling through https://us.yahoo.com I would frequently get the following warnings:
Mar 05, 2021 12:10:40 PM com.sun.javafx.webkit.prism.WCMediaPlayerImpl onError
WARNING: onError, errCode=0, msg=Could not create player!
And:
Mar 05, 2021 12:10:41 PM com.sun.javafx.webkit.prism.WCMediaPlayerImpl$CreateThread run
WARNING: CreateThread ERROR: java.lang.UnsupportedOperationException: Unsupported protocol "data"
I would get that warning regardless of how the application was packaged. I don't know how to solve the problem, or if there even is a solution without modifying the JavaFX code itself.
Have you seen running JavaFX application after jpackage? Try to download Gluon jmods and use it instead of %JAVAFX_HOME%

Error in executing OWBClient.sh in UNIX

I am trying to run the OWBClient.sh with the command in UNIX and I am getting the following error:
" The JVM option is invalid: -XX: MaxPermSize=256M. Could not create the Java Virtual Machine."
OWB Version: 10.2.0.5
Oracle Database : 10g
UName: AIX
When exploring more on the above issue, I got an information that OWB 10.2 could not be run in AIX. It would be helpful if anyone can can shed some light on whether OWB 10.2.0.5 can be run on AIX?
Editing my post to share an update.I have tried to execute the owbclient.sh file by removing the -XX:MaxPermSize=256M part. I am now getting a different kind of error...
$ ./owbclient.sh
[Launcher]: Error! Cannot find and load the jar file '../../../jdk/jre/lib/ rt.jar'. OWB application may not be launched due to this error.
[Launcher]: Error! Cannot find and load the jar file '../../../jdk/jre/lib/ jce.jar'. OWB application may not be launched due to this error.
StaticLoader: Setting locale to en__
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:85)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:58)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:60)
at java.lang.reflect.Method.invoke(Method.java:391)
at Launcher.main(Launcher.java:167)
Caused by: java.lang.InternalError: Can't connect to X11 window server using ':0 .0' as the value of the DISPLAY variable.
at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
at sun.awt.X11GraphicsEnvironment.(X11GraphicsEnvironment.java:1 75)
at java.lang.Class.forName1(Native Method)
at java.lang.Class.forName(Class.java:180)
at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvi ronment.java:91)
at sun.awt.motif.MToolkit.(MToolkit.java:124)
at java.lang.Class.forName1(Native Method)
at java.lang.Class.forName(Class.java:180)
at java.awt.Toolkit$2.run(Toolkit.java:796)
at java.security.AccessController.doPrivileged1(Native Method)
at java.security.AccessController.doPrivileged(AccessController.java:287 )
at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:787)
at java.awt.Component.getToolkitImpl(Component.java:873)
at java.awt.Component.getToolkit(Component.java:857)
at java.awt.Component.createImage(Component.java:2729)
at oracle.wh.ui.common.CommonUtils.getIcon(CommonUtils.java:622)
at oracle.wh.ui.framework.beans.splash.SplashBean.setImageLoc(SplashBean .java:111)
at oracle.wh.ui.framework.beans.splash.SplashBean.(SplashBean.java :42)
at oracle.wh.ui.framework.StaticLoader.main(StaticLoader.java:67)
... 6 more
java.lang.reflect.InvocationTargetException
$

Issues running CAMEL JAR file built in windows using Eclipse when run in Linux command line using JAVA or MVN command

I have built a Camel project in Eclipse with Maven dependencies.
It ran successfully and also Built the Jar file and ran it from the command prompt
which is running as required. But when I moved the JAR file onto to our Linux machine
which is like a Job Manager server and when I try to run the JAR file as below
I am getting the below error message.
When I try to run with the below command
$ java –jar mycamelproject
I am getting the below error, but I do have the below mentioned dependency in the Dependency-Jars folder.
Exception in thread "main" java.lang.NoClassDefFoundError: org/springframework/c
at java.lang.Class.getDeclaredMethods0(Native Method)
at java.lang.Class.privateGetDeclaredMethods(Class.java:2531)
at java.lang.Class.getMethod0(Class.java:2774)
at java.lang.Class.getMethod(Class.java:1663)
at sun.launcher.LauncherHelper.getMainMethod(LauncherHelper.java:494)
at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:486)
Caused by: java.lang.ClassNotFoundException: org.springframework.context.support
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
... 6 more
Then I tried running with the below command.
$ mvn -X exec:java -Dexec.mainClass=mycamelpackage.mycamelmainclass
I am getting a series of the below errors such as below
[DEBUG] Could not find metadata org.codehaus.mojo/maven-metadata.xml in local (/home/ec2-user/.m2/repository)
[DEBUG] Skipped remote update check for org.codehaus.mojo/maven-metadata.xml, already updated during this session.
[WARNING] Failure to transfer org.codehaus.mojo/maven-metadata.xml from
http://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced. Original error: Could not transfer metadata org.codehaus.mojo/maven-metadata.xml from/to central (http://repo.maven.apache.org/maven2): proxy.host.net
[ERROR] No plugin found for prefix 'exec' in the current project
and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo]
available from the repositories
How should java –jar mycamelproject work if no classpath is set? And mycamelproject should be a JAR file anyway (and if it is, you should add the *.jar extension).
Beside that, I guess your local Maven repository may be corrupt. That's usually the reason why you see the resolution will not be reattempted error message. The easiest way to fix this is to remove the corrupt directories and start Maven again.

running mahout RecommenderJob on EMR

I'm trying to run a RecommenderJob on amazon EMR. I have a jar called SmartJukebox.jar (not runnable) and it contains a class main.TrackRecommander (and that's it).
I created a job flow with the jar:
s3n://smartjukebox/SmartJukebox.jar
and args:
main.TrackRecommander --input s3n://smartjukebox/ratings.csv --output s3n://smartjukebox/output --usersFile s3n://smartjukebox/user.txt.
The class TrackRecommander uses the class RecommenderJob.
I run the job flow and i get this in the error log -
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/mahout/cf/taste/hadoop/item/RecommenderJob
at main.TrackRecommander.main(TrackRecommander.java:136)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.hadoop.util.RunJar.main(RunJar.java:156)
Caused by: java.lang.ClassNotFoundException: org.apache.mahout.cf.taste.hadoop.item.RecommenderJob
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
... 6 more
now i see that the JVM can't find RecommenderJob and i didn't put RecommenderJob in my jar. I thought EMR would have mahout jars built in, but i can't find anything about that.
what is the solution here?
Thanks.
You're problem is exactly what you say: "I didn't put RecommenderJob in my jar." Unless you put those classes in your JAR, of course it can't be found. Why would EMR have this built in? Add the Mahout ".job" file classes to your JAR first.
You will need to create a job jar which contains all the classes required by the code to run which includes the mahout classes too.
Take a look at
https://github.com/tdunning/MiA
Check how to create a job jar using maven assembly plugin in pom.xml and the job.xml in the src/main/resources directory.
IF you exclude the hadoop classes then you can run it on any hadoop instance.

Flex .swc build using org.sonatype.flexmojos is failing

I am trying to create and build a flex library project (.swc) using maven 2 firsttime.
I am able to create directory structure but build is failing.
My maven settings are :
Maven version : apache-maven-3.0.2
mvn archetype:generate
-DarchetypeGroupId=org.sonatype.flexmojos
-DarchetypeArtifactId=flexmojos-archetypes-library
-DarchetypeVersion=3.8
-DgroupId=com.test
-DartifactId=sampleflexproject2 –e
This created the basic project skeleton as per my need.
mvn clean install –e –X
I get below exception while executing this command.
[ERROR] Failed to execute goal org.sonatype.flexmojos:flexmojos-maven-plugin:4.0-pre-alpha-1:compile-swc (default-compile-swc) on project sampleflexproject2: The parameters 'output' for goal org.sonatype.flexmojos:flexmojos-maven-plugin:4.0-pre-alpha-1:compile-swc are missing or invalid -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException:
Failed to execute goal org.sonatype.flexmojos:flexmojos-maven-plugin:4.0-pre-alpha-1:compile-swc (default-compile-swc) on project sampleflexproject2: The parameters 'output' for goal org.sonatype.flexmojos:flexmojos-maven-plugin:4.0-pre-alpha-1:compile-swc are missing or invalid
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:221)
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:319)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:534)
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:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
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:409)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352) Caused by: org.apache.maven.plugin.PluginParameterException:
The parameters 'out put' for goal org.sonatype.flexmojos:flexmojos-maven-plugin:4.0-pre-alpha-1:compile-swc are missing or invalid
at org.apache.maven.plugin.internal.DefaultMavenPluginManager.validateParameters(DefaultMavenPluginManager.java:688)
at org.apache.maven.plugin.internal.DefaultMavenPluginManager.populatePluginFields(DefaultMavenPluginManager.java:580)
at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getConfiguredMojo(DefaultMavenPluginManager.java:525)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:98)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
Do you foresee any obvious issue in this ?
Please post a simplified version of the POM.
The issue seems to be though that you are missing some configuration for the flexmojos-maven-plugin. It is complaining that the goal default-compile-swc has no output property defined.
Take a look at your plugin definition:
<plugin>
<groupId>org.sonatype.flexmojos</groupId>
<artifactId>flexmojos-maven-plugin</artifactId>
<version>4.0-pre-alpha-1</version>
<configuration>
<output>${basedir}/target/sampleflexproject2.swf</output>
</configuration>
</plugin>
That though alone will probably not be sufficient for a successful build.
Take a look https://repository.sonatype.org/content/sites/maven-sites/flexmojos/4.0-RC1/compile-swc-mojo.html for more information on what should be set in the configuration block.

Resources