You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Robert Scholte <rf...@apache.org> on 2018/11/27 20:52:07 UTC
plugin:descriptor fails with java.util.NoSuchElementException
Hi,
sometimes the maven-plugin-plugin fails to write the plugin descriptor and
exits with the exception below.
I see the same unreliable behavior on our Jenkins servers too, re-running
often fixes the issue.
I have seen the issue several times locally when running with mvn.cmd, so
far never with mvnDebug.cmd and always running with default #threads.
I can't find a reason why elementStack[1] gets out of sync.
If there are others experiencing the same or similar issues, please share
your analysis.
Hopefully we can solve this instability issue soon.
thanks,
Robert
[1]
http://codehaus-plexus.github.io/plexus-utils/xref/org/codehaus/plexus/util/xml/PrettyPrintXMLWriter.html#L40
[ERROR] Failed to execute goal
org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
(default-descriptor) on project maven-javadoc-plugin: Execution
default-descriptor of goal
org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor failed.
NoSuchElementException -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute
goal org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
(default-descriptor) on project maven-javadoc-plugin: Execution
default-descriptor of goal
org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor failed
Caused by: java.util.NoSuchElementException
at java.util.LinkedList.removeLast (LinkedList.java:281)
at org.codehaus.plexus.util.xml.PrettyPrintXMLWriter.endElement
(PrettyPrintXMLWriter.java:297)
at
org.apache.maven.tools.plugin.generator.PluginDescriptorGenerator.writeDescriptor
(PluginDescriptorGenerator.java:175)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Tibor Digana <ti...@apache.org>.
One more hint. What if the start element was added as NULL by an accident?
What if the impl of LinkedList ignores such element and then there are N -
1 elements to remove.
Adding an asset may help to find it.
On Sun, Dec 9, 2018 at 8:00 PM Tibor Digana <ti...@apache.org> wrote:
> I have checked everything, including the commit hash, the change, trigger
> and log.
> It's undeterministic run as you said.
> What happens if you simply use ArrayDeque instead of LinkedList?
> How can we identify it's the problem of strings conc and List impl?
> Perhaps only by giving a try several times and avoid influence after these
> tests.
>
>
> On Sun, Dec 9, 2018 at 6:29 PM Robert Scholte <rf...@apache.org>
> wrote:
>
>> For your interest, just hit it again:
>>
>>
>> https://builds.apache.org/job/maven-box/job/maven-javadoc-plugin/job/MJAVADOC-543/
>>
>> First run only fails for Build windows-jdk7-m3.2.x_build, with the
>> j.u.NoSuchElementException
>> A rerun without any changes,now it luckily succeeds.
>>
>> Robert
>>
>> On Sun, 09 Dec 2018 17:35:45 +0100, Tibor Digana <ti...@apache.org>
>>
>> wrote:
>>
>> > Is the issue found on Oracle Jira or bug report?
>> > This might to do with some build version in Java 1.7. Usually they fix
>> it
>> > right after since this bug hits the JVM stability and Oracle is paying
>> an
>> > attention to JIT stability.
>> >
>> >
>> >
>> > On Sun, Dec 9, 2018 at 4:36 PM Robert Scholte <rf...@apache.org>
>> > wrote:
>> >
>> >> I have to admit that it still looks weird, but the open and close tags
>> >> are
>> >> balanced.
>> >> Also notice that only Java 7 (sometimes) hits this issue.
>> >> Gabriel was able to provide a test that always fails on Java 7, not on
>> >> the
>> >> other JDKs.
>> >> It must have to do with optimization when the JVM is warmed up.
>> >>
>> >> Anyway, the provided patch takes away the failures and the writing to
>> >> the
>> >> stream is now cleaner too.
>> >> You might want to dive into this, but I wonder if it is worth it.
>> >> Issue will be resolved with the next release.
>> >>
>> >> thanks,
>> >> Robert
>> >>
>> >> On Sat, 08 Dec 2018 12:44:40 +0100, Enrico Olivelli
>> >> <eo...@gmail.com>
>> >>
>> >> wrote:
>> >>
>> >> > +1 for Tibor's explanation.
>> >> > Enrico
>> >> >
>> >> > Il sab 8 dic 2018, 12:29 Tibor Digana <ti...@apache.org> ha
>> >> > scritto:
>> >> >
>> >> >> PluginDescriptorGenerator.writeDescriptor does not use Threads so it
>> >> >> must
>> >> >> be the problem that the number of calls "endElement" is greater than
>> >> >> calls
>> >> >> "startElement".
>> >> >>
>> >> >>
>> >>
>> https://github.com/apache/maven-plugin-tools/blob/master/maven-plugin-tools-generators/src/main/java/org/apache/maven/tools/plugin/generator/PluginDescriptorGenerator.java
>> >> >>
>> >> >>
>> >> >> On Sat, Dec 8, 2018 at 11:46 AM Tibor Digana <
>> tibordigana@apache.org>
>> >> >> wrote:
>> >> >>
>> >> >> > I do not think it can be such JVM issue with string
>> concatenations,
>> >> >> > otherwise
>> >> >> > all the world has the same problem.
>> >> >> > This type of issue is usually caused by multiple writes from
>> >> multiple
>> >> >> > threads.
>> >> >> > Try to log every method with Thread id and we should see
>> multiple
>> >> ids.
>> >> >> > The java.io is supposed to be synchronized and thread safe.
>> >> Therefore
>> >> >> > PrintWriter is a wrapper of thread safe implementations.
>> >> >> > We should use ConcurrentLinkedList and identify large
>> >> functionality.
>> >> >> If
>> >> >> > large methods changes status at multiple lines, then this is a
>> >> >> critical
>> >> >> > section and the class must be synchronized.
>> >> >> >
>> >> >> > Cheers
>> >> >> > Tibor
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >> > --
>> >> >> > Sent from:
>> >> >> http://maven.40175.n5.nabble.com/Maven-Developers-f142166.html
>> >> >> >
>> >> >> >
>> >> ---------------------------------------------------------------------
>> >> >> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> >> >> > For additional commands, e-mail: dev-help@maven.apache.org
>> >> >> >
>> >> >> >
>> >>
>> >> ---------------------------------------------------------------------
>> >> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> >> For additional commands, e-mail: dev-help@maven.apache.org
>> >>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> For additional commands, e-mail: dev-help@maven.apache.org
>>
>>
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Tibor Digana <ti...@apache.org>.
I have checked everything, including the commit hash, the change, trigger
and log.
It's undeterministic run as you said.
What happens if you simply use ArrayDeque instead of LinkedList?
How can we identify it's the problem of strings conc and List impl?
Perhaps only by giving a try several times and avoid influence after these
tests.
On Sun, Dec 9, 2018 at 6:29 PM Robert Scholte <rf...@apache.org> wrote:
> For your interest, just hit it again:
>
>
> https://builds.apache.org/job/maven-box/job/maven-javadoc-plugin/job/MJAVADOC-543/
>
> First run only fails for Build windows-jdk7-m3.2.x_build, with the
> j.u.NoSuchElementException
> A rerun without any changes,now it luckily succeeds.
>
> Robert
>
> On Sun, 09 Dec 2018 17:35:45 +0100, Tibor Digana <ti...@apache.org>
>
> wrote:
>
> > Is the issue found on Oracle Jira or bug report?
> > This might to do with some build version in Java 1.7. Usually they fix it
> > right after since this bug hits the JVM stability and Oracle is paying an
> > attention to JIT stability.
> >
> >
> >
> > On Sun, Dec 9, 2018 at 4:36 PM Robert Scholte <rf...@apache.org>
> > wrote:
> >
> >> I have to admit that it still looks weird, but the open and close tags
> >> are
> >> balanced.
> >> Also notice that only Java 7 (sometimes) hits this issue.
> >> Gabriel was able to provide a test that always fails on Java 7, not on
> >> the
> >> other JDKs.
> >> It must have to do with optimization when the JVM is warmed up.
> >>
> >> Anyway, the provided patch takes away the failures and the writing to
> >> the
> >> stream is now cleaner too.
> >> You might want to dive into this, but I wonder if it is worth it.
> >> Issue will be resolved with the next release.
> >>
> >> thanks,
> >> Robert
> >>
> >> On Sat, 08 Dec 2018 12:44:40 +0100, Enrico Olivelli
> >> <eo...@gmail.com>
> >>
> >> wrote:
> >>
> >> > +1 for Tibor's explanation.
> >> > Enrico
> >> >
> >> > Il sab 8 dic 2018, 12:29 Tibor Digana <ti...@apache.org> ha
> >> > scritto:
> >> >
> >> >> PluginDescriptorGenerator.writeDescriptor does not use Threads so it
> >> >> must
> >> >> be the problem that the number of calls "endElement" is greater than
> >> >> calls
> >> >> "startElement".
> >> >>
> >> >>
> >>
> https://github.com/apache/maven-plugin-tools/blob/master/maven-plugin-tools-generators/src/main/java/org/apache/maven/tools/plugin/generator/PluginDescriptorGenerator.java
> >> >>
> >> >>
> >> >> On Sat, Dec 8, 2018 at 11:46 AM Tibor Digana <tibordigana@apache.org
> >
> >> >> wrote:
> >> >>
> >> >> > I do not think it can be such JVM issue with string concatenations,
> >> >> > otherwise
> >> >> > all the world has the same problem.
> >> >> > This type of issue is usually caused by multiple writes from
> >> multiple
> >> >> > threads.
> >> >> > Try to log every method with Thread id and we should see multiple
> >> ids.
> >> >> > The java.io is supposed to be synchronized and thread safe.
> >> Therefore
> >> >> > PrintWriter is a wrapper of thread safe implementations.
> >> >> > We should use ConcurrentLinkedList and identify large
> >> functionality.
> >> >> If
> >> >> > large methods changes status at multiple lines, then this is a
> >> >> critical
> >> >> > section and the class must be synchronized.
> >> >> >
> >> >> > Cheers
> >> >> > Tibor
> >> >> >
> >> >> >
> >> >> >
> >> >> >
> >> >> > --
> >> >> > Sent from:
> >> >> http://maven.40175.n5.nabble.com/Maven-Developers-f142166.html
> >> >> >
> >> >> >
> >> ---------------------------------------------------------------------
> >> >> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> >> >> > For additional commands, e-mail: dev-help@maven.apache.org
> >> >> >
> >> >> >
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> >> For additional commands, e-mail: dev-help@maven.apache.org
> >>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Robert Scholte <rf...@apache.org>.
For your interest, just hit it again:
https://builds.apache.org/job/maven-box/job/maven-javadoc-plugin/job/MJAVADOC-543/
First run only fails for Build windows-jdk7-m3.2.x_build, with the
j.u.NoSuchElementException
A rerun without any changes,now it luckily succeeds.
Robert
On Sun, 09 Dec 2018 17:35:45 +0100, Tibor Digana <ti...@apache.org>
wrote:
> Is the issue found on Oracle Jira or bug report?
> This might to do with some build version in Java 1.7. Usually they fix it
> right after since this bug hits the JVM stability and Oracle is paying an
> attention to JIT stability.
>
>
>
> On Sun, Dec 9, 2018 at 4:36 PM Robert Scholte <rf...@apache.org>
> wrote:
>
>> I have to admit that it still looks weird, but the open and close tags
>> are
>> balanced.
>> Also notice that only Java 7 (sometimes) hits this issue.
>> Gabriel was able to provide a test that always fails on Java 7, not on
>> the
>> other JDKs.
>> It must have to do with optimization when the JVM is warmed up.
>>
>> Anyway, the provided patch takes away the failures and the writing to
>> the
>> stream is now cleaner too.
>> You might want to dive into this, but I wonder if it is worth it.
>> Issue will be resolved with the next release.
>>
>> thanks,
>> Robert
>>
>> On Sat, 08 Dec 2018 12:44:40 +0100, Enrico Olivelli
>> <eo...@gmail.com>
>>
>> wrote:
>>
>> > +1 for Tibor's explanation.
>> > Enrico
>> >
>> > Il sab 8 dic 2018, 12:29 Tibor Digana <ti...@apache.org> ha
>> > scritto:
>> >
>> >> PluginDescriptorGenerator.writeDescriptor does not use Threads so it
>> >> must
>> >> be the problem that the number of calls "endElement" is greater than
>> >> calls
>> >> "startElement".
>> >>
>> >>
>> https://github.com/apache/maven-plugin-tools/blob/master/maven-plugin-tools-generators/src/main/java/org/apache/maven/tools/plugin/generator/PluginDescriptorGenerator.java
>> >>
>> >>
>> >> On Sat, Dec 8, 2018 at 11:46 AM Tibor Digana <ti...@apache.org>
>> >> wrote:
>> >>
>> >> > I do not think it can be such JVM issue with string concatenations,
>> >> > otherwise
>> >> > all the world has the same problem.
>> >> > This type of issue is usually caused by multiple writes from
>> multiple
>> >> > threads.
>> >> > Try to log every method with Thread id and we should see multiple
>> ids.
>> >> > The java.io is supposed to be synchronized and thread safe.
>> Therefore
>> >> > PrintWriter is a wrapper of thread safe implementations.
>> >> > We should use ConcurrentLinkedList and identify large
>> functionality.
>> >> If
>> >> > large methods changes status at multiple lines, then this is a
>> >> critical
>> >> > section and the class must be synchronized.
>> >> >
>> >> > Cheers
>> >> > Tibor
>> >> >
>> >> >
>> >> >
>> >> >
>> >> > --
>> >> > Sent from:
>> >> http://maven.40175.n5.nabble.com/Maven-Developers-f142166.html
>> >> >
>> >> >
>> ---------------------------------------------------------------------
>> >> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> >> > For additional commands, e-mail: dev-help@maven.apache.org
>> >> >
>> >> >
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> For additional commands, e-mail: dev-help@maven.apache.org
>>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Robert Scholte <rf...@apache.org>.
I've found a few NoSuchElementException + LinkedList issues, although not
in combination with removeLast()
But this made it clear for me there have been issues with LinkedList...
Robert
On Sun, 09 Dec 2018 17:35:45 +0100, Tibor Digana <ti...@apache.org>
wrote:
> Is the issue found on Oracle Jira or bug report?
> This might to do with some build version in Java 1.7. Usually they fix it
> right after since this bug hits the JVM stability and Oracle is paying an
> attention to JIT stability.
>
>
>
> On Sun, Dec 9, 2018 at 4:36 PM Robert Scholte <rf...@apache.org>
> wrote:
>
>> I have to admit that it still looks weird, but the open and close tags
>> are
>> balanced.
>> Also notice that only Java 7 (sometimes) hits this issue.
>> Gabriel was able to provide a test that always fails on Java 7, not on
>> the
>> other JDKs.
>> It must have to do with optimization when the JVM is warmed up.
>>
>> Anyway, the provided patch takes away the failures and the writing to
>> the
>> stream is now cleaner too.
>> You might want to dive into this, but I wonder if it is worth it.
>> Issue will be resolved with the next release.
>>
>> thanks,
>> Robert
>>
>> On Sat, 08 Dec 2018 12:44:40 +0100, Enrico Olivelli
>> <eo...@gmail.com>
>>
>> wrote:
>>
>> > +1 for Tibor's explanation.
>> > Enrico
>> >
>> > Il sab 8 dic 2018, 12:29 Tibor Digana <ti...@apache.org> ha
>> > scritto:
>> >
>> >> PluginDescriptorGenerator.writeDescriptor does not use Threads so it
>> >> must
>> >> be the problem that the number of calls "endElement" is greater than
>> >> calls
>> >> "startElement".
>> >>
>> >>
>> https://github.com/apache/maven-plugin-tools/blob/master/maven-plugin-tools-generators/src/main/java/org/apache/maven/tools/plugin/generator/PluginDescriptorGenerator.java
>> >>
>> >>
>> >> On Sat, Dec 8, 2018 at 11:46 AM Tibor Digana <ti...@apache.org>
>> >> wrote:
>> >>
>> >> > I do not think it can be such JVM issue with string concatenations,
>> >> > otherwise
>> >> > all the world has the same problem.
>> >> > This type of issue is usually caused by multiple writes from
>> multiple
>> >> > threads.
>> >> > Try to log every method with Thread id and we should see multiple
>> ids.
>> >> > The java.io is supposed to be synchronized and thread safe.
>> Therefore
>> >> > PrintWriter is a wrapper of thread safe implementations.
>> >> > We should use ConcurrentLinkedList and identify large
>> functionality.
>> >> If
>> >> > large methods changes status at multiple lines, then this is a
>> >> critical
>> >> > section and the class must be synchronized.
>> >> >
>> >> > Cheers
>> >> > Tibor
>> >> >
>> >> >
>> >> >
>> >> >
>> >> > --
>> >> > Sent from:
>> >> http://maven.40175.n5.nabble.com/Maven-Developers-f142166.html
>> >> >
>> >> >
>> ---------------------------------------------------------------------
>> >> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> >> > For additional commands, e-mail: dev-help@maven.apache.org
>> >> >
>> >> >
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> For additional commands, e-mail: dev-help@maven.apache.org
>>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Tibor Digana <ti...@apache.org>.
Is the issue found on Oracle Jira or bug report?
This might to do with some build version in Java 1.7. Usually they fix it
right after since this bug hits the JVM stability and Oracle is paying an
attention to JIT stability.
On Sun, Dec 9, 2018 at 4:36 PM Robert Scholte <rf...@apache.org> wrote:
> I have to admit that it still looks weird, but the open and close tags
> are
> balanced.
> Also notice that only Java 7 (sometimes) hits this issue.
> Gabriel was able to provide a test that always fails on Java 7, not on
> the
> other JDKs.
> It must have to do with optimization when the JVM is warmed up.
>
> Anyway, the provided patch takes away the failures and the writing to the
> stream is now cleaner too.
> You might want to dive into this, but I wonder if it is worth it.
> Issue will be resolved with the next release.
>
> thanks,
> Robert
>
> On Sat, 08 Dec 2018 12:44:40 +0100, Enrico Olivelli <eo...@gmail.com>
>
> wrote:
>
> > +1 for Tibor's explanation.
> > Enrico
> >
> > Il sab 8 dic 2018, 12:29 Tibor Digana <ti...@apache.org> ha
> > scritto:
> >
> >> PluginDescriptorGenerator.writeDescriptor does not use Threads so it
> >> must
> >> be the problem that the number of calls "endElement" is greater than
> >> calls
> >> "startElement".
> >>
> >>
> https://github.com/apache/maven-plugin-tools/blob/master/maven-plugin-tools-generators/src/main/java/org/apache/maven/tools/plugin/generator/PluginDescriptorGenerator.java
> >>
> >>
> >> On Sat, Dec 8, 2018 at 11:46 AM Tibor Digana <ti...@apache.org>
> >> wrote:
> >>
> >> > I do not think it can be such JVM issue with string concatenations,
> >> > otherwise
> >> > all the world has the same problem.
> >> > This type of issue is usually caused by multiple writes from multiple
> >> > threads.
> >> > Try to log every method with Thread id and we should see multiple ids.
> >> > The java.io is supposed to be synchronized and thread safe. Therefore
> >> > PrintWriter is a wrapper of thread safe implementations.
> >> > We should use ConcurrentLinkedList and identify large functionality.
> >> If
> >> > large methods changes status at multiple lines, then this is a
> >> critical
> >> > section and the class must be synchronized.
> >> >
> >> > Cheers
> >> > Tibor
> >> >
> >> >
> >> >
> >> >
> >> > --
> >> > Sent from:
> >> http://maven.40175.n5.nabble.com/Maven-Developers-f142166.html
> >> >
> >> > ---------------------------------------------------------------------
> >> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> >> > For additional commands, e-mail: dev-help@maven.apache.org
> >> >
> >> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Robert Scholte <rf...@apache.org>.
I have to admit that it still looks weird, but the open and close tags are
balanced.
Also notice that only Java 7 (sometimes) hits this issue.
Gabriel was able to provide a test that always fails on Java 7, not on the
other JDKs.
It must have to do with optimization when the JVM is warmed up.
Anyway, the provided patch takes away the failures and the writing to the
stream is now cleaner too.
You might want to dive into this, but I wonder if it is worth it.
Issue will be resolved with the next release.
thanks,
Robert
On Sat, 08 Dec 2018 12:44:40 +0100, Enrico Olivelli <eo...@gmail.com>
wrote:
> +1 for Tibor's explanation.
> Enrico
>
> Il sab 8 dic 2018, 12:29 Tibor Digana <ti...@apache.org> ha
> scritto:
>
>> PluginDescriptorGenerator.writeDescriptor does not use Threads so it
>> must
>> be the problem that the number of calls "endElement" is greater than
>> calls
>> "startElement".
>>
>> https://github.com/apache/maven-plugin-tools/blob/master/maven-plugin-tools-generators/src/main/java/org/apache/maven/tools/plugin/generator/PluginDescriptorGenerator.java
>>
>>
>> On Sat, Dec 8, 2018 at 11:46 AM Tibor Digana <ti...@apache.org>
>> wrote:
>>
>> > I do not think it can be such JVM issue with string concatenations,
>> > otherwise
>> > all the world has the same problem.
>> > This type of issue is usually caused by multiple writes from multiple
>> > threads.
>> > Try to log every method with Thread id and we should see multiple ids.
>> > The java.io is supposed to be synchronized and thread safe. Therefore
>> > PrintWriter is a wrapper of thread safe implementations.
>> > We should use ConcurrentLinkedList and identify large functionality.
>> If
>> > large methods changes status at multiple lines, then this is a
>> critical
>> > section and the class must be synchronized.
>> >
>> > Cheers
>> > Tibor
>> >
>> >
>> >
>> >
>> > --
>> > Sent from:
>> http://maven.40175.n5.nabble.com/Maven-Developers-f142166.html
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> > For additional commands, e-mail: dev-help@maven.apache.org
>> >
>> >
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Enrico Olivelli <eo...@gmail.com>.
+1 for Tibor's explanation.
Enrico
Il sab 8 dic 2018, 12:29 Tibor Digana <ti...@apache.org> ha scritto:
> PluginDescriptorGenerator.writeDescriptor does not use Threads so it must
> be the problem that the number of calls "endElement" is greater than calls
> "startElement".
>
> https://github.com/apache/maven-plugin-tools/blob/master/maven-plugin-tools-generators/src/main/java/org/apache/maven/tools/plugin/generator/PluginDescriptorGenerator.java
>
>
> On Sat, Dec 8, 2018 at 11:46 AM Tibor Digana <ti...@apache.org>
> wrote:
>
> > I do not think it can be such JVM issue with string concatenations,
> > otherwise
> > all the world has the same problem.
> > This type of issue is usually caused by multiple writes from multiple
> > threads.
> > Try to log every method with Thread id and we should see multiple ids.
> > The java.io is supposed to be synchronized and thread safe. Therefore
> > PrintWriter is a wrapper of thread safe implementations.
> > We should use ConcurrentLinkedList and identify large functionality. If
> > large methods changes status at multiple lines, then this is a critical
> > section and the class must be synchronized.
> >
> > Cheers
> > Tibor
> >
> >
> >
> >
> > --
> > Sent from:
> http://maven.40175.n5.nabble.com/Maven-Developers-f142166.html
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
> >
> >
>
--
-- Enrico Olivelli
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Tibor Digana <ti...@apache.org>.
PluginDescriptorGenerator.writeDescriptor does not use Threads so it must
be the problem that the number of calls "endElement" is greater than calls
"startElement".
https://github.com/apache/maven-plugin-tools/blob/master/maven-plugin-tools-generators/src/main/java/org/apache/maven/tools/plugin/generator/PluginDescriptorGenerator.java
On Sat, Dec 8, 2018 at 11:46 AM Tibor Digana <ti...@apache.org> wrote:
> I do not think it can be such JVM issue with string concatenations,
> otherwise
> all the world has the same problem.
> This type of issue is usually caused by multiple writes from multiple
> threads.
> Try to log every method with Thread id and we should see multiple ids.
> The java.io is supposed to be synchronized and thread safe. Therefore
> PrintWriter is a wrapper of thread safe implementations.
> We should use ConcurrentLinkedList and identify large functionality. If
> large methods changes status at multiple lines, then this is a critical
> section and the class must be synchronized.
>
> Cheers
> Tibor
>
>
>
>
> --
> Sent from: http://maven.40175.n5.nabble.com/Maven-Developers-f142166.html
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Tibor Digana <ti...@apache.org>.
I do not think it can be such JVM issue with string concatenations, otherwise
all the world has the same problem.
This type of issue is usually caused by multiple writes from multiple
threads.
Try to log every method with Thread id and we should see multiple ids.
The java.io is supposed to be synchronized and thread safe. Therefore
PrintWriter is a wrapper of thread safe implementations.
We should use ConcurrentLinkedList and identify large functionality. If
large methods changes status at multiple lines, then this is a critical
section and the class must be synchronized.
Cheers
Tibor
--
Sent from: http://maven.40175.n5.nabble.com/Maven-Developers-f142166.html
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Gabriel Belingueres <be...@gmail.com>.
I'll go for a minimal patch commenting with the rationale, and then build
upon that.
I also tested it will work if execute maven disabling string concatenation
optimization:
MAVEN_OPTS=-XX:-OptimizeStringConcat
which could used as a workaround for the short term.
El vie., 30 de nov. de 2018 a la(s) 06:18, Robert Scholte (
rfscholte@apache.org) escribió:
> Interesting if that works, but if the concatenation is the issue, we
> could
> also try:
>
> write( "</" );
> write( elementStack.removeLast() );
> write( ">" );
>
> If this doesn't work but your proposed code does, it must have a good
> comment that this is a Java 7 workaround and can only be optimized once
> we
> require Java 8.
>
> I have also another idea: replace LinkedList with ArrayDeque, since it is
> really a LinkedList implementation issue. Also, according to the docs:
> "this class is likely to be faster than Stack when used as a stack, and
> faster than LinkedList when used as a queue."
>
> thanks,
> Robert
>
> On Fri, 30 Nov 2018 07:38:38 +0100, Hervé BOUTEMY <he...@free.fr>
>
> wrote:
>
> > wow, nice idea
> > I noticed the issue for a long time, but never figured out the link
> with
> > Java
> > 7 nor this idea of fix that is so "magic"...
> >
> > thank you for the help
> >
> > Regards,
> >
> > Hervé
> >
> > Le vendredi 30 novembre 2018, 05:11:56 CET Gabriel Belingueres a écrit :
> >> Indeed, that seems to be the case. It magically worked after replacing
> >> the
> >> following line:
> >>
> http://codehaus-plexus.github.io/plexus-utils/xref/org/codehaus/plexus/util/
> >> xml/PrettyPrintXMLWriter.html#L307
> >>
> >> with this:
> >> String element = elementStack.removeLast();
> >> write( "</" + element + ">" );
> >>
> >> I will soon create the issue and PR.
> >>
> >> Gabriel
> >>
> >> El jue., 29 de nov. de 2018 a la(s) 15:25, Robert Scholte (
> >>
> >> rfscholte@apache.org) escribió:
> >> > At builds.apache.org:
> >> > Java version: 1.7.0_79, vendor: Oracle Corporation
> >> >
> >> > Local
> >> > Java version: 1.7.0_80, vendor: Oracle Corporation
> >> >
> >> > does seem to be Java7 only...
> >> > I need to check this for a longer period, but might be a good
> >> conclusion.
> >> >
> >> > thanks,
> >> > Robert
> >> >
> >> >
> >> > On Thu, 29 Nov 2018 04:54:59 +0100, Gabriel Belingueres
> >> >
> >> > <be...@gmail.com> wrote:
> >> > > Hi Robert:
> >> > >
> >> > > I'm testing it and getting *consistently* the same exception with
> >> this
> >> > > config:
> >> > >
> >> > > Apache Maven 3.6.0 (97c98ec64a1fdfee7767ce5ffb20918da4f719f3;
> >> > > 2018-10-24T15:41:47-03:00)
> >> > > Maven home: C:\productos\apache-maven-3.6.0\bin\..
> >> > > Java version: 1.7.0_80, vendor: Oracle Corporation, runtime:
> >> C:\Program
> >> > > Files\Java\jdk1.7.0_80\jre
> >> > > Default locale: es_AR, platform encoding: Cp1252
> >> > > OS name: "windows 8.1", version: "6.3", arch: "amd64", family:
> >> "windows"
> >> > >
> >> > > (actually it is a win 10 but it fails to recognze it).
> >> > >
> >> > > It works OK when remote debugging with mvnDebug.
> >> > >
> >> > > Don't know why throws a NoSuchElementException when trying to
> >> remove an
> >> > > element on a non empty LinkedList...my best guess is that it is some
> >> > > sort
> >> > > of bug in the hotspot optimization of the JVM.
> >> > >
> >> > > Which Java 7 specific update is running on Jenkins?
> >> > >
> >> > > Gabriel
> >> > >
> >> > > El mar., 27 de nov. de 2018 a la(s) 17:52, Robert Scholte (
> >> > >
> >> > > rfscholte@apache.org) escribió:
> >> > >> Hi,
> >> > >>
> >> > >> sometimes the maven-plugin-plugin fails to write the plugin
> >> descriptor
> >> > >> and
> >> > >> exits with the exception below.
> >> > >> I see the same unreliable behavior on our Jenkins servers too,
> >> > >> re-running
> >> > >> often fixes the issue.
> >> > >> I have seen the issue several times locally when running with
> >> mvn.cmd,
> >> > >> so
> >> > >> far never with mvnDebug.cmd and always running with default
> >> #threads.
> >> > >> I can't find a reason why elementStack[1] gets out of sync.
> >> > >>
> >> > >> If there are others experiencing the same or similar issues, please
> >> > >> share
> >> > >> your analysis.
> >> > >> Hopefully we can solve this instability issue soon.
> >> > >>
> >> > >> thanks,
> >> > >> Robert
> >> > >>
> >> > >> [1]
> >> >
> >> >
> >>
> http://codehaus-plexus.github.io/plexus-utils/xref/org/codehaus/plexus/uti
> >> > l/xml/PrettyPrintXMLWriter.html#L40>
> >> > >> [ERROR] Failed to execute goal
> >> > >> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
> >> > >> (default-descriptor) on project maven-javadoc-plugin: Execution
> >> > >> default-descriptor of goal
> >> > >> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
> >> failed.
> >> > >> NoSuchElementException -> [Help 1]
> >> > >> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to
> >> > >> execute
> >> > >> goal org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
> >> > >> (default-descriptor) on project maven-javadoc-plugin: Execution
> >> > >> default-descriptor of goal
> >> > >> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
> >> failed
> >> > >>
> >> > >>
> >> > >>
> >> > >> Caused by: java.util.NoSuchElementException
> >> > >>
> >> > >> at java.util.LinkedList.removeLast (LinkedList.java:281)
> >> > >> at
> >> org.codehaus.plexus.util.xml.PrettyPrintXMLWriter.endElement
> >> > >>
> >> > >> (PrettyPrintXMLWriter.java:297)
> >> > >>
> >> > >> at
> >> >
> >> >
> >>
> org.apache.maven.tools.plugin.generator.PluginDescriptorGenerator.writeDes
> >> > criptor>
> >> > >> (PluginDescriptorGenerator.java:175)
> >> > >>
> >> > >>
> >> ---------------------------------------------------------------------
> >> > >> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> >> > >> For additional commands, e-mail: dev-help@maven.apache.org
> >> >
> >> > ---------------------------------------------------------------------
> >> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> >> > For additional commands, e-mail: dev-help@maven.apache.org
> >
> >
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Robert Scholte <rf...@apache.org>.
Interesting if that works, but if the concatenation is the issue, we could
also try:
write( "</" );
write( elementStack.removeLast() );
write( ">" );
If this doesn't work but your proposed code does, it must have a good
comment that this is a Java 7 workaround and can only be optimized once we
require Java 8.
I have also another idea: replace LinkedList with ArrayDeque, since it is
really a LinkedList implementation issue. Also, according to the docs:
"this class is likely to be faster than Stack when used as a stack, and
faster than LinkedList when used as a queue."
thanks,
Robert
On Fri, 30 Nov 2018 07:38:38 +0100, Hervé BOUTEMY <he...@free.fr>
wrote:
> wow, nice idea
> I noticed the issue for a long time, but never figured out the link with
> Java
> 7 nor this idea of fix that is so "magic"...
>
> thank you for the help
>
> Regards,
>
> Hervé
>
> Le vendredi 30 novembre 2018, 05:11:56 CET Gabriel Belingueres a écrit :
>> Indeed, that seems to be the case. It magically worked after replacing
>> the
>> following line:
>> http://codehaus-plexus.github.io/plexus-utils/xref/org/codehaus/plexus/util/
>> xml/PrettyPrintXMLWriter.html#L307
>>
>> with this:
>> String element = elementStack.removeLast();
>> write( "</" + element + ">" );
>>
>> I will soon create the issue and PR.
>>
>> Gabriel
>>
>> El jue., 29 de nov. de 2018 a la(s) 15:25, Robert Scholte (
>>
>> rfscholte@apache.org) escribió:
>> > At builds.apache.org:
>> > Java version: 1.7.0_79, vendor: Oracle Corporation
>> >
>> > Local
>> > Java version: 1.7.0_80, vendor: Oracle Corporation
>> >
>> > does seem to be Java7 only...
>> > I need to check this for a longer period, but might be a good
>> conclusion.
>> >
>> > thanks,
>> > Robert
>> >
>> >
>> > On Thu, 29 Nov 2018 04:54:59 +0100, Gabriel Belingueres
>> >
>> > <be...@gmail.com> wrote:
>> > > Hi Robert:
>> > >
>> > > I'm testing it and getting *consistently* the same exception with
>> this
>> > > config:
>> > >
>> > > Apache Maven 3.6.0 (97c98ec64a1fdfee7767ce5ffb20918da4f719f3;
>> > > 2018-10-24T15:41:47-03:00)
>> > > Maven home: C:\productos\apache-maven-3.6.0\bin\..
>> > > Java version: 1.7.0_80, vendor: Oracle Corporation, runtime:
>> C:\Program
>> > > Files\Java\jdk1.7.0_80\jre
>> > > Default locale: es_AR, platform encoding: Cp1252
>> > > OS name: "windows 8.1", version: "6.3", arch: "amd64", family:
>> "windows"
>> > >
>> > > (actually it is a win 10 but it fails to recognze it).
>> > >
>> > > It works OK when remote debugging with mvnDebug.
>> > >
>> > > Don't know why throws a NoSuchElementException when trying to
>> remove an
>> > > element on a non empty LinkedList...my best guess is that it is some
>> > > sort
>> > > of bug in the hotspot optimization of the JVM.
>> > >
>> > > Which Java 7 specific update is running on Jenkins?
>> > >
>> > > Gabriel
>> > >
>> > > El mar., 27 de nov. de 2018 a la(s) 17:52, Robert Scholte (
>> > >
>> > > rfscholte@apache.org) escribió:
>> > >> Hi,
>> > >>
>> > >> sometimes the maven-plugin-plugin fails to write the plugin
>> descriptor
>> > >> and
>> > >> exits with the exception below.
>> > >> I see the same unreliable behavior on our Jenkins servers too,
>> > >> re-running
>> > >> often fixes the issue.
>> > >> I have seen the issue several times locally when running with
>> mvn.cmd,
>> > >> so
>> > >> far never with mvnDebug.cmd and always running with default
>> #threads.
>> > >> I can't find a reason why elementStack[1] gets out of sync.
>> > >>
>> > >> If there are others experiencing the same or similar issues, please
>> > >> share
>> > >> your analysis.
>> > >> Hopefully we can solve this instability issue soon.
>> > >>
>> > >> thanks,
>> > >> Robert
>> > >>
>> > >> [1]
>> >
>> >
>> http://codehaus-plexus.github.io/plexus-utils/xref/org/codehaus/plexus/uti
>> > l/xml/PrettyPrintXMLWriter.html#L40>
>> > >> [ERROR] Failed to execute goal
>> > >> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
>> > >> (default-descriptor) on project maven-javadoc-plugin: Execution
>> > >> default-descriptor of goal
>> > >> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
>> failed.
>> > >> NoSuchElementException -> [Help 1]
>> > >> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to
>> > >> execute
>> > >> goal org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
>> > >> (default-descriptor) on project maven-javadoc-plugin: Execution
>> > >> default-descriptor of goal
>> > >> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
>> failed
>> > >>
>> > >>
>> > >>
>> > >> Caused by: java.util.NoSuchElementException
>> > >>
>> > >> at java.util.LinkedList.removeLast (LinkedList.java:281)
>> > >> at
>> org.codehaus.plexus.util.xml.PrettyPrintXMLWriter.endElement
>> > >>
>> > >> (PrettyPrintXMLWriter.java:297)
>> > >>
>> > >> at
>> >
>> >
>> org.apache.maven.tools.plugin.generator.PluginDescriptorGenerator.writeDes
>> > criptor>
>> > >> (PluginDescriptorGenerator.java:175)
>> > >>
>> > >>
>> ---------------------------------------------------------------------
>> > >> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> > >> For additional commands, e-mail: dev-help@maven.apache.org
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> > For additional commands, e-mail: dev-help@maven.apache.org
>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Hervé BOUTEMY <he...@free.fr>.
wow, nice idea
I noticed the issue for a long time, but never figured out the link with Java
7 nor this idea of fix that is so "magic"...
thank you for the help
Regards,
Hervé
Le vendredi 30 novembre 2018, 05:11:56 CET Gabriel Belingueres a écrit :
> Indeed, that seems to be the case. It magically worked after replacing the
> following line:
> http://codehaus-plexus.github.io/plexus-utils/xref/org/codehaus/plexus/util/
> xml/PrettyPrintXMLWriter.html#L307
>
> with this:
> String element = elementStack.removeLast();
> write( "</" + element + ">" );
>
> I will soon create the issue and PR.
>
> Gabriel
>
> El jue., 29 de nov. de 2018 a la(s) 15:25, Robert Scholte (
>
> rfscholte@apache.org) escribió:
> > At builds.apache.org:
> > Java version: 1.7.0_79, vendor: Oracle Corporation
> >
> > Local
> > Java version: 1.7.0_80, vendor: Oracle Corporation
> >
> > does seem to be Java7 only...
> > I need to check this for a longer period, but might be a good conclusion.
> >
> > thanks,
> > Robert
> >
> >
> > On Thu, 29 Nov 2018 04:54:59 +0100, Gabriel Belingueres
> >
> > <be...@gmail.com> wrote:
> > > Hi Robert:
> > >
> > > I'm testing it and getting *consistently* the same exception with this
> > > config:
> > >
> > > Apache Maven 3.6.0 (97c98ec64a1fdfee7767ce5ffb20918da4f719f3;
> > > 2018-10-24T15:41:47-03:00)
> > > Maven home: C:\productos\apache-maven-3.6.0\bin\..
> > > Java version: 1.7.0_80, vendor: Oracle Corporation, runtime: C:\Program
> > > Files\Java\jdk1.7.0_80\jre
> > > Default locale: es_AR, platform encoding: Cp1252
> > > OS name: "windows 8.1", version: "6.3", arch: "amd64", family: "windows"
> > >
> > > (actually it is a win 10 but it fails to recognze it).
> > >
> > > It works OK when remote debugging with mvnDebug.
> > >
> > > Don't know why throws a NoSuchElementException when trying to remove an
> > > element on a non empty LinkedList...my best guess is that it is some
> > > sort
> > > of bug in the hotspot optimization of the JVM.
> > >
> > > Which Java 7 specific update is running on Jenkins?
> > >
> > > Gabriel
> > >
> > > El mar., 27 de nov. de 2018 a la(s) 17:52, Robert Scholte (
> > >
> > > rfscholte@apache.org) escribió:
> > >> Hi,
> > >>
> > >> sometimes the maven-plugin-plugin fails to write the plugin descriptor
> > >> and
> > >> exits with the exception below.
> > >> I see the same unreliable behavior on our Jenkins servers too,
> > >> re-running
> > >> often fixes the issue.
> > >> I have seen the issue several times locally when running with mvn.cmd,
> > >> so
> > >> far never with mvnDebug.cmd and always running with default #threads.
> > >> I can't find a reason why elementStack[1] gets out of sync.
> > >>
> > >> If there are others experiencing the same or similar issues, please
> > >> share
> > >> your analysis.
> > >> Hopefully we can solve this instability issue soon.
> > >>
> > >> thanks,
> > >> Robert
> > >>
> > >> [1]
> >
> > http://codehaus-plexus.github.io/plexus-utils/xref/org/codehaus/plexus/uti
> > l/xml/PrettyPrintXMLWriter.html#L40>
> > >> [ERROR] Failed to execute goal
> > >> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
> > >> (default-descriptor) on project maven-javadoc-plugin: Execution
> > >> default-descriptor of goal
> > >> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor failed.
> > >> NoSuchElementException -> [Help 1]
> > >> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to
> > >> execute
> > >> goal org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
> > >> (default-descriptor) on project maven-javadoc-plugin: Execution
> > >> default-descriptor of goal
> > >> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor failed
> > >>
> > >>
> > >>
> > >> Caused by: java.util.NoSuchElementException
> > >>
> > >> at java.util.LinkedList.removeLast (LinkedList.java:281)
> > >> at org.codehaus.plexus.util.xml.PrettyPrintXMLWriter.endElement
> > >>
> > >> (PrettyPrintXMLWriter.java:297)
> > >>
> > >> at
> >
> > org.apache.maven.tools.plugin.generator.PluginDescriptorGenerator.writeDes
> > criptor>
> > >> (PluginDescriptorGenerator.java:175)
> > >>
> > >> ---------------------------------------------------------------------
> > >> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > >> For additional commands, e-mail: dev-help@maven.apache.org
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Gabriel Belingueres <be...@gmail.com>.
Indeed, that seems to be the case. It magically worked after replacing the
following line:
http://codehaus-plexus.github.io/plexus-utils/xref/org/codehaus/plexus/util/xml/PrettyPrintXMLWriter.html#L307
with this:
String element = elementStack.removeLast();
write( "</" + element + ">" );
I will soon create the issue and PR.
Gabriel
El jue., 29 de nov. de 2018 a la(s) 15:25, Robert Scholte (
rfscholte@apache.org) escribió:
> At builds.apache.org:
> Java version: 1.7.0_79, vendor: Oracle Corporation
>
> Local
> Java version: 1.7.0_80, vendor: Oracle Corporation
>
> does seem to be Java7 only...
> I need to check this for a longer period, but might be a good conclusion.
>
> thanks,
> Robert
>
>
> On Thu, 29 Nov 2018 04:54:59 +0100, Gabriel Belingueres
> <be...@gmail.com> wrote:
>
> > Hi Robert:
> >
> > I'm testing it and getting *consistently* the same exception with this
> > config:
> >
> > Apache Maven 3.6.0 (97c98ec64a1fdfee7767ce5ffb20918da4f719f3;
> > 2018-10-24T15:41:47-03:00)
> > Maven home: C:\productos\apache-maven-3.6.0\bin\..
> > Java version: 1.7.0_80, vendor: Oracle Corporation, runtime: C:\Program
> > Files\Java\jdk1.7.0_80\jre
> > Default locale: es_AR, platform encoding: Cp1252
> > OS name: "windows 8.1", version: "6.3", arch: "amd64", family: "windows"
> >
> > (actually it is a win 10 but it fails to recognze it).
> >
> > It works OK when remote debugging with mvnDebug.
> >
> > Don't know why throws a NoSuchElementException when trying to remove an
> > element on a non empty LinkedList...my best guess is that it is some sort
> > of bug in the hotspot optimization of the JVM.
> >
> > Which Java 7 specific update is running on Jenkins?
> >
> > Gabriel
> >
> > El mar., 27 de nov. de 2018 a la(s) 17:52, Robert Scholte (
> > rfscholte@apache.org) escribió:
> >
> >> Hi,
> >>
> >> sometimes the maven-plugin-plugin fails to write the plugin descriptor
> >> and
> >> exits with the exception below.
> >> I see the same unreliable behavior on our Jenkins servers too,
> >> re-running
> >> often fixes the issue.
> >> I have seen the issue several times locally when running with mvn.cmd,
> >> so
> >> far never with mvnDebug.cmd and always running with default #threads.
> >> I can't find a reason why elementStack[1] gets out of sync.
> >>
> >> If there are others experiencing the same or similar issues, please
> >> share
> >> your analysis.
> >> Hopefully we can solve this instability issue soon.
> >>
> >> thanks,
> >> Robert
> >>
> >> [1]
> >>
> >>
> http://codehaus-plexus.github.io/plexus-utils/xref/org/codehaus/plexus/util/xml/PrettyPrintXMLWriter.html#L40
> >>
> >>
> >>
> >> [ERROR] Failed to execute goal
> >> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
> >> (default-descriptor) on project maven-javadoc-plugin: Execution
> >> default-descriptor of goal
> >> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor failed.
> >> NoSuchElementException -> [Help 1]
> >> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to
> >> execute
> >> goal org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
> >> (default-descriptor) on project maven-javadoc-plugin: Execution
> >> default-descriptor of goal
> >> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor failed
> >>
> >>
> >>
> >> Caused by: java.util.NoSuchElementException
> >> at java.util.LinkedList.removeLast (LinkedList.java:281)
> >> at org.codehaus.plexus.util.xml.PrettyPrintXMLWriter.endElement
> >> (PrettyPrintXMLWriter.java:297)
> >> at
> >>
> org.apache.maven.tools.plugin.generator.PluginDescriptorGenerator.writeDescriptor
> >>
> >> (PluginDescriptorGenerator.java:175)
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> >> For additional commands, e-mail: dev-help@maven.apache.org
> >>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Robert Scholte <rf...@apache.org>.
At builds.apache.org:
Java version: 1.7.0_79, vendor: Oracle Corporation
Local
Java version: 1.7.0_80, vendor: Oracle Corporation
does seem to be Java7 only...
I need to check this for a longer period, but might be a good conclusion.
thanks,
Robert
On Thu, 29 Nov 2018 04:54:59 +0100, Gabriel Belingueres
<be...@gmail.com> wrote:
> Hi Robert:
>
> I'm testing it and getting *consistently* the same exception with this
> config:
>
> Apache Maven 3.6.0 (97c98ec64a1fdfee7767ce5ffb20918da4f719f3;
> 2018-10-24T15:41:47-03:00)
> Maven home: C:\productos\apache-maven-3.6.0\bin\..
> Java version: 1.7.0_80, vendor: Oracle Corporation, runtime: C:\Program
> Files\Java\jdk1.7.0_80\jre
> Default locale: es_AR, platform encoding: Cp1252
> OS name: "windows 8.1", version: "6.3", arch: "amd64", family: "windows"
>
> (actually it is a win 10 but it fails to recognze it).
>
> It works OK when remote debugging with mvnDebug.
>
> Don't know why throws a NoSuchElementException when trying to remove an
> element on a non empty LinkedList...my best guess is that it is some sort
> of bug in the hotspot optimization of the JVM.
>
> Which Java 7 specific update is running on Jenkins?
>
> Gabriel
>
> El mar., 27 de nov. de 2018 a la(s) 17:52, Robert Scholte (
> rfscholte@apache.org) escribió:
>
>> Hi,
>>
>> sometimes the maven-plugin-plugin fails to write the plugin descriptor
>> and
>> exits with the exception below.
>> I see the same unreliable behavior on our Jenkins servers too,
>> re-running
>> often fixes the issue.
>> I have seen the issue several times locally when running with mvn.cmd,
>> so
>> far never with mvnDebug.cmd and always running with default #threads.
>> I can't find a reason why elementStack[1] gets out of sync.
>>
>> If there are others experiencing the same or similar issues, please
>> share
>> your analysis.
>> Hopefully we can solve this instability issue soon.
>>
>> thanks,
>> Robert
>>
>> [1]
>>
>> http://codehaus-plexus.github.io/plexus-utils/xref/org/codehaus/plexus/util/xml/PrettyPrintXMLWriter.html#L40
>>
>>
>>
>> [ERROR] Failed to execute goal
>> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
>> (default-descriptor) on project maven-javadoc-plugin: Execution
>> default-descriptor of goal
>> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor failed.
>> NoSuchElementException -> [Help 1]
>> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to
>> execute
>> goal org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
>> (default-descriptor) on project maven-javadoc-plugin: Execution
>> default-descriptor of goal
>> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor failed
>>
>>
>>
>> Caused by: java.util.NoSuchElementException
>> at java.util.LinkedList.removeLast (LinkedList.java:281)
>> at org.codehaus.plexus.util.xml.PrettyPrintXMLWriter.endElement
>> (PrettyPrintXMLWriter.java:297)
>> at
>> org.apache.maven.tools.plugin.generator.PluginDescriptorGenerator.writeDescriptor
>>
>> (PluginDescriptorGenerator.java:175)
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> For additional commands, e-mail: dev-help@maven.apache.org
>>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org
Re: plugin:descriptor fails with java.util.NoSuchElementException
Posted by Gabriel Belingueres <be...@gmail.com>.
Hi Robert:
I'm testing it and getting *consistently* the same exception with this
config:
Apache Maven 3.6.0 (97c98ec64a1fdfee7767ce5ffb20918da4f719f3;
2018-10-24T15:41:47-03:00)
Maven home: C:\productos\apache-maven-3.6.0\bin\..
Java version: 1.7.0_80, vendor: Oracle Corporation, runtime: C:\Program
Files\Java\jdk1.7.0_80\jre
Default locale: es_AR, platform encoding: Cp1252
OS name: "windows 8.1", version: "6.3", arch: "amd64", family: "windows"
(actually it is a win 10 but it fails to recognze it).
It works OK when remote debugging with mvnDebug.
Don't know why throws a NoSuchElementException when trying to remove an
element on a non empty LinkedList...my best guess is that it is some sort
of bug in the hotspot optimization of the JVM.
Which Java 7 specific update is running on Jenkins?
Gabriel
El mar., 27 de nov. de 2018 a la(s) 17:52, Robert Scholte (
rfscholte@apache.org) escribió:
> Hi,
>
> sometimes the maven-plugin-plugin fails to write the plugin descriptor
> and
> exits with the exception below.
> I see the same unreliable behavior on our Jenkins servers too, re-running
> often fixes the issue.
> I have seen the issue several times locally when running with mvn.cmd, so
> far never with mvnDebug.cmd and always running with default #threads.
> I can't find a reason why elementStack[1] gets out of sync.
>
> If there are others experiencing the same or similar issues, please share
> your analysis.
> Hopefully we can solve this instability issue soon.
>
> thanks,
> Robert
>
> [1]
>
> http://codehaus-plexus.github.io/plexus-utils/xref/org/codehaus/plexus/util/xml/PrettyPrintXMLWriter.html#L40
>
>
>
> [ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
> (default-descriptor) on project maven-javadoc-plugin: Execution
> default-descriptor of goal
> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor failed.
> NoSuchElementException -> [Help 1]
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute
> goal org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor
> (default-descriptor) on project maven-javadoc-plugin: Execution
> default-descriptor of goal
> org.apache.maven.plugins:maven-plugin-plugin:3.5.2:descriptor failed
>
>
>
> Caused by: java.util.NoSuchElementException
> at java.util.LinkedList.removeLast (LinkedList.java:281)
> at org.codehaus.plexus.util.xml.PrettyPrintXMLWriter.endElement
> (PrettyPrintXMLWriter.java:297)
> at
> org.apache.maven.tools.plugin.generator.PluginDescriptorGenerator.writeDescriptor
>
> (PluginDescriptorGenerator.java:175)
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>