Fórum

Transaction roll back

thumbnail
KK rajput, modificado 12 Anos atrás.

Transaction roll back

Expert Postagens: 266 Data de Entrada: 10/04/08 Postagens Recentes
Hi Friends ,
I am trying to invoke service through web services to add user in liferay in case of if Validation related to user screen name or emailAddress fails then it give me below exception.
Processing of HttpInvokerServiceExporter remote call resulted in fatal exception: com.vignet.platform.v2.portlet.service.RegUserService.addRegUser
org.springframework.transaction.UnexpectedRollbackException: Transaction rolled back because it has been marked as rollback-only
at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:717)
at org.springframework.transaction.interceptor.TransactionAspectSupport.commitTransactionAfterReturning(TransactionAspectSupport.java:393)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:120)
at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:58)
at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:58)
at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvice.java:58)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202)
at $Proxy299.addRegUser(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:309)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183)
Do any one have idea related to this.
thumbnail
David H Nebinger, modificado 12 Anos atrás.

RE: Transaction roll back

Liferay Legend Postagens: 14914 Data de Entrada: 02/09/06 Postagens Recentes
What's the question? How to pre-validate your fields? Why the transaction is rollback only?
thumbnail
KK rajput, modificado 12 Anos atrás.

RE: Transaction roll back

Expert Postagens: 266 Data de Entrada: 10/04/08 Postagens Recentes
I am trying to access userlocalserive.adduserService in my custom impl from plugin environment. and by custom service is called using web services. While adding user when we get certain exceptions like emailAddressException or screen name related exception then we want pass valid info to web service but we are not able to do since whatever we are returning is not reaching to web service it is getting null always in case of exceptions.
thumbnail
Hitoshi Ozawa, modificado 11 Anos atrás.

RE: Transaction roll back

Liferay Legend Postagens: 7942 Data de Entrada: 24/03/10 Postagens Recentes
So, can't you pre-validate before calling Liferay's API. I'm also not sure what you mean by "we are not able to do since whatever we are returning is not reaching to web service it is getting null always in case of exceptions." Are you asking us on how to set these properties?