[JIRA] Commented: (NXS-894) Creation related event handlers doesn't work for types created by a content template

2012-01-06 Thread Sun Tan (JIRA NUXEO)

[ 
https://jira.nuxeo.com/browse/NXS-894?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=109047#comment-109047
 ] 

Sun Tan commented on NXS-894:
-

Any value, even if it's not related to the user principal: its crashing when 
initializing all the variables 

 Creation related event handlers doesn't work for types created by a content 
 template
 

 Key: NXS-894
 URL: https://jira.nuxeo.com/browse/NXS-894
 Project: Nuxeo Studio
  Issue Type: Bug
Affects Versions: 2.5
Reporter: Sun Tan

 It seems that content templates uses a SimplePrincipal and not NuxeoPrincipal
 If the EL field is the only activation field filled
 {code}
 19:58:40,641 ERROR [OperationEventListener] Failed to handle event 
 aboutToCreate using chain: InitPropertiesListener
 java.lang.ClassCastException: org.nuxeo.ecm.core.api.SimplePrincipal cannot 
 be cast to org.nuxeo.ecm.core.api.NuxeoPrincipal
   at 
 org.nuxeo.ecm.automation.core.scripting.Scripting.initBindings(Scripting.java:87)
   at 
 org.nuxeo.ecm.automation.core.scripting.MvelExpression.eval(MvelExpression.java:38)
   at 
 org.nuxeo.ecm.automation.core.events.EventHandler.isEnabled(EventHandler.java:254)
   at 
 org.nuxeo.ecm.automation.core.events.EventHandlerRegistry.handleEvent(EventHandlerRegistry.java:195)
   at 
 org.nuxeo.ecm.automation.core.events.OperationEventListener.handleEvent(OperationEventListener.java:33)
   at 
 org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:195)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.fireEvent(AbstractSession.java:400)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.notifyEvent(AbstractSession.java:452)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.createDocument(AbstractSession.java:863)
   at 
 org.nuxeo.ecm.platform.content.template.factories.SimpleTemplateBasedFactory.createContentStructure(SimpleTemplateBasedFactory.java:67)
   at 
 org.nuxeo.ecm.platform.content.template.service.ContentTemplateServiceImpl.executeFactoryForType(ContentTemplateServiceImpl.java:179)
   at 
 org.nuxeo.ecm.platform.content.template.listener.ContentCreationListener.handleEvent(ContentCreationListener.java:60)
   at 
 org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:195)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.fireEvent(AbstractSession.java:400)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.notifyEvent(AbstractSession.java:452)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.createDocument(AbstractSession.java:896)
   at 
 org.nuxeo.ecm.platform.content.template.factories.SimpleTemplateBasedFactory.createContentStructure(SimpleTemplateBasedFactory.java:67)
   at 
 org.nuxeo.ecm.platform.content.template.service.ContentTemplateServiceImpl.executeFactoryForType(ContentTemplateServiceImpl.java:179)
   at 
 org.nuxeo.ecm.platform.content.template.listener.ContentCreationListener.handleEvent(ContentCreationListener.java:60)
   at 
 org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:195)
 {code}

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira


___
ECM-tickets mailing list
ECM-tickets@lists.nuxeo.com
http://lists.nuxeo.com/mailman/listinfo/ecm-tickets


[JIRA] Commented: (NXS-894) Creation related event handlers doesn't work for types created by a content template

2012-01-05 Thread Alain Escaffre (JIRA NUXEO)

[ 
https://jira.nuxeo.com/browse/NXS-894?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=109036#comment-109036
 ] 

Alain Escaffre commented on NXS-894:


what value was put in the EL field ? 

 Creation related event handlers doesn't work for types created by a content 
 template
 

 Key: NXS-894
 URL: https://jira.nuxeo.com/browse/NXS-894
 Project: Nuxeo Studio
  Issue Type: Bug
Affects Versions: 2.5
Reporter: Sun Tan

 It seems that content templates uses a SimplePrincipal and not NuxeoPrincipal
 If the EL field is the only activation field filled
 {code}
 19:58:40,641 ERROR [OperationEventListener] Failed to handle event 
 aboutToCreate using chain: InitPropertiesListener
 java.lang.ClassCastException: org.nuxeo.ecm.core.api.SimplePrincipal cannot 
 be cast to org.nuxeo.ecm.core.api.NuxeoPrincipal
   at 
 org.nuxeo.ecm.automation.core.scripting.Scripting.initBindings(Scripting.java:87)
   at 
 org.nuxeo.ecm.automation.core.scripting.MvelExpression.eval(MvelExpression.java:38)
   at 
 org.nuxeo.ecm.automation.core.events.EventHandler.isEnabled(EventHandler.java:254)
   at 
 org.nuxeo.ecm.automation.core.events.EventHandlerRegistry.handleEvent(EventHandlerRegistry.java:195)
   at 
 org.nuxeo.ecm.automation.core.events.OperationEventListener.handleEvent(OperationEventListener.java:33)
   at 
 org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:195)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.fireEvent(AbstractSession.java:400)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.notifyEvent(AbstractSession.java:452)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.createDocument(AbstractSession.java:863)
   at 
 org.nuxeo.ecm.platform.content.template.factories.SimpleTemplateBasedFactory.createContentStructure(SimpleTemplateBasedFactory.java:67)
   at 
 org.nuxeo.ecm.platform.content.template.service.ContentTemplateServiceImpl.executeFactoryForType(ContentTemplateServiceImpl.java:179)
   at 
 org.nuxeo.ecm.platform.content.template.listener.ContentCreationListener.handleEvent(ContentCreationListener.java:60)
   at 
 org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:195)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.fireEvent(AbstractSession.java:400)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.notifyEvent(AbstractSession.java:452)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.createDocument(AbstractSession.java:896)
   at 
 org.nuxeo.ecm.platform.content.template.factories.SimpleTemplateBasedFactory.createContentStructure(SimpleTemplateBasedFactory.java:67)
   at 
 org.nuxeo.ecm.platform.content.template.service.ContentTemplateServiceImpl.executeFactoryForType(ContentTemplateServiceImpl.java:179)
   at 
 org.nuxeo.ecm.platform.content.template.listener.ContentCreationListener.handleEvent(ContentCreationListener.java:60)
   at 
 org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:195)
 {code}

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira


___
ECM-tickets mailing list
ECM-tickets@lists.nuxeo.com
http://lists.nuxeo.com/mailman/listinfo/ecm-tickets


[JIRA] Commented: (NXS-894) Creation related event handlers doesn't work for types created by a content template

2012-01-03 Thread Anahide Tchertchian (JIRA NUXEO)

[ 
https://jira.nuxeo.com/browse/NXS-894?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=108817#comment-108817
 ] 

Anahide Tchertchian commented on NXS-894:
-

please add steps to reproduce and move this issue to NXP: this is not an issue 
in Studio.

 Creation related event handlers doesn't work for types created by a content 
 template
 

 Key: NXS-894
 URL: https://jira.nuxeo.com/browse/NXS-894
 Project: Nuxeo Studio
  Issue Type: Bug
Affects Versions: 2.5
Reporter: Sun Tan

 It seems that content templates uses a SimplePrincipal and not NuxeoPrincipal
 If the EL field is the only activation field filled
 {code}
 19:58:40,641 ERROR [OperationEventListener] Failed to handle event 
 aboutToCreate using chain: InitPropertiesListener
 java.lang.ClassCastException: org.nuxeo.ecm.core.api.SimplePrincipal cannot 
 be cast to org.nuxeo.ecm.core.api.NuxeoPrincipal
   at 
 org.nuxeo.ecm.automation.core.scripting.Scripting.initBindings(Scripting.java:87)
   at 
 org.nuxeo.ecm.automation.core.scripting.MvelExpression.eval(MvelExpression.java:38)
   at 
 org.nuxeo.ecm.automation.core.events.EventHandler.isEnabled(EventHandler.java:254)
   at 
 org.nuxeo.ecm.automation.core.events.EventHandlerRegistry.handleEvent(EventHandlerRegistry.java:195)
   at 
 org.nuxeo.ecm.automation.core.events.OperationEventListener.handleEvent(OperationEventListener.java:33)
   at 
 org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:195)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.fireEvent(AbstractSession.java:400)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.notifyEvent(AbstractSession.java:452)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.createDocument(AbstractSession.java:863)
   at 
 org.nuxeo.ecm.platform.content.template.factories.SimpleTemplateBasedFactory.createContentStructure(SimpleTemplateBasedFactory.java:67)
   at 
 org.nuxeo.ecm.platform.content.template.service.ContentTemplateServiceImpl.executeFactoryForType(ContentTemplateServiceImpl.java:179)
   at 
 org.nuxeo.ecm.platform.content.template.listener.ContentCreationListener.handleEvent(ContentCreationListener.java:60)
   at 
 org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:195)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.fireEvent(AbstractSession.java:400)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.notifyEvent(AbstractSession.java:452)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.createDocument(AbstractSession.java:896)
   at 
 org.nuxeo.ecm.platform.content.template.factories.SimpleTemplateBasedFactory.createContentStructure(SimpleTemplateBasedFactory.java:67)
   at 
 org.nuxeo.ecm.platform.content.template.service.ContentTemplateServiceImpl.executeFactoryForType(ContentTemplateServiceImpl.java:179)
   at 
 org.nuxeo.ecm.platform.content.template.listener.ContentCreationListener.handleEvent(ContentCreationListener.java:60)
   at 
 org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:195)
 {code}

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira


___
ECM-tickets mailing list
ECM-tickets@lists.nuxeo.com
http://lists.nuxeo.com/mailman/listinfo/ecm-tickets


[JIRA] Commented: (NXS-894) Creation related event handlers doesn't work for types created by a content template

2012-01-03 Thread Sun Tan (JIRA NUXEO)

[ 
https://jira.nuxeo.com/browse/NXS-894?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=108820#comment-108820
 ] 

Sun Tan commented on NXS-894:
-

- target platform Nuxeo DM 5.5
- Create an event handler associated to aboutToCreate event
- Don't add any filter/condition BUT an EL expression
- Deploy the studio project in an empty Nuxeo DM 5.5, run Nuxeo and the error 
appears.

 Creation related event handlers doesn't work for types created by a content 
 template
 

 Key: NXS-894
 URL: https://jira.nuxeo.com/browse/NXS-894
 Project: Nuxeo Studio
  Issue Type: Bug
Affects Versions: 2.5
Reporter: Sun Tan

 It seems that content templates uses a SimplePrincipal and not NuxeoPrincipal
 If the EL field is the only activation field filled
 {code}
 19:58:40,641 ERROR [OperationEventListener] Failed to handle event 
 aboutToCreate using chain: InitPropertiesListener
 java.lang.ClassCastException: org.nuxeo.ecm.core.api.SimplePrincipal cannot 
 be cast to org.nuxeo.ecm.core.api.NuxeoPrincipal
   at 
 org.nuxeo.ecm.automation.core.scripting.Scripting.initBindings(Scripting.java:87)
   at 
 org.nuxeo.ecm.automation.core.scripting.MvelExpression.eval(MvelExpression.java:38)
   at 
 org.nuxeo.ecm.automation.core.events.EventHandler.isEnabled(EventHandler.java:254)
   at 
 org.nuxeo.ecm.automation.core.events.EventHandlerRegistry.handleEvent(EventHandlerRegistry.java:195)
   at 
 org.nuxeo.ecm.automation.core.events.OperationEventListener.handleEvent(OperationEventListener.java:33)
   at 
 org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:195)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.fireEvent(AbstractSession.java:400)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.notifyEvent(AbstractSession.java:452)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.createDocument(AbstractSession.java:863)
   at 
 org.nuxeo.ecm.platform.content.template.factories.SimpleTemplateBasedFactory.createContentStructure(SimpleTemplateBasedFactory.java:67)
   at 
 org.nuxeo.ecm.platform.content.template.service.ContentTemplateServiceImpl.executeFactoryForType(ContentTemplateServiceImpl.java:179)
   at 
 org.nuxeo.ecm.platform.content.template.listener.ContentCreationListener.handleEvent(ContentCreationListener.java:60)
   at 
 org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:195)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.fireEvent(AbstractSession.java:400)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.notifyEvent(AbstractSession.java:452)
   at 
 org.nuxeo.ecm.core.api.AbstractSession.createDocument(AbstractSession.java:896)
   at 
 org.nuxeo.ecm.platform.content.template.factories.SimpleTemplateBasedFactory.createContentStructure(SimpleTemplateBasedFactory.java:67)
   at 
 org.nuxeo.ecm.platform.content.template.service.ContentTemplateServiceImpl.executeFactoryForType(ContentTemplateServiceImpl.java:179)
   at 
 org.nuxeo.ecm.platform.content.template.listener.ContentCreationListener.handleEvent(ContentCreationListener.java:60)
   at 
 org.nuxeo.ecm.core.event.impl.EventServiceImpl.fireEvent(EventServiceImpl.java:195)
 {code}

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira


___
ECM-tickets mailing list
ECM-tickets@lists.nuxeo.com
http://lists.nuxeo.com/mailman/listinfo/ecm-tickets