[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1651) HibernateTransaction: @Transactional + Transaction.setRollbackOnly() issue
by Przemyslaw Jaskierski (JIRA)
HibernateTransaction: @Transactional + Transaction.setRollbackOnly() issue
--------------------------------------------------------------------------
Key: JBSEAM-1651
URL: http://jira.jboss.com/jira/browse/JBSEAM-1651
Project: JBoss Seam
Issue Type: Bug
Components: Core
Affects Versions: 2.0.0.BETA1
Environment: Tomcat 6.0.13, Hibernate local transactions, Seam CVS 11/07/2007.
Reporter: Przemyslaw Jaskierski
Priority: Blocker
Fix For: 2.0.0.CR1
Full story in referenced forum thread (please ignore bogus h:messages problem report).
!!! Another thing that looks strange is this "registering synchronization: ManagedHibernateSession(java:/seamManagedHibernateSession)" message. This is a "non-JNDI-driven" environment, my components.xml looks like:
<core:init transaction-management-enabled="true" debug="true"/>
<persistence:managed-hibernate-session name="seamManagedHibernateSession" auto-create="true"
session-factory="#{sessionFactoryDelegate.sessionFactory}"/>
<transaction:hibernate-transaction session="#{seamManagedHibernateSession}"/>
where sessionFactoryDelegate is my STATELESS-scoped Seam component that provides HibernateSessionFactory by getSessionFactory(). This factory is created using Spring from a hibernate.cfg.xml file that has configured JDBC transactions as transaction strategy and then injected to this Seam component at startup. I'm sure it has no meaning here, just want you to have a full picture.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
16 years, 10 months
[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1657) Add getAttributes() / setAttribute() to BaseSeamTest.Request
by Dan Allen (JIRA)
Add getAttributes() / setAttribute() to BaseSeamTest.Request
------------------------------------------------------------
Key: JBSEAM-1657
URL: http://jira.jboss.com/jira/browse/JBSEAM-1657
Project: JBoss Seam
Issue Type: Feature Request
Components: Core
Affects Versions: 2.0.0.BETA1
Reporter: Dan Allen
Priority: Minor
Fix For: 2.0.0.CR1
It would be nice (but not a do or die feature) for the Request class of BaseSeamTest to support reading and writing of request (HttpServletRequest) attributes. All the groundwork is already in place, it is just a matter of adding the accessor methods to get at the Map. This feature is important for people looking to inject primitive event-scope attributes from a form that need to be injected into a component that is not yet instantiated. Again, it depends on the scenario of the test, but I came across a test that needed this feature.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
16 years, 10 months
[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1654) ManagedEntityIdentityInterceptor does not clear values in conversation context
by Wolfgang Schwendt (JIRA)
ManagedEntityIdentityInterceptor does not clear values in conversation context
------------------------------------------------------------------------------
Key: JBSEAM-1654
URL: http://jira.jboss.com/jira/browse/JBSEAM-1654
Project: JBoss Seam
Issue Type: Bug
Affects Versions: 2.0.0.BETA1
Reporter: Wolfgang Schwendt
Priority: Critical
The method entityRefsToIds() of org.jboss.seam.persistence.ManagedEntityIdentityInterceptor is called after control returns from the intercepted target method. It iterates over the fields of the target object and saves the values of certain field in the conversation context. However, the curent implementation as of Seam 2.0.0.Beta1 saves only non-null values. This has the implication that when a previous invocation of this interceptor already saved a non-null value of a field in the conversation context, but a subsequent invocation of the target method sets this field in the target object to null, the old saved value in the conversation context won't be cleared. From the user perspective, this leads to an unexpected "caching behavior" of an old field value.
See more detailed discussion at http://www.jboss.com/index.html?module=bb&op=viewtopic&t=113258&postdays=...
It appears to be an issue that should be investigated, because it fundamentally affects the use of stateful components in Seam.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
16 years, 10 months
[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1429) "Stack must not be null" error thrown from SeamFilter (weird)
by Przemyslaw Jaskierski (JIRA)
"Stack must not be null" error thrown from SeamFilter (weird)
-------------------------------------------------------------
Key: JBSEAM-1429
URL: http://jira.jboss.com/jira/browse/JBSEAM-1429
Project: JBoss Seam
Issue Type: Bug
Affects Versions: 1.3.0.ALPHA
Environment: Tomcat 6.0.13, jboss-seam-CVS.20070601
Reporter: Przemyslaw Jaskierski
As described in http://www.jboss.com/index.html?module=bb&op=viewtopic&t=110606. After adding SeamFilter to filter chain I've got
this stacktrace after invoking an action from a4j:commandLink. As requested I'm going to attach example application.
SEVERE: Servlet.service() for servlet Faces Servlet threw exception
java.lang.IllegalArgumentException: Stack must not be null
at org.jboss.seam.core.ConversationEntry.<init>(ConversationEntry.java:40)
at org.jboss.seam.core.ConversationEntries.createConversationEntry(ConversationEntries.java:50)
at org.jboss.seam.core.Manager.createConversationEntry(Manager.java:685)
at org.jboss.seam.core.Manager.beforeRedirect(Manager.java:834)
at org.jboss.seam.core.Manager.beforeRedirect(Manager.java:852)
at org.jboss.seam.core.Manager.appendConversationIdFromRedirectFilter(Manager.java:1104)
at org.jboss.seam.web.RedirectFilter$1.sendRedirect(RedirectFilter.java:66)
at com.sun.faces.context.ExternalContextImpl.redirect(ExternalContextImpl.java:419)
at org.ajax4jsf.framework.ajax.AjaxViewHandler.restoreView(AjaxViewHandler.java:180)
at com.sun.facelets.FaceletViewHandler.restoreView(FaceletViewHandler.java:310)
at org.ajax4jsf.framework.ViewHandlerWrapper.restoreView(ViewHandlerWrapper.java:116)
at org.ajax4jsf.framework.ajax.AjaxViewHandler.restoreView(AjaxViewHandler.java:150)
at com.sun.faces.lifecycle.RestoreViewPhase.execute(RestoreViewPhase.java:141)
at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)
at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:117)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.doFilter(BaseFilter.java:264)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:60)
at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:55)
at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:47)
at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:55)
at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:81)
at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:55)
at org.ajax4jsf.framework.ajax.xmlfilter.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:126)
at org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.doFilter(BaseFilter.java:248)
at org.jboss.seam.web.AbstractAjax4jsfFilter.doFilter(AbstractAjax4jsfFilter.java:35)
at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:55)
at org.jboss.seam.web.SeamFilter.doFilter(SeamFilter.java:126)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at net.sf.ehcache.constructs.web.filter.GzipFilter.doFilter(GzipFilter.java:75)
at net.sf.ehcache.constructs.web.filter.Filter.doFilter(Filter.java:92)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:261)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:581)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
16 years, 10 months
[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1636) Cannot inject Spring-bound HibernateSessionFactory to Seam-managed Hibernate Session
by Przemyslaw Jaskierski (JIRA)
Cannot inject Spring-bound HibernateSessionFactory to Seam-managed Hibernate Session
------------------------------------------------------------------------------------
Key: JBSEAM-1636
URL: http://jira.jboss.com/jira/browse/JBSEAM-1636
Project: JBoss Seam
Issue Type: Bug
Components: Spring
Environment: Tomcat 6.0.13, Spring 2.0.6, Seam CVS 08072007
Reporter: Przemyslaw Jaskierski
Priority: Minor
Attachments: seamComponentNamespaceStackTrace.txt.zip, springELResolverStackTrace.txt.zip, springStartedFromSeam.txt.zip
Filling this PR as requested by Mike.
For a full story please read related topic. As you requested I tried to reproduce environment from my previous unsuccessful attempts. It's a little bit frustrating but after assembling it once again now Spring EL resolver seams to working somewhat in some aspects. But let's try to report step by step.
1. Spring-EL approach: Spring-bound session factory, referenced in components, Spring EL resolver put into faces-config. There are two cases:
1.a. I have Seam-session-scoped bean that in @Create tries to get Hibernate session and retrieve some information from RDBMS. I have abstracted Seam-managed-hibernate-session access, and this additional layer simply invokes Component.instance(NAME_OF_SEAM_MANAGED_HIBERNATE_SESSION_COMPONENT_DECLARED_IN_COMPONENTSXML) instead of relying in @In. This layer is completely pluggable and allows to select HibernateSession manager (Seam, Spring OSIV, custom one for Test) and inject it into data access layer.
Ok, so this @Create call renders a bunch of extremely huge stacktreace (WORKED in Microncontainer/Seam 1.3 combo flawlessly). You can see these stracktraces in springELResolverStackTrace.txt.zip file.
1.b. Every following HibernateSession access seams to WORK now (I swear It didn't :(). Strange... Anyway I cannot use it because of 1.a.
1.1 components.xml
<persistence:managed-hibernate-session name="seamManagedHibernateSession" auto-create="true"
session-factory="#{hibernateSessionFactory}"/>
<transaction:hibernate-transaction session="#{seamManagedHibernateSession}"/>
2. Spring namespace approach: Spring-bound session factory, referenced in components.xml, <seam:component> added to Factory definition in application context:
<bean id="pecpHibernateSessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean" scope="prototype">
<seam:component class="org.hibernate.impl.SessionFactoryImpl"/>
<property name="dataSource" ref="dataSource" />
<property name="configLocation" value="classpath:conf/hibernate/hibernate.cfg.xml" />
<property name="configurationClass" value="org.hibernate.cfg.AnnotationConfiguration"/>
<property name="namingStrategy">
<bean class="egd.persistence.hibernate.extensions.UnderscoreAwareNamingStrategy"/>
</property>
</bean>
Spring listener put AFTER Seam listener in web.xml. App contexts configured from Spring listener. Result: java.lang.IllegalStateException: No active application scope. See seamComponentNamespaceStackTrace.txt.zip.
2.1. components.xml like in 1.1.
3. <spring:context-loader> approach. Everything like in point 2., but Spring listener removed from web.xml.
Result: "Seam cannot wrap JDK proxied IoC beans. Please use CGLib or Javassist proxying instead" - stracktrace in
springStartedFromSeam.txt.zip
3.1. components.xml
<core:init transaction-management-enabled="true" debug="true"/>
<core:manager conversation-timeout="120000"
concurrent-request-timeout="500"
conversation-id-parameter="k"/>
<spring:context-loader config-locations="classpath:conf/spring/core.xml,
classpath:conf/spring/persistence-common.xml,
classpath:conf/spring/persistence-hibernate.xml,
classpath:conf/spring/statistics.xml"/>
<persistence:managed-hibernate-session name="seamManagedHibernateSession" auto-create="true"
session-factory="#{hibernateSessionFactory}"/>
<transaction:hibernate-transaction session="#{seamManagedHibernateSession}"/>
That's all info I can get about this. Having a model example of such integration that I was struggling with would be a quite nice POC.
Now I need to get back to code, because I lost a lot of time lately :). Will happy live with my current workaround for a while :).
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
16 years, 10 months
[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-947) Problem with seam component <s:fileUpload/> in JBoss Portal
by Pietro Passantini (JIRA)
Problem with seam component <s:fileUpload/> in JBoss Portal
-----------------------------------------------------------
Key: JBSEAM-947
URL: http://jira.jboss.com/jira/browse/JBSEAM-947
Project: JBoss Seam
Issue Type: Bug
Components: JSF
Affects Versions: 1.1.6.GA, 1.1.5.GA
Environment: Windows XP Pro service pack 2, I.E. and FireFox, JBossAS 4.0.5.GA, JBoss Portal 2.4.1
Reporter: Pietro Passantini
I need to upload a file to Jackrabbit Repository using Seam Framework running on Portlet, with the <s:fileUpload/> component.
It doesn't work.
I've tried different ways to solve the problem, but none worked.
It could be a bug.
It seams that when the enctype of h:form is ="multipart/form-data", the method upload of fileManager is not called; if I don't set the enctype of h:form the method upload is called, but the bean file is null.
I'm trying with this configutaration:
JSP
<h:form id="myForm" enctype="multipart/form-data" >
<s:fileUpload accept="" fileName="#{file.filename}" data="#{file.data}" />
<h:commandButton value="Upload" action="#{fileManager.upload}"/>
</h:form>
BEAN
"file" is the bean that represents the file uploaded
"fileManager" is the bean that use the file uploaded
WEB.XML
...
<filter-name>Seam Filter</filter-name>
<filter-class>org.jboss.seam.servlet.SeamMultipartFilter</filter-class>
<filter-mapping>
<filter-name>Seam Filter</filter-name>
<url-pattern>*.seam</url-pattern>
</filter-mapping>
...
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
16 years, 10 months