[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2022-05-27 Thread Jira


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

Thorbjørn Ravn Andersen commented on MCOMPILER-394:
---

[~loeti] ah, found your build.log showing your stack trace.   This is a problem 
with javac which has been present for _very_ long (see 
[https://lists.apache.org/thread/4hkrc437rrmmgmzhztgjc2jl2khhposj|https://lists.apache.org/thread/4hkrc437rrmmgmzhztgjc2jl2khhposj)]
 ) where you apparently found an edge case.   This is not a Maven bug, but a 
bug in Javac as the newer OpenJDK version reports.   

Note that the Eclipse compiler does not have this bug and may be a here-and-now 
fix by telling the compiler plugin to use that instead of javac.   See 
[https://stackoverflow.com/a/49599478/53897] for details.  In the long run, I 
would suggest you refactor these classes instead.

 

[~michael-o] I agree.

 

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10, Windows 7 and also 
> with Ubuntu.
>Reporter: Markus Bader
>Priority: Major
> Attachments: MCompiler394.java, build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian Jira
(v8.20.7#820007)


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2022-05-27 Thread Michael Osipov (Jira)


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

Michael Osipov commented on MCOMPILER-394:
--

I am inclined to close this issue because as far as I understand this is a JDK 
issue, and not a plugin one.

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10, Windows 7 and also 
> with Ubuntu.
>Reporter: Markus Bader
>Priority: Major
> Attachments: MCompiler394.java, build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian Jira
(v8.20.7#820007)


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2022-05-27 Thread Jira


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

Thorbjørn Ravn Andersen commented on MCOMPILER-394:
---

[~loeti] I have now created a small project with your class at  
[https://github.com/ravn/MCOMPILER-394,] which fails to compile for me both 
from within IntelliJ and from the MacOS command line.

 

The error message for me is as follows.  Is it the same you see?

 

```

[INFO] Compiling 2 source files to /Users/ravn/git/MCOMPILER-394/target/classes
An exception has occurred in the compiler (17.0.1). Please file a bug against 
the Java compiler via the Java bug reporting page (http://bugreport.java.com) 
after checking the Bug Database (http://bugs.java.com) for duplicates. Include 
your program, the following diagnostic, and the parameters passed to the Java 
compiler in your report. Thank you.
java.lang.StackOverflowError
    at jdk.compiler/com.sun.tools.javac.comp.Attr.visitBinary(Attr.java:3970)
    at 
jdk.compiler/com.sun.tools.javac.tree.JCTree$JCBinary.accept(JCTree.java:2156)
    at jdk.compiler/com.sun.tools.javac.comp.Attr.attribTree(Attr.java:674)
    at jdk.compiler/com.sun.tools.javac.comp.Attr.attribExpr(Attr.java:727)
    at jdk.compiler/com.sun.tools.javac.comp.Attr.visitBinary(Attr.java:3970)
    at 
jdk.compiler/com.sun.tools.javac.tree.JCTree$JCBinary.accept(JCTree.java:2156)

```

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10, Windows 7 and also 
> with Ubuntu.
>Reporter: Markus Bader
>Priority: Major
> Attachments: MCompiler394.java, build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian Jira
(v8.20.7#820007)


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2022-05-27 Thread Markus Bader (Jira)


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

Markus Bader commented on MCOMPILER-394:


It's not easy. I tried it with a blank project with only one test class and 
could not reproduce the issue. I tried it with 400 attributes in one class. 
Then I tried to add this class to an existing, more complex project and I still 
was not able to get the error. But after increasing the number of attributes to 
1000, the error occured.

So try following: Take my class with 1000 attributes, add it to an own, complex 
maven project and try to compile it. If not reproducable, increase the number 
of attributes (incl. getter, setter, toString()).

[^MCompiler394.java]

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10, Windows 7 and also 
> with Ubuntu.
>Reporter: Markus Bader
>Priority: Major
> Attachments: MCompiler394.java, build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian Jira
(v8.20.7#820007)


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2022-05-26 Thread Jira


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

Thorbjørn Ravn Andersen commented on MCOMPILER-394:
---

[~loeti] now that you found the cause, can you make a sharable test case 
reproducing this on e.g. latest Ubuntu.

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10, Windows 7 and also 
> with Ubuntu.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian Jira
(v8.20.7#820007)


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2022-05-13 Thread Markus Bader (Jira)


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

Markus Bader commented on MCOMPILER-394:


In Nov. 2021 we found the reason for this behaviour. We have a POJO class with 
many attributes and its getter- and setter-methods. Did I say "many 
attributes"? I mean many many attributes. many many many!

The toString() method was correspondingly long (nearly 800 lines). After 
removing the toString() method, the error didn't appear anymore. I think, we 
should rethink the architecture of this class...  ;)

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10, Windows 7 and also 
> with Ubuntu.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian Jira
(v8.20.7#820007)


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2020-06-26 Thread Benjamin Marwell (Jira)


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

Benjamin Marwell commented on MCOMPILER-394:


I think I ran into this some time ago as well.

> Can you try a different Java version?

> We tried 1.8.0_172, 1.8.0_211 and 1.8.0_221: All the same result.
> Unfortunately our sources are not compatible to Java 11, so I couldn't try 11.

But I remember I switched to adopt-openj9 JDK 11 and the problem went away. 
Judging from your post, you only tried oracle versions. You should easily be 
able to test with Java 11 with only a few small tweaks:
 * Download adopt-openj9 or adopt-hotspot from adoptopenjdk.net. Those are 
Eclipse Adoptium implementations of OpenJDK with Hotspot JVM and OpenJDK with 
Eclipse OpenJ9 JVM.
 * Either set {{maven.compiler.release}} to 8 or both {{maven.compiler.target}} 
and {{maven.compiler.source}} to 1.8
 * You might need just a handful dependencies. Usually it just comes down to 
the javax/jakarta annotation api and javax/jakarta xml bind API.

That should usually do it, at least for the majority of projects. Depending of 
how you organised your projects, this might be done in a few minutes.
 

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10, Windows 7 and also 
> with Ubuntu.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



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


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2020-03-04 Thread Markus Bader (Jira)


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

Markus Bader commented on MCOMPILER-394:


Same problem with 3.8.1

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10, Windows 7 and also 
> with Ubuntu.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



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


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2020-02-06 Thread Robert Scholte (Jira)


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

Robert Scholte commented on MCOMPILER-394:
--

I've just noticed you're still using maven-compiuler-plugin 3.1, could you at 
least update it to 3.8.1?

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10, Windows 7 and also 
> with Ubuntu.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



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


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2020-02-06 Thread Markus Bader (Jira)


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

Markus Bader commented on MCOMPILER-394:


Update: We've now renamed the root folder which fixed the problem - for a few 
weeks. After that the issue came back - even Jenkins runs into the problem now 
and then.

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10 and also with Windows 
> 7.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



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


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2019-09-11 Thread Markus Bader (Jira)


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

Markus Bader commented on MCOMPILER-394:


Some new info: The same issue now occurs also on an Ubuntu environment. 
Renaming the root folder of the project fixes it.

Java Version 1.8.0_201.

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10 and also with Windows 
> 7.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian Jira
(v8.3.2#803003)


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2019-07-26 Thread Markus Bader (JIRA)


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

Markus Bader commented on MCOMPILER-394:


Yes, that's the problem. It's even for me not reproducable in another 
environment. As I said, it suffices to copy the whole project into another 
directory or just rename the directory and the error ist not reproducable.

I've tried to minimize the number of Java classes for providing a sample 
project (my project has 150 classes). While minimizing the number of classes 
the error disappeared when I removed the class MathParser I mentioned above. I 
don't really think that this class is the cause. I always ask me: "Why does the 
error disappear when I rename the directory?". I think, the error would also 
disappear when I remove other classes. I will try this.

I also tried to increase the memory size with "-J -Xss4096M -Xms:4096m" but 
this didn't change anything.

 

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10 and also with Windows 
> 7.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2019-07-25 Thread Robert Scholte (JIRA)


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

Robert Scholte commented on MCOMPILER-394:
--

So there's no exact code to reproduce (yet), so it is hard to analyze. The 
stacktrace indicates it is a javac issue. I can help getting the issue at the 
right place, but I need some help.
Try to provide a single sourcefile with the issue (maybe you need to include 
the absolute path to that folder too) and clear instructions what you changed 
to make it fail.
If I can reproduce it as well, I should be able to help, the info you've 
provided so far is just not enough.




 

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10 and also with Windows 
> 7.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2019-07-25 Thread Markus Bader (JIRA)


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

Markus Bader commented on MCOMPILER-394:


The packagename is a placeholder for the real package name. The real name 
contains the name of our customer and some other details I didn't want to 
publish.

Teh question is: Why does it work, when I rename the root folder of the project 
(where the POM is located)?

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10 and also with Windows 
> 7.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2019-07-24 Thread Robert Scholte (JIRA)


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

Robert Scholte commented on MCOMPILER-394:
--

bq. package some.anonymised.package;

Not sure if this is an example, but it is not a valid package name. {{package}} 
is a keyword and cannot be used as part of the package name.

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10 and also with Windows 
> 7.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2019-07-24 Thread Markus Bader (JIRA)


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

Markus Bader commented on MCOMPILER-394:


The same with 3.8.1.  :(

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10 and also with Windows 
> 7.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)


[jira] [Commented] (MCOMPILER-394) Stackoverflow while compiling Java Sources, but works after renaming project directory

2019-07-24 Thread Robert Scholte (JIRA)


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

Robert Scholte commented on MCOMPILER-394:
--

I see you're using maven-compiler-plugin 3.1. Please test it with the most 
recent version (that's 3.8.1 at the moment)

> Stackoverflow while compiling Java Sources, but works after renaming project 
> directory
> --
>
> Key: MCOMPILER-394
> URL: https://issues.apache.org/jira/browse/MCOMPILER-394
> Project: Maven Compiler Plugin
>  Issue Type: Bug
>Affects Versions: 3.1
> Environment: The problem occurs with Windows 10 and also with Windows 
> 7.
>Reporter: Markus Bader
>Priority: Major
> Attachments: build.log
>
>
> Me and one of my colleagues have following problem (others do not): We want 
> to build a maven project, but "mvn clean install" ends up in a stackoverflow 
> error. But after renaming the project directory, it works. Also after 
> renaming the name of the parent directory and leaving the name of the project 
> directory by its original value, compilation is possible.
>  I also tried changing the artifactId so that it doesn't match the folder 
> name. Result: stackoverflow.
> To make it more strange: I tried to reduce the used Java classes for possibly 
> identifying a class to be responsible for this phenomenon. Therefor I deleted 
> a class named "MathParser" and after that compilation was possible. So I 
> analysed the content of the class and found out, that the stackoverflow error 
> occurs even if the class ist nearly empty. With following content I can 
> reproduce the error:
>  
> {code:java}
> package some.anonymised.package;
> public class MathParser {
>     private void doSomething(String func) throws Exception {
>     throw new Exception ("function '" + func + "' is not defined");
>     }
> } {code}
> With an empty method body, the build works fine.
> I attached the log created with debug option activated (with reduced number 
> of classes and reduced content of MathParser). For anonymisation purposes I 
> replaced the name of some directories, packages etc. by "x".



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)