Nuxeo doesn't resolve any Action Seam
I set up eclipse on a windows 7 machine with the 5.6 tomcat release of nuxeo. I created a fresh new workspace. I'm using java 1.6.0_37 to run the server. I installed the latest stable version of Nuxeo IDE. I've created a Nuxeo Plugin Project using the wizard and then an Action Seam called 'test' using the wizard without modyfing any code.
Nuxeo complains with:
ERROR [org.nuxeo.ecm.platform.actions.DefaultActionFilter] evaluation of condition SeamContext.get("test").accept() failed: returning false
and if i delete the filter condition from the xml then i get this error
ERROR [javax.enterprise.resource.webcontainer.jsf.application] javax.el.PropertyNotFoundException: Target Unreachable, identifier 'test' resolved to null
what could have happened?
The seam action bean is not loaded because the nuxeo runtime used is not a SDK. The SDK distribution includes is pre-bundled with all sources and also some development components that we don't want in a standard distribution. The seam hot-reloader is bundled in that way.
Thanks, I think I've got it. The bean deployment is not taken in account because you're not in dev mode. Can you edit 'NUXEO_HOME/bin/nuxeo-sdk.conf' and uncomment the line 'org.nuxeo.dev=true' and restart the nuxeo instance. It should work then.
The key-point in the log was the message
2012-12-05 14:56:02,544 INFO [org.nuxeo.ecm.platform.ui.web.reload.NuxeoJSFReloadHandler] Do not flush the JSF application: debug mode is not set
The next IDE hot fix release will fix this configuration problem NXIDE-234. Sorry for the time you've lost on this.
Now I get this error:
<code><pre> 2012-12-05 16:27:11,991 WARN [org.nuxeo.ecm.core.api.TransactionalCoreSessionWrapper] Session invoked in a container without a transaction active: turn on debug logs for more information about the faulty call. 2012-12-05 16:27:11,991 DEBUG [org.nuxeo.ecm.core.api.TransactionalCoreSessionWrapper] Session invoked in a container without a transaction java.lang.Throwable
at org.nuxeo.ecm.core.api.TransactionalCoreSessionWrapper.checkTxActiveRequired(TransactionalCoreSessionWrapper.java:104)
at org.nuxeo.ecm.core.api.TransactionalCoreSessionWrapper.invoke(TransactionalCoreSessionWrapper.java:130)
at $Proxy43.query(Unknown Source)
at org.nuxeo.ecm.platform.routing.core.impl.DocumentRoutingTreePersister.getDocumentRoutesStructure(DocumentRoutingTreePersister.java:214)
[…] </code></pre>
I downloaded eclipse: eclipse-java-juno-SR1-win32-x86_64
I set up eclipse to use my java 1.6.0_37 by going to Preferences -> Java -> Installed JREs and selecting the right one
I downloaded and installed the Nuxeo Ide (I tried both the stable version and the dev version but it's the same)
I enabled dev mode in the nuxeo.conf file
I created a new workspace in an empty folder
I created a Nuxeo Plugin Project using the Wizard
I created an Action Bean with a strange name to avoid naming conflicts
still Nuxeo complains that <code><pre> 2012-12-06 12:34:39,395 ERROR [org.nuxeo.ecm.platform.actions.DefaultActionFilter] evaluation of condition SeamContext.get("nameOfMyBean").accept failed: returning false </pre></code>
And I tried this in different computers and OS (in the same phisical building) always getting the same results.
Could you reproduce it?
Could you please tell us if you found something why you obtain this message :
2012-12-06 12:34:39,395 ERROR [org.nuxeo.ecm.platform.actions.DefaultActionFilter] evaluation of condition SeamContext.get("nameOfMyBean").accept failed: returning false
I have the same problem with a specific Actionbean created in eclipse IDE. Thanks
<pre> <category name="org.nuxeo">
</category> <category name="javax.faces">
</category> <category name="org.apache.myfaces">
</category> <category name="com.sun.faces">
</category> </pre>
<code><pre> 2012-12-04 13:16:25,874 DEBUG [org.nuxeo.ecm.platform.actions.ActionService] Checking access for action 'com.example.Test'… 2012-12-04 13:16:25,874 ERROR [org.nuxeo.ecm.platform.actions.DefaultActionFilter] evaluation of condition SeamContext.get("test").accept failed: returning false 2012-12-04 13:16:25,874 DEBUG [org.nuxeo.ecm.platform.actions.ActionService] Filter 'com.example.Test' denied access 2012-12-04 13:16:25,874 DEBUG [org.nuxeo.ecm.platform.actions.ActionService] Denying access for action 'com.example.Test' </pre></code>
According to the log the component and the action are regularly registered.
<pre> 2012-12-05 11:02:57,729 INFO [org.jboss.seam.Component] Component: yop, scope: CONVERSATION, type: JAVA_BEAN, class: org.nuxeo.sample.YopBean </pre>
<pre> <category name="org.jboss.seam">
</category> </pre>
<code><pre> 2012-12-05 13:34:37,337 DEBUG [org.nuxeo.ecm.platform.actions.ActionService] Checking access for action 'org.nuxeo.sample.MyOwnUniqueTestBean'… 2012-12-05 13:34:37,337 DEBUG [org.jboss.seam.Component] seam component not found: myOwnUniqueTest 2012-12-05 13:34:37,337 ERROR [org.nuxeo.ecm.platform.actions.DefaultActionFilter] evaluation of condition SeamContext.get("myOwnUniqueTest").accept() failed: returning false 2012-12-05 13:34:37,337 DEBUG [org.nuxeo.ecm.platform.actions.ActionService] Filter 'org.nuxeo.sample.MyOwnUniqueTestBean' denied access 2012-12-05 13:34:37,337 DEBUG [org.nuxeo.ecm.platform.actions.ActionService] Denying access for action 'org.nuxeo.sample.MyOwnUniqueTestBean' </pre></code>
http://pastebin.com/5H60Dvrp