How to integrate spring-batch in Wildfly - spring-batch

Does anyone know how to integrate spring-batch into a standalone wildfly (8.x)
instead of jberet ??
I tried to follow the instructions on this page : http://www.radcortez.com/spring-batch-as-wildfly-module/
I disabled all the Arquillian stuff and was able to run mvn process-resources
but when im trying to run mvn wildfly:execute-commands -P install-spring-batch im getting an error :
[ERROR] Failed to execute goal org.wildfly.plugins:wildfly-maven-plugin:1.0.1.Final:execute-commands (default-cli) on project wildfly-spring-batch: Execution default-cli of goal org.wildfly.plugins:wildfly-maven-plugin:1.0.1.Final:execute-commands failed: Failed to process file 'C:\workspace\spring-batch\target\scripts\wildfly-add-spring-batch.cli': Command execution failed for command ' --resources=${wildfly.module.classpath}'. Failed to locate C:\workspace\spring-batch\${wildfly.module.classpath}
My understanding was that these path's would be generated during the run, but i will have to investigate further

Related

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M3:test (default-test) on project. while 'Run as Maven test'

I am trying to create my own custom rules for Z PL/SQL Analyzer plugin by Felipebz. For that, I am following this tutorial.
I downloaded the mentioned Github Directory in that tutorial and imported it in Eclipse. Now, when I try to Run it as "Maven test", I get Following error:
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M3:test (default-test) on project plsql-custom-rules: There are test failures.
There are some more errors in the log:
[INFO] Running com.company.plsql.ForbiddenDmlCheckTest
[ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.284 s <<< FAILURE! - in com.company.plsql.ForbiddenDmlCheckTest
[ERROR] test(com.company.plsql.ForbiddenDmlCheckTest) Time elapsed: 0.181 s <<< ERROR!
java.lang.NoSuchMethodError: org.assertj.core.api.Assertions.assertThat(Ljava/lang/String;)Lorg/assertj/core/api/AbstractStringAssert;
at com.company.plsql.ForbiddenDmlCheckTest.test(ForbiddenDmlCheckTest.java:10)
Does someone know any solution to this particular problem?
I want to create a jar for testing it in my SonarQube Server. But, before changing anything in the code, I wanted to test it first as it is; because I reckon that there is a sample rule already provided in the downloaded Project template. I can make further changes in the code once I get to test it as a jar file at first place.
Carefully check build configuration below, targeted xml that include your test objects name should be correct and commands should correct. Configuration example:
Eg for correct way :
clean install -Drelease.testng=inventoryAndWarehouseModuleSmoke.xml
This error may also be due to this.
As Raphael Alves suggested, I solved it by adding the following dependency to pom.xml
<dependency>
<groupId>org.assertj</groupId>
<artifactId>assertj-core</artifactId>
<version>3.11.1</version>
<scope>test</scope>
</dependency>
You might want to check for the latest version of this dependency on Maven Repository

I am unable to build mongodb-binding with YCSB

I am trying to build mongodb-async driver with YCSB (0.15.0) version. I am running it on Clear Linux OS, and have MONGODB version 4.0.5 and mvn -version is 3.6.0.
I am running the command "mvn -pl com.yahoo.ycsb:mongodb-binding -am clean package" from my home directory of YCSB, and get the following error:
Could not resolve dependencies for project com.yahoo.ycsb:mongodb-bindin
g:jar:0.16.0-SNAPSHOT: Failed to collect dependencies at com.allanbank:mongodb-async-driver:jar:2.10.1: Failed to read artifact des
criptor for com.allanbank:mongodb-async-driver:jar:2.10.1: Could not transfer artifact com.allanbank:mongodb-async-driver:pom:2.10.
1 from/to allanbank (http://www.allanbank.com/repo/): Connect to www.allanbank.com:80 [www.allanbank.com/206.210.70.161] failed: Co
nnection timed out (Connection timed out) -> [Help 1]
Can someone please point me what might be going wrong. Thanks in advance
I think you have to configure the JAVA_HOME in the .mavenrc by adding:
expot JAVA_HOME=your path (eg: export JAVA_HOME=/usr/lib/jvm/java-8-oracle/) into this file

Building Spark with mvn fails

I am trying to build spark 1.5.0. I am using this command:
sh ./make-distribution.sh --name 2.6.0 --tgz -Phadoop-2.6 -Phive
But get the following error code:
Failed to execute goal net.alchim31.maven:scala-maven-plugin:3.2.2:compile (scala-compile-first) on project spark-launcher_2.10: Execution scala-compile-first of goal net.alchim31.maven:scala-maven-plugin:3.2.2:compile failed. CompileFailed.
Also I get this error message:
Required file not found: scala-compiler-2.10.4.jar
Does anybody know, how I can fix this problem?
Thank you very much in advance.
Shutdown zinc first. See the documentation here
./build/zinc-<version>/bin/zinc -shutdown

Can't deploy kitchensink example

I have wildfly 8.2.0.Final installed and I'm using eclipse with jboss developer studio plugin. From the jboss central side within eclipse I started the sample kitchensink. When I try to deploy via 'mvn clean install jboss-as:deploy' I'm getting the error:
[ERROR] Failed to execute goal org.jboss.as.plugins:jboss-as-maven-plugin:7.4.Final:deploy (default-cli) on project jboss-kitchensink: Could not execute goal deploy on /home/vagrant/workspaces/projects1/jboss-kitchensink/target/jboss-kitchensink.war. Reason: I/O Error could not execute operation '{
[ERROR] "address" => [],
[ERROR] "operation" => "read-attribute",
[ERROR] "name" => "launch-type"
[ERROR] }': java.net.ConnectException: JBAS012144: Could not connect to remote://localhost:9990. The connection timed out
What is the mistake?
Make sure you don't mix WildFly with JBoss AS, and don't start the sample twice (from Eclipse and from Maven).
The WildFly quickstarts are here, don't use an older version targeting JBoss AS.
The kitchensink sample can be deployed via mvn wildfly:deploy, not mvn jboss-as:deploy.

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.5-r682619-maestro-2.0.0:test (default-test) on project

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.5-r682619-maestro-2.0.0:test (default-test) on project ms61-webservice-xxxx: There are test failures. what does it mean and how to resolve it. I am doing maven build for the first time.
It means the build failed because you have failing tests. Resolve it by fixing the code so the tests pass.