Andrei Silviu Dragnea opened MSHARED-1045 and commented
#2 breaks binary backwards compatibility of interface MavenReport, because replacing org.codehaus.doxia.sink.Sink with org.apache.maven.doxia.sink.Sink changes the signature of method:
void generate( Sink sink, Locale locale ) throws MavenReportException;
So nothing compiled against version 3.0 of the maven-reporting-api works with 3.1.0 anymore.
I suggest either reverting this commit in a new release or updating the code in a backwards-compatible manner with two mutually recursive default implementations for both the old and new signature (this requires Java 8 support though):
@Deprecated
default void generate( org.codehaus.doxia.sink.Sink sink, Locale locale ) throws MavenReportException {
generate((Sink) sink, locale);
}
default void generate( Sink sink, Locale locale ) throws MavenReportException {
generate((org.codehaus.doxia.sink.Sink) sink, locale);
}
The solution above can result in ClassCastExceptions though, because some org.apache.maven.doxia.sink.Sink maybe do not implement org.codehaus.doxia.sink. I do not know any way of safely evolving the type of an input parameter for a method.
Issue Links:
Andrei Silviu Dragnea opened MSHARED-1045 and commented
#2 breaks binary backwards compatibility of interface
MavenReport, because replacingorg.codehaus.doxia.sink.Sinkwithorg.apache.maven.doxia.sink.Sinkchanges the signature of method:So nothing compiled against version
3.0of themaven-reporting-apiworks with3.1.0anymore.I suggest either reverting this commit in a new release or updating the code in a backwards-compatible manner with two mutually recursive default implementations for both the old and new signature (this requires Java 8 support though):
The solution above can result in
ClassCastExceptions though, because someorg.apache.maven.doxia.sink.Sinkmaybe do not implementorg.codehaus.doxia.sink. I do not know any way of safely evolving the type of an input parameter for a method.Issue Links:
("is fixed by")
("is caused by")