Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Oomph » IllegalStateException: Profile <some profile> is not current. Expected timestamp 0 but was 0.
IllegalStateException: Profile <some profile> is not current. Expected timestamp 0 but was 0. [message #1748331] Tue, 22 November 2016 10:27 Go to next message
Konrad Windszus is currently offline Konrad WindszusFriend
Messages: 40
Registered: July 2009
Member
Similar to https://bugs.eclipse.org/bugs/show_bug.cgi?id=446138 I get from time to time the following exception during the "Perform Setup Tasks" step. The exact log is
java.lang.IllegalStateException: Profile <some profile name> is not current. Expected timestamp 0 but was 0.
	at org.eclipse.equinox.internal.p2.engine.SimpleProfileRegistry.lockProfile(SimpleProfileRegistry.java:854)
	at org.eclipse.equinox.internal.p2.engine.Engine.perform(Engine.java:67)
	at org.eclipse.equinox.internal.p2.engine.Engine.perform(Engine.java:44)
	at org.eclipse.equinox.internal.provisional.p2.director.PlanExecutionHelper.executePlan(PlanExecutionHelper.java:42)
	at org.eclipse.oomph.p2.internal.core.ProfileTransactionImpl$3.commit(ProfileTransactionImpl.java:543)
	at org.eclipse.oomph.p2.internal.core.ProfileTransactionImpl.commit(ProfileTransactionImpl.java:340)
	at org.eclipse.oomph.setup.p2.impl.P2TaskImpl.perform(P2TaskImpl.java:720)
	at org.eclipse.oomph.setup.internal.core.SetupTaskPerformer.doPerformNeededSetupTasks(SetupTaskPerformer.java:3121)
	at org.eclipse.oomph.setup.internal.core.SetupTaskPerformer.access$1(SetupTaskPerformer.java:3064)
	at org.eclipse.oomph.setup.internal.core.SetupTaskPerformer$WorkspaceUtil$1.run(SetupTaskPerformer.java:4282)
	at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2240)
	at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:2267)
	at org.eclipse.oomph.setup.internal.core.SetupTaskPerformer$WorkspaceUtil.performNeededSetupTasks(SetupTaskPerformer.java:4276)
	at org.eclipse.oomph.setup.internal.core.SetupTaskPerformer$WorkspaceUtil.access$0(SetupTaskPerformer.java:4274)
	at org.eclipse.oomph.setup.internal.core.SetupTaskPerformer.performNeededSetupTasks(SetupTaskPerformer.java:3055)
	at org.eclipse.oomph.setup.internal.core.SetupTaskPerformer.performTriggeredSetupTasks(SetupTaskPerformer.java:3030)
	at org.eclipse.oomph.setup.internal.core.SetupTaskPerformer.perform(SetupTaskPerformer.java:2930)
	at org.eclipse.oomph.setup.ui.wizards.ProgressPage$9.run(ProgressPage.java:556)
	at org.eclipse.oomph.setup.ui.wizards.ProgressPage$11$1.run(ProgressPage.java:682)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)

I use Oomph v1.5.0.
Any ideas what could be the issue here and how to fix? Should I report a bug at bugzilla?
Usually when I restart Eclipse it works again afterwards.

[Updated on: Tue, 22 November 2016 10:29]

Report message to a moderator

Re: IllegalStateException: Profile <some profile> is not current. Expected timestamp 0 but was [message #1748348 is a reply to message #1748331] Tue, 22 November 2016 11:53 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33258
Registered: July 2009
Senior Member
I've seen that in recent times. If I can't reproduce it, it's unlikely I can ever fix it. Somehow this method must be returning false but without turning on the debug options, I'm not sure how to tell what's wrong. Perhaps listProfileTimestamps is returning an empty array.

	private boolean checkTimestamps(IProfile profile, IProfile internalProfile) {
		long[] timestamps = listProfileTimestamps(profile.getProfileId());
		if (timestamps.length == 0) {
			if (DebugHelper.DEBUG_PROFILE_REGISTRY)
				DebugHelper.debug(PROFILE_REGISTRY, "check timestamp: expected " + profile.getTimestamp() + " but no profiles were found"); //$NON-NLS-1$ //$NON-NLS-2$
			resetProfiles();
			return false;
		}

		long currentTimestamp = (timestamps.length == 0) ? -1 : timestamps[timestamps.length - 1];
		if (profile.getTimestamp() != currentTimestamp) {
			if (DebugHelper.DEBUG_PROFILE_REGISTRY)
				DebugHelper.debug(PROFILE_REGISTRY, "check timestamp: expected " + profile.getTimestamp() + " but was " + currentTimestamp); //$NON-NLS-1$ //$NON-NLS-2$
			if (internalProfile.getTimestamp() != currentTimestamp)
				resetProfiles();
			return false;
		}

		return true;
	}


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: IllegalStateException: Profile <some profile> is not current. Expected timestamp 0 but was [message #1849793 is a reply to message #1748348] Wed, 02 February 2022 20:38 Go to previous messageGo to next message
Holger Herzog is currently offline Holger HerzogFriend
Messages: 1
Registered: February 2022
Junior Member
Maybe this helps: I observed this error quite reproducible by starting multiple instances of the same org.eclipse.equinox.launcher_1.6.400.v20210924-0641.jar in parallel with "-clean" option. Without "-clean" option, the concurrent instances start properly.

The installation I'm starting is a standard eclipse installation installed using the Eclipse installer (~/.p2/pool) on Mac OS 12.1 M1 Pro. I'm using different workspaces for each instance via "-data" parameter. The application I'm callling is "org.eclipse.ant.core.antRunner" with a custom build file that calls target "p2.mirror". Note: The source and the target of p2.mirror both are NOT in ~/.p2/pool, they are located in dedicated directories, where all running instances share the same source repository, but have different targets.

PS: Is this really the relevant code? I don't understand how it is possible that two long values are checked as being not equal, and one code line later, they turn out both to be equal to "0". How can this happen?
Re: IllegalStateException: Profile <some profile> is not current. Expected timestamp 0 but was [message #1860301 is a reply to message #1748331] Thu, 27 July 2023 12:27 Go to previous messageGo to next message
Shiva Sharma is currently offline Shiva SharmaFriend
Messages: 7
Registered: January 2014
Junior Member
I see this issue too during headless application build nightly tests.
I also see issue when using -clean option.
Can someone please help ??

Error Log:
!ENTRY org.eclipse.equinox.p2.reconciler.dropins 4 0 2023-07-27 17:49:11.053
!MESSAGE FrameworkEvent ERROR
!STACK 0
org.osgi.framework.BundleException: Exception in org.eclipse.equinox.internal.p2.reconciler.dropins.Activator.start() of bundle org.eclipse.equinox.p2.reconciler.dropins.
at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:835)
at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:763)
at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:1011)
at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:365)
at org.eclipse.osgi.container.Module.doStart(Module.java:605)
at org.eclipse.osgi.container.Module.start(Module.java:468)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel$2.run(ModuleContainer.java:1845)
at org.eclipse.osgi.internal.framework.EquinoxContainerAdaptor$1$1.execute(EquinoxContainerAdaptor.java:136)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1838)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1781)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1743)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1665)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:234)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:345)
Caused by: java.lang.IllegalStateException: Profile epp.package.cpp is not current. Expected timestamp 0 but was 0.
at org.eclipse.equinox.internal.p2.engine.SimpleProfileRegistry.lockProfile(SimpleProfileRegistry.java:865)
at org.eclipse.equinox.internal.p2.engine.Engine.perform(Engine.java:72)
at org.eclipse.equinox.internal.p2.engine.Engine.perform(Engine.java:48)
at org.eclipse.equinox.internal.p2.reconciler.dropins.ProfileSynchronizer.executePlan(ProfileSynchronizer.java:792)
at org.eclipse.equinox.internal.p2.reconciler.dropins.ProfileSynchronizer.performAddRemove(ProfileSynchronizer.java:205)
at org.eclipse.equinox.internal.p2.reconciler.dropins.ProfileSynchronizer.synchronize(ProfileSynchronizer.java:144)
at org.eclipse.equinox.internal.p2.reconciler.dropins.Activator.synchronize(Activator.java:444)
at org.eclipse.equinox.internal.p2.reconciler.dropins.Activator.start(Activator.java:179)
at org.eclipse.osgi.internal.framework.BundleContextImpl$2.run(BundleContextImpl.java:814)
at org.eclipse.osgi.internal.framework.BundleContextImpl$2.run(BundleContextImpl.java:1)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:554)
at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:806)
... 14 more
Root exception:
java.lang.IllegalStateException: Profile epp.package.cpp is not current. Expected timestamp 0 but was 0.
at org.eclipse.equinox.internal.p2.engine.SimpleProfileRegistry.lockProfile(SimpleProfileRegistry.java:865)
at org.eclipse.equinox.internal.p2.engine.Engine.perform(Engine.java:72)
at org.eclipse.equinox.internal.p2.engine.Engine.perform(Engine.java:48)
at org.eclipse.equinox.internal.p2.reconciler.dropins.ProfileSynchronizer.executePlan(ProfileSynchronizer.java:792)
at org.eclipse.equinox.internal.p2.reconciler.dropins.ProfileSynchronizer.performAddRemove(ProfileSynchronizer.java:205)
at org.eclipse.equinox.internal.p2.reconciler.dropins.ProfileSynchronizer.synchronize(ProfileSynchronizer.java:144)
at org.eclipse.equinox.internal.p2.reconciler.dropins.Activator.synchronize(Activator.java:444)
at org.eclipse.equinox.internal.p2.reconciler.dropins.Activator.start(Activator.java:179)
at org.eclipse.osgi.internal.framework.BundleContextImpl$2.run(BundleContextImpl.java:814)
at org.eclipse.osgi.internal.framework.BundleContextImpl$2.run(BundleContextImpl.java:1)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:554)
at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:806)
at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:763)
at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:1011)
at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:365)
at org.eclipse.osgi.container.Module.doStart(Module.java:605)
at org.eclipse.osgi.container.Module.start(Module.java:468)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel$2.run(ModuleContainer.java:1845)
at org.eclipse.osgi.internal.framework.EquinoxContainerAdaptor$1$1.execute(EquinoxContainerAdaptor.java:136)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1838)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1781)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1743)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1665)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:234)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:345)
Re: IllegalStateException: Profile <some profile> is not current. Expected timestamp 0 but was [message #1860316 is a reply to message #1860301] Fri, 28 July 2023 06:10 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33258
Registered: July 2009
Senior Member
Sorry, I've not been able to reproduce this and I have no good theory for the cause nor how to work around the problem.

Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:Oomph executable installer
Next Topic:Use Oomph for Updating Eclipse app
Goto Forum:
  


Current Time: Fri Dec 06 15:13:46 GMT 2024

Powered by FUDForum. Page generated in 0.03753 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top