This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 154928 - Deadlock when editing source code in the diff view
Summary: Deadlock when editing source code in the diff view
Status: RESOLVED DUPLICATE of bug 154199
Alias: None
Product: editor
Classification: Unclassified
Component: Parsing & Indexing (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Tomas Zezula
URL:
Keywords: THREAD
Depends on:
Blocks:
 
Reported: 2008-12-08 12:44 UTC by Marian Petras
Modified: 2009-02-19 20:45 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
full thread dump (19.95 KB, text/plain)
2008-12-08 12:45 UTC, Marian Petras
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Marian Petras 2008-12-08 12:44:45 UTC
I got a deadlock while changing code (in the subversion diff view). The call-stacks of threads involved in the deadlock
do not showorg.netbeans.modules.parsing.impl.TaskProcessor$InternalLock), anything related to the diff view so I think
the diff view was innocent in this case.

Found one Java-level deadlock:
=============================
"CaretAwareJavaSourceTaskFactory worker":
  waiting to lock monitor 0x87c37674 (object 0x8c01b2b8, a 
  which is held by "Java Source Worker Thread"
"Java Source Worker Thread":
  waiting to lock monitor 0x87c39eb0 (object 0x8e241c00, a org.netbeans.modules.parsing.impl.SourceCache),
  which is held by "OpenIDE-request-processor-4"
"OpenIDE-request-processor-4":
  waiting to lock monitor 0x0886988c (object 0x8e241c50, a org.netbeans.modules.parsing.api.Source),
  which is held by "Java Source Worker Thread"

Java stack information for the threads listed above:
===================================================
"CaretAwareJavaSourceTaskFactory worker":
	at org.netbeans.modules.parsing.impl.TaskProcessor.rescheduleTasks(TaskProcessor.java:360)
	- waiting to lock <0x8c01b2b8> (a org.netbeans.modules.parsing.impl.TaskProcessor$InternalLock)
	at org.netbeans.modules.parsing.impl.Utilities.rescheduleTask(Utilities.java:133)
	at org.netbeans.modules.java.source.JavaSourceAccessor.rescheduleTask(JavaSourceAccessor.java:192)
	at org.netbeans.api.java.source.JavaSourceTaskFactory$3.rescheduleTask(JavaSourceTaskFactory.java:255)
	at org.netbeans.api.java.source.JavaSourceTaskFactory.reschedule(JavaSourceTaskFactory.java:231)
	- locked <0x8bdc5f80> (a org.netbeans.modules.java.hints.infrastructure.SuggestionsTaskFactory)
	at org.netbeans.api.java.source.support.CaretAwareJavaSourceTaskFactory.access$400(:71)
	at org.netbeans.api.java.source.support.CaretAwareJavaSourceTaskFactory$ComponentListener.run(:184)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:573)
	at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:1005)
"Java Source Worker Thread":
	at org.netbeans.modules.parsing.impl.SourceCache.getSnapshot(SourceCache.java:107)
	- waiting to lock <0x8e241c00> (a org.netbeans.modules.parsing.impl.SourceCache)
	at org.netbeans.modules.parsing.impl.TaskProcessor$CompilationJob.run(TaskProcessor.java:730)
	- locked <0x8e241c50> (a org.netbeans.modules.parsing.api.Source)
	- locked <0x8c01b2b8> (a org.netbeans.modules.parsing.impl.TaskProcessor$InternalLock)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
	at java.lang.Thread.run(Thread.java:619)
"OpenIDE-request-processor-4":
	at org.netbeans.modules.parsing.api.Source._getDocument(Source.java:351)
	- waiting to lock <0x8e241c50> (a org.netbeans.modules.parsing.api.Source)
	at org.netbeans.modules.parsing.api.Source.getDocument(Source.java:217)
	at org.netbeans.modules.languages.ParserListenerFactoryImpl.create(ParserListenerFactoryImpl.java:75)
	at org.netbeans.modules.parsing.impl.SourceCache.createTasks(SourceCache.java:311)
	at org.netbeans.modules.parsing.impl.SourceCache.scheduleTasks(SourceCache.java:329)
	- locked <0x8e241c00> (a org.netbeans.modules.parsing.impl.SourceCache)
	at org.netbeans.modules.parsing.spi.Scheduler$1.run(Scheduler.java:152)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:573)
	at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:1005)

Found 1 deadlock.

I am attaching the full thread-dump.

This deadlock is similar to the one reported in issue #154199 ("Deadlock when navigating to code from found usages") and
may by caused by the same bug.
Comment 1 Marian Petras 2008-12-08 12:45:17 UTC
Created attachment 74689 [details]
full thread dump
Comment 2 Tomas Zezula 2008-12-08 14:37:37 UTC

*** This issue has been marked as a duplicate of 154199 ***