SoftwareEntwicklung Beratung Schulung

A coders, hackers heaven.....Hm...I do not think so...

Apache Maven Version 3.5.0-alpha-1 Released

| Comments

The Apache Maven team would like to announce the release of Maven 3.5.0-alpha-1.

NOTE: This is an ALPHA release. There is the potential that features may be added/removed between this release and the first GA release in the 3.5.x release line. Please consult the Known Issues section below before use

You can download the appropriate sources, etc. from the archives section on the download page as Maven 3.3.9 is still the recommended GA release

https://archive.apache.org/dist/maven/maven-3/3.5.0-alpha-1/

Release Notes for 3.5.0-alpha-1.

Known Issues

The following issues were identified during release testing of this ALPHA release but have not been deemed as release blockers:

  • MNG-6177 The --file and -f option to specify a pom.xml to use does not work if the path includes characters that need quoting such as whitespace or &.
  • MNG-6115 If Maven is installed in a writable location, every build will create a new lib/ext/jansi-.... file.

Why not Maven 3.4.0?

After Maven 3.3.9 was released, the Eclipse Aether project was retired and the code base was migrated to the Apache Maven project.

The original goal for the 3.4.0 release was to replace Aether with the exact same code after migration to the Apache Maven project and then proceed with bug fixes to the resolver code as well as other areas of Maven.

The migration of the code between the two foundations took longer than expected and as a result there were other changes committed to Maven core that were outside the scope of intent for 3.4.0.

In order to refocus on the original intent for 3.4.0, the decision was taken to revert the Maven core history to the point of the 3.3.9 release and merge in the desired changes one at a time.

Because there had been a lot of communication about different features being delivered and bugs fixed in Maven 3.4.0 and the new history may not contain them in the first release, the decision was taken to forever burn the 3.4.x release line.

More detail on this decision can be read in the mailing list archive.

Apache Maven Archetype Plugin 3.0.0 Released

| Comments

The Apache Maven team is pleased to announce the release of the Apache Maven Archetype Plugin, version 3.0.0.

The Archetype Plugin allows the user to create a Maven project from an existing template called an archetype. It also allows the user to create an archetype from an existing project.

You can download the appropriate sources etc. from the download page.

You should specify the version in your project’s plugin configuration:

1
2
3
4
5
<plugin>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-archetype-plugin</artifactId>
  <version>3.0.0</version>
</plugin>

Maven 3: How Version Comparison Works?

| Comments

In the ancient time before maven 3 the version of an artifact had to follow the pattern:

1
<majorversion [> . <minorversion [> . <incrementalversion ] ] [> - <buildnumber | qualifier ]>

so far so good. Now let us assume we have the following two versions:

  • 1.0.9.3.1
  • 1.0.10.11

What would you expect which version is newer than the other or the older one? I suppose you would say: 1.0.9.3.1 is older than 1.0.10.11 or with other words: 1.0.10.11 is newer than 1.0.9.3.1 or to express it in a more mathematical way:

1
1.0.9.3.1 < 1.0.10.11

Or another example:

  • 1.0alpha10
  • 1.0alpha2

So I assume that you have expected that Maven 2 should have handled that like this:

1
1.0alpha10 > 1.0alpha2

Unfortunately Maven 2 had handled them different because the previous versions did not follow the above pattern which results into string based comparison of the versions and finally into the following result:

1
2
1.0.9.3.1 > 1.0.10.11
1.0alpha10 < 1.0alpha2

which is obviously not the result you have expected.

Maven 3

Starting with Maven 3 (released 2010!) the version comparison has been changed but unfortunately the above myth keeps tenaciously.

So the first thing is that you can use as many digits as you like and separate them by dots. This means the following versions are valid:

Version Version
2 1
1.1 1.0
1.2.3 1.2.1
1.2.3.4 1.2.2.4
1.4.5.7.9 1.4.5.60.9
1.2.30.4.5 1.2.2.4.5
1.0.10.11 1.0.9.3.1
1.0alpha10 1.0alpha2
1.0 1.0.0

Regarding the above list which version is mathematically greater, greater or equal, less than, less or equal than the other?

Version Version
2 > 1
1.1 > 1.0
1.2.3 > 1.2.1
1.2.3.4 > 1.2.2.4
1.4.5.7.9 < 1.4.5.60.9
1.2.30.4.5 > 1.2.2.4.5
1.0.10.11 > 1.0.9.3.1
1.0alpha10 > 1.0alpha2
1.0 = 1.0.0

So what about things like 1.6.0-RC1 ? Let us assume we have the following versions:

  • 1.6.0
  • 1.6.0-RC1

So how does the comparison result look like? If you think a little you might already know the solution. The 1.6.0-RC1 is of course older than 1.6.0 or expressed mathematically:

1
1.6.0-RC1 < 1.6.0

This is because a release candidate is created before the final 1.6.0 release. So other things could be concluded out of the above like this:

1
2
1.6.0-RC3 < 1.6.0-RC10 < 1.6.0
2.34.5.6-RC3 < 2.34.5.6-RC10 < 2.34.5.6

So what about things like milestones: 1.6.0-m1?

1
1.6.0-m1 < 1.6.0 

which is this way based on the assumption made above. Milestones are before the final releases. So of course you can conclude ordering of milestones like this:

1
2
1.6.0-m1 < 1.6.0-m4
1.6.0-m4 < 1.6.0-m10

The above is also valid for the cases where we separate the milestone via a dot instead of a dash.

1
2
1.6.0.m1 < 1.6.0.m4
1.6.0.m4 < 1.6.0.m10

You can do things like the following if you like:

1
1.6.0-m1.9.9.11 < 1.6.0-m1.9.10.11

So now we come to an important thing, if we compare the following two versions 1.6.0-m1 with 1.6.0.m1. On the first glance you might think those two versions are equal because they describe a milestone with the same version 1.6.0. The result of the comparison in Maven is different:

1
1.6.0-m1 < 1.6.0.m1

This means in consequence that a part which is separated via - is less important than a part wich is separated via ., or the part which is separated via . has precedence over the part which is separated via -.

Snapshots

We have only considered releases yet. So now let us take a look at SNAPSHOTs. So let us try to see which version is before the other one in case of such version 1.6.0-SNASPHOT and 1.6.0.m1? So you might already know the result. The SNAPSHOT version is before the other one 1.6.0.m1 cause a SNAPSHOT means there has no release before of 1.6.0.

You can add the -SNAPSHOT part to each of the above examples but the results will keep the same.

Experiments

If you like to experiment with some of the above examples or check your ideas you can simply use your existing(?) Maven installation for this. Starting with Maven 3.2.5 there is a command line interface which can show you the comparision results for versions given on the command line like this:

1
java -jar apache-maven-3.2.5/lib/maven-artifact-3.2.5.jar 1.6.0 1.6.0.m1

The output will look similar like this:

1
2
3
4
Display parameters as parsed by Maven (in canonical form) and comparison result:
1. 1.6.0 == 1.6
   1.6.0 > 1.6.0-rc1
2. 1.6.0-rc1 == 1.6-rc-1

MojoHaus Build Helper Maven Plugin Version 3.0.0 Released

| Comments

The MojoHaus team is pleased to announce the release of the Build Helper Maven Plugin Version 3.0.0.

This plugin contains various small independent goals to assist with Maven build lifecycle.

To get this update, simply specify the version in your project’s plugin configuration:

1
2
3
4
5
<plugin>
  <groupId>org.codehaus.mojo</groupId>
  <artifactId>build-helper-maven-plugin</artifactId>
  <version>3.0.0</version>
</plugin>

Apache Maven Wagon Version 2.12 Released

| Comments

The Apache Maven team is pleased to announce the release of Apache Maven Wagon 2.12.

Apache Maven Wagon is a transport abstraction that is used in Maven’s artifact and repository handling code.

Release Notes – Maven Wagon – Version 2.12.

Bugs:

  • WAGON-408 – ITs for #testSecuredGet() fail with Windows
  • WAGON-426 – Fingerprints loss in known_hosts
  • WAGON-439 – Jsch issue in java 1.7 and Kerberos-enabled ssh servers
  • WAGON-449 – CLIENT not changed after setting PoolingHttpClientConnectionManager
  • WAGON-469 – wagon-http does not enable Expect-Continue by default
  • WAGON-475 – TransferEvent GET used instead of PUT and vice versa
  • WAGON-476 – HTTP Provider follows redirects on PUT and may change request method
  • WAGON-479 – Preemptive auth with HTTP Provider may fail because BasicScheme is added as completed=true to the AuthCache
  • WAGON-480 – Non-threadsafe HttpClientContext is shared between threaded use of HttpClientWagon
  • WAGON-481 – Sensitive (auth) information is not cleared when HttpClientWagon is disconnected
  • WAGON-485 – ScpWagon parses file size to int causing overflow for large files

Improvements:

  • WAGON-455 – Upgrade of ‘plexus-utils’ to version 3.0.23.
  • WAGON-458 – Implementation for FTPS
  • WAGON-460 – Upgrade plexus-utils to 3.0.24
  • WAGON-464 – Upgrade jsch dependency to 0.1.51 or newer to support ECDSA host key typess
  • WAGON-465 – wagon-ssh: add API option to check for remote exit code
  • WAGON-466 – wagon-ssh: Better error message when ssh account is locked
  • WAGON-467 – wagon-ssh: options to configure hostKeyChecking and PreferredAuthentications
  • WAGON-472 – Upgrade Commons IO to 2.5
  • WAGON-484 – Update WebDAV Provider naming

Tasks:

  • WAGON-389 – Incorrect versions on gh-pages
  • WAGON-447 – Remove Commons Lang 2 for a few cases
  • WAGON-457 – Wagon tests fail on Windows because Subversion crashes on a test repo
  • WAGON-470 – Update TLS certificates for HTTPS tests
  • WAGON-471 – Clean up dependency mess (reported by dependency:analyze)
  • WAGON-473 – Don’t abuse IllegalArgumentException to intercept null input
  • WAGON-474 – Upgrade and revise all tests for Jetty 8
  • WAGON-483 – Upgrade SLF4J to 1.7.22

Enjoy,

-The Apache Maven team

Apache Maven Shade Plugin Version 3.0.0 Released

| Comments

The Apache Maven team is pleased to announce the release of the Apache Maven Shade Plugin, version 3.0.0.

This plugin provides the capability to package the artifact in an uber-jar, including its dependencies and to shade – i.e. rename – the packages of some of the dependencies.

You should specify the version in your project’s plugin configuration:

1
2
3
4
5
<plugin>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-shade-plugin</artifactId>
  <version>3.0.0</version>
</plugin>

You can download the appropriate sources etc. from the download page.

Apache Maven Shared Invoker Version 3.0.0 Released

| Comments

The Apache Maven team is pleased to announce the release of the Apache Maven Shared Maven Invoker, version 3.0.0

This API is concerned with firing a Maven build in a new JVM. It accomplishes its task by building up a conventional Maven command line from options given in the current request, along with those global options specified in the invoker itself. Once it has the command line, the invoker will execute it, and capture the resulting exit code or any exception thrown to signal a failure to execute. Input/output control can be specified using an InputStream and up to two InvocationOutputHandlers.

You can download the appropriate sources etc. from the download page.

1
2
3
4
5
6
7
<dependencies>
  <dependency>
    <groupId>org.apache.maven.shared</groupId>
    <artifactId>maven-invoker</artifactId>
    <version>3.0.0</version>
  </dependency>
</dependencies>

Apache Maven Compiler Plugin Version 3.6.1 Released

| Comments

The Apache Maven team is pleased to announce the release of the Apache Maven Compiler Plugin, version 3.6.1.

The Compiler Plugin is used to compile the sources of your project.

Attention: Starting with version 3.5, the maven-compiler-plugin requires Maven 3 and won’t work with Maven 2 anymore.

You should specify the version in your project’s plugin configuration:

1
2
3
4
5
<plugin>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-compiler-plugin</artifactId>
  <version>3.6.1</version>
</plugin>

Most important change is the support for test-compile when using JDK 9 build b148+

MojoHaus License Maven Plugin Version 1.12 Released

| Comments

The Mojo team is pleased to announce the release of the License Maven Plugin, version 1.12.

This plugin manages the license of a maven project and its dependencies (update file headers, download dependencies licenses, check thirdparty licenses, …).

To get this update, simply specify the version in your project`s plugin configuration:

1
2
3
4
5
<plugin>
  <groupId>org.codehaus.mojo</groupId>
  <artifactId>license-maven-plugin</artifactId>
  <version>1.12</version>
</plugin>

Release Notes for License Maven Plugin Version 1.12

http://www.mojohaus.org/license-maven-plugin/github-report.html

Enjoy,

The Mojo team.

Tony

The Jenkins API Client for Java Version 0.3.7 Released

| Comments

We have released a new version of the The Jenkins API client for Java. The new released 0.3.7 contains several bugfixes and new features. Detailed information about the changes can be found in the release notes.

This is the second release under the Jenkins Github Organization umbrella.

  • Build class offers now two different methods to get the test informations. Using either getTestResult() for non maven type jobs or getTestReport() for maven type jobs.

  • New methods have been added to change the description of a job. The display name and/or the description of a build can be changed.

  • Added new helper class has been added to trigger a job wait until the job is finished.

  • All build methods of Job now consistently giving back a QueueReference.

  • Now you can request to get all builds back of a job which was not possible in previous releases.

The Jenkins API client for Java allows you to get informations about builds for example the duration of a build or test report informations.

Details API changes are documented in the release notes.