You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Wojciech Durczynski (JIRA)" <ji...@apache.org> on 2008/07/14 12:21:06 UTC
[jira] Created: (CAMEL-715) ConcurrentModificationException in
ThreadProcessor
ConcurrentModificationException in ThreadProcessor
--------------------------------------------------
Key: CAMEL-715
URL: https://issues.apache.org/activemq/browse/CAMEL-715
Project: Apache Camel
Issue Type: Bug
Components: camel-core
Reporter: Wojciech Durczynski
Priority: Critical
Fix For: 1.4.0
When defining very simple routing with ThreadProcessor I get ConcurrentModificationException on multicore systems.
Example:
from("direct:a").thread(10).process(new Processor() {
@Override
public void process(Exchange ex) throws Exception {
//sth
}
});
Stack trace:
Exception in thread "Thread Processor"
java.util.ConcurrentModificationException
at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
at java.util.HashMap$EntryIterator.next(HashMap.java:834)
at java.util.HashMap$EntryIterator.next(HashMap.java:832)
at java.util.HashMap.putAll(HashMap.java:523)
at
org.apache.camel.processor.Pipeline.createNextExchange(Pipeline.java:146
)
at org.apache.camel.processor.Pipeline$1.done(Pipeline.java:123)
at
org.apache.camel.processor.ThreadProcessor$ProcessCall.run(ThreadProcess
or.j
ava:66)
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecuto
r.ja
va:885)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.ja
va:9
07)
at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (CAMEL-715) ConcurrentModificationException in
ThreadProcessor
Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-715?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=44266#action_44266 ]
Claus Ibsen commented on CAMEL-715:
-----------------------------------
And please provide us with information about OS: Camel Version, Java Version etc.
> ConcurrentModificationException in ThreadProcessor
> --------------------------------------------------
>
> Key: CAMEL-715
> URL: https://issues.apache.org/activemq/browse/CAMEL-715
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-core
> Reporter: Wojciech Durczynski
> Priority: Critical
> Fix For: 1.4.0
>
>
> When defining very simple routing with ThreadProcessor I get ConcurrentModificationException on multicore systems.
> Example:
> from("direct:a").thread(10).process(new Processor() {
> @Override
> public void process(Exchange ex) throws Exception {
> //sth
> }
> });
> Stack trace:
> Exception in thread "Thread Processor"
> java.util.ConcurrentModificationException
> at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
> at java.util.HashMap$EntryIterator.next(HashMap.java:834)
> at java.util.HashMap$EntryIterator.next(HashMap.java:832)
> at java.util.HashMap.putAll(HashMap.java:523)
> at
> org.apache.camel.processor.Pipeline.createNextExchange(Pipeline.java:146
> )
> at org.apache.camel.processor.Pipeline$1.done(Pipeline.java:123)
> at
> org.apache.camel.processor.ThreadProcessor$ProcessCall.run(ThreadProcess
> or.j
> ava:66)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecuto
> r.ja
> va:885)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.ja
> va:9
> 07)
> at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (CAMEL-715) ConcurrentModificationException in
ThreadProcessor
Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-715?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=44265#action_44265 ]
Claus Ibsen commented on CAMEL-715:
-----------------------------------
Hi
Could you attach your sample that doesn't work on your system.
I have tried to create an unit test that demonstrates the bug but I runs fine here.
> ConcurrentModificationException in ThreadProcessor
> --------------------------------------------------
>
> Key: CAMEL-715
> URL: https://issues.apache.org/activemq/browse/CAMEL-715
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-core
> Reporter: Wojciech Durczynski
> Priority: Critical
> Fix For: 1.4.0
>
>
> When defining very simple routing with ThreadProcessor I get ConcurrentModificationException on multicore systems.
> Example:
> from("direct:a").thread(10).process(new Processor() {
> @Override
> public void process(Exchange ex) throws Exception {
> //sth
> }
> });
> Stack trace:
> Exception in thread "Thread Processor"
> java.util.ConcurrentModificationException
> at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
> at java.util.HashMap$EntryIterator.next(HashMap.java:834)
> at java.util.HashMap$EntryIterator.next(HashMap.java:832)
> at java.util.HashMap.putAll(HashMap.java:523)
> at
> org.apache.camel.processor.Pipeline.createNextExchange(Pipeline.java:146
> )
> at org.apache.camel.processor.Pipeline$1.done(Pipeline.java:123)
> at
> org.apache.camel.processor.ThreadProcessor$ProcessCall.run(ThreadProcess
> or.j
> ava:66)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecuto
> r.ja
> va:885)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.ja
> va:9
> 07)
> at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (CAMEL-715) ConcurrentModificationException in
ThreadProcessor
Posted by "Wojciech Durczynski (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-715?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=44271#action_44271 ]
Wojciech Durczynski commented on CAMEL-715:
-------------------------------------------
Attached test case causes ConcurrentModificationException.
It happens on multicore machines only (always on quad core processor, never on single core)
Testing environment:
jdk 1.6.0_06
camel 1.4-SNAPSHOT
windows xp
eclipse 3.4
> ConcurrentModificationException in ThreadProcessor
> --------------------------------------------------
>
> Key: CAMEL-715
> URL: https://issues.apache.org/activemq/browse/CAMEL-715
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-core
> Reporter: Wojciech Durczynski
> Priority: Critical
> Fix For: 1.4.0
>
> Attachments: JUnitTestCase.java
>
>
> When defining very simple routing with ThreadProcessor I get ConcurrentModificationException on multicore systems.
> Example:
> from("direct:a").thread(10).process(new Processor() {
> @Override
> public void process(Exchange ex) throws Exception {
> //sth
> }
> });
> Stack trace:
> Exception in thread "Thread Processor"
> java.util.ConcurrentModificationException
> at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
> at java.util.HashMap$EntryIterator.next(HashMap.java:834)
> at java.util.HashMap$EntryIterator.next(HashMap.java:832)
> at java.util.HashMap.putAll(HashMap.java:523)
> at
> org.apache.camel.processor.Pipeline.createNextExchange(Pipeline.java:146
> )
> at org.apache.camel.processor.Pipeline$1.done(Pipeline.java:123)
> at
> org.apache.camel.processor.ThreadProcessor$ProcessCall.run(ThreadProcess
> or.j
> ava:66)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecuto
> r.ja
> va:885)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.ja
> va:9
> 07)
> at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (CAMEL-715) ConcurrentModificationException in
ThreadProcessor
Posted by "Willem Jiang (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-715?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Willem Jiang reassigned CAMEL-715:
----------------------------------
Assignee: Willem Jiang
> ConcurrentModificationException in ThreadProcessor
> --------------------------------------------------
>
> Key: CAMEL-715
> URL: https://issues.apache.org/activemq/browse/CAMEL-715
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-core
> Affects Versions: 1.4.0
> Reporter: Wojciech Durczynski
> Assignee: Willem Jiang
> Fix For: 1.5.0
>
> Attachments: JUnitTestCase.java
>
>
> When defining very simple routing with ThreadProcessor I get ConcurrentModificationException on multicore systems.
> Example:
> from("direct:a").thread(10).process(new Processor() {
> @Override
> public void process(Exchange ex) throws Exception {
> //sth
> }
> });
> Stack trace:
> Exception in thread "Thread Processor"
> java.util.ConcurrentModificationException
> at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
> at java.util.HashMap$EntryIterator.next(HashMap.java:834)
> at java.util.HashMap$EntryIterator.next(HashMap.java:832)
> at java.util.HashMap.putAll(HashMap.java:523)
> at
> org.apache.camel.processor.Pipeline.createNextExchange(Pipeline.java:146
> )
> at org.apache.camel.processor.Pipeline$1.done(Pipeline.java:123)
> at
> org.apache.camel.processor.ThreadProcessor$ProcessCall.run(ThreadProcess
> or.j
> ava:66)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecuto
> r.ja
> va:885)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.ja
> va:9
> 07)
> at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (CAMEL-715) ConcurrentModificationException in
ThreadProcessor
Posted by "Wojciech Durczynski (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-715?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Wojciech Durczynski updated CAMEL-715:
--------------------------------------
Attachment: (was: JUnitTestCase.java)
> ConcurrentModificationException in ThreadProcessor
> --------------------------------------------------
>
> Key: CAMEL-715
> URL: https://issues.apache.org/activemq/browse/CAMEL-715
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-core
> Reporter: Wojciech Durczynski
> Priority: Critical
> Fix For: 1.4.0
>
> Attachments: JUnitTestCase.java
>
>
> When defining very simple routing with ThreadProcessor I get ConcurrentModificationException on multicore systems.
> Example:
> from("direct:a").thread(10).process(new Processor() {
> @Override
> public void process(Exchange ex) throws Exception {
> //sth
> }
> });
> Stack trace:
> Exception in thread "Thread Processor"
> java.util.ConcurrentModificationException
> at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
> at java.util.HashMap$EntryIterator.next(HashMap.java:834)
> at java.util.HashMap$EntryIterator.next(HashMap.java:832)
> at java.util.HashMap.putAll(HashMap.java:523)
> at
> org.apache.camel.processor.Pipeline.createNextExchange(Pipeline.java:146
> )
> at org.apache.camel.processor.Pipeline$1.done(Pipeline.java:123)
> at
> org.apache.camel.processor.ThreadProcessor$ProcessCall.run(ThreadProcess
> or.j
> ava:66)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecuto
> r.ja
> va:885)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.ja
> va:9
> 07)
> at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (CAMEL-715) ConcurrentModificationException in
ThreadProcessor
Posted by "Willem Jiang (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-715?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Willem Jiang resolved CAMEL-715.
--------------------------------
Resolution: Fixed
http://svn.apache.org/viewvc?rev=679273&view=rev
> ConcurrentModificationException in ThreadProcessor
> --------------------------------------------------
>
> Key: CAMEL-715
> URL: https://issues.apache.org/activemq/browse/CAMEL-715
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-core
> Affects Versions: 1.4.0
> Reporter: Wojciech Durczynski
> Assignee: Willem Jiang
> Fix For: 1.5.0
>
> Attachments: JUnitTestCase.java
>
>
> When defining very simple routing with ThreadProcessor I get ConcurrentModificationException on multicore systems.
> Example:
> from("direct:a").thread(10).process(new Processor() {
> @Override
> public void process(Exchange ex) throws Exception {
> //sth
> }
> });
> Stack trace:
> Exception in thread "Thread Processor"
> java.util.ConcurrentModificationException
> at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
> at java.util.HashMap$EntryIterator.next(HashMap.java:834)
> at java.util.HashMap$EntryIterator.next(HashMap.java:832)
> at java.util.HashMap.putAll(HashMap.java:523)
> at
> org.apache.camel.processor.Pipeline.createNextExchange(Pipeline.java:146
> )
> at org.apache.camel.processor.Pipeline$1.done(Pipeline.java:123)
> at
> org.apache.camel.processor.ThreadProcessor$ProcessCall.run(ThreadProcess
> or.j
> ava:66)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecuto
> r.ja
> va:885)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.ja
> va:9
> 07)
> at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (CAMEL-715) ConcurrentModificationException in
ThreadProcessor
Posted by "Wojciech Durczynski (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-715?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Wojciech Durczynski updated CAMEL-715:
--------------------------------------
Attachment: JUnitTestCase.java
JUnit test case that causes error
> ConcurrentModificationException in ThreadProcessor
> --------------------------------------------------
>
> Key: CAMEL-715
> URL: https://issues.apache.org/activemq/browse/CAMEL-715
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-core
> Reporter: Wojciech Durczynski
> Priority: Critical
> Fix For: 1.4.0
>
> Attachments: JUnitTestCase.java
>
>
> When defining very simple routing with ThreadProcessor I get ConcurrentModificationException on multicore systems.
> Example:
> from("direct:a").thread(10).process(new Processor() {
> @Override
> public void process(Exchange ex) throws Exception {
> //sth
> }
> });
> Stack trace:
> Exception in thread "Thread Processor"
> java.util.ConcurrentModificationException
> at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
> at java.util.HashMap$EntryIterator.next(HashMap.java:834)
> at java.util.HashMap$EntryIterator.next(HashMap.java:832)
> at java.util.HashMap.putAll(HashMap.java:523)
> at
> org.apache.camel.processor.Pipeline.createNextExchange(Pipeline.java:146
> )
> at org.apache.camel.processor.Pipeline$1.done(Pipeline.java:123)
> at
> org.apache.camel.processor.ThreadProcessor$ProcessCall.run(ThreadProcess
> or.j
> ava:66)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecuto
> r.ja
> va:885)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.ja
> va:9
> 07)
> at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (CAMEL-715) ConcurrentModificationException in
ThreadProcessor
Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-715?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Claus Ibsen updated CAMEL-715:
------------------------------
Fix Version/s: 1.5.0
(was: 1.4.0)
Affects Version/s: 1.4.0
Priority: Major (was: Critical)
> ConcurrentModificationException in ThreadProcessor
> --------------------------------------------------
>
> Key: CAMEL-715
> URL: https://issues.apache.org/activemq/browse/CAMEL-715
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-core
> Affects Versions: 1.4.0
> Reporter: Wojciech Durczynski
> Fix For: 1.5.0
>
> Attachments: JUnitTestCase.java
>
>
> When defining very simple routing with ThreadProcessor I get ConcurrentModificationException on multicore systems.
> Example:
> from("direct:a").thread(10).process(new Processor() {
> @Override
> public void process(Exchange ex) throws Exception {
> //sth
> }
> });
> Stack trace:
> Exception in thread "Thread Processor"
> java.util.ConcurrentModificationException
> at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
> at java.util.HashMap$EntryIterator.next(HashMap.java:834)
> at java.util.HashMap$EntryIterator.next(HashMap.java:832)
> at java.util.HashMap.putAll(HashMap.java:523)
> at
> org.apache.camel.processor.Pipeline.createNextExchange(Pipeline.java:146
> )
> at org.apache.camel.processor.Pipeline$1.done(Pipeline.java:123)
> at
> org.apache.camel.processor.ThreadProcessor$ProcessCall.run(ThreadProcess
> or.j
> ava:66)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecuto
> r.ja
> va:885)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.ja
> va:9
> 07)
> at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (CAMEL-715) ConcurrentModificationException in
ThreadProcessor
Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-715?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=44274#action_44274 ]
Claus Ibsen commented on CAMEL-715:
-----------------------------------
Wojciech. Thanks for the test. It fails on my laptop as well.
However I must say though that such a scenario isn't really a real use-case. Who will fire 500000 messages simulationsly in one thread ;)
But we will try to look into it.
> ConcurrentModificationException in ThreadProcessor
> --------------------------------------------------
>
> Key: CAMEL-715
> URL: https://issues.apache.org/activemq/browse/CAMEL-715
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-core
> Reporter: Wojciech Durczynski
> Priority: Critical
> Fix For: 1.4.0
>
> Attachments: JUnitTestCase.java
>
>
> When defining very simple routing with ThreadProcessor I get ConcurrentModificationException on multicore systems.
> Example:
> from("direct:a").thread(10).process(new Processor() {
> @Override
> public void process(Exchange ex) throws Exception {
> //sth
> }
> });
> Stack trace:
> Exception in thread "Thread Processor"
> java.util.ConcurrentModificationException
> at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
> at java.util.HashMap$EntryIterator.next(HashMap.java:834)
> at java.util.HashMap$EntryIterator.next(HashMap.java:832)
> at java.util.HashMap.putAll(HashMap.java:523)
> at
> org.apache.camel.processor.Pipeline.createNextExchange(Pipeline.java:146
> )
> at org.apache.camel.processor.Pipeline$1.done(Pipeline.java:123)
> at
> org.apache.camel.processor.ThreadProcessor$ProcessCall.run(ThreadProcess
> or.j
> ava:66)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecuto
> r.ja
> va:885)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.ja
> va:9
> 07)
> at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (CAMEL-715) ConcurrentModificationException in
ThreadProcessor
Posted by "Wojciech Durczynski (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-715?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Wojciech Durczynski updated CAMEL-715:
--------------------------------------
Attachment: JUnitTestCase.java
Attachment without license
> ConcurrentModificationException in ThreadProcessor
> --------------------------------------------------
>
> Key: CAMEL-715
> URL: https://issues.apache.org/activemq/browse/CAMEL-715
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-core
> Reporter: Wojciech Durczynski
> Priority: Critical
> Fix For: 1.4.0
>
> Attachments: JUnitTestCase.java
>
>
> When defining very simple routing with ThreadProcessor I get ConcurrentModificationException on multicore systems.
> Example:
> from("direct:a").thread(10).process(new Processor() {
> @Override
> public void process(Exchange ex) throws Exception {
> //sth
> }
> });
> Stack trace:
> Exception in thread "Thread Processor"
> java.util.ConcurrentModificationException
> at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
> at java.util.HashMap$EntryIterator.next(HashMap.java:834)
> at java.util.HashMap$EntryIterator.next(HashMap.java:832)
> at java.util.HashMap.putAll(HashMap.java:523)
> at
> org.apache.camel.processor.Pipeline.createNextExchange(Pipeline.java:146
> )
> at org.apache.camel.processor.Pipeline$1.done(Pipeline.java:123)
> at
> org.apache.camel.processor.ThreadProcessor$ProcessCall.run(ThreadProcess
> or.j
> ava:66)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecuto
> r.ja
> va:885)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.ja
> va:9
> 07)
> at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.