Tribune

Home » Liferay Portal » English » 3. Development

Vista Combinata Vista Piatta Vista ad Albero
Discussioni [ Precedente | Successivo ]
toggle
Daniel Breitner
Strange Errors when accessing Liferay Services
29 marzo 2013 11.56
Risposta

Daniel Breitner

Punteggio: Junior Member

Messaggi: 89

Data di Iscrizione: 16 luglio 2008

Messaggi recenti

Hi everybody,

I encountered a very strange exception in Liferay GA1 (MAC OS).
I created a hook that offers a liferay service to store values.
The jar of that service is in m servers lib/ext directory, the hook has been deployed.

When I am trying to use that service I do get:


18:32:08,012 ERROR [render_portlet_jsp:154] org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'com.test.service.service.HibernateTransactionEntityLocalService' is defined
at com.liferay.portal.bean.BeanLocatorImpl.doLocate(BeanLocatorImpl.java:114)
at com.liferay.portal.bean.BeanLocatorImpl.locate(BeanLocatorImpl.java:67)
at com.liferay.portal.kernel.bean.PortletBeanLocatorUtil.locate(PortletBeanLocatorUtil.java:47)
at com.test.service.service.HibernateTransactionEntityLocalServiceUtil.getService(HibernateTransactionEntityLocalServiceUtil.java:81)
at com.test.service.service.HibernateTransactionEntityLocalServiceUtil.getListTypesforEnum(HibernateTransactionEntityLocalServiceUtil.java:72)
at com.test.database.dao.liferay_impl.SchedulerLiferayDAO.getAllScheduleActions(SchedulerLiferayDAO.java:299)
at com.test.bean.SchedulerBB.fillScheduleActions(SchedulerBB.java:961)
at com.test.bean.SchedulerBB.<init>(SchedulerBB.java:448)
at java.lang.Class.newInstance0(Class.java:357)
at java.lang.Class.newInstance(Class.java:310)
at com.sun.faces.mgbean.BeanBuilder.newBeanInstance(BeanBuilder.java:188)
at com.sun.faces.mgbean.BeanBuilder.build(BeanBuilder.java:102)
at com.sun.faces.mgbean.BeanManager.createAndPush(BeanManager.java:409)
at com.sun.faces.mgbean.BeanManager.create(BeanManager.java:269)
at com.sun.faces.el.ManagedBeanELResolver.resolveBean(ManagedBeanELResolver.java:244)
at com.sun.faces.el.ManagedBeanELResolver.getValue(ManagedBeanELResolver.java:116)
at com.sun.faces.el.DemuxCompositeELResolver._getValue(DemuxCompositeELResolver.java:176)
at com.sun.faces.el.DemuxCompositeELResolver.getValue(DemuxCompositeELResolver.java:203)
at org.jboss.el.parser.AstIdentifier.getValue(AstIdentifier.java:44)
at org.jboss.el.parser.AstValue.getValue(AstValue.java:63)
Mehdi norouzi
RE: Strange Errors when accessing Liferay Services
30 marzo 2013 2.28
Risposta

Mehdi norouzi

Punteggio: New Member

Messaggi: 14

Data di Iscrizione: 17 luglio 2006

Messaggi recenti

Hi
It seems your problem is in way you use hook, you can make hook (Override service, jsp, properties) as portlet and then deploy it. I think it's not necessary to make jar and put in ext/lib
David H Nebinger
RE: Strange Errors when accessing Liferay Services
30 marzo 2013 6.00
Risposta

David H Nebinger

Punteggio: Liferay Legend

Messaggi: 7232

Data di Iscrizione: 1 settembre 2006

Messaggi recenti

You should not do SB in a hook because it does not have the context to run. Deploy as a simple portlet plugin and you'll be a step closer...

To use the service in a hook, you either have to put the service jar in ROOT/WEB-INF/lib or move service jar to the global lib dir (lib/ext).