[GitHub] [maven-enforcer] KroArtem commented on a change in pull request #86: [MENFORCER-376] Add excludes/includes functionality to RequireJavaVendor rule

2021-01-26 Thread GitBox


KroArtem commented on a change in pull request #86:
URL: https://github.com/apache/maven-enforcer/pull/86#discussion_r565083783



##
File path: 
enforcer-rules/src/main/java/org/apache/maven/plugins/enforcer/RequireJavaVendor.java
##
@@ -31,40 +33,112 @@
  */
 public class RequireJavaVendor extends AbstractNonCacheableEnforcerRule
 {
-private String name;
+/**
+ * Specify the banned vendors. This should be an exact match of the System 
Property
+ * java.vendor, which you can also see with mvn --version. 
+ * The rule will fail if vendor name matches any exclude, unless it also 
matches an
+ * include rule.
+ *
+ * Some examples are:
+ * 
+ * AdoptOpenJDK prohibits vendor name AdoptOpenJDK 
+ * Amazon prohibits vendor name Amazon 
+ * 
+ *
+ * @see #setExcludes(List)
+ * @see #getExcludes()
+ */
+private List excludes = null;
+
+/**
+ * Specify the allowed vendor names. This should be an exact match of the 
System Property
+ * java.vendor, which you can also see with mvn --version. 
+ * Includes override the exclude rules.
+ *
+ * @see #setIncludes(List)
+ * @see #getIncludes()
+ */
+private List includes = null;
 
 @Override
 public void execute( EnforcerRuleHelper helper ) throws 
EnforcerRuleException
 {
-if ( !SystemUtils.JAVA_VENDOR.equals( name ) )
+if ( excludes != null )
 {
-String message = getMessage();
-String error = "Vendor " + SystemUtils.JAVA_VENDOR + " did not 
match required vendor " + name;
-StringBuilder sb = new StringBuilder();
-if ( message != null )
+if ( excludes.contains( SystemUtils.JAVA_VENDOR ) )
 {
-sb.append( message ).append( System.lineSeparator() );
+if ( includes != null )
+{
+if ( !includes.contains( SystemUtils.JAVA_VENDOR ) )
+{
+createException();
+}
+return;
+}
+createException();
 }
-
-sb.append( error );
-
-throw new EnforcerRuleException( sb.toString() );
 }
 }
 
 /**
- * Specify the required name. Some examples are:
- * Name should be an exact match of the System Property java.vendor, which 
you can also see with mvn --version
+ * Gets the excludes.
  *
- * 
- * AdoptOpenJDK enforces vendor name AdoptOpenJDK 
- * Amazon enforces vendor name Amazon 
- * 
+ * @return the excludes
+ */
+public List getExcludes()
+{
+return this.excludes;
+}
+
+/**
+ * Specify the banned vendors. This should be an exact match of the System 
Property
+ * java.vendor, which you can also see with mvn --version. 
+ * The rule will fail if vendor name matches any exclude, unless it also 
matches an
+ * include rule.
+ *
+ * @see #getExcludes()
+ * @param theExcludes the excludes to set
+ */
+public void setExcludes( List theExcludes )
+{
+this.excludes = theExcludes;
+}
+
+/**
+ * Gets the includes.
  *
- * @param name the required name to set
+ * @return the includes
  */
-public final void setName( String name )
+public List getIncludes()
 {
-this.name = name;
+return this.includes;
+}
+
+/**
+ * Specify the allowed vendor names. This should be an exact match of the 
System Property
+ * java.vendor, which you can also see with mvn --version. 
+ * Includes override the exclude rules.
+ * *
+ * @see #setIncludes(List)
+ * @param theIncludes the includes to set
+ */
+public void setIncludes( List theIncludes )
+{
+this.includes = theIncludes;
+}
+
+private void createException() throws EnforcerRuleException
+{
+String message = getMessage();
+String error = "Vendor " + SystemUtils.JAVA_VENDOR + " is in a list of 
banned vendors: " + excludes;
+StringBuilder sb = new StringBuilder();
+if ( message != null )
+{
+sb.append( message ).append( System.lineSeparator() );

Review comment:
   ok, I'll fix it today. Just understood that documentation 
(`requireJavaVendor.apt.vm`) has to be updated too.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on pull request #437: [MNG-7082] - remove deprecation on org.apache.maven.plugin.logging.Log

2021-01-26 Thread GitBox


McFoggy commented on pull request #437:
URL: https://github.com/apache/maven/pull/437#issuecomment-768091466


   @rmannibucau finally I only removed depreciation on 
`org.apache.maven.plugin.logging.Log`, there was a consensus for this point 
let's stick to it.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-enforcer] bmarwell commented on a change in pull request #86: [MENFORCER-376] Add excludes/includes functionality to RequireJavaVendor rule

2021-01-26 Thread GitBox


bmarwell commented on a change in pull request #86:
URL: https://github.com/apache/maven-enforcer/pull/86#discussion_r565072990



##
File path: 
enforcer-rules/src/main/java/org/apache/maven/plugins/enforcer/RequireJavaVendor.java
##
@@ -31,40 +33,112 @@
  */
 public class RequireJavaVendor extends AbstractNonCacheableEnforcerRule
 {
-private String name;
+/**
+ * Specify the banned vendors. This should be an exact match of the System 
Property
+ * java.vendor, which you can also see with mvn --version. 
+ * The rule will fail if vendor name matches any exclude, unless it also 
matches an
+ * include rule.
+ *
+ * Some examples are:
+ * 
+ * AdoptOpenJDK prohibits vendor name AdoptOpenJDK 
+ * Amazon prohibits vendor name Amazon 
+ * 
+ *
+ * @see #setExcludes(List)
+ * @see #getExcludes()
+ */
+private List excludes = null;
+
+/**
+ * Specify the allowed vendor names. This should be an exact match of the 
System Property
+ * java.vendor, which you can also see with mvn --version. 
+ * Includes override the exclude rules.
+ *
+ * @see #setIncludes(List)
+ * @see #getIncludes()
+ */
+private List includes = null;
 
 @Override
 public void execute( EnforcerRuleHelper helper ) throws 
EnforcerRuleException
 {
-if ( !SystemUtils.JAVA_VENDOR.equals( name ) )
+if ( excludes != null )
 {
-String message = getMessage();
-String error = "Vendor " + SystemUtils.JAVA_VENDOR + " did not 
match required vendor " + name;
-StringBuilder sb = new StringBuilder();
-if ( message != null )
+if ( excludes.contains( SystemUtils.JAVA_VENDOR ) )
 {
-sb.append( message ).append( System.lineSeparator() );
+if ( includes != null )
+{
+if ( !includes.contains( SystemUtils.JAVA_VENDOR ) )
+{
+createException();
+}
+return;
+}
+createException();
 }
-
-sb.append( error );
-
-throw new EnforcerRuleException( sb.toString() );
 }
 }
 
 /**
- * Specify the required name. Some examples are:
- * Name should be an exact match of the System Property java.vendor, which 
you can also see with mvn --version
+ * Gets the excludes.
  *
- * 
- * AdoptOpenJDK enforces vendor name AdoptOpenJDK 
- * Amazon enforces vendor name Amazon 
- * 
+ * @return the excludes
+ */
+public List getExcludes()
+{
+return this.excludes;
+}
+
+/**
+ * Specify the banned vendors. This should be an exact match of the System 
Property
+ * java.vendor, which you can also see with mvn --version. 
+ * The rule will fail if vendor name matches any exclude, unless it also 
matches an
+ * include rule.
+ *
+ * @see #getExcludes()
+ * @param theExcludes the excludes to set
+ */
+public void setExcludes( List theExcludes )
+{
+this.excludes = theExcludes;
+}
+
+/**
+ * Gets the includes.
  *
- * @param name the required name to set
+ * @return the includes
  */
-public final void setName( String name )
+public List getIncludes()
 {
-this.name = name;
+return this.includes;
+}
+
+/**
+ * Specify the allowed vendor names. This should be an exact match of the 
System Property
+ * java.vendor, which you can also see with mvn --version. 
+ * Includes override the exclude rules.
+ * *
+ * @see #setIncludes(List)
+ * @param theIncludes the includes to set
+ */
+public void setIncludes( List theIncludes )
+{
+this.includes = theIncludes;
+}
+
+private void createException() throws EnforcerRuleException
+{
+String message = getMessage();
+String error = "Vendor " + SystemUtils.JAVA_VENDOR + " is in a list of 
banned vendors: " + excludes;
+StringBuilder sb = new StringBuilder();
+if ( message != null )
+{
+sb.append( message ).append( System.lineSeparator() );

Review comment:
   @KroArtem I think this might be the only fix needed. Rest looks fine to 
me.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-enforcer] bmarwell commented on a change in pull request #86: [MENFORCER-376] Add excludes/includes functionality to RequireJavaVendor rule

2021-01-26 Thread GitBox


bmarwell commented on a change in pull request #86:
URL: https://github.com/apache/maven-enforcer/pull/86#discussion_r565072791



##
File path: 
enforcer-rules/src/main/java/org/apache/maven/plugins/enforcer/RequireJavaVendor.java
##
@@ -31,40 +33,112 @@
  */
 public class RequireJavaVendor extends AbstractNonCacheableEnforcerRule
 {
-private String name;
+/**
+ * Specify the banned vendors. This should be an exact match of the System 
Property
+ * java.vendor, which you can also see with mvn --version. 
+ * The rule will fail if vendor name matches any exclude, unless it also 
matches an
+ * include rule.
+ *
+ * Some examples are:
+ * 
+ * AdoptOpenJDK prohibits vendor name AdoptOpenJDK 
+ * Amazon prohibits vendor name Amazon 
+ * 
+ *
+ * @see #setExcludes(List)
+ * @see #getExcludes()
+ */
+private List excludes = null;
+
+/**
+ * Specify the allowed vendor names. This should be an exact match of the 
System Property
+ * java.vendor, which you can also see with mvn --version. 
+ * Includes override the exclude rules.
+ *
+ * @see #setIncludes(List)
+ * @see #getIncludes()
+ */
+private List includes = null;
 
 @Override
 public void execute( EnforcerRuleHelper helper ) throws 
EnforcerRuleException
 {
-if ( !SystemUtils.JAVA_VENDOR.equals( name ) )
+if ( excludes != null )
 {
-String message = getMessage();
-String error = "Vendor " + SystemUtils.JAVA_VENDOR + " did not 
match required vendor " + name;
-StringBuilder sb = new StringBuilder();
-if ( message != null )
+if ( excludes.contains( SystemUtils.JAVA_VENDOR ) )
 {
-sb.append( message ).append( System.lineSeparator() );
+if ( includes != null )
+{
+if ( !includes.contains( SystemUtils.JAVA_VENDOR ) )
+{
+createException();
+}
+return;
+}
+createException();
 }
-
-sb.append( error );
-
-throw new EnforcerRuleException( sb.toString() );
 }
 }
 
 /**
- * Specify the required name. Some examples are:
- * Name should be an exact match of the System Property java.vendor, which 
you can also see with mvn --version
+ * Gets the excludes.
  *
- * 
- * AdoptOpenJDK enforces vendor name AdoptOpenJDK 
- * Amazon enforces vendor name Amazon 
- * 
+ * @return the excludes
+ */
+public List getExcludes()
+{
+return this.excludes;
+}
+
+/**
+ * Specify the banned vendors. This should be an exact match of the System 
Property
+ * java.vendor, which you can also see with mvn --version. 
+ * The rule will fail if vendor name matches any exclude, unless it also 
matches an
+ * include rule.
+ *
+ * @see #getExcludes()
+ * @param theExcludes the excludes to set
+ */
+public void setExcludes( List theExcludes )
+{
+this.excludes = theExcludes;
+}
+
+/**
+ * Gets the includes.
  *
- * @param name the required name to set
+ * @return the includes
  */
-public final void setName( String name )
+public List getIncludes()

Review comment:
   Probably just an oversight that this was never part of a release. 
Happens to all of us. :) 





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex edited a comment on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex edited a comment on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767947574


   > Maybe you want to contribute instead of micro-managing my edits? ๐Ÿ˜‰
   
   After having checked all your code review suggestions plus all the other 
places I changed which you did not even mention, my assumption was confirmed 
that collaboratively working on this would have saved time. If you had just 
checked out the PR and tried to flip types in your IDE, you would have noticed. 
I think that code reviews outside of an IDE which actually compiles are not 
particularly helpful in this case where it is about changing types in order to 
avoid casting. So - no offence meant - this was a waste of time for both of us 
and I want to re-invite you to piggy-back on my PR and just commit whatever 
improvements you have for it. Before you could even write "could you edit this 
like that?", you would have done it already with no more time spent but without 
me spending time on checking, commenting back, you reading the comments again.
   
   We could
 * avoid micro-management,
 * save time,
 * get better code faster,
 * avoid some of the [7 wastes of lean 
production](https://agilecoachdiaries.wordpress.com/2017/01/19/lean-software-development-7-wastes-of-software-development/),
 such as hand-offs, stretching the cycle time by scattering the touch times 
across a longer than necessary time frame, in turn requiring more context 
changes for both of us, trying to remember where we left off last time. You are 
a busy developer and doing OSS in your spare time, I assume. Even if someone 
pays you for it, you do not want to create waste.
 
   Sorry for lobbying here and making this a general discussion, but I always 
do that when contributing to a project for the first time in order to find out 
if it would be attractive for me to contribute again in the future. I am 
strictly against the policy in so many OSS projects that PRs get micro-managed 
in many iterations up to the point in which the contributor, not unlike a 
remote-controlled puppet, has shaped the code into something resembling what 
the reviewer would have written by herself. Better to accept an imperfect, but 
valuable PR and help polishing it by yourself. Then chances are much higher 
that the code ends up the way you like it as a maintainer. Also, the 
contributor can learn from the edits. Win-win.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex edited a comment on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex edited a comment on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767947574


   > Maybe you want to contribute instead of micro-managing my edits? ๐Ÿ˜‰
   
   After having checked all your code review suggestions plus all the other 
places I changed which you did not even mention, my assumption was confirmed 
that collaboratively working on this would have saved time. If you had just 
checked out the PR and tried to flip types in your IDE, you would have noticed. 
I think that code reviews outside of an IDE which actually compiles are not 
particularly helpful in this case where it is about changing types in order to 
avoid casting. So - no offence meant - this was a waste of time for both of us 
and I want to re-invite you to piggy-back on my PR and just commit whatever 
improvements you have for it. Before you could even write "could you edit this 
like that?", you would have done it already with no more time spent but without 
me spending time on checking, commenting back, you reading the comments again.
   
   We could
 * avoid micro-management,
 * save time,
 * get better code faster,
 * avoid some of the [7 wastes of lean 
production](https://agilecoachdiaries.wordpress.com/2017/01/19/lean-software-development-7-wastes-of-software-development/),
 such as hand-offs, stretching the cycle time by scattering the touch times 
across a longer than necessary time frame, in turn requiring more context 
changes for both of us, trying to remember where we left off last time. You are 
a busy developer and doing OSS in your spare time, I assume. Even if someone 
pays you for it, you do not want to create waste.
 
   Sorry for lobbying here and making this a general discussion, but I always 
do that when contributing to a project for the first time in order to find out 
if it would be attractive for me to contribute again in the future. I am 
strictly against the policy in so many OSS projects that PRs get micro-managed 
in many iterations up to the point in which the contributor, not unlike a 
remote-controlled puppet, has shaped the code into something the reviewer would 
have written. Better to accept an imperfect, but valuable PR and help polishing 
it by yourself. Then the chances are much higher that the code ends up the way 
you like it as a maintainer. Also, the contributor can learn from the edits. 
Win-win.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex edited a comment on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex edited a comment on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767947574


   > Maybe you want to contribute instead of micro-managing my edits? ๐Ÿ˜‰
   
   After having checked all your code review suggestions plus all the other 
places I changed which you did not even mention, my assumption was confirmed 
that collaboratively working on this would have saved time. If you had just 
checked out the PR and tried to flip types in your IDE, you would have noticed. 
I think that code reviews outside of an IDE which actually compiles are not 
particularly helpful in this case where it is about changing types in order to 
avoid casting. So - no offence meant - this was a waste of time for both of us 
and I want to re-invite you to piggy-back on my PR and just commit whatever 
improvements you have for it. Before you could even write "could you edit this 
like that?", you would have done it already with no more time spent but without 
me spending time on checking, commenting back, you reading the comments again.
   
   We could
 * avoid micro-management,
 * save time,
 * get better code faster,
 * avoid some of the [7 wastes of lean 
production](https://agilecoachdiaries.wordpress.com/2017/01/19/lean-software-development-7-wastes-of-software-development/),
 such as hand-offs, stretching the cycle time by scattering the touch times 
across a longer than necessary time frame, in turn requiring more context 
changes for both of us, trying to remember where we left off last time. You are 
a busy developer and doing OSS in your spare time, I assume. Even if someone 
pays you for it, you do not want to create waste.
 
   Sorry for lobbying here and making this a general discussion, but I always 
do that when contributing to a project for the first time in order to find out 
if it would be attractive for me to contribute again in the future. I am 
strictly against the policy in so many OSS projects that PRs get micro-managed 
in many iterations up to the point in which the contributor has shaped the code 
into something the reviewer would have written. Better to accept an imperfect, 
but valuable PR and help polishing it by yourself. Then the chances are much 
higher that the code ends up the way you like it as a maintainer. Also, the 
contributor can learn from the edits. Win-win.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Comment Edited] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Alexander Kriegisch (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272513#comment-17272513
 ] 

Alexander Kriegisch edited comment on SUREFIRE-1882 at 1/27/21, 2:42 AM:
-

I think that enforcing only the *byte code version* would not solve the 
problem. We need to make sure that the code is compiled against the *JDK 8 
API*, too. I have never used the Javac 9+ compiler switch {{--release}} or the 
corresponding Maven Compiler option {{}}, but is that not what we need 
here? If I understand this option correctly, it would lead to compile errors 
when using Java 9+ specific APIs incompatible with Java 8.

References:
  * 
https://maven.apache.org/plugins/maven-compiler-plugin/compile-mojo.html#release
  * https://stackoverflow.com/a/43103038/1082681


was (Author: kriegaex):
I think that enforcing only the *byte code version* would not solve the 
problem. We need to make sure that the code is compiled against the *JDK 8 
API*, too. I have never used the Javac 9+ compiler switch {{--release}} or the 
corresponding Maven Compiler option {{}}, but is that not what we need 
here? If I understand this option correctly, it would lead to compile errors 
when using Java 9+ specific APIs incompatible to Java 8.

References:
  * 
https://maven.apache.org/plugins/maven-compiler-plugin/compile-mojo.html#release
  * https://stackoverflow.com/a/43103038/1082681

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.

[jira] [Comment Edited] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Alexander Kriegisch (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272513#comment-17272513
 ] 

Alexander Kriegisch edited comment on SUREFIRE-1882 at 1/27/21, 2:41 AM:
-

I think that enforcing only the *byte code version* would not solve the 
problem. We need to make sure that the code is compiled against the *JDK 8 
API*, too. I have never used the Javac 9+ compiler switch {{--release}} or the 
corresponding Maven Compiler option {{}}, but is that not what we need 
here? If I understand this option correctly, it would lead to compile errors 
when using Java 9+ specific APIs incompatible to Java 8.

References:
  * 
https://maven.apache.org/plugins/maven-compiler-plugin/compile-mojo.html#release
  * https://stackoverflow.com/a/43103038/1082681


was (Author: kriegaex):
I think that enforcing only the *byte code version* would not solve the 
problem. We need to make sure that the code is compiled against the *JDK 8 
API*, too. I have never used the Javac 9+ compiler switch `--release` or the 
corresponding Maven Compiler option ``, but is that not what we need 
here? If I understand this option correctly, it would lead to compile errors 
when using Java 9+ specific APIs incompatible to Java 8.

References:
  * 
https://maven.apache.org/plugins/maven-compiler-plugin/compile-mojo.html#release
  * https://stackoverflow.com/a/43103038/1082681

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.

[jira] [Comment Edited] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Alexander Kriegisch (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272513#comment-17272513
 ] 

Alexander Kriegisch edited comment on SUREFIRE-1882 at 1/27/21, 1:56 AM:
-

I think that enforcing only the *byte code version* would not solve the 
problem. We need to make sure that the code is compiled against the *JDK 8 
API*, too. I have never used the Javac 9+ compiler switch `--release` or the 
corresponding Maven Compiler option ``, but is that not what we need 
here? If I understand this option correctly, it would lead to compile errors 
when using Java 9+ specific APIs incompatible to Java 8.

References:
  * 
https://maven.apache.org/plugins/maven-compiler-plugin/compile-mojo.html#release
  * https://stackoverflow.com/a/43103038/1082681


was (Author: kriegaex):
I think that enforcing only the *byte code version* would not solve the 
problem. We need to make sure that the code is compiled against the *JDK 8 
API,* too. I have never used the Javac 9+ compiler switch `--release` or the 
corresponding Maven Compiler option ``, but is that not what we need 
here? If I understand this option correctly, it would lead to compile errors 
when using Java 9+ specific APIs incompatible to Java 8.

References:
  * 
https://maven.apache.org/plugins/maven-compiler-plugin/compile-mojo.html#release
  * https://stackoverflow.com/a/43103038/1082681

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plug

[jira] [Comment Edited] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Alexander Kriegisch (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272513#comment-17272513
 ] 

Alexander Kriegisch edited comment on SUREFIRE-1882 at 1/27/21, 1:55 AM:
-

I think that enforcing only the *byte code version* would not solve the 
problem. We need to make sure that the code is compiled against the *JDK 8 
API,* too. I have never used the Javac 9+ compiler switch `--release` or the 
corresponding Maven Compiler option ``, but is that not what we need 
here? If I understand this option correctly, it would lead to compile errors 
when using Java 9+ specific APIs incompatible to Java 8.

References:
  * 
https://maven.apache.org/plugins/maven-compiler-plugin/compile-mojo.html#release
  * https://stackoverflow.com/a/43103038/1082681


was (Author: kriegaex):
I think that enforcing the byte code version would not solve the problem. We 
need to make sure that the code is compiled against the JDK 8 API, too. I have 
never used the Javac 9+ compiler switch `--release` or the corresponding Maven 
Compiler option ``, but is that not what we need here? If I understand 
this option correctly, it would lead to compile errors when using Java 9+ 
specific APIs incompatible to Java 8.

References:
  * 
https://maven.apache.org/plugins/maven-compiler-plugin/compile-mojo.html#release
  * https://stackoverflow.com/a/43103038/1082681

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefi

[jira] [Commented] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Alexander Kriegisch (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272513#comment-17272513
 ] 

Alexander Kriegisch commented on SUREFIRE-1882:
---

I think that enforcing the byte code version would not solve the problem. We 
need to make sure that the code is compiled against the JDK 8 API, too. I have 
never used the Javac 9+ compiler switch `--release` or the corresponding Maven 
Compiler option ``, but is that not what we need here? If I understand 
this option correctly, it would lead to compile errors when using Java 9+ 
specific APIs incompatible to Java 8.

References:
  * 
https://maven.apache.org/plugins/maven-compiler-plugin/compile-mojo.html#release
  * https://stackoverflow.com/a/43103038/1082681

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:266)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1320)
> [ERROR]   (...)
> {code}
> See also the dump file attached to this ticket.
> When running the build e.g. with Java 11 or Java 14, the same error does not 
> occur. I tested with the current master, commit 
> [f14fa54b|https://github.com/apache/maven-surefire/commit/f14fa54b9eba073c8c896a829fac1c2037b34222].
> The root cause seems to be this part of the dump file:
> {code}
> java.lang.NoSuchMethodError: java.nio.ByteBuffer.flip()Ljava/nio/ByteBuffer;
>   at 
> org.a

[GitHub] [maven-surefire] kriegaex commented on a change in pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex commented on a change in pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#discussion_r564965487



##
File path: 
maven-surefire-common/src/test/java/org/apache/maven/plugin/surefire/report/StatelessXmlReporterTest.java
##
@@ -380,7 +381,7 @@ public void testSyncOnDeferredFile() throws Exception
 {
 Utf8RecodingDeferredFileOutputStream out = new 
Utf8RecodingDeferredFileOutputStream( "test" );
 ByteBuffer cache = ByteBuffer.wrap( new byte[] {1, 2, 3} );
-cache.position( 3 );
+( (Buffer) cache ).position( 3 );

Review comment:
   Sorry for kicking off all CI builds for this little change. Thanks for 
the review.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex edited a comment on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex edited a comment on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767947574


   > Maybe you want to contribute instead of micro-managing my edits? ๐Ÿ˜‰
   
   After having checked all your code review suggestions plus all the other 
places I changed which you did not even mention, my assumption was confirmed 
that collaboratively working on this would have saved time. If you had just 
checked out the PR and tried to flip types in your IDE, you would have noticed. 
I think that code reviews outside of an IDE which actually compiles are not 
particularly helpful in this case where it is about changing types in order to 
avoid casting. So - no offence meant - this was a waste of time for both of us 
and I want to re-invite you to piggy-back on my PR and just commit whatever 
improvements you have for it. Before you could even write "could you edit this 
like that?", you would have done it already with no more time spent but without 
me spending time on checking, commenting back, you reading the comments again.
   
   We could
 * avoid micro-management,
 * save time,
 * get better code faster,
 * avoid some of the 7 wastes of lean production, such as hand-offs, 
stretching the cycle time by scattering the touch times across a longer than 
necessary time frame, in turn requiring more context changes for both of us, 
trying to remember where we left of last time. You are a busy developer and 
doing OSS in your spare time, I assume. Even if someone pays you for it, you do 
not want to create waste.
 
   Sorry for lobbying here and making this a general discussion, but I always 
do that when contributing to a project for the first time in order to find out 
if it would be attractive for me to contribute again in the future. I am 
strictly against the policy in so many OSS projects that PRs get micro-managed 
in many iterations up to the point in which the contributor has shaped the code 
into something the reviewer would have written. Better to accept an imperfect, 
but valuable PR and help polishing it by yourself. Then the chances are much 
higher that the code ends up the way you like it as a maintainer. Also, the 
contributor can learn from the edits. Win-win.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex edited a comment on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex edited a comment on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767947574


   > Maybe you want to contribute instead of micro-managing my edits? ๐Ÿ˜‰
   
   After having checked all your code review suggestions plus all the other 
places I changed which you did not even mention, my assumption was confirmed 
that collaboratively working on this would have saved time. If you had just 
checked out the PR and tried to flip types in your IDE, you would have noticed. 
I think that code reviews outside of an IDE which actually compiles are not 
particularly helpful in this case where it is about changing types in order to 
avoid casting. So - no offence meant - this was a waste of time for both of us 
and I want to re-invite you to piggy-back on my PR and just commit whatever 
improvements you have for it. Before you could even write "could you edit this 
like that?", you would have done it already with no more time spent but without 
me spending time on checking, commenting back, you reading the comments again.
   
   We could
 * avoid micro-management,
 * save time,
 * get better code faster,
 * avoid some of the 7 wastes of lean production, such as hand-offs, 
stretching the cycle time by scattering the touch times across a longer than 
necessary time frame, in turn requiring more context changes for both of us, 
trying to remember where we left of last time. You are a busy developer and 
doing OSS in your spare time, I assume. Even if someone pays you for it, you do 
not want to create waste.
 
   Sorry for lobbying here and making this a general discussion, but I always 
do that when contributing to a project for the first time in order to find out 
if it would be attractive for me to contribute again in the future. I am 
strictly against the policy in so many OSS projects that PRs get micro-managed 
in many iterations up to the point in which the contributor has shaped the code 
into something the reviewer would have written. Better to accept an imperfect, 
but valuable PR and help polishing it by yourself. Then the chances are much 
higher that the code ends up thhe way you like it as a maintainer. Also, the 
contributor can learn from the edits. Win-win.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex edited a comment on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex edited a comment on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767947574


   > Maybe you want to contribute instead of micro-managing my edits? ๐Ÿ˜‰
   
   After having checked all your code review suggestions plus all the other 
places I changed which you did not even mention, my assumption was confirmed 
that collaboratively working on this would have saved time. If you had just 
checked out the PR and tried to flip types in your IDE, you would have noticed. 
I think that code reviews outside of an IDE which actually compiles are not 
particularly helpful in this case where it is about changing types in order to 
avoid casting. So - no offence meant - this was a waste of time for both of us 
and I want to re-invite you to piggy-back on my PR and just commit whatever 
improvements you have for it. Before you could even write "could you edit this 
like that?", you would have done it already with no more time spent but without 
me spending time on checking, commenting back, you reading the comments again.
   
   We could
 * avoid micro-management,
 * save time,
 * get better code faster,
 * avoid some of the 7 wastes of lean production, such as hand-offs, 
stretching the cycle time by scattering the touch times across a longer than 
necessary time frame. You are a busy developer and doing OSS in your spare 
time, I assume. Even if someone pays you for it, you do not want to create 
waste.
 
   Sorry for lobbying here and making this a general discussion, but I always 
do that when contributing to a project for the first time in order to find out 
if it would be attractive for me to contribute again in the future. I am 
strictly against the policy in so many OSS projects that PRs get micro-managed 
in many iterations up to the point in which the contributor has shaped the code 
into something the reviewer would have written. Better to accept an imperfect, 
but valuable PR and help polishing it by yourself. Then the chances are much 
higher that the code ends up thhe way you like it as a maintainer. Also, the 
contributor can learn from the edits. Win-win.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex edited a comment on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex edited a comment on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767947574


   > Maybe you want to contribute instead of micro-managing my edits? ๐Ÿ˜‰
   
   After having checked all your code review suggestions plus all the other 
places I changed which you did not even mention, my assumption was confirmed 
that collaboratively working on this would have saved time. If you had just 
checked out the PR and tried to flip types in your IDE, you would have noticed. 
I think that code reviews outside of an IDE which actually compiles are not 
particularly helpful in this case where it is about changing types in order to 
avoid casting. So - no offence meant - this was a waste of time for both of us 
and I want to re-invite you to piggy-back on my PR and just commit whatever 
improvements you have for it. Before you even write "could you edit this like 
that?", you would have done it already with no more time spent but without me 
spending time on checking, commenting back, you reading the comments again.
   
   We could
 * avoid micro-management,
 * save time,
 * get better code faster,
 * avoid some of the 7 wastes of lean production, such as hand-offs, 
stretching the cycle time by scattering the touch times across a longer than 
necessary time frame. You are a busy developer and doing OSS in your spare 
time, I assume. Even if someone pays you for it, you do not want to create 
waste.
 
   Sorry for lobbying here and making this a general discussion, but I always 
do that when contributing to a project for the first time in order to find out 
if it would be attractive for me to contribute again in the future. I am 
strictly against the policy in so many OSS projects that PRs get micro-managed 
in many iterations up to the point in which the contributor has shaped the code 
into something the reviewer would have written. Better to accept an imperfect, 
but valuable PR and help polishing it by yourself. Then the chances are much 
higher that the code ends up thhe way you like it as a maintainer. Also, the 
contributor can learn from the edits. Win-win.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex commented on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex commented on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767947574


   > Maybe you want to contribute instead of micro-managing my edits? ๐Ÿ˜‰
   
   After having checked all your code review suggestions plus all the other 
places I changed which you did not even mention, my assumption that 
collaboratively working on this would have saved time. If you had just checked 
out the PR and tried to flip types in your IDE, you would have noticed. I think 
that code reviews outside of an IDE which actually compiles are not 
particularly helpful in this case where it is about changing types in order to 
avoid casting. So - no offence meant - this was a waste of time for both of us 
and I want to re-invite you to piggy-back on my PR and just commit whatever 
improvements you have for it. Before you even write "could you edit this like 
that?", you would have done it already with no more time spent but without me 
spending time on checking, commenting back, you reading the comments again.
   
   We could
 * avoid micro-management,
 * save time,
 * get better code faster,
 * avoid some of the 7 wastes of lean production, such as hand-offs, 
stretching the cycle time by scattering the touch times across a longer than 
necessary time frame. You are a busy developer and doing OSS in your spare 
time, I assume. Even if someone pays you for it, you do not want to create 
waste.
 
   Sorry for lobbying here and making this a general discussion, but I always 
do that when contributing to a project for the first time in order to find out 
if it would be attractive for me to contribute again in the future. I am 
strictly against the policy in so many OSS projects that PRs get micro-managed 
in many iterations up to the point in which the contributor has shaped the code 
into something the reviewer would have written. Better to accept an imperfect, 
but valuable PR and help polishing it by yourself. Then the chances are much 
higher that the code ends up thhe way you like it as a maintainer. Also, the 
contributor can learn from the edits. Win-win.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] Tibor17 commented on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


Tibor17 commented on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767947085


   We can move on if the fix is complete.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] Tibor17 commented on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


Tibor17 commented on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767945402


   I talked about the Travis CI with our Infra team. They have migrated 
`travis-ci.org` to `travis-ci.com`. Let's leave the Travis alone for a while 
but it will come back in some form ;-) 



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex commented on a change in pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex commented on a change in pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#discussion_r564957111



##
File path: 
surefire-api/src/main/java/org/apache/maven/surefire/api/stream/AbstractStreamEncoder.java
##
@@ -112,17 +113,17 @@ public void encodeString( CharsetEncoder encoder, 
ByteBuffer result, String stri
 {
 String nonNullString = nonNull( string );
 
-int counterPosition = result.position();
+int counterPosition = ( (Buffer) result ).position();

Review comment:
   No, see 
https://github.com/apache/maven-surefire/pull/332#discussion_r564955600. 
Furthermore, the call `encoder.encode( wrap( nonNullString ), result, true );` 
requires `result` to be a `ByteBuffer` again.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex commented on a change in pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex commented on a change in pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#discussion_r564956338



##
File path: 
surefire-api/src/main/java/org/apache/maven/surefire/api/stream/AbstractStreamDecoder.java
##
@@ -28,6 +28,7 @@
 import java.io.EOFException;
 import java.io.File;
 import java.io.IOException;
+import java.nio.Buffer;

Review comment:
   No, we cannot, see 
https://github.com/apache/maven-surefire/pull/332#discussion_r564955600





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex commented on a change in pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex commented on a change in pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#discussion_r564955600



##
File path: 
maven-surefire-common/src/test/java/org/apache/maven/plugin/surefire/report/StatelessXmlReporterTest.java
##
@@ -380,7 +381,7 @@ public void testSyncOnDeferredFile() throws Exception
 {
 Utf8RecodingDeferredFileOutputStream out = new 
Utf8RecodingDeferredFileOutputStream( "test" );
 ByteBuffer cache = ByteBuffer.wrap( new byte[] {1, 2, 3} );
-cache.position( 3 );
+( (Buffer) cache ).position( 3 );

Review comment:
   I checked all tests and also all application code by manually flipping 
local `ByteBuffer` variables to `Buffer`, and this is the only place where this 
is actually possible. In all other places one of the following stops me from 
easily changing  `ByteBuffer` into `Buffer` types:
 * Other `ByteBuffer` methods are being used, requiring casts in the 
reverse direction to `ByteBuffer`.
 * The variable is declared as a method parameter, requiring signature 
changes, possibly recursively.
 * The variable is used in method calls requiring a cast in reverse 
direction to `ByteBuffer`.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex commented on a change in pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex commented on a change in pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#discussion_r564942022



##
File path: 
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/report/Utf8RecodingDeferredFileOutputStream.java
##
@@ -93,14 +94,14 @@ public synchronized void write( String output, boolean 
newLine )
 }
 else
 {
-cache.flip();
+( (Buffer) cache ).flip();

Review comment:
   Again, at some point `array()` is called, returning `Object` instead of 
`byte[]`. Furthermore, `put()` is called twice, a method unavailable in 
`Buffer`.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex commented on a change in pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex commented on a change in pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#discussion_r564941015



##
File path: 
maven-surefire-common/src/test/java/org/apache/maven/plugin/surefire/extensions/StreamFeederTest.java
##
@@ -90,9 +91,9 @@ public void shouldEncodeCommandToStream() throws Exception
 public Object answer( InvocationOnMock invocation ) throws 
IOException
 {
 ByteBuffer bb = invocation.getArgument( 0 );

Review comment:
   `bb.array()` two lines further down would then return `Object` instead 
of `byte[]` which would mean a cast in that place instead. Is that preferable 
in your opinion?





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex commented on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex commented on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767927878


   Is the Travis CI build really still necessary?



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Closed] (MARTIFACT-2) First version release

2021-01-26 Thread Herve Boutemy (Jira)


 [ 
https://issues.apache.org/jira/browse/MARTIFACT-2?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Herve Boutemy closed MARTIFACT-2.
-
Resolution: Fixed

vote started

> First version release
> -
>
> Key: MARTIFACT-2
> URL: https://issues.apache.org/jira/browse/MARTIFACT-2
> Project: Maven Artifact Plugin
>  Issue Type: Wish
>Reporter: Slawomir Jaranowski
>Priority: Major
> Fix For: 0.1
>
>
> When do you want to release first version of plugin?
> Released version will be easier to testing.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Assigned] (MNG-7078) The integration tests use the default maven settings

2021-01-26 Thread Michael Osipov (Jira)


 [ 
https://issues.apache.org/jira/browse/MNG-7078?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Michael Osipov reassigned MNG-7078:
---

Assignee: (was: Michael Osipov)

> The integration tests use the default maven settings
> 
>
> Key: MNG-7078
> URL: https://issues.apache.org/jira/browse/MNG-7078
> Project: Maven
>  Issue Type: Improvement
>  Components: Integration Tests
>Reporter: Guillaume Nodet
>Priority: Major
>
> I have a profile that caused one integration test to fail, but it took me 
> some time to realise the problem came from my {{~/.m2/settings.xml}} file.  
> It would be better to have the tests use an empty settings file.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Tibor Digana (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272332#comment-17272332
 ] 

Tibor Digana commented on SUREFIRE-1882:


[~KroArtem]
Pls check it in our POM 
https://github.com/apache/maven-surefire/blob/master/pom.xml
Do we have it? If not, then you can open a new PR and add it into the POM.

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:266)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1320)
> [ERROR]   (...)
> {code}
> See also the dump file attached to this ticket.
> When running the build e.g. with Java 11 or Java 14, the same error does not 
> occur. I tested with the current master, commit 
> [f14fa54b|https://github.com/apache/maven-surefire/commit/f14fa54b9eba073c8c896a829fac1c2037b34222].
> The root cause seems to be this part of the dump file:
> {code}
> java.lang.NoSuchMethodError: java.nio.ByteBuffer.flip()Ljava/nio/ByteBuffer;
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:67)
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:44)
>   at 
> org.apache.maven.surefire.api.stream.AbstractStreamEncoder.write(AbstractStreamEncoder.java:77)
>   at 
> o

[GitHub] [maven] McFoggy commented on pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on pull request #438:
URL: https://github.com/apache/maven/pull/438#issuecomment-767746580


   If asked for, I will squash the commits.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on pull request #438:
URL: https://github.com/apache/maven/pull/438#issuecomment-767740201


   FYI ICLA received & handled by Apache secretary, signed CLAs list updated 
(https://people.apache.org/unlistedclas.html)




This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Comment Edited] (MJAVADOC-329) Allow generation of empty javadoc JARs

2021-01-26 Thread John Robert Fallows (Jira)


[ 
https://issues.apache.org/jira/browse/MJAVADOC-329?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272302#comment-17272302
 ] 

John Robert Fallows edited comment on MJAVADOC-329 at 1/26/21, 6:18 PM:


Pull request implementing *generateIfEmpty* for *javadoc:jar* goal.

[https://github.com/apache/maven-javadoc-plugin/pull/65]
{code:xml}

  org.apache.maven.plugins
  maven-antrun-plugin
  

  package
  

  

  
  
run
  

  


ย  org.apache.maven.plugins
ย  maven-javadoc-plugin
ย  3.2.0
ย  
ย  ย  
ย  ย  ย  **/internal/**/*.java
ย  ย  
ย  
ย  
ย  ย  
ย  ย  ย  
ย  ย  ย  ย  jar
ย  ย  ย  
ย  ย  
ย  

{code}
where no non-internal classes exist, therefore no public Javadoc is required, 
yet Maven Central requires inclusion of a Javadoc JAR during deployment.

This now simplifies to
{code:xml}

ย  org.apache.maven.plugins
ย  maven-javadoc-plugin
ย  3.2.1
ย  
ย  ย  
ย  ย  ย  **/internal/**/*.java
ย  ย  
ย  ย  true
ย  
ย  
ย  ย  
ย  ย  ย  
ย  ย  ย  ย  jar
ย  ย  ย  
ย  ย  
ย  

{code}


was (Author: jfallows):
Pull request implementing *generateIfEmpty* for *javadoc:jar* goal.

{{[https://github.com/apache/maven-javadoc-plugin/pull/65]}}


{{ }}
{{ org.apache.maven.plugins}}
{{ maven-antrun-plugin}}
{{ }}
{{ }}
{{ package}}
{{ }}
{{ }}
{{ }}
{{ }}
{{ }}
{{ }}
{{ run}}
{{ }}
{{ }}
{{ }}
{{ }}
{{ }}
{{ ย  org.apache.maven.plugins}}
{{ ย  maven-javadoc-plugin}}
{{ ย  3.2.0}}
{{ ย  }}
{{ ย  ย  }}
{{ ย  ย  ย  **/internal/**/*.java}}
{{ ย  ย  }}
{{ ย  }}
{{ ย  }}
{{ ย  ย  }}
{{ ย  ย  ย  }}
{{ ย  ย  ย  ย  jar}}
{{ ย  ย  ย  }}
{{ ย  ย  }}
{{ ย  }}
{{ }}


{{where no non-internal classes exist, therefore no public Javadoc is required, 
yet Maven Central requires inclusion of a Javadoc JAR during deployment.}}

{{This now simplifies to}}

{{}}
{{ ย  org.apache.maven.plugins}}
{{ ย  maven-javadoc-plugin}}
{{ ย  3.2.1}}
{{ ย  }}
{{ ย  ย  }}
{{ ย  ย  ย  **/internal/**/*.java}}
{{ ย  ย  }}
{{ ย  ย  true}}
{{ ย  }}
{{ ย  }}
{{ ย  ย  }}
{{ ย  ย  ย  }}
{{ ย  ย  ย  ย  jar}}
{{ ย  ย  ย  }}
{{ ย  ย  }}
{{ ย  }}
{{ }}

> Allow generation of empty javadoc JARs
> --
>
> Key: MJAVADOC-329
> URL: https://issues.apache.org/jira/browse/MJAVADOC-329
> Project: Maven Javadoc Plugin
>  Issue Type: Improvement
>Affects Versions: 2.8
>Reporter: Vincent Massol
>Assignee: Robert Scholte
>Priority: Major
>
> Here's my use case:
> * I want to be able to deploy my artifacts to Maven Central. There's a 
> requirement that a javadoc jar exists for the arifact to deploy
> * However I have some maven modules of type packaging = jar that have java 
> files but these files are located in an "internal" package (internal api that 
> we don't expose to end users since it's not part of our public API contract) 
> which we exclude from the javadoc generation
> The problem is that the javadoc plugin doesn't generate any JAR if there are 
> no java files matching (even if I have other files such as a package.html 
> file in my src/main/javadoc/* directories).
> I'd like it to be possible to generate an "empty" javadoc JAR containing only 
> a package.html file for example.
> Thanks a lot



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Comment Edited] (MJAVADOC-329) Allow generation of empty javadoc JARs

2021-01-26 Thread John Robert Fallows (Jira)


[ 
https://issues.apache.org/jira/browse/MJAVADOC-329?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272302#comment-17272302
 ] 

John Robert Fallows edited comment on MJAVADOC-329 at 1/26/21, 6:16 PM:


Pull request implementing *generateIfEmpty* for *javadoc:jar* goal.

{{[https://github.com/apache/maven-javadoc-plugin/pull/65]}}


{{ }}
{{ org.apache.maven.plugins}}
{{ maven-antrun-plugin}}
{{ }}
{{ }}
{{ package}}
{{ }}
{{ }}
{{ }}
{{ }}
{{ }}
{{ }}
{{ run}}
{{ }}
{{ }}
{{ }}
{{ }}
{{ }}
{{ ย  org.apache.maven.plugins}}
{{ ย  maven-javadoc-plugin}}
{{ ย  3.2.0}}
{{ ย  }}
{{ ย  ย  }}
{{ ย  ย  ย  **/internal/**/*.java}}
{{ ย  ย  }}
{{ ย  }}
{{ ย  }}
{{ ย  ย  }}
{{ ย  ย  ย  }}
{{ ย  ย  ย  ย  jar}}
{{ ย  ย  ย  }}
{{ ย  ย  }}
{{ ย  }}
{{ }}


{{where no non-internal classes exist, therefore no public Javadoc is required, 
yet Maven Central requires inclusion of a Javadoc JAR during deployment.}}

{{This now simplifies to}}

{{}}
{{ ย  org.apache.maven.plugins}}
{{ ย  maven-javadoc-plugin}}
{{ ย  3.2.1}}
{{ ย  }}
{{ ย  ย  }}
{{ ย  ย  ย  **/internal/**/*.java}}
{{ ย  ย  }}
{{ ย  ย  true}}
{{ ย  }}
{{ ย  }}
{{ ย  ย  }}
{{ ย  ย  ย  }}
{{ ย  ย  ย  ย  jar}}
{{ ย  ย  ย  }}
{{ ย  ย  }}
{{ ย  }}
{{ }}


was (Author: jfallows):
Pull request implementing *generateIfEmpty* for *javadoc:jar* goal.

[https://github.com/apache/maven-javadoc-plugin/pull/65]

  org.apache.maven.plugins
  maven-antrun-plugin
  

  package
  

  

  
  
run
  

  


ย  org.apache.maven.plugins
ย  maven-javadoc-plugin
ย  3.2.0
ย  
ย  ย  
ย  ย  ย  **/internal/**/*.java
ย  ย  
ย  
ย  
ย  ย  
ย  ย  ย  
ย  ย  ย  ย  jar
ย  ย  ย  
ย  ย  
ย  

{{}}where no non-internal classes exist, therefore no public Javadoc is 
required, yet Maven Central requires inclusion of a Javadoc JAR during 
deployment.

This now simplifies to

ย  org.apache.maven.plugins
ย  maven-javadoc-plugin
ย  3.2.1
ย  
ย  ย  
ย  ย  ย  **/internal/**/*.java
ย  ย  
ย  ย  true
ย  
ย  
ย  ย  
ย  ย  ย  
ย  ย  ย  ย  jar
ย  ย  ย  
ย  ย  
ย  


> Allow generation of empty javadoc JARs
> --
>
> Key: MJAVADOC-329
> URL: https://issues.apache.org/jira/browse/MJAVADOC-329
> Project: Maven Javadoc Plugin
>  Issue Type: Improvement
>Affects Versions: 2.8
>Reporter: Vincent Massol
>Assignee: Robert Scholte
>Priority: Major
>
> Here's my use case:
> * I want to be able to deploy my artifacts to Maven Central. There's a 
> requirement that a javadoc jar exists for the arifact to deploy
> * However I have some maven modules of type packaging = jar that have java 
> files but these files are located in an "internal" package (internal api that 
> we don't expose to end users since it's not part of our public API contract) 
> which we exclude from the javadoc generation
> The problem is that the javadoc plugin doesn't generate any JAR if there are 
> no java files matching (even if I have other files such as a package.html 
> file in my src/main/javadoc/* directories).
> I'd like it to be possible to generate an "empty" javadoc JAR containing only 
> a package.html file for example.
> Thanks a lot



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (MJAVADOC-329) Allow generation of empty javadoc JARs

2021-01-26 Thread John Robert Fallows (Jira)


[ 
https://issues.apache.org/jira/browse/MJAVADOC-329?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272302#comment-17272302
 ] 

John Robert Fallows commented on MJAVADOC-329:
--

Pull request implementing *generateIfEmpty* for *javadoc:jar* goal.

[https://github.com/apache/maven-javadoc-plugin/pull/65]

  org.apache.maven.plugins
  maven-antrun-plugin
  

  package
  

  

  
  
run
  

  


ย  org.apache.maven.plugins
ย  maven-javadoc-plugin
ย  3.2.0
ย  
ย  ย  
ย  ย  ย  **/internal/**/*.java
ย  ย  
ย  
ย  
ย  ย  
ย  ย  ย  
ย  ย  ย  ย  jar
ย  ย  ย  
ย  ย  
ย  

{{}}where no non-internal classes exist, therefore no public Javadoc is 
required, yet Maven Central requires inclusion of a Javadoc JAR during 
deployment.

This now simplifies to

ย  org.apache.maven.plugins
ย  maven-javadoc-plugin
ย  3.2.1
ย  
ย  ย  
ย  ย  ย  **/internal/**/*.java
ย  ย  
ย  ย  true
ย  
ย  
ย  ย  
ย  ย  ย  
ย  ย  ย  ย  jar
ย  ย  ย  
ย  ย  
ย  


> Allow generation of empty javadoc JARs
> --
>
> Key: MJAVADOC-329
> URL: https://issues.apache.org/jira/browse/MJAVADOC-329
> Project: Maven Javadoc Plugin
>  Issue Type: Improvement
>Affects Versions: 2.8
>Reporter: Vincent Massol
>Assignee: Robert Scholte
>Priority: Major
>
> Here's my use case:
> * I want to be able to deploy my artifacts to Maven Central. There's a 
> requirement that a javadoc jar exists for the arifact to deploy
> * However I have some maven modules of type packaging = jar that have java 
> files but these files are located in an "internal" package (internal api that 
> we don't expose to end users since it's not part of our public API contract) 
> which we exclude from the javadoc generation
> The problem is that the javadoc plugin doesn't generate any JAR if there are 
> no java files matching (even if I have other files such as a package.html 
> file in my src/main/javadoc/* directories).
> I'd like it to be possible to generate an "empty" javadoc JAR containing only 
> a package.html file for example.
> Thanks a lot



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [maven-javadoc-plugin] jfallows opened a new pull request #65: [MJAVADOC-329] - Allow generation of empty javadoc JARs

2021-01-26 Thread GitBox


jfallows opened a new pull request #65:
URL: https://github.com/apache/maven-javadoc-plugin/pull/65


   Add `generateIfEmpty` property to `javadoc:jar` goal, defaulting to `false` 
for backwards compatibility.
   Add `testGenerateIfEmpty` property to `javadoc:test-jar` goal for 
consistency, defaulting to `false` for backwards compatibility.
   
   ```
 
   org.apache.maven.plugins
   maven-antrun-plugin
   3.0.0
   
 
   package
   
 
   
 
   
   
 run
   
 
   
 
 
   org.apache.maven.plugins
   maven-javadoc-plugin
   3.2.0
   
 
   **/internal/**/*.java
 
   
   
 
   
 jar
   
 
   
 
   ```
   where no non-internal classes exist, therefore no public Javadoc is 
required, yet Maven Central requires inclusion of a Javadoc JAR during 
deployment.
   
   This now simplifies to
   ```
 
   org.apache.maven.plugins
   maven-javadoc-plugin
   3.2.1
   
 
   **/internal/**/*.java
 
 true
   
   
 
   
 jar
   
 
   
 
   ```
   
   Integration tests passed successfully.
   ```
   [INFO] --- maven-invoker-plugin:3.2.1:verify (integration-test) @ 
maven-javadoc-plugin ---
   [INFO] -
   [INFO] Build Summary:
   [INFO]   Passed: 54, Failed: 0, Errors: 0, Skipped: 17
   [INFO] -
   [INFO] 

   [INFO] BUILD SUCCESS
   [INFO] 

   ```
   
   As [ASF Committer](http://people.apache.org/committer-index.html) `jfallows`,
- [x] I hereby declare this contribution to be licenced under the [Apache 
License Version 2.0, January 2004](http://www.apache.org/licenses/LICENSE-2.0)
   
   ### Checklist
   
   Following this checklist to help us incorporate your 
   contribution quickly and easily:
   
- [x] Make sure there is a [JIRA 
issue](https://issues.apache.org/jira/browse/MJAVADOC) filed 
  for the change (usually before you start working on it).  Trivial 
changes like typos do not 
  require a JIRA issue.  Your pull request should address just this 
issue, without 
  pulling in other changes.
- [x] Each commit in the pull request should have a meaningful subject line 
and body.
- [x] Format the pull request title like `[MJAVADOC-XXX] - Fixes bug in 
ApproximateQuantiles`,
  where you replace `MJAVADOC-XXX` with the appropriate JIRA issue. 
Best practice
  is to use the JIRA issue title in the pull request title and in the 
first line of the 
  commit message.
- [x] Write a pull request description that is detailed enough to 
understand what the pull request does, how, and why.
- [x] Run `mvn clean verify -Prun-its` to make sure basic checks pass. A 
more thorough check will 
  be performed on your pull request automatically.
   
   If your pull request is about ~20 lines of code you don't need to sign an
   [Individual Contributor License 
Agreement](https://www.apache.org/licenses/icla.pdf) if you are unsure
   please ask on the developers list.
   
   To make clear that you license your contribution under 
   the [Apache License Version 2.0, January 
2004](http://www.apache.org/licenses/LICENSE-2.0)
   you have to acknowledge this by using the following check-box.
   
- [x] I hereby declare this contribution to be licenced under the [Apache 
License Version 2.0, January 2004](http://www.apache.org/licenses/LICENSE-2.0)
   
- [ ] In any other case, please file an [Apache Individual Contributor 
License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564616279



##
File path: maven-plugin-api/pom.xml
##
@@ -54,6 +54,11 @@ under the License.
   org.codehaus.plexus
   plexus-classworlds
 
+

Review comment:
   mockito removed and custom impl provided where needed.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564616540



##
File path: 
maven-plugin-api/src/main/java/org/apache/maven/plugin/logging/Log.java
##
@@ -63,6 +65,20 @@
  */
 void debug( Throwable error );
 
+/**
+ * Send a message to the user in the debug error level by computing 
the message
+ * only when needed. The supplier will be called only if @see 
#isDebugEnabled() is true.
+ * 
+ * @param messageSupplier a non null Supplier of the message to use
+ */
+default void debug( Supplier messageSupplier )

Review comment:
   default methods removed, abstract class introduced





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Krosheninnikov Artem (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272157#comment-17272157
 ] 

Krosheninnikov Artem commented on SUREFIRE-1882:


Isn't it possible to reuse 
https://www.mojohaus.org/extra-enforcer-rules/enforceBytecodeVersion.html here?

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:266)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1320)
> [ERROR]   (...)
> {code}
> See also the dump file attached to this ticket.
> When running the build e.g. with Java 11 or Java 14, the same error does not 
> occur. I tested with the current master, commit 
> [f14fa54b|https://github.com/apache/maven-surefire/commit/f14fa54b9eba073c8c896a829fac1c2037b34222].
> The root cause seems to be this part of the dump file:
> {code}
> java.lang.NoSuchMethodError: java.nio.ByteBuffer.flip()Ljava/nio/ByteBuffer;
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:67)
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:44)
>   at 
> org.apache.maven.surefire.api.stream.AbstractStreamEncoder.write(AbstractStreamEncoder.java:77)
>   at 
> org.apache.maven.surefire.booter.spi.EventChannelE

[jira] [Comment Edited] (MPIR-402) Modules Report: provide links to Maven Central

2021-01-26 Thread Florian Brunner (Jira)


[ 
https://issues.apache.org/jira/browse/MPIR-402?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272145#comment-17272145
 ] 

Florian Brunner edited comment on MPIR-402 at 1/26/21, 3:02 PM:


Feel free to already have a look at it, but I haven't created a PR yet, as it 
needs some small clean-ups and testing.

Of course, any feedback is welcome.


was (Author: puce):
Feel free to already have a look at, but I haven't created a PR yet, as it 
needs some small clean-ups and testing.

> Modules Report: provide links to Maven Central
> --
>
> Key: MPIR-402
> URL: https://issues.apache.org/jira/browse/MPIR-402
> Project: Maven Project Info Reports Plugin
>  Issue Type: New Feature
>  Components: modules
>Reporter: Florian Brunner
>Priority: Major
> Fix For: waiting-for-feedback
>
>
> In the table of the modules report also provide the links to Maven Central.
> This issue is actually about contributing a patch I made some years ago back 
> to this upstream project.
> Here is a sample how it looks like: 
> [https://www.drombler.org/drombler-fx/1.0/docs/site/modules.html]
> I'm using this patch already for several years and it is great for 
> documenting the Maven coordinates of libraries, especially in multi-Module 
> projects, IMHO.
> I typically directly point to this report from some prominent places such 
> from a top site inside the documentation 
> ([https://www.drombler.org/drombler-fx/1.0/]) or in blog posts 
> (https://puces-blog.blogspot.com/2020/01/drombler-fx-version-10-released.html).



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (MPIR-402) Modules Report: provide links to Maven Central

2021-01-26 Thread Florian Brunner (Jira)


[ 
https://issues.apache.org/jira/browse/MPIR-402?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272145#comment-17272145
 ] 

Florian Brunner commented on MPIR-402:
--

Feel free to already have a look at, but I haven't created a PR yet, as it 
needs some small clean-ups and testing.

> Modules Report: provide links to Maven Central
> --
>
> Key: MPIR-402
> URL: https://issues.apache.org/jira/browse/MPIR-402
> Project: Maven Project Info Reports Plugin
>  Issue Type: New Feature
>  Components: modules
>Reporter: Florian Brunner
>Priority: Major
> Fix For: waiting-for-feedback
>
>
> In the table of the modules report also provide the links to Maven Central.
> This issue is actually about contributing a patch I made some years ago back 
> to this upstream project.
> Here is a sample how it looks like: 
> [https://www.drombler.org/drombler-fx/1.0/docs/site/modules.html]
> I'm using this patch already for several years and it is great for 
> documenting the Maven coordinates of libraries, especially in multi-Module 
> projects, IMHO.
> I typically directly point to this report from some prominent places such 
> from a top site inside the documentation 
> ([https://www.drombler.org/drombler-fx/1.0/]) or in blog posts 
> (https://puces-blog.blogspot.com/2020/01/drombler-fx-version-10-released.html).



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564572336



##
File path: maven-plugin-api/pom.xml
##
@@ -54,6 +54,11 @@ under the License.
   org.codehaus.plexus
   plexus-classworlds
 
+

Review comment:
   I will remove mockito & change to custom/stub impl and change the tests 
accordingly





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564571911



##
File path: 
maven-plugin-api/src/main/java/org/apache/maven/plugin/logging/Log.java
##
@@ -63,6 +65,20 @@
  */
 void debug( Throwable error );
 
+/**
+ * Send a message to the user in the debug error level by computing 
the message
+ * only when needed. The supplier will be called only if @see 
#isDebugEnabled() is true.
+ * 
+ * @param messageSupplier a non null Supplier of the message to use
+ */
+default void debug( Supplier messageSupplier )

Review comment:
   ok I'll remove the default methods from the interface





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Tibor Digana (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272127#comment-17272127
 ] 

Tibor Digana commented on SUREFIRE-1882:


[~kriegaex]
This issue was found out after the release because i used JDK11+ however the 
compiler was set to java source/target version 1.8.
I guess the users used Java 1.8. In the current development iteration we have 
imposed the limitation on the build only to Java 1.8 but the tests used another 
JVM and this way we were safe. We wanted to bypass the issue this way because 
we did not understand the root cause and workaround.

{quote}
>> BTW, are there or could someone add any static byte code verifiers in 
>> Surefire which could automatically detect and report this issue? 
{quote}

I think we can do it in the build when we simply build the project with higher 
version of JDK than the integration tests. This means JDK 11 for the project 
and JDK 1.8 for the tests.


> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:266)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1320)
> [ERROR]   (...)
> {code}
> See also the dump file attached to this ticket.
> When running the build e.g. with Java 11 or Java 14, the same error does not 
> occur. I tested with the current master, commit 
> [f14fa54b|https://github.com/apache/maven-surefire/commit/f14fa54b9eb

[GitHub] [maven] rmannibucau commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


rmannibucau commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564558395



##
File path: 
maven-plugin-api/src/main/java/org/apache/maven/plugin/logging/Log.java
##
@@ -63,6 +65,20 @@
  */
 void debug( Throwable error );
 
+/**
+ * Send a message to the user in the debug error level by computing 
the message
+ * only when needed. The supplier will be called only if @see 
#isDebugEnabled() is true.
+ * 
+ * @param messageSupplier a non null Supplier of the message to use
+ */
+default void debug( Supplier messageSupplier )

Review comment:
   We had that discussion on Artifact#setPath/getpath thread and it ended 
up as a compromise to do both.
   I'm not sure it is worth but I'm fine with this but implementing it in 
implementation is the prerequisite on my side - not having it in the interface 
is fine for me since it is not a breaking change until you upgrade your mojo 
API and have a custom impl - which is fine.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] rmannibucau commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


rmannibucau commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564557392



##
File path: maven-plugin-api/pom.xml
##
@@ -54,6 +54,11 @@ under the License.
   org.codehaus.plexus
   plexus-classworlds
 
+

Review comment:
   Well for the last part mockito does way more than a custom impl and half 
of it is not desired I guess for such tests (mainly cause of maintenance).
   On the logger impl I meant DefaultLog impl whatever is under (if it moves to 
something else than plexus and uses a slf4j particular binding it would be the 
kind of same comment).





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Updated] (MNG-7055) Using MINSTALL/DEPLOY 3.0.0-M1+ does not write plugin information into maven-metadata.xml

2021-01-26 Thread Michael Osipov (Jira)


 [ 
https://issues.apache.org/jira/browse/MNG-7055?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Michael Osipov updated MNG-7055:

Description: 
Copying [~michaelo]'s comment from mailing list on HEAD with Maven core ITs:

https://markmail.org/message/ggcioupa6yaet4xe#query:+page:1+mid:noyp5d3iyclrfgyp+state:results


{noformat}[ERROR] Tests run: 834, Failures: 0, Errors: 1, Skipped: 0, Time 
elapsed: 287.261 s <<< FAILURE! - in org.apache.maven.it.IntegrationTestSuite
[ERROR] 
testitMNG3372(org.apache.maven.it.MavenITmng3372DirectInvocationOfPluginsTest)
Time elapsed: 1.5 s  <<< ERROR!
org.apache.maven.it.VerificationException:
Exit code was non-zero: 1; command line and log =
/var/osipovmi/Projekte/maven-integration-testing/core-it-suite/target/apache-maven/bin/mvn
--global-settings
/var/osipovmi/Projekte/maven-integration-testing/core-it-suite/target/test-classes/settings.xml
-s
/var/osipovmi/Projekte/maven-integration-testing/core-it-suite/target/test-classes/mng-3372/direct-using-prefix/settings.xml
-e --batch-mode
-Dmaven.repo.local=/net/home/osipovmi/var/Projekte/maven-integration-testing/repo
mng3372:test
[INFO] Error stacktraces are turned on.
[INFO] Scanning for projects...
[WARNING]
[WARNING] Some problems were encountered while building the effective model for
org.apache.maven.its.mng3372:project:jar:1.0-SNAPSHOT
[WARNING] Version not locked for default bindings plugins [maven-clean-plugin,
maven-resources-plugin, maven-jar-plugin, maven-compiler-plugin,
maven-surefire-plugin, maven-install-plugin, maven-deploy-plugin,
maven-site-plugin], you should define versions in pluginManagement section of
your pom.xml or parent @ line 6, column 14
[WARNING]
[WARNING] It is highly recommended to fix these problems because they threaten 
the stability of your build.
[WARNING]
[WARNING] For this reason, future Maven versions might no longer support 
building such malformed projects.
[WARNING]
[INFO] Downloading from central: 
file:target/null/org/apache/maven/its/mng3372/maven-metadata.xml
[INFO] Downloading from central: 
file:target/null/org/apache/maven/plugins/maven-metadata.xml
[INFO] Downloading from central: 
file:target/null/org/codehaus/mojo/maven-metadata.xml
[INFO] 
[INFO] BUILD FAILURE
[INFO] 
[INFO] Total time:  0.056 s
[INFO] Finished at: 2020-06-04T22:03:01+02:00
[INFO] 
[ERROR] No plugin found for prefix 'mng3372' in the current project and in the
plugin groups [org.apache.maven.its.mng3372, org.apache.maven.plugins,
org.codehaus.mojo] available from the repositories [local
(/net/home/osipovmi/var/Projekte/maven-integration-testing/repo), central
(file:target/null)] -> [Help 1]
org.apache.maven.plugin.prefix.NoPluginFoundForPrefixException: No plugin found
for prefix 'mng3372' in the current project and in the plugin groups
[org.apache.maven.its.mng3372, org.apache.maven.plugins, org.codehaus.mojo]
available from the repositories [local 
(/net/home/osipovmi/var/Projekte/maven-integration-testing/repo), central 
(file:target/null)]
at 
org.apache.maven.plugin.prefix.internal.DefaultPluginPrefixResolver.resolve(DefaultPluginPrefixResolver.java:98)
at 
org.apache.maven.lifecycle.internal.MojoDescriptorCreator.findPluginForPrefix(MojoDescriptorCreator.java:269)
at 
org.apache.maven.lifecycle.internal.MojoDescriptorCreator.getMojoDescript{noformat}

  was:
Copying @mosipov's comment from mailing list on HEAD with Maven core ITs:

https://markmail.org/message/ggcioupa6yaet4xe#query:+page:1+mid:noyp5d3iyclrfgyp+state:results


{noformat}[ERROR] Tests run: 834, Failures: 0, Errors: 1, Skipped: 0, Time 
elapsed: 287.261 s <<< FAILURE! - in org.apache.maven.it.IntegrationTestSuite
[ERROR] 
testitMNG3372(org.apache.maven.it.MavenITmng3372DirectInvocationOfPluginsTest)
Time elapsed: 1.5 s  <<< ERROR!
org.apache.maven.it.VerificationException:
Exit code was non-zero: 1; command line and log =
/var/osipovmi/Projekte/maven-integration-testing/core-it-suite/target/apache-maven/bin/mvn
--global-settings
/var/osipovmi/Projekte/maven-integration-testing/core-it-suite/target/test-classes/settings.xml
-s
/var/osipovmi/Projekte/maven-integration-testing/core-it-suite/target/test-classes/mng-3372/direct-using-prefix/settings.xml
-e --batch-mode
-Dmaven.repo.local=/net/home/osipovmi/var/Projekte/maven-integration-testing/repo
mng3372:test
[INFO] Error stacktraces are turned on.
[INFO] Scanning for projects...
[WARNING]
[WARNING] Some problems were encountered while building the effective model for
org.apache.maven.its.mng3372:project:jar:1.0-SNAPSHOT
[WARNING] Version not locked for default bindings plugins [maven-clean-plugin,
maven-resources-plugin, maven-jar-plugin, maven-compiler-plugin,
maven-surefire-plugin, maven-instal

[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564547259



##
File path: maven-plugin-api/pom.xml
##
@@ -54,6 +54,11 @@ under the License.
   org.codehaus.plexus
   plexus-classworlds
 
+

Review comment:
   > with a custom Log impl
   
   you probably meant with a org.codehaus.plexus.logging.Logger implementation 
; applying to tests in DefaultLogTest.
   
   @rmannibucau If I provide a stub/custom impl what is the difference with the 
mock ; I mean in regard of the remark _"... what it brings but I see how the 
test can pass with a broken impl"_





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] slachiewicz commented on pull request #437: [MNG-7082] - remove deprecation on org.apache.maven.plugin.logging.Log

2021-01-26 Thread GitBox


slachiewicz commented on pull request #437:
URL: https://github.com/apache/maven/pull/437#issuecomment-767568731


   Sorry, that should be comment to other PR



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on pull request #437: [MNG-7082] - remove deprecation on org.apache.maven.plugin.logging.Log

2021-01-26 Thread GitBox


McFoggy commented on pull request #437:
URL: https://github.com/apache/maven/pull/437#issuecomment-767563490


   > 
   > 
   > One short notice - Plexus logger Log here, api and implementation is from 
Eclipse Plexus Sisu
   
   Sorry @slachiewicz I do not get your point.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] michael-o commented on pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


michael-o commented on pull request #438:
URL: https://github.com/apache/maven/pull/438#issuecomment-767563022


   > 
   > 
   > @McFoggy it is the outcome of the discussions because slf4j is 1. 
unstable, 2. has no correct binding impl (it is a singleton leading to a bunch 
of issues in mojo when transparently exposed) 3. does not enable to switch the 
binding until you reimpl slf4j by design 4. is not contextual with most 
available impl and 5. we already reimplement slf4j and just inherit from a 
small API part but not the rest. I fully understand it can be surprising but it 
is the outcome of most vendors in most projects caring of the context and to 
have a pluggable logging impl so it is not that shocking after some thoughts as 
seen in the discussion.
   
   I would expect such discussions to be held with @ceki instead with just us.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564527199



##
File path: 
maven-plugin-api/src/test/java/org/apache/maven/plugin/logging/SystemStreamLogTest.java
##
@@ -0,0 +1,94 @@
+package org.apache.maven.plugin.logging;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.junit.jupiter.api.AfterAll;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
+import org.mockito.Mock;
+import org.mockito.Mockito;
+
+import java.io.PrintStream;
+import java.util.function.Supplier;
+
+/**
+ * Tests for {@link SystemStreamLog} 
+ */
+public class SystemStreamLogTest 
+{
+  private static final String EXPECTED_MESSAGE = "expected message";
+  private static PrintStream outStream;
+  private static PrintStream errStream;
+  private static PrintStream mockOut;
+  private static PrintStream mockErr;
+
+  /*
+   * As SystemStreamLog info/warn/error log levels are active, this test 
checks that
+   * a message supplier is really called/executed when logging at those levels 
+   */
+  @Test
+  public void testLazyMessageIsEvaluatedForActiveLogLevels()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.info(messageSupplier);
+logger.warn(messageSupplier);
+logger.error(messageSupplier);
+
+Mockito.verify(messageSupplier, Mockito.times(3)).get();
+  }
+
+  /*
+   * As SystemStreamLog debug log level is inactive, this test checks that
+   * a message supplier is not called/executed when logging at debug level
+   */
+  @Test
+  public void testDebugLazyMessageIsNotEvaluated()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.debug(messageSupplier);

Review comment:
   Simplification of test to be consistent with `DefaultLogTest` in latter 
commit





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564527024



##
File path: 
maven-plugin-api/src/test/java/org/apache/maven/plugin/logging/SystemStreamLogTest.java
##
@@ -0,0 +1,94 @@
+package org.apache.maven.plugin.logging;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.junit.jupiter.api.AfterAll;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
+import org.mockito.Mock;
+import org.mockito.Mockito;
+
+import java.io.PrintStream;
+import java.util.function.Supplier;
+
+/**
+ * Tests for {@link SystemStreamLog} 
+ */
+public class SystemStreamLogTest 
+{
+  private static final String EXPECTED_MESSAGE = "expected message";
+  private static PrintStream outStream;
+  private static PrintStream errStream;
+  private static PrintStream mockOut;
+  private static PrintStream mockErr;
+
+  /*
+   * As SystemStreamLog info/warn/error log levels are active, this test 
checks that
+   * a message supplier is really called/executed when logging at those levels 
+   */
+  @Test
+  public void testLazyMessageIsEvaluatedForActiveLogLevels()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.info(messageSupplier);
+logger.warn(messageSupplier);
+logger.error(messageSupplier);
+
+Mockito.verify(messageSupplier, Mockito.times(3)).get();
+  }
+
+  /*
+   * As SystemStreamLog debug log level is inactive, this test checks that
+   * a message supplier is not called/executed when logging at debug level
+   */
+  @Test
+  public void testDebugLazyMessageIsNotEvaluated()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.debug(messageSupplier);
+
+Mockito.verify(messageSupplier, Mockito.never()).get();
+  }
+
+  @BeforeAll
+  public static void initialize()
+  {
+outStream = System.out;
+errStream = System.err;
+
+mockOut = Mockito.mock(PrintStream.class);
+System.setOut(mockOut);
+mockErr = Mockito.mock(PrintStream.class);

Review comment:
   mocks for Sytem.err & System.out removed, this part disappeared from test





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564526250



##
File path: 
maven-plugin-api/src/test/java/org/apache/maven/plugin/logging/SystemStreamLogTest.java
##
@@ -0,0 +1,94 @@
+package org.apache.maven.plugin.logging;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.junit.jupiter.api.AfterAll;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
+import org.mockito.Mock;
+import org.mockito.Mockito;
+
+import java.io.PrintStream;
+import java.util.function.Supplier;
+
+/**
+ * Tests for {@link SystemStreamLog} 
+ */
+public class SystemStreamLogTest 
+{
+  private static final String EXPECTED_MESSAGE = "expected message";
+  private static PrintStream outStream;
+  private static PrintStream errStream;
+  private static PrintStream mockOut;
+  private static PrintStream mockErr;
+
+  /*
+   * As SystemStreamLog info/warn/error log levels are active, this test 
checks that
+   * a message supplier is really called/executed when logging at those levels 
+   */
+  @Test
+  public void testLazyMessageIsEvaluatedForActiveLogLevels()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.info(messageSupplier);
+logger.warn(messageSupplier);
+logger.error(messageSupplier);

Review comment:
   Simplification of test to be consistent with `DefaultLogTest` in latter 
commit





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-artifact-plugin] hboutemy merged pull request #8: tidy up dependencies

2021-01-26 Thread GitBox


hboutemy merged pull request #8:
URL: https://github.com/apache/maven-artifact-plugin/pull/8


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564525577



##
File path: 
maven-plugin-api/src/main/java/org/apache/maven/plugin/logging/Log.java
##
@@ -63,6 +65,20 @@
  */
 void debug( Throwable error );
 
+/**
+ * Send a message to the user in the debug error level by computing 
the message
+ * only when needed. The supplier will be called only if @see 
#isDebugEnabled() is true.
+ * 
+ * @param messageSupplier a non null Supplier of the message to use
+ */
+default void debug( Supplier messageSupplier )

Review comment:
   new methods added in later commits





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] rmannibucau commented on pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


rmannibucau commented on pull request #438:
URL: https://github.com/apache/maven/pull/438#issuecomment-767550173


   @McFoggy it is the outcome of the discussions because slf4j is 1. unstable, 
2. has no correct binding impl (it is a singleton leading to a bunch of issues 
in mojo when transparently exposed) 3. does not enable to switch the binding 
until you reimpl slf4j by design 4. is not contextual with most available impl 
and 5. we already reimplement slf4j and just inherit from a small API part but 
not the rest. I fully understand it can be surprising but it is the outcome of 
most vendors in most projects caring of the context and to have a pluggable 
logging impl so it is not that shocking after some thoughts as seen in the 
discussion.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on pull request #438:
URL: https://github.com/apache/maven/pull/438#issuecomment-767546195


   > I really can't believe we are reinventing the wheel by implementing SLF4J 
Light.
   
   that's not what I understood from the different discussions.
   I really thought that it was expected to leverage the 
`org.apache.maven.plugin.logging.Log` abstraction which represents the _public_ 
interface that plugins should see and use.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564504423



##
File path: maven-plugin-api/pom.xml
##
@@ -54,6 +54,11 @@ under the License.
   org.codehaus.plexus
   plexus-classworlds
 
+

Review comment:
   That was just a simple unit test, as far as possible I didn't wanted to 
interfere/pollute the console outputs.
   If it is not a common practice to mock then I can add a stub/custom impl 
(with control on log level) for the same purpose.
   





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564502239



##
File path: 
maven-plugin-api/src/main/java/org/apache/maven/plugin/logging/Log.java
##
@@ -63,6 +65,20 @@
  */
 void debug( Throwable error );
 
+/**
+ * Send a message to the user in the debug error level by computing 
the message
+ * only when needed. The supplier will be called only if @see 
#isDebugEnabled() is true.
+ * 
+ * @param messageSupplier a non null Supplier of the message to use
+ */
+default void debug( Supplier messageSupplier )

Review comment:
   I used the default methods not to break any other potential 
implementation.
   If it is preferred not to do so then I can go with a breaking change and 
introduction of an Abstract class between the implementations. 
   Let's wait a bit for others POV.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564500288



##
File path: 
maven-plugin-api/src/test/java/org/apache/maven/plugin/logging/SystemStreamLogTest.java
##
@@ -0,0 +1,94 @@
+package org.apache.maven.plugin.logging;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.junit.jupiter.api.AfterAll;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
+import org.mockito.Mock;
+import org.mockito.Mockito;
+
+import java.io.PrintStream;
+import java.util.function.Supplier;
+
+/**
+ * Tests for {@link SystemStreamLog} 
+ */
+public class SystemStreamLogTest 
+{
+  private static final String EXPECTED_MESSAGE = "expected message";
+  private static PrintStream outStream;
+  private static PrintStream errStream;
+  private static PrintStream mockOut;
+  private static PrintStream mockErr;
+
+  /*
+   * As SystemStreamLog info/warn/error log levels are active, this test 
checks that
+   * a message supplier is really called/executed when logging at those levels 
+   */
+  @Test
+  public void testLazyMessageIsEvaluatedForActiveLogLevels()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.info(messageSupplier);
+logger.warn(messageSupplier);
+logger.error(messageSupplier);
+
+Mockito.verify(messageSupplier, Mockito.times(3)).get();
+  }
+
+  /*
+   * As SystemStreamLog debug log level is inactive, this test checks that
+   * a message supplier is not called/executed when logging at debug level
+   */
+  @Test
+  public void testDebugLazyMessageIsNotEvaluated()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.debug(messageSupplier);
+
+Mockito.verify(messageSupplier, Mockito.never()).get();
+  }
+
+  @BeforeAll
+  public static void initialize()
+  {
+outStream = System.out;
+errStream = System.err;
+
+mockOut = Mockito.mock(PrintStream.class);
+System.setOut(mockOut);
+mockErr = Mockito.mock(PrintStream.class);

Review comment:
   @slawekjaranowski did you saw my 
[comment](https://github.com/apache/maven/pull/438#issuecomment-767480098) 
above ? I think I should remove totally the mocks for stdout/stderr since they 
can also interfere with others tests in parallel.
   I think it is safer to pollute a bit the console output than to change 
stdout/stderr that are shared inside the JVM and could potentially be used 
while the test executes.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564498644



##
File path: 
maven-plugin-api/src/test/java/org/apache/maven/plugin/logging/SystemStreamLogTest.java
##
@@ -0,0 +1,94 @@
+package org.apache.maven.plugin.logging;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.junit.jupiter.api.AfterAll;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
+import org.mockito.Mock;
+import org.mockito.Mockito;
+
+import java.io.PrintStream;
+import java.util.function.Supplier;
+
+/**
+ * Tests for {@link SystemStreamLog} 
+ */
+public class SystemStreamLogTest 
+{
+  private static final String EXPECTED_MESSAGE = "expected message";
+  private static PrintStream outStream;
+  private static PrintStream errStream;
+  private static PrintStream mockOut;
+  private static PrintStream mockErr;
+
+  /*
+   * As SystemStreamLog info/warn/error log levels are active, this test 
checks that
+   * a message supplier is really called/executed when logging at those levels 
+   */
+  @Test
+  public void testLazyMessageIsEvaluatedForActiveLogLevels()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.info(messageSupplier);
+logger.warn(messageSupplier);
+logger.error(messageSupplier);
+
+Mockito.verify(messageSupplier, Mockito.times(3)).get();
+  }
+
+  /*
+   * As SystemStreamLog debug log level is inactive, this test checks that
+   * a message supplier is not called/executed when logging at debug level
+   */
+  @Test
+  public void testDebugLazyMessageIsNotEvaluated()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.debug(messageSupplier);

Review comment:
   same answer than above, log levels are hardcoded in 
`SystemStreamLog.java`.
   
   Do you prefer the same kind of test than in `DefaultLogTest` ? meaning 
calling all log levels and check number of Supplier calls.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564497192



##
File path: 
maven-plugin-api/src/test/java/org/apache/maven/plugin/logging/SystemStreamLogTest.java
##
@@ -0,0 +1,94 @@
+package org.apache.maven.plugin.logging;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.junit.jupiter.api.AfterAll;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
+import org.mockito.Mock;
+import org.mockito.Mockito;
+
+import java.io.PrintStream;
+import java.util.function.Supplier;
+
+/**
+ * Tests for {@link SystemStreamLog} 
+ */
+public class SystemStreamLogTest 
+{
+  private static final String EXPECTED_MESSAGE = "expected message";
+  private static PrintStream outStream;
+  private static PrintStream errStream;
+  private static PrintStream mockOut;
+  private static PrintStream mockErr;
+
+  /*
+   * As SystemStreamLog info/warn/error log levels are active, this test 
checks that
+   * a message supplier is really called/executed when logging at those levels 
+   */
+  @Test
+  public void testLazyMessageIsEvaluatedForActiveLogLevels()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.info(messageSupplier);
+logger.warn(messageSupplier);
+logger.error(messageSupplier);

Review comment:
   no because log levels are hard coded in `SystemStreamLog`. Only info, 
warn, error are active.

##
File path: 
maven-plugin-api/src/test/java/org/apache/maven/plugin/logging/SystemStreamLogTest.java
##
@@ -0,0 +1,94 @@
+package org.apache.maven.plugin.logging;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.junit.jupiter.api.AfterAll;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
+import org.mockito.Mock;
+import org.mockito.Mockito;
+
+import java.io.PrintStream;
+import java.util.function.Supplier;
+
+/**
+ * Tests for {@link SystemStreamLog} 
+ */
+public class SystemStreamLogTest 
+{
+  private static final String EXPECTED_MESSAGE = "expected message";
+  private static PrintStream outStream;
+  private static PrintStream errStream;
+  private static PrintStream mockOut;
+  private static PrintStream mockErr;
+
+  /*
+   * As SystemStreamLog info/warn/error log levels are active, this test 
checks that
+   * a message supplier is really called/executed when logging at those levels 
+   */
+  @Test
+  public void testLazyMessageIsEvaluatedForActiveLogLevels()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.info(messageSupplier);
+logger.warn(messageSupplier);
+logger.error(messageSupplier);
+
+Mockito.verify(messageSupplier, Mockito.times(3)).get();
+  }
+
+  /*
+   * As SystemStreamLog debug log level is inactive, this test checks that
+   * a message supplier is not called/executed when logging at debug level
+   */
+  @Test
+  public void testDebugLazyMessageIsNotEvaluated()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.debug(messageSupplier);
+
+Mockito.v

[GitHub] [maven] McFoggy commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564496153



##
File path: 
maven-plugin-api/src/main/java/org/apache/maven/plugin/logging/Log.java
##
@@ -63,6 +65,20 @@
  */
 void debug( Throwable error );
 
+/**
+ * Send a message to the user in the debug error level by computing 
the message
+ * only when needed. The supplier will be called only if @see 
#isDebugEnabled() is true.
+ * 
+ * @param messageSupplier a non null Supplier of the message to use
+ */
+default void debug( Supplier messageSupplier )

Review comment:
   I will add some for each log level with an exception.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Michael Osipov (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272087#comment-17272087
 ] 

Michael Osipov commented on SUREFIRE-1882:
--

They are likely more, my commits depicts only those used in Wagon.

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:266)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1320)
> [ERROR]   (...)
> {code}
> See also the dump file attached to this ticket.
> When running the build e.g. with Java 11 or Java 14, the same error does not 
> occur. I tested with the current master, commit 
> [f14fa54b|https://github.com/apache/maven-surefire/commit/f14fa54b9eba073c8c896a829fac1c2037b34222].
> The root cause seems to be this part of the dump file:
> {code}
> java.lang.NoSuchMethodError: java.nio.ByteBuffer.flip()Ljava/nio/ByteBuffer;
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:67)
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:44)
>   at 
> org.apache.maven.surefire.api.stream.AbstractStreamEncoder.write(AbstractStreamEncoder.java:77)
>   at 
> org.apache.maven.surefire.booter.spi.EventChannelEncoder.write(EventChannelEncoder.java:333)
>   at

[GitHub] [maven] michael-o commented on pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


michael-o commented on pull request #438:
URL: https://github.com/apache/maven/pull/438#issuecomment-767524135


   I really can't believe we are reinventing the wheel by implementing SLF4J 
Light.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] michael-o commented on pull request #413: [MNG-6843] Thread-safe artifacts in MavenProject

2021-01-26 Thread GitBox


michael-o commented on pull request #413:
URL: https://github.com/apache/maven/pull/413#issuecomment-767523804


   Please ping me next week, I am current incapable to do anything fruitful. 
Alternatively, go through Core ITs commits from me and check Plugin changes.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-shared-utils] rfscholte commented on a change in pull request #70: [MNG-6915] Add a helper method to get the terminal width

2021-01-26 Thread GitBox


rfscholte commented on a change in pull request #70:
URL: https://github.com/apache/maven-shared-utils/pull/70#discussion_r564454311



##
File path: pom.xml
##
@@ -70,7 +70,7 @@
 
   org.fusesource.jansi
   jansi
-  2.0.1
+  2.2.0
   true

Review comment:
   It must be optional, it is Maven that's responsible to provide it and to 
decide which features are supported.
   Maven 3.3.9 and earlier would otherwise have mixed output.
   





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] slachiewicz commented on pull request #437: [MNG-7082] - remove deprecation on org.apache.maven.plugin.logging.Log

2021-01-26 Thread GitBox


slachiewicz commented on pull request #437:
URL: https://github.com/apache/maven/pull/437#issuecomment-767493277


   One short notice - Plexus logger Log here, api and implementation is from 
Eclipse Plexus Sisu



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] rmannibucau commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


rmannibucau commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564449085



##
File path: maven-plugin-api/pom.xml
##
@@ -54,6 +54,11 @@ under the License.
   org.codehaus.plexus
   plexus-classworlds
 
+

Review comment:
   can we not use it and just test with a custom Log impl (like an in 
memory one or reusing default/logger one)? I don't see what it brings but I see 
how the test can pass with a broken impl ;)

##
File path: 
maven-plugin-api/src/main/java/org/apache/maven/plugin/logging/Log.java
##
@@ -63,6 +65,20 @@
  */
 void debug( Throwable error );
 
+/**
+ * Send a message to the user in the debug error level by computing 
the message
+ * only when needed. The supplier will be called only if @see 
#isDebugEnabled() is true.
+ * 
+ * @param messageSupplier a non null Supplier of the message to use
+ */
+default void debug( Supplier messageSupplier )

Review comment:
   don't think we need any default, I would add an AbstractLog our two impl 
would inherit from and that's it, will avoid the common default pitfalls - or 
corrollar is all our impl should impl it without using the default impl, up to 
you.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] slawekjaranowski commented on a change in pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


slawekjaranowski commented on a change in pull request #438:
URL: https://github.com/apache/maven/pull/438#discussion_r564440925



##
File path: 
maven-plugin-api/src/main/java/org/apache/maven/plugin/logging/Log.java
##
@@ -63,6 +65,20 @@
  */
 void debug( Throwable error );
 
+/**
+ * Send a message to the user in the debug error level by computing 
the message
+ * only when needed. The supplier will be called only if @see 
#isDebugEnabled() is true.
+ * 
+ * @param messageSupplier a non null Supplier of the message to use
+ */
+default void debug( Supplier messageSupplier )

Review comment:
   why do you not add  methods, like
   
   void debug( Supplier messageSupplier, Throwable error  )

##
File path: 
maven-plugin-api/src/test/java/org/apache/maven/plugin/logging/SystemStreamLogTest.java
##
@@ -0,0 +1,94 @@
+package org.apache.maven.plugin.logging;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.junit.jupiter.api.AfterAll;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
+import org.mockito.Mock;
+import org.mockito.Mockito;
+
+import java.io.PrintStream;
+import java.util.function.Supplier;
+
+/**
+ * Tests for {@link SystemStreamLog} 
+ */
+public class SystemStreamLogTest 
+{
+  private static final String EXPECTED_MESSAGE = "expected message";
+  private static PrintStream outStream;
+  private static PrintStream errStream;
+  private static PrintStream mockOut;
+  private static PrintStream mockErr;
+
+  /*
+   * As SystemStreamLog info/warn/error log levels are active, this test 
checks that
+   * a message supplier is really called/executed when logging at those levels 
+   */
+  @Test
+  public void testLazyMessageIsEvaluatedForActiveLogLevels()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.info(messageSupplier);
+logger.warn(messageSupplier);
+logger.error(messageSupplier);

Review comment:
   missing? `logger.debug`

##
File path: 
maven-plugin-api/src/test/java/org/apache/maven/plugin/logging/SystemStreamLogTest.java
##
@@ -0,0 +1,94 @@
+package org.apache.maven.plugin.logging;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.junit.jupiter.api.AfterAll;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.Test;
+import org.mockito.Mock;
+import org.mockito.Mockito;
+
+import java.io.PrintStream;
+import java.util.function.Supplier;
+
+/**
+ * Tests for {@link SystemStreamLog} 
+ */
+public class SystemStreamLogTest 
+{
+  private static final String EXPECTED_MESSAGE = "expected message";
+  private static PrintStream outStream;
+  private static PrintStream errStream;
+  private static PrintStream mockOut;
+  private static PrintStream mockErr;
+
+  /*
+   * As SystemStreamLog info/warn/error log levels are active, this test 
checks that
+   * a message supplier is really called/executed when logging at those levels 
+   */
+  @Test
+  public void testLazyMessageIsEvaluatedForActiveLogLevels()
+  {
+Supplier messageSupplier = Mockito.mock(Supplier.class);
+Mockito.when(messageSupplier.get()).thenReturn(EXPECTED_MESSAGE);
+
+Log logger = new SystemStreamLog();
+logger.info(messageSupplier);
+logger.warn(messageSupplier);

[GitHub] [maven] rmannibucau commented on pull request #437: [MNG-7082] - remove deprecation on org.apache.maven.plugin.logging.Log

2021-01-26 Thread GitBox


rmannibucau commented on pull request #437:
URL: https://github.com/apache/maven/pull/437#issuecomment-767488286


   @McFoggy not a big blocker for me since removing the deprecation on Log is 
the "big thing" there IMHO but think it is worth to have an implementation not 
deprecated (maybe default only?).



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy commented on pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy commented on pull request #438:
URL: https://github.com/apache/maven/pull/438#issuecomment-767480098


   Initially I did not wanted to pollute `stdout` & `stderr` that's why I 
mocked them in SystemStreamLogTest.
   Thinking more about it, it can be a bad idea to have mocked them.
   If required I'll remove the mock and let the SystemStreamLogTest test output 
messages.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex edited a comment on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex edited a comment on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767476849


   Maybe you want to contribute instead of micro-managing my edits? ๐Ÿ˜‰
   
   
![image](https://user-images.githubusercontent.com/1537384/105838558-d1250f00-6002-11eb-9689-55ee8b4f7f02.png)
   
   Just add commits to this PR to your heart's content. I would not mind at 
all, considering myself your junior in this project anyway. I am an agile coach 
in my daytime job, not a professional software developer (I was 20 years ago). 
So I am all open for collaborative software development because this is what I 
am teaching to my coachee dev teams.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex edited a comment on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex edited a comment on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767476849


   Maybe you want to contribute instead of micro-managing my edits? ๐Ÿ˜‰
   
   
![image](https://user-images.githubusercontent.com/1537384/105838558-d1250f00-6002-11eb-9689-55ee8b4f7f02.png)
   
   Just add commits to this PR to your heart's content. I am an agile coach in 
my daytime job, not a software developer. So I am all open for collaborative 
software development because this is what I am teaching to my coachee dev teams.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex commented on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex commented on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767476849


   Maybe you want to contribute instead of micro-managing my edits? ๐Ÿ˜‰
   
   
![image](https://user-images.githubusercontent.com/1537384/105838558-d1250f00-6002-11eb-9689-55ee8b4f7f02.png)
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] Tibor17 commented on a change in pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


Tibor17 commented on a change in pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#discussion_r564434105



##
File path: 
surefire-api/src/main/java/org/apache/maven/surefire/api/stream/AbstractStreamEncoder.java
##
@@ -112,17 +113,17 @@ public void encodeString( CharsetEncoder encoder, 
ByteBuffer result, String stri
 {
 String nonNullString = nonNull( string );
 
-int counterPosition = result.position();
+int counterPosition = ( (Buffer) result ).position();

Review comment:
   `position` method is also in the Buffer class. Maybe we can directly 
declare such type.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] Tibor17 commented on a change in pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


Tibor17 commented on a change in pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#discussion_r564432905



##
File path: 
surefire-api/src/main/java/org/apache/maven/surefire/api/stream/AbstractStreamDecoder.java
##
@@ -28,6 +28,7 @@
 import java.io.EOFException;
 import java.io.File;
 import java.io.IOException;
+import java.nio.Buffer;

Review comment:
   Can we declare the variables as `Buffer` in this class instead of 
ByteBuffer?





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy opened a new pull request #438: [MNG-7083] - introduce lazy Log message evaluation

2021-01-26 Thread GitBox


McFoggy opened a new pull request #438:
URL: https://github.com/apache/maven/pull/438


   as discussed in the dev mailing list 
[[1](https://mail-archives.apache.org/mod_mbox/maven-dev/202101.mbox/%3CCAGjJkv0%2BAa1ffGYnxWVYkz8_QWt7KsAYcJ0CsEe%2BMGy6h6FQ6w%40mail.gmail.com%3E)][[2](https://mail-archives.apache.org/mod_mbox/maven-dev/202101.mbox/%3CCAGjJkv2trLUX6W0UQwmsizPUNdZ6GXS9FB3ApP7w%2B7MhbBXT-g%40mail.gmail.com%3E)]
 this PR enhances org.apache.maven.plugin.logging.Log by adding a lazy log 
method with a `java.util.function.Supplier` for each log level.
   For each level the supplier will be called only if the corresponding log 
level is active.
   Using java 8 interface default method ensures backward compatibility with 
other potential existing implementations.
   
   Following this checklist to help us incorporate your 
   contribution quickly and easily:
   
- [X] Make sure there is a [JIRA 
issue](https://issues.apache.org/jira/browse/MNG) filed 
  for the change (usually before you start working on it).  Trivial 
changes like typos do not 
  require a JIRA issue.  Your pull request should address just this 
issue, without 
  pulling in other changes.
- [X] Each commit in the pull request should have a meaningful subject line 
and body.
- [X] Format the pull request title like `[MNG-XXX] - Fixes bug in 
ApproximateQuantiles`,
  where you replace `MNG-XXX` with the appropriate JIRA issue. Best 
practice
  is to use the JIRA issue title in the pull request title and in the 
first line of the 
  commit message.
- [X] Write a pull request description that is detailed enough to 
understand what the pull request does, how, and why.
- [X] Run `mvn clean verify` to make sure basic checks pass. A more 
thorough check will 
  be performed on your pull request automatically.
- [X] You have run the [Core IT][core-its] 
   
   Still two unrelatd ITs tests are failing locally
   
   [ERROR] Errors:
   [ERROR]   
MavenITmng5669ReadPomsOnce>AbstractMavenIntegrationTestCase.runTest:255->testWithBuildConsumer:119
 ยป Verification
   [ERROR]   
MavenITmng5669ReadPomsOnce>AbstractMavenIntegrationTestCase.runTest:255->testWithoutBuildConsumer:65
 ยป Verification
   
   
   If your pull request is about ~20 lines of code you don't need to sign an
   [Individual Contributor License 
Agreement](https://www.apache.org/licenses/icla.pdf) if you are unsure
   please ask on the developers list.
   
   To make clear that you license your contribution under 
   the [Apache License Version 2.0, January 
2004](http://www.apache.org/licenses/LICENSE-2.0)
   you have to acknowledge this by using the following check-box.
   
- [X] I hereby declare this contribution to be licenced under the [Apache 
License Version 2.0, January 2004](http://www.apache.org/licenses/LICENSE-2.0)
   
- [ ] In any other case, please file an [Apache Individual Contributor 
License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   > PS: I'll verify by asking on the mailing list if I have an ICLA already, 
or fill one if not.
   
   [core-its]: https://maven.apache.org/core-its/core-it-suite/
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] Tibor17 commented on a change in pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


Tibor17 commented on a change in pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#discussion_r564431601



##
File path: 
maven-surefire-common/src/test/java/org/apache/maven/plugin/surefire/report/StatelessXmlReporterTest.java
##
@@ -380,7 +381,7 @@ public void testSyncOnDeferredFile() throws Exception
 {
 Utf8RecodingDeferredFileOutputStream out = new 
Utf8RecodingDeferredFileOutputStream( "test" );
 ByteBuffer cache = ByteBuffer.wrap( new byte[] {1, 2, 3} );
-cache.position( 3 );
+( (Buffer) cache ).position( 3 );

Review comment:
   Can we declare the `cache` as `Buffer` in the tests as well?





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] Tibor17 commented on a change in pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


Tibor17 commented on a change in pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#discussion_r564430829



##
File path: 
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/report/Utf8RecodingDeferredFileOutputStream.java
##
@@ -93,14 +94,14 @@ public synchronized void write( String output, boolean 
newLine )
 }
 else
 {
-cache.flip();
+( (Buffer) cache ).flip();

Review comment:
   Can we declare the `cache` as `Buffer` here as well?





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] Tibor17 commented on a change in pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


Tibor17 commented on a change in pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#discussion_r564430136



##
File path: 
maven-surefire-common/src/test/java/org/apache/maven/plugin/surefire/extensions/StreamFeederTest.java
##
@@ -90,9 +91,9 @@ public void shouldEncodeCommandToStream() throws Exception
 public Object answer( InvocationOnMock invocation ) throws 
IOException
 {
 ByteBuffer bb = invocation.getArgument( 0 );

Review comment:
   I mean to declare the type as Buffer, see my proposal `Buffer bb = 
invocation.getArgument( 0 );`





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] Tibor17 commented on a change in pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


Tibor17 commented on a change in pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#discussion_r564429679



##
File path: 
maven-surefire-common/src/test/java/org/apache/maven/plugin/surefire/extensions/StreamFeederTest.java
##
@@ -90,9 +91,9 @@ public void shouldEncodeCommandToStream() throws Exception
 public Object answer( InvocationOnMock invocation ) throws 
IOException
 {
 ByteBuffer bb = invocation.getArgument( 0 );

Review comment:
   Maybe it would be nicer to declare the type here and then we do not have 
to cast `bb`.





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Alexander Kriegisch (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272037#comment-17272037
 ] 

Alexander Kriegisch commented on SUREFIRE-1882:
---

BTW, are there or could someone add any static byte code verifiers in Surefire 
which could automatically detect and report this issue? Chances are that it 
will re-occur the next time someone uses {{ByteBuffer}}.

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:266)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1320)
> [ERROR]   (...)
> {code}
> See also the dump file attached to this ticket.
> When running the build e.g. with Java 11 or Java 14, the same error does not 
> occur. I tested with the current master, commit 
> [f14fa54b|https://github.com/apache/maven-surefire/commit/f14fa54b9eba073c8c896a829fac1c2037b34222].
> The root cause seems to be this part of the dump file:
> {code}
> java.lang.NoSuchMethodError: java.nio.ByteBuffer.flip()Ljava/nio/ByteBuffer;
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:67)
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:44)
>   at 
> org.apache.maven.surefire.api.stream.AbstractStreamEncod

[jira] [Commented] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Alexander Kriegisch (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272034#comment-17272034
 ] 

Alexander Kriegisch commented on SUREFIRE-1882:
---

Like I said before when linking to the MongoDB comment, I think I have taken 
care of all 4 methods:
* {{position}}
* {{limit}}
* {{flip}}
* {{clear}}

Did I forget any?

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:266)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1320)
> [ERROR]   (...)
> {code}
> See also the dump file attached to this ticket.
> When running the build e.g. with Java 11 or Java 14, the same error does not 
> occur. I tested with the current master, commit 
> [f14fa54b|https://github.com/apache/maven-surefire/commit/f14fa54b9eba073c8c896a829fac1c2037b34222].
> The root cause seems to be this part of the dump file:
> {code}
> java.lang.NoSuchMethodError: java.nio.ByteBuffer.flip()Ljava/nio/ByteBuffer;
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:67)
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:44)
>   at 
> org.apache.maven.surefire.api.stream.AbstractStreamEncoder.write(AbstractStreamEncoder.java:77)
>   

[GitHub] [maven] McFoggy commented on pull request #437: [MNG-7082] - remove deprecation on org.apache.maven.plugin.logging.Log

2021-01-26 Thread GitBox


McFoggy commented on pull request #437:
URL: https://github.com/apache/maven/pull/437#issuecomment-767467591


   Hi Romain, 
   
   >isn't only Log which shouldn't be deprecated
   
   I hesitated on this. I can switch it back for the 2 implementations if it is 
more aligned with the long term goal.
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Tibor Digana (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272033#comment-17272033
 ] 

Tibor Digana commented on SUREFIRE-1882:


[~kriegaex] Thx for the fix. This issue looks clear to me ;-)
Should we do the same with the {{position}} method?

{code:java}
java.lang.NoSuchMethodError: 
java.nio.ByteBuffer.position(I)Ljava/nio/ByteBuffer;
{code}



> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:266)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1320)
> [ERROR]   (...)
> {code}
> See also the dump file attached to this ticket.
> When running the build e.g. with Java 11 or Java 14, the same error does not 
> occur. I tested with the current master, commit 
> [f14fa54b|https://github.com/apache/maven-surefire/commit/f14fa54b9eba073c8c896a829fac1c2037b34222].
> The root cause seems to be this part of the dump file:
> {code}
> java.lang.NoSuchMethodError: java.nio.ByteBuffer.flip()Ljava/nio/ByteBuffer;
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:67)
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:44)
>   at 
> org.apache.maven.surefire.api.stream.AbstractStreamEncoder.write(

[GitHub] [maven-surefire] Tibor17 commented on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


Tibor17 commented on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767465083


   @kriegaex I did rerun of the build. The networ is bad sometimes.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-shared-utils] elharo commented on a change in pull request #70: [MNG-6915] Add a helper method to get the terminal width

2021-01-26 Thread GitBox


elharo commented on a change in pull request #70:
URL: https://github.com/apache/maven-shared-utils/pull/70#discussion_r564418571



##
File path: pom.xml
##
@@ -70,7 +70,7 @@
 
   org.fusesource.jansi
   jansi
-  2.0.1
+  2.2.0
   true

Review comment:
   Why is this marked optional instead of simply declaring it? It feels 
like unnecessary complexity. The model code checks for its presence but the 
test code doesn't seem to. 





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Comment Edited] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Alexander Kriegisch (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272021#comment-17272021
 ] 

Alexander Kriegisch edited comment on SUREFIRE-1882 at 1/26/21, 10:45 AM:
--

I did a naive but hopefully thorough global search & replace and it seems to 
fix the issue, at least in my project:
https://github.com/apache/maven-surefire/pull/332

Please be kind with me, I have never contributed to any Maven project before. 
At least locally all tests and style checks pass, I hope I did nothing wrong. I 
replaced each of the 4 method calls in question according to the [commit 
comment in 
MongoDB|https://github.com/mongodb/mongo-java-driver/commit/21c91bd364d38489e0bbe2e390efdb3746ee3fff]
 referred to from the Wagon commit.

Why did I say "naive"? Simply because I replaced all corresponding method calls 
by casts, both in production and test code, even if it meant nested casting or 
repetitive casting. Maybe someone likes to optimise if it does not look nice 
enough like this. Feel free to accept the PR and then add an additional commit 
before merging to master.

*Edit:* I did not add any comprehensive regression test for this problem 
because that is beyond my means as a hobby programmer. Maybe a maintainer wants 
to add to this PR correspondingly.


was (Author: kriegaex):
I did a naive but hopefully thorough global search & replace and it seems to 
fix the issue, at least in my project:
https://github.com/apache/maven-surefire/pull/332

Please be kind with me, I have never contributed to any Maven project before. 
At least locally all tests and style checks pass, I hope I did nothing wrong. I 
replaced each of the 4 method calls in question according to the [commit 
comment in 
MongoDB|https://github.com/mongodb/mongo-java-driver/commit/21c91bd364d38489e0bbe2e390efdb3746ee3fff]
 referred to from the Wagon commit.

Why did I say "naive"? Simply because I replaced all corresponding method calls 
by casts, both in production and test code, even if it meant nested casting or 
repetitive casting. Maybe someone likes to optimise if it does not look nice 
enough like this. Feel free to accept the PR and then add an additional commit 
before merging to master.

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tm

[GitHub] [maven-surefire] kriegaex edited a comment on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex edited a comment on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767453228


   Looks like the "CI for Windows 1" failure was caused by a network problem:
   
   ```text
   Caused by: java.net.UnknownHostException: repo.maven.apache.org
   at java.net.Inet6AddressImpl.lookupAllHostAddr (Native Method)
   at java.net.InetAddress$2.lookupAllHostAddr (InetAddress.java:929)
   at java.net.InetAddress.getAddressesFromNameService 
(InetAddress.java:1324)
   at java.net.InetAddress.getAllByName0 (InetAddress.java:1277)
   at java.net.InetAddress.getAllByName (InetAddress.java:1193)
   at java.net.InetAddress.getAllByName (InetAddress.java:1127)
   at 
org.apache.maven.wagon.providers.http.httpclient.impl.conn.SystemDefaultDnsResolver.resolve
 (SystemDefaultDnsResolver.java:45)
   ```
   
   The same build was successful on my local workstation a few minutes before 
the CI run.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] rmannibucau commented on pull request #437: [MNG-7082] - remove deprecation on org.apache.maven.plugin.logging.Log

2021-01-26 Thread GitBox


rmannibucau commented on pull request #437:
URL: https://github.com/apache/maven/pull/437#issuecomment-767455778


   Hi @McFoggy , isnt only Log which shouldn't be deprecated and the 
implementation can stay deprecated if we want to forward them to slf4j 
internally - I suspect we will want to do it in DefaultLog but for now it uses 
plexus which is not desired anymore from what I understood?



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven-surefire] kriegaex commented on pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex commented on pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332#issuecomment-767453228


   Looks like CI failure was caused by a network problem:
   
   ```text
   Caused by: java.net.UnknownHostException: repo.maven.apache.org
   at java.net.Inet6AddressImpl.lookupAllHostAddr (Native Method)
   at java.net.InetAddress$2.lookupAllHostAddr (InetAddress.java:929)
   at java.net.InetAddress.getAddressesFromNameService 
(InetAddress.java:1324)
   at java.net.InetAddress.getAllByName0 (InetAddress.java:1277)
   at java.net.InetAddress.getAllByName (InetAddress.java:1193)
   at java.net.InetAddress.getAllByName (InetAddress.java:1127)
   at 
org.apache.maven.wagon.providers.http.httpclient.impl.conn.SystemDefaultDnsResolver.resolve
 (SystemDefaultDnsResolver.java:45)
   ```
   
   The same build was successful on my local workstation a few minutes before 
the CI run.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] McFoggy opened a new pull request #437: [MNG-7082] - remove deprecation on org.apache.maven.plugin.logging.Log

2021-01-26 Thread GitBox


McFoggy opened a new pull request #437:
URL: https://github.com/apache/maven/pull/437


   as discussed in the dev mailing list 
[[1](https://mail-archives.apache.org/mod_mbox/maven-dev/202101.mbox/%3CCAGjJkv0%2BAa1ffGYnxWVYkz8_QWt7KsAYcJ0CsEe%2BMGy6h6FQ6w%40mail.gmail.com%3E)][[2](https://mail-archives.apache.org/mod_mbox/maven-dev/202101.mbox/%3CCAGjJkv2trLUX6W0UQwmsizPUNdZ6GXS9FB3ApP7w%2B7MhbBXT-g%40mail.gmail.com%3E)]
 this PR removes depreciation on `org.apache.maven.plugin.logging.Log` and 
implementations.
   
   Following this checklist to help us incorporate your 
   contribution quickly and easily:
   
- [X] Make sure there is a [JIRA 
issue](https://issues.apache.org/jira/browse/MNG) filed 
  for the change (usually before you start working on it).  Trivial 
changes like typos do not 
  require a JIRA issue.  Your pull request should address just this 
issue, without 
  pulling in other changes.
- [X] Each commit in the pull request should have a meaningful subject line 
and body.
- [X] Format the pull request title like `[MNG-XXX] - Fixes bug in 
ApproximateQuantiles`,
  where you replace `MNG-XXX` with the appropriate JIRA issue. Best 
practice
  is to use the JIRA issue title in the pull request title and in the 
first line of the 
  commit message.
- [X] Write a pull request description that is detailed enough to 
understand what the pull request does, how, and why.
- [X] Run `mvn clean verify` to make sure basic checks pass. A more 
thorough check will 
  be performed on your pull request automatically.
- [X] You have run the [Core IT][core-its] 
   
   Two unrelatd ITs tests are failing locally
   
   [ERROR] Errors:
   [ERROR]   
MavenITmng5669ReadPomsOnce>AbstractMavenIntegrationTestCase.runTest:255->testWithBuildConsumer:119
 ยป Verification
   [ERROR]   
MavenITmng5669ReadPomsOnce>AbstractMavenIntegrationTestCase.runTest:255->testWithoutBuildConsumer:65
 ยป Verification
   
   
   If your pull request is about ~20 lines of code you don't need to sign an
   [Individual Contributor License 
Agreement](https://www.apache.org/licenses/icla.pdf) if you are unsure
   please ask on the developers list.
   
   To make clear that you license your contribution under 
   the [Apache License Version 2.0, January 
2004](http://www.apache.org/licenses/LICENSE-2.0)
   you have to acknowledge this by using the following check-box.
   
- [X] I hereby declare this contribution to be licenced under the [Apache 
License Version 2.0, January 2004](http://www.apache.org/licenses/LICENSE-2.0)
   
- [ ] In any other case, please file an [Apache Individual Contributor 
License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   [core-its]: https://maven.apache.org/core-its/core-it-suite/
   
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [maven] famod commented on pull request #413: [MNG-6843] Thread-safe artifacts in MavenProject

2021-01-26 Thread GitBox


famod commented on pull request #413:
URL: https://github.com/apache/maven/pull/413#issuecomment-767452439


   @michael-o friendly reminder:
   > Can you point me to such a test with a custom mojo? I would then try to 
take a (timeboxed) stab at it.
   > Thanks!
   
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Alexander Kriegisch (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272021#comment-17272021
 ] 

Alexander Kriegisch commented on SUREFIRE-1882:
---

I did a naive but hopefully thorough global search & replace and it seems to 
fix the issue, at least in my project:
https://github.com/apache/maven-surefire/pull/332

Please be kind with me, I have never contributed to any Maven project before. 
At least locally all tests and style checks pass, I hope I did nothing wrong. I 
replaced each of the 4 method calls in question according to the [commit 
comment in 
MongoDB|https://github.com/mongodb/mongo-java-driver/commit/21c91bd364d38489e0bbe2e390efdb3746ee3fff]
 referred to from the Wagon commit.

Why did I say "naive"? Simply because I replaced all corresponding method calls 
by casts, both in production and test code, even if it meant nested casting or 
repetitive casting. Maybe someone likes to optimise if it does not look nice 
enough like this. Feel free to accept the PR and then add an additional commit 
before merging to master.

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:266)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1320)
> [ERROR]   (...)
> {code}
> See also the dump file attached to this ticket.
> When running the build e.g. with Java 11 or Java 14, the same error d

[GitHub] [maven-surefire] kriegaex opened a new pull request #332: [SUREFIRE-1882] Fix failures when compiled on Java 9+ and run on Java 8

2021-01-26 Thread GitBox


kriegaex opened a new pull request #332:
URL: https://github.com/apache/maven-surefire/pull/332


   Cast to Buffer to avoid java.lang.NoSuchMethodError due to JDK API
   breakage.
   
   This was fixed in a similar way in apache/maven-wagon@92c0d2a.
   
   See mongodb/mongo-java-driver@21c91bd for details.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (MPIR-402) Modules Report: provide links to Maven Central

2021-01-26 Thread Michael Osipov (Jira)


[ 
https://issues.apache.org/jira/browse/MPIR-402?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272007#comment-17272007
 ] 

Michael Osipov commented on MPIR-402:
-

I will go through soon...

> Modules Report: provide links to Maven Central
> --
>
> Key: MPIR-402
> URL: https://issues.apache.org/jira/browse/MPIR-402
> Project: Maven Project Info Reports Plugin
>  Issue Type: New Feature
>  Components: modules
>Reporter: Florian Brunner
>Priority: Major
> Fix For: waiting-for-feedback
>
>
> In the table of the modules report also provide the links to Maven Central.
> This issue is actually about contributing a patch I made some years ago back 
> to this upstream project.
> Here is a sample how it looks like: 
> [https://www.drombler.org/drombler-fx/1.0/docs/site/modules.html]
> I'm using this patch already for several years and it is great for 
> documenting the Maven coordinates of libraries, especially in multi-Module 
> projects, IMHO.
> I typically directly point to this report from some prominent places such 
> from a top site inside the documentation 
> ([https://www.drombler.org/drombler-fx/1.0/]) or in blog posts 
> (https://puces-blog.blogspot.com/2020/01/drombler-fx-version-10-released.html).



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Michael Osipov (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17272005#comment-17272005
 ] 

Michael Osipov commented on SUREFIRE-1882:
--

You edit is correct. The supplied commit shows how to solve this.

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:266)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1320)
> [ERROR]   (...)
> {code}
> See also the dump file attached to this ticket.
> When running the build e.g. with Java 11 or Java 14, the same error does not 
> occur. I tested with the current master, commit 
> [f14fa54b|https://github.com/apache/maven-surefire/commit/f14fa54b9eba073c8c896a829fac1c2037b34222].
> The root cause seems to be this part of the dump file:
> {code}
> java.lang.NoSuchMethodError: java.nio.ByteBuffer.flip()Ljava/nio/ByteBuffer;
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:67)
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:44)
>   at 
> org.apache.maven.surefire.api.stream.AbstractStreamEncoder.write(AbstractStreamEncoder.java:77)
>   at 
> org.apache.maven.surefire.booter.spi.EventChannelEncoder.write(EventChannelEncoder.java:333)
>   at 

[jira] [Comment Edited] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Alexander Kriegisch (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17271979#comment-17271979
 ] 

Alexander Kriegisch edited comment on SUREFIRE-1882 at 1/26/21, 9:11 AM:
-

[~michael-o], what is that supposed to tell me? Please elaborate so that I as a 
user (not a maintainer or contributor) can also get a basic understanding of 
your message. Thank you so much.

*Edit:* Oh, I think you mean that in order to fix this, {{ByteBuffer}} 
instances calling certain methods overloaded in Java 9+ ought to be cast to 
{{Buffer}} like you did for Wagon and the other guy did for MongoDB.


was (Author: kriegaex):
[~michael-o], what is that supposed to tell me? Please elaborate so that I as a 
user (not a maintainer or contributor) can also get a basic understanding of 
your message. Thank you so much.

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:266)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1320)
> [ERROR]   (...)
> {code}
> See also the dump file attached to this ticket.
> When running the build e.g. with Java 11 or Java 14, the same error does not 
> occur. I tested with the current master, commit 
> [f14fa54b|https://github.com/apache/maven-surefire/commit/f14fa54b9eba073c8c896a829fac1c2037b34222].
> The root cause seems to be this part of the dump file

[jira] [Commented] (SUREFIRE-1882) 3.0.0-M6-SNAPSHOT no longer working with Java 8

2021-01-26 Thread Alexander Kriegisch (Jira)


[ 
https://issues.apache.org/jira/browse/SUREFIRE-1882?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17271979#comment-17271979
 ] 

Alexander Kriegisch commented on SUREFIRE-1882:
---

[~michael-o], what is that supposed to tell me? Please elaborate so that I as a 
user (not a maintainer or contributor) can also get a basic understanding of 
your message. Thank you so much.

> 3.0.0-M6-SNAPSHOT no longer working with Java 8
> ---
>
> Key: SUREFIRE-1882
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1882
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin, Maven Surefire Plugin
>Affects Versions: 3.0.0-M6
>Reporter: Alexander Kriegisch
>Priority: Major
> Attachments: 2021-01-26T13-22-12_972-jvmRun1.dump
>
>
> When running my build on JDK 8, I see
> {code}
> [INFO] --- maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test (reuse-jvm) @ 
> sarek-mock ---
> [INFO] 
> [INFO] ---
> [INFO]  T E S T S
> [INFO] ---
> [INFO] 
> [INFO] Results:
> [INFO] 
> [INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> [WARNING] Could not delete temp directory 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 because File 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  unable to be deleted.
> [INFO] 
> 
> [INFO] Reactor Summary for sarek-parent 1.0-SNAPSHOT:
> [INFO] 
> [INFO] (...)
> [INFO] sarek-mock . FAILURE [  1.541 
> s]
> [INFO] (...)
> [INFO] 
> 
> [INFO] BUILD FAILURE
> [INFO] 
> 
> [INFO] Total time:  15.095 s
> [INFO] Finished at: 2021-01-26T13:22:20+07:00
> [INFO] 
> 
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M6-SNAPSHOT:test 
> (reuse-jvm) on project sarek-mock: There are test failures.
> [ERROR] 
> [ERROR] Please refer to 
> C:\Users\alexa\Documents\java-src\Sarek\sarek-mock\target\surefire-reports 
> for the individual test results.
> [ERROR] Please refer to dump files (if any exist) [date].dump, 
> [date]-jvmRun[N].dump and [date].dumpstream.
> [ERROR] The forked VM terminated without properly saying goodbye. VM crash or 
> System.exit called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: The 
> forked VM terminated without properly saying goodbye. VM crash or System.exit 
> called?
> [ERROR] Command was cmd.exe /X /C ""C:\Program 
> Files\Java\jdk1.8.0_211\jre\bin\java" -jar 
> C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157\surefirebooter4446112705128419789.jar
>  C:\Users\alexa\AppData\Local\Temp\surefire9150168311367699157 
> 2021-01-26T13-22-12_972-jvmRun1 surefire4902538894981773413tmp 
> surefire_05054187083706494231tmp"
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:751)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:306)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:266)
> [ERROR]   at 
> org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1320)
> [ERROR]   (...)
> {code}
> See also the dump file attached to this ticket.
> When running the build e.g. with Java 11 or Java 14, the same error does not 
> occur. I tested with the current master, commit 
> [f14fa54b|https://github.com/apache/maven-surefire/commit/f14fa54b9eba073c8c896a829fac1c2037b34222].
> The root cause seems to be this part of the dump file:
> {code}
> java.lang.NoSuchMethodError: java.nio.ByteBuffer.flip()Ljava/nio/ByteBuffer;
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:67)
>   at 
> org.apache.maven.surefire.api.util.internal.AbstractNoninterruptibleWritableChannel.write(AbstractNoninterruptibleWritableChannel.java:44)
>   at 
> org.apache.maven.surefire.api.stream.AbstractStreamEncoder.write(AbstractStrea

  1   2   >