Mantis Bugtracker
  

Viewing Issue Advanced Details [ Jump to Notes ] [ View Simple ] [ Issue History ] [ Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0004971 [Resin] major always 03-01-12 04:23 09-11-14 11:19
Reporter RLM View Status public  
Assigned To ferg
Priority normal Resolution won't fix Platform
Status closed   OS
Projection none   OS Version
ETA none Fixed in Version Product Version 4.0.14
  Product Build
Summary 0004971: resin-maven-plugin ignoring resin.version
Description When using the resin-maven-plugin version 4.0.14 (for Resin 4.0.15 as there is no plugin for .15) the property -Dresin.version is ignored.

The .pom say the License is GPL 2.0
I could not find the source code anywhere so I had to use a decompiler.

It seems that the method buildVersionedWarTag in AbstractDeployMojo class is just calling the method buildWarTag NOT adding the version info to the returned CommitBuilder.

Please find my modified version in the attached file (buildVersionedWarTag.java)
This version checks to see if any version info is given. If not the CommitBuilder is returned "as-is".
Otherwise the version-string is split and set on the CommitBuilder before returning it.

This implementation expects the version given in "sane" format. That is
- its build by up to 4 parts divided by .
- the first 3 parts (if present) need to be parseable to int
- the 4th part is an optional string

Can you please implement this (or simular) fix at least back to version 4.0.14 of the resin-maven-plugin? and release new versions?

Best regards

René Markvard
Steps To Reproduce
Additional Information
Attached Files  buildVersionedWarTag.java [^] (492 bytes) 03-01-12 04:23
 buildVersionedWarTag.v2.java [^] (693 bytes) 03-01-12 23:47
 MavenCopyTag#doTask.java [^] (757 bytes) 03-01-12 23:48

- Relationships

- Notes
(0005703)
RLM
03-01-12 05:36

This implementation gives NPE when no version is given. I have made a fix which I'm about to test right now.

There is also a fix on the way for MavenCopyTag not using the version for sourceTag.

I will test both and send a Fix for both later.
 
(0005705)
RLM
03-01-12 23:54

The file buildVersionedWarTag.v2.java contains a fix for the NPE

Also the version-handling code has been moved to a seperate protected function to enable the fix given in MavenCopyTag#doTask.java.
This fixes the issue that MavenCopyTag also ignored the version given.

While playing around with resin:query-tags i figured that it almost never make sence NOT to use the -Dresin.pattern parameter as using the CommitBuilder will also use the various default values in that Class.
Using the -Dresin.pattern parameter is also the only way of defining af regex pattern for version.
 
(0006518)
ferg
09-11-14 11:19

resin-maven-plugin is discontinued.
 

- Issue History
Date Modified Username Field Change
03-01-12 04:23 RLM New Issue
03-01-12 04:23 RLM File Added: buildVersionedWarTag.java
03-01-12 05:36 RLM Note Added: 0005703
03-01-12 05:36 RLM Issue Monitored: RLM
03-01-12 23:47 RLM File Added: buildVersionedWarTag.v2.java
03-01-12 23:48 RLM File Added: MavenCopyTag#doTask.java
03-01-12 23:54 RLM Note Added: 0005705
09-11-14 11:19 ferg Note Added: 0006518
09-11-14 11:19 ferg Assigned To  => ferg
09-11-14 11:19 ferg Status new => closed
09-11-14 11:19 ferg Resolution open => won't fix


Mantis 1.0.0rc3[^]
Copyright © 2000 - 2005 Mantis Group
37 total queries executed.
28 unique queries executed.
Powered by Mantis Bugtracker