Bug 1370912 - Compensation mechanism does not work for RefreshLunsSizeCommand
Summary: Compensation mechanism does not work for RefreshLunsSizeCommand
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: BLL.Storage
Version: 4.0.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ovirt-4.0.4
: 4.0.4
Assignee: Idan Shaby
QA Contact: Kevin Alon Goldblatt
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-08-28 09:50 UTC by Idan Shaby
Modified: 2016-09-20 07:04 UTC (History)
5 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2016-09-15 11:57:08 UTC
oVirt Team: Storage
Embargoed:
amureini: ovirt-4.0.z?
rule-engine: planning_ack?
amureini: devel_ack+
rule-engine: testing_ack?


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 62887 0 master MERGED core: fix compensation mechanism in RefreshLunsSizeCommand 2016-08-28 10:23:35 UTC
oVirt gerrit 62909 0 ovirt-engine-4.0 MERGED core: fix compensation mechanism in RefreshLunsSizeCommand 2016-08-29 09:24:42 UTC

Description Idan Shaby 2016-08-28 09:50:48 UTC
Description of problem:
An exception is logged when the compensation mechanism tries to compensate RefreshLunsSizeCommand:

2016-08-28 12:48:04,754 ERROR [org.ovirt.engine.core.bll.CommandsFactory] (ServerService Thread Pool -- 56) [] CommandsFactory : Failed to get type information using reflection for Class  'org.ovirt.engine.core.bll.storage.domain.RefreshLunsSizeCommand', Command Id '50fadb6c-a192-45ec-882f-ee7d49bc9d83': org.ovirt.engine.core.bll.storage.domain.RefreshLunsSizeCommand.<init>(org.ovirt.engine.core.compat.Guid)
2016-08-28 12:48:04,754 ERROR [org.ovirt.engine.core.bll.CommandsFactory] (ServerService Thread Pool -- 56) [] Exception: java.lang.NoSuchMethodException: org.ovirt.engine.core.bll.storage.domain.RefreshLunsSizeCommand.<init>(org.ovirt.engine.core.compat.Guid)
	at java.lang.Class.getConstructor0(Class.java:3082) [rt.jar:1.8.0_101]
	at java.lang.Class.getDeclaredConstructor(Class.java:2178) [rt.jar:1.8.0_101]
	at org.ovirt.engine.core.bll.CommandsFactory.createCommand(CommandsFactory.java:127) [bll.jar:]
	at org.ovirt.engine.core.bll.Backend.compensate(Backend.java:419) [bll.jar:]
	at org.ovirt.engine.core.bll.Backend.initialize(Backend.java:267) [bll.jar:]
	at org.ovirt.engine.core.bll.Backend.create(Backend.java:198) [bll.jar:]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.8.0_101]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) [rt.jar:1.8.0_101]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.8.0_101]
	at java.lang.reflect.Method.invoke(Method.java:498) [rt.jar:1.8.0_101]
	at org.jboss.as.ee.component.ManagedReferenceLifecycleMethodInterceptor.processInvocation(ManagedReferenceLifecycleMethodInterceptor.java:96)
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.invocation.InterceptorContext$Invocation.proceed(InterceptorContext.java:437)
	at org.jboss.as.weld.ejb.Jsr299BindingsInterceptor.delegateInterception(Jsr299BindingsInterceptor.java:70) [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.as.weld.ejb.Jsr299BindingsInterceptor.doLifecycleInterception(Jsr299BindingsInterceptor.java:117) [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.as.weld.ejb.Jsr299BindingsInterceptor.processInvocation(Jsr299BindingsInterceptor.java:103) [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.invocation.InterceptorContext$Invocation.proceed(InterceptorContext.java:437)
	at org.jboss.weld.ejb.AbstractEJBRequestScopeActivationInterceptor.aroundInvoke(AbstractEJBRequestScopeActivationInterceptor.java:73) [weld-core-impl-2.3.2.Final.jar:2.3.2.Final]
	at org.jboss.as.weld.ejb.EjbRequestScopeActivationInterceptor.processInvocation(EjbRequestScopeActivationInterceptor.java:83) [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.as.weld.injection.WeldInjectionInterceptor.processInvocation(WeldInjectionInterceptor.java:53) [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.as.ee.component.AroundConstructInterceptorFactory$1.processInvocation(AroundConstructInterceptorFactory.java:28)
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.as.weld.injection.WeldInterceptorInjectionInterceptor.processInvocation(WeldInterceptorInjectionInterceptor.java:56) [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.as.ee.component.ComponentInstantiatorInterceptor.processInvocation(ComponentInstantiatorInterceptor.java:74)
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.as.weld.ejb.Jsr299BindingsCreateInterceptor.processInvocation(Jsr299BindingsCreateInterceptor.java:100) [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.as.ee.component.NamespaceContextInterceptor.processInvocation(NamespaceContextInterceptor.java:50)
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.as.ejb3.tx.CMTTxInterceptor.invokeInNoTx(CMTTxInterceptor.java:263) [wildfly-ejb3-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.as.ejb3.tx.CMTTxInterceptor.supports(CMTTxInterceptor.java:374) [wildfly-ejb3-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.as.ejb3.tx.LifecycleCMTTxInterceptor.processInvocation(LifecycleCMTTxInterceptor.java:68) [wildfly-ejb3-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.as.weld.injection.WeldInjectionContextInterceptor.processInvocation(WeldInjectionContextInterceptor.java:43) [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.as.ejb3.component.interceptors.CurrentInvocationContextInterceptor.processInvocation(CurrentInvocationContextInterceptor.java:41) [wildfly-ejb3-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.as.ee.concurrent.ConcurrentContextInterceptor.processInvocation(ConcurrentContextInterceptor.java:45) [wildfly-ee-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.invocation.ContextClassLoaderInterceptor.processInvocation(ContextClassLoaderInterceptor.java:64)
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.invocation.InterceptorContext.run(InterceptorContext.java:356)
	at org.jboss.invocation.PrivilegedWithCombinerInterceptor.processInvocation(PrivilegedWithCombinerInterceptor.java:80)
	at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
	at org.jboss.invocation.ChainedInterceptor.processInvocation(ChainedInterceptor.java:61)
	at org.jboss.as.ee.component.BasicComponent.constructComponentInstance(BasicComponent.java:161)
	at org.jboss.as.ee.component.BasicComponent.constructComponentInstance(BasicComponent.java:134)
	at org.jboss.as.ee.component.BasicComponent.createInstance(BasicComponent.java:88)
	at org.jboss.as.ejb3.component.singleton.SingletonComponent.getComponentInstance(SingletonComponent.java:124) [wildfly-ejb3-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.as.ejb3.component.singleton.SingletonComponent.start(SingletonComponent.java:138) [wildfly-ejb3-10.0.0.Final.jar:10.0.0.Final]
	at org.jboss.as.ee.component.ComponentStartService$1.run(ComponentStartService.java:54)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [rt.jar:1.8.0_101]
	at java.util.concurrent.FutureTask.run(FutureTask.java:266) [rt.jar:1.8.0_101]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [rt.jar:1.8.0_101]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [rt.jar:1.8.0_101]
	at java.lang.Thread.run(Thread.java:745) [rt.jar:1.8.0_101]
	at org.jboss.threads.JBossThread.run(JBossThread.java:320)

2016-08-28 12:48:04,759 ERROR [org.ovirt.engine.core.bll.Backend] (ServerService Thread Pool -- 56) [] Failed to run compensation on startup for Command 'org.ovirt.engine.core.bll.storage.domain.RefreshLunsSizeCommand', Command Id '50fadb6c-a192-45ec-882f-ee7d49bc9d83'


Version-Release number of selected component (if applicable):
a58290fe513ffc1c879e984ed746667319ede8ba

How reproducible:
100%

Steps to Reproduce:
1. Create an iSCSI storage domain.
2. Resize the underlying lun(s) of that domain in the storage server.
3. Edit the storage domain in the web admin, go to "LUNs > Targets" and resize the lun(s).
4. Restart the engine after the storage domain is saved to the db and before RefreshLunsSizeCommand ends.

Actual results:
An exception is logged.

Expected results:
The compensation mechanism should roll back the storage domain's values in the db.

Comment 1 Kevin Alon Goldblatt 2016-09-13 17:00:14 UTC
(In reply to Idan Shaby from comment #0)
> Description of problem:
> An exception is logged when the compensation mechanism tries to compensate
> RefreshLunsSizeCommand:
> 
> 2016-08-28 12:48:04,754 ERROR [org.ovirt.engine.core.bll.CommandsFactory]
> (ServerService Thread Pool -- 56) [] CommandsFactory : Failed to get type
> information using reflection for Class 
> 'org.ovirt.engine.core.bll.storage.domain.RefreshLunsSizeCommand', Command
> Id '50fadb6c-a192-45ec-882f-ee7d49bc9d83':
> org.ovirt.engine.core.bll.storage.domain.RefreshLunsSizeCommand.<init>(org.
> ovirt.engine.core.compat.Guid)
> 2016-08-28 12:48:04,754 ERROR [org.ovirt.engine.core.bll.CommandsFactory]
> (ServerService Thread Pool -- 56) [] Exception:
> java.lang.NoSuchMethodException:
> org.ovirt.engine.core.bll.storage.domain.RefreshLunsSizeCommand.<init>(org.
> ovirt.engine.core.compat.Guid)
> 	at java.lang.Class.getConstructor0(Class.java:3082) [rt.jar:1.8.0_101]
> 	at java.lang.Class.getDeclaredConstructor(Class.java:2178)
> [rt.jar:1.8.0_101]
> 	at
> org.ovirt.engine.core.bll.CommandsFactory.createCommand(CommandsFactory.java:
> 127) [bll.jar:]
> 	at org.ovirt.engine.core.bll.Backend.compensate(Backend.java:419) [bll.jar:]
> 	at org.ovirt.engine.core.bll.Backend.initialize(Backend.java:267) [bll.jar:]
> 	at org.ovirt.engine.core.bll.Backend.create(Backend.java:198) [bll.jar:]
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> [rt.jar:1.8.0_101]
> 	at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:
> 62) [rt.jar:1.8.0_101]
> 	at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.
> java:43) [rt.jar:1.8.0_101]
> 	at java.lang.reflect.Method.invoke(Method.java:498) [rt.jar:1.8.0_101]
> 	at
> org.jboss.as.ee.component.ManagedReferenceLifecycleMethodInterceptor.
> processInvocation(ManagedReferenceLifecycleMethodInterceptor.java:96)
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.invocation.InterceptorContext$Invocation.
> proceed(InterceptorContext.java:437)
> 	at
> org.jboss.as.weld.ejb.Jsr299BindingsInterceptor.
> delegateInterception(Jsr299BindingsInterceptor.java:70)
> [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.as.weld.ejb.Jsr299BindingsInterceptor.
> doLifecycleInterception(Jsr299BindingsInterceptor.java:117)
> [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.as.weld.ejb.Jsr299BindingsInterceptor.
> processInvocation(Jsr299BindingsInterceptor.java:103)
> [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.invocation.InterceptorContext$Invocation.
> proceed(InterceptorContext.java:437)
> 	at
> org.jboss.weld.ejb.AbstractEJBRequestScopeActivationInterceptor.
> aroundInvoke(AbstractEJBRequestScopeActivationInterceptor.java:73)
> [weld-core-impl-2.3.2.Final.jar:2.3.2.Final]
> 	at
> org.jboss.as.weld.ejb.EjbRequestScopeActivationInterceptor.
> processInvocation(EjbRequestScopeActivationInterceptor.java:83)
> [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.as.weld.injection.WeldInjectionInterceptor.
> processInvocation(WeldInjectionInterceptor.java:53)
> [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.as.ee.component.AroundConstructInterceptorFactory$1.
> processInvocation(AroundConstructInterceptorFactory.java:28)
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.as.weld.injection.WeldInterceptorInjectionInterceptor.
> processInvocation(WeldInterceptorInjectionInterceptor.java:56)
> [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.as.ee.component.ComponentInstantiatorInterceptor.
> processInvocation(ComponentInstantiatorInterceptor.java:74)
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.as.weld.ejb.Jsr299BindingsCreateInterceptor.
> processInvocation(Jsr299BindingsCreateInterceptor.java:100)
> [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.as.ee.component.NamespaceContextInterceptor.
> processInvocation(NamespaceContextInterceptor.java:50)
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.as.ejb3.tx.CMTTxInterceptor.invokeInNoTx(CMTTxInterceptor.java:
> 263) [wildfly-ejb3-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.as.ejb3.tx.CMTTxInterceptor.supports(CMTTxInterceptor.java:374)
> [wildfly-ejb3-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.as.ejb3.tx.LifecycleCMTTxInterceptor.
> processInvocation(LifecycleCMTTxInterceptor.java:68)
> [wildfly-ejb3-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.as.weld.injection.WeldInjectionContextInterceptor.
> processInvocation(WeldInjectionContextInterceptor.java:43)
> [wildfly-weld-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.as.ejb3.component.interceptors.CurrentInvocationContextInterceptor.
> processInvocation(CurrentInvocationContextInterceptor.java:41)
> [wildfly-ejb3-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.as.ee.concurrent.ConcurrentContextInterceptor.
> processInvocation(ConcurrentContextInterceptor.java:45)
> [wildfly-ee-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.invocation.ContextClassLoaderInterceptor.
> processInvocation(ContextClassLoaderInterceptor.java:64)
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at org.jboss.invocation.InterceptorContext.run(InterceptorContext.java:356)
> 	at
> org.jboss.invocation.PrivilegedWithCombinerInterceptor.
> processInvocation(PrivilegedWithCombinerInterceptor.java:80)
> 	at
> org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:340)
> 	at
> org.jboss.invocation.ChainedInterceptor.processInvocation(ChainedInterceptor.
> java:61)
> 	at
> org.jboss.as.ee.component.BasicComponent.
> constructComponentInstance(BasicComponent.java:161)
> 	at
> org.jboss.as.ee.component.BasicComponent.
> constructComponentInstance(BasicComponent.java:134)
> 	at
> org.jboss.as.ee.component.BasicComponent.createInstance(BasicComponent.java:
> 88)
> 	at
> org.jboss.as.ejb3.component.singleton.SingletonComponent.
> getComponentInstance(SingletonComponent.java:124)
> [wildfly-ejb3-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.as.ejb3.component.singleton.SingletonComponent.
> start(SingletonComponent.java:138)
> [wildfly-ejb3-10.0.0.Final.jar:10.0.0.Final]
> 	at
> org.jboss.as.ee.component.ComponentStartService$1.run(ComponentStartService.
> java:54)
> 	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
> [rt.jar:1.8.0_101]
> 	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
> [rt.jar:1.8.0_101]
> 	at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:
> 1142) [rt.jar:1.8.0_101]
> 	at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:
> 617) [rt.jar:1.8.0_101]
> 	at java.lang.Thread.run(Thread.java:745) [rt.jar:1.8.0_101]
> 	at org.jboss.threads.JBossThread.run(JBossThread.java:320)
> 
> 2016-08-28 12:48:04,759 ERROR [org.ovirt.engine.core.bll.Backend]
> (ServerService Thread Pool -- 56) [] Failed to run compensation on startup
> for Command
> 'org.ovirt.engine.core.bll.storage.domain.RefreshLunsSizeCommand', Command
> Id '50fadb6c-a192-45ec-882f-ee7d49bc9d83'
> 
> 
> Version-Release number of selected component (if applicable):
> a58290fe513ffc1c879e984ed746667319ede8ba
> 
> How reproducible:
> 100%
> 
> Steps to Reproduce:
> 1. Create an iSCSI storage domain.
> 2. Resize the underlying lun(s) of that domain in the storage server.
> 3. Edit the storage domain in the web admin, go to "LUNs > Targets" and
> resize the lun(s).


At this point according to the above scenario the additional size added to the LUN is displayed as a text button in the "LUNs > Targets" tab >>>> HOWEVER nothing happens when pressing this button and no resizing is performed. Please clarify whether the LUN resize should be performed by pressing the additional size added with the text "+10 GB"



> 4. Restart the engine after the storage domain is saved to the db and before
> RefreshLunsSizeCommand ends.
> 
> Actual results:
> An exception is logged.
> 
> Expected results:
> The compensation mechanism should roll back the storage domain's values in
> the db.

Comment 2 Idan Shaby 2016-09-14 05:46:04 UTC
You should press that button and then click on the "OK" button.


Note You need to log in before you can comment on or make changes to this bug.