You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Gerhard Wipplinger <ge...@gmail.com> on 2012/01/05 19:16:19 UTC

Maven3 LinkageError in maven report

Hi,

I tried to create a maven report using some kind of a filter sink:

public class DoxiaTestMojo extends AbstractMavenReport {

...

  @Override
  protected void executeReport(Locale locale) throws
MavenReportException {
      org.apache.maven.doxia.sink.Sink s = new SinkAdapter() {
              ...
      };
      ... 
  }
}

If I execute this report I get the following error:

[WARNING] An issue has occurred with report at.gw.test.DoxiaTestMojo,
skip LinkageError loader constraint violation in interface itable
initialization: when resolving method
"org.apache.maven.doxia.sink.AbstractSink.enableLogging(Lorg/apache/maven/doxia/logging/Log;)V" the class loader (instance of org/codehaus/plexus/classworlds/realm/ClassRealm) of the current class, org/apache/maven/doxia/sink/AbstractSink, and the class loader (instance of org/codehaus/plexus/classworlds/realm/ClassRealm) for interface org/apache/maven/doxia/logging/LogEnabled have different Class objects for the type org/apache/maven/doxia/logging/Log used in the signature, please report an issue to Maven dev team.

I think the problem is that the interfaces of the doxia-logging-api are
not imported to the class realm of the report ...


Does anyone has a workaround for this?


Thanks,
Gerhard



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Maven3 LinkageError in maven report

Posted by Gerhard Wipplinger <ge...@gmail.com>.
I'm already using getSink(), but I wanted to put a sink between the
provided sink and multiple doxia parsers.
I thought it's useful if multiple pages has to be aggregated to one
page and some extra work has to be done, e.g. resolve links to anchors
between different different source documents (in this case I need a
two-pass approach).

On Thu, Jan 5, 2012 at 9:59 PM, Olivier Lamy <ol...@apache.org> wrote:
> Hello,
>
> I wonder why you create a sink ?
> If your mojo extends AbstractMavenReport just use getSink().
>
>
> 2012/1/5 Gerhard Wipplinger <ge...@gmail.com>:
>> Hi,
>>
>> I tried to create a maven report using some kind of a filter sink:
>>
>> public class DoxiaTestMojo extends AbstractMavenReport {
>>
>> ...
>>
>>  @Override
>>  protected void executeReport(Locale locale) throws
>> MavenReportException {
>>      org.apache.maven.doxia.sink.Sink s = new SinkAdapter() {
>>              ...
>>      };
>>      ...
>>  }
>> }
>>
>> If I execute this report I get the following error:
>>
>> [WARNING] An issue has occurred with report at.gw.test.DoxiaTestMojo,
>> skip LinkageError loader constraint violation in interface itable
>> initialization: when resolving method
>> "org.apache.maven.doxia.sink.AbstractSink.enableLogging(Lorg/apache/maven/doxia/logging/Log;)V" the class loader (instance of org/codehaus/plexus/classworlds/realm/ClassRealm) of the current class, org/apache/maven/doxia/sink/AbstractSink, and the class loader (instance of org/codehaus/plexus/classworlds/realm/ClassRealm) for interface org/apache/maven/doxia/logging/LogEnabled have different Class objects for the type org/apache/maven/doxia/logging/Log used in the signature, please report an issue to Maven dev team.
>>
>> I think the problem is that the interfaces of the doxia-logging-api are
>> not imported to the class realm of the report ...
>>
>>
>> Does anyone has a workaround for this?
>>
>>
>> Thanks,
>> Gerhard
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>
>
>
>
> --
> Olivier Lamy
> Talend: http://coders.talend.com
> http://twitter.com/olamy | http://linkedin.com/in/olamy
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Maven3 LinkageError in maven report

Posted by Olivier Lamy <ol...@apache.org>.
Hello,

I wonder why you create a sink ?
If your mojo extends AbstractMavenReport just use getSink().


2012/1/5 Gerhard Wipplinger <ge...@gmail.com>:
> Hi,
>
> I tried to create a maven report using some kind of a filter sink:
>
> public class DoxiaTestMojo extends AbstractMavenReport {
>
> ...
>
>  @Override
>  protected void executeReport(Locale locale) throws
> MavenReportException {
>      org.apache.maven.doxia.sink.Sink s = new SinkAdapter() {
>              ...
>      };
>      ...
>  }
> }
>
> If I execute this report I get the following error:
>
> [WARNING] An issue has occurred with report at.gw.test.DoxiaTestMojo,
> skip LinkageError loader constraint violation in interface itable
> initialization: when resolving method
> "org.apache.maven.doxia.sink.AbstractSink.enableLogging(Lorg/apache/maven/doxia/logging/Log;)V" the class loader (instance of org/codehaus/plexus/classworlds/realm/ClassRealm) of the current class, org/apache/maven/doxia/sink/AbstractSink, and the class loader (instance of org/codehaus/plexus/classworlds/realm/ClassRealm) for interface org/apache/maven/doxia/logging/LogEnabled have different Class objects for the type org/apache/maven/doxia/logging/Log used in the signature, please report an issue to Maven dev team.
>
> I think the problem is that the interfaces of the doxia-logging-api are
> not imported to the class realm of the report ...
>
>
> Does anyone has a workaround for this?
>
>
> Thanks,
> Gerhard
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>



-- 
Olivier Lamy
Talend: http://coders.talend.com
http://twitter.com/olamy | http://linkedin.com/in/olamy

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org