I am using ubuntu 14.04 LTS
Having java 7 and 8 installed from oracle.
Using alternative and working with java 7 but one of my projects use java 8.
gradle build --version
returns that it works with java 7 -> since most of my projects use this version, i don't want to change this.
Solution: creating in the java 8 project, in the root directory, file named gradle.properties
inside it for example in my case :
org.gradle.java.home=/usr/lib/jvm/java-8-oracle/
this way, when you will do gradle build in this project, gradle will use this version instead of the one defined for him.
Hoped it helped,
Dor
Showing posts with label build. Show all posts
Showing posts with label build. Show all posts
Jun 19, 2014
May 21, 2014
NoClassDefFoundError: jersey/repackaged/com/google/common/collect/Maps
Hi,
I am working with spring 4.0.4 and jersey 2.7 and Gradle 1.11 suddelny out of nowhere i build and deployed to my tomcat 7 (latest release) and got the above error.
Worked to figure out what went wrong about an hour.
Than i saw that they released a new 2.8 lately, decided to try it - it worked +
Problem solved for me after upgrading from jersey 2.7 to 2.8
and adding this to my gradle dependencies
"org.glassfish.jersey.bundles.repackaged:jersey-guava:2.8"
Hopefully it will help you too,
Dor
I am working with spring 4.0.4 and jersey 2.7 and Gradle 1.11 suddelny out of nowhere i build and deployed to my tomcat 7 (latest release) and got the above error.
Worked to figure out what went wrong about an hour.
Than i saw that they released a new 2.8 lately, decided to try it - it worked +
Problem solved for me after upgrading from jersey 2.7 to 2.8
and adding this to my gradle dependencies
"org.glassfish.jersey.bundles.repackaged:jersey-guava:2.8"
Hopefully it will help you too,
Dor
Sep 14, 2012
ERROR: Failed to parse POMs
Strange situation where the local build success but the build on the jenkins fails.
After investigation i have noticed that one of the developers have add a tab somewhere in the pom.
The tab \t character cause this error in the jenkins.
Removing this character solved the issue. Of course i have reported that also to the jenkins guys.
Hoped it helped you,
Dor
Jul 19, 2012
Maven parallel build
Hi All,
I have looked for a while for this option, wondered how could it be that they don't have it.
Finally i found it, since maven 3v, they add an experimental option, the T option.
You can now run maven build parallel way. Meaning, maven will check which parts from the project tree he can build in parallel and do it.
Performance ?
Big boost, something like >20%, Do it for your self and compare, you want regret it.
Good also for CI (Jenkins for example)
How?
First way,
"mvn -T 4 clean install"
-T => Stands for telling maven to use the parallel way.
4 => Means, 4 threads to use.
Second way and my preferred,
"mvn -T 4C clean install"
-T => Stands for telling maven to use the parallel way.
4C => Means, 4 threads on each core
Dor
I have looked for a while for this option, wondered how could it be that they don't have it.
Finally i found it, since maven 3v, they add an experimental option, the T option.
You can now run maven build parallel way. Meaning, maven will check which parts from the project tree he can build in parallel and do it.
Performance ?
Big boost, something like >20%, Do it for your self and compare, you want regret it.
Good also for CI (Jenkins for example)
How?
First way,
"mvn -T 4 clean install"
-T => Stands for telling maven to use the parallel way.
4 => Means, 4 threads to use.
Second way and my preferred,
"mvn -T 4C clean install"
-T => Stands for telling maven to use the parallel way.
4C => Means, 4 threads on each core
Dor
Labels:
build,
ci,
jenkins,
maven,
multithreading,
mvn,
parallel,
performance,
project
Dec 19, 2010
Element 'filters' cannot have character [children], because the type's content type is element-only. maven
Go this error while adding filter to web.xml.
My mistake was that i forgot creating the <filter> tag inside the <filters>.
I did this:
<filters>src/main/filters/filter.properties</filters> instead of doing this:
<filters><filter>src/main/filters/filter.properties</filter></filters>
Minor mistake that can happen in one minute out of focus.
Hoped it helped,
Dor
My mistake was that i forgot creating the <filter> tag inside the <filters>.
I did this:
<filters>src/main/filters/filter.properties</filters> instead of doing this:
<filters><filter>src/main/filters/filter.properties</filter></filters>
Minor mistake that can happen in one minute out of focus.
Hoped it helped,
Dor
Nov 23, 2010
gin.jar
Hi,
Currently there is no jar to download and you must do the job by your self.
To compile gin with ant, svn checkout the latest version from google trunk.
You need to set up a user / system environment variable, restart your IDE and then use ant on build.xml
The new "gin.jar" file will be created in the out\dist directory.
That suite for me. You can also click here for more help.
Dor
Currently there is no jar to download and you must do the job by your self.
To compile gin with ant, svn checkout the latest version from google trunk.
You need to set up a user / system environment variable, restart your IDE and then use ant on build.xml
The new "gin.jar" file will be created in the out\dist directory.
That suite for me. You can also click here for more help.
Dor
Buildfile: build.xml does not exist!
If you got this error, try running your build file like this:
"ant -buildfile filepath\filename.xml"
You need also to have %JAVA_HOME%\bin and %ANT_HOME%\bin defined in your path.
"ant -buildfile filepath\filename.xml"
You need also to have %JAVA_HOME%\bin and %ANT_HOME%\bin defined in your path.
Subscribe to:
Posts (Atom)