Hi,
Jesfre wrote at Freitag, 3. Juli 2009 08:45:
> Jörg Schaible-2 wrote:
>>
>> Jesfre wrote at Freitag, 3. Juli 2009 01:05:
>>
>>>
>>> Hi everyone...
>>> I have an error with this description... And I'm confused because I run
>>> ">mvn clean install" with SUCCESSFUL result but when I try to run it on
>>> the host of the customer the build fails... And, more rare, fails only
>>> with webapp submodules...
>>
>> [snip]
>>
>>> [INFO] Trace
>>> com.thoughtworks.xstream.converters.reflection.ObjectAccessException:
>>> Invalid final field
>>> org.apache.maven.plugin.war.util.DependencyInfo.dependency
>>> at
>>>
>>
com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.validateFieldAccess(Ljava.lang.reflect.Field;)V(PureJavaReflectionProvider.java:161)
>>> at
>>>
>>
com.thoughtworks.xstream.converters.reflection.PureJavaReflectionProvider.visitSerializableFields(Ljava.lang.Object;Lcom.thoughtworks.xstream.converters.reflection.ReflectionProvider$Visitor;)V(PureJavaReflectionProvider.java:114)
>>> at
>>>
>>
com.thoughtworks.xstream.converters.reflection.AbstractReflectionConverter.doMarshal(Ljava.lang.Object;Lcom.thoughtworks.xstream.io.HierarchicalStreamWriter;Lcom.thoughtworks.xstream.converters.MarshallingContext;)V(AbstractReflectionConverter.java:51)
>>
>> [snip]
>>
>> Which JDK version of what vendor is on the host?
>
> Sorry...
> I'm using:
>
> Maven 2
> JDK 1.4
> App server Weblogic 8.1 SP3
> Platform Linux
OK. Can you open a JIRA issue in the war plugin? The version you're using is
not JDK 1.4 compatible, but I simply guess that the developer was not aware
of it.
Background: XStream is a small library converting objects to XML and back.
The developers of the war plugin used it to convert somewhere between this
DependencyInfo and XML. However, this type has a final field "dependency".
Since JDK 5 it is possible to write into final fields using reflection (see
Javadoc), but it is simply not possible with JDK 1.4. For JDK 1.4 support
the field may not be declared final.
- Jörg
---------------------------------------------------------------------
To unsubscribe, e-mail:
users-unsubscribe@...
For additional commands, e-mail:
users-help@...