Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 350370

Summary: NPE occurred during: "Updating indexes".
Product: z_Archived Reporter: Philippe Bastiani <philippe.bastiani>
Component: m2eAssignee: Project Inbox <m2e.core-inbox>
Status: CLOSED INVALID QA Contact:
Severity: normal    
Priority: P3 CC: igor, mkleint, philippe.bastiani
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows Vista   
Whiteboard:

Description Philippe Bastiani CLA 2011-06-26 04:18:34 EDT
Build Identifier: e3.7 20110615-0604 / m2e 1.0.0.20110607-2117

See the stacktrace:

!ENTRY org.eclipse.core.jobs 4 2 2011-06-26 10:03:24.597
!MESSAGE An internal error occurred during: "Updating indexes".
!STACK 0
java.lang.NullPointerException
	at org.eclipse.m2e.core.MavenPlugin.getMavenConfiguration(MavenPlugin.java:61)
	at org.eclipse.m2e.core.internal.index.nexus.NexusIndexManager.updateIndex(NexusIndexManager.java:1079)
	at org.eclipse.m2e.core.internal.index.nexus.NexusIndexManager$1.run(NexusIndexManager.java:658)
	at org.eclipse.m2e.core.internal.index.nexus.IndexUpdaterJob.run(IndexUpdaterJob.java:71)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)

Reproducible: Didn't try
Comment 1 Milos Kleint CLA 2011-06-27 07:38:10 EDT
MavenPluginActivator.getDefault().getMavenConfiguration() is where the NPE appears. The code in stacktrace is called after MavenPluginActivator.stop() is being called and reference to the MavenPluginActivator static reference is nullified. 

Not sure if the proper solution is to not nullify the ref or check for null when calling MavenPluginActivator.getDefault()
Comment 2 Igor Fedorenko CLA 2012-05-21 11:13:21 EDT
Closing old/stale bugreports.
Comment 3 Denis Roy CLA 2021-04-19 13:25:43 EDT
Moved to https://github.com/eclipse-m2e/m2e-core/issues/