You can subscribe to this list here.
| 2003 |
Jan
|
Feb
(55) |
Mar
(100) |
Apr
(203) |
May
(330) |
Jun
(190) |
Jul
(302) |
Aug
(323) |
Sep
(197) |
Oct
(245) |
Nov
(490) |
Dec
(330) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2004 |
Jan
(194) |
Feb
(400) |
Mar
(416) |
Apr
(415) |
May
(359) |
Jun
(381) |
Jul
(491) |
Aug
(311) |
Sep
(291) |
Oct
(273) |
Nov
(355) |
Dec
(266) |
| 2005 |
Jan
(306) |
Feb
(303) |
Mar
(520) |
Apr
(346) |
May
(255) |
Jun
(221) |
Jul
(171) |
Aug
(247) |
Sep
(147) |
Oct
(125) |
Nov
(165) |
Dec
(65) |
| 2006 |
Jan
(90) |
Feb
(53) |
Mar
(121) |
Apr
(103) |
May
(113) |
Jun
(103) |
Jul
(104) |
Aug
(67) |
Sep
(78) |
Oct
(82) |
Nov
(78) |
Dec
(70) |
| 2007 |
Jan
(77) |
Feb
(76) |
Mar
(63) |
Apr
(30) |
May
(47) |
Jun
(41) |
Jul
(44) |
Aug
(44) |
Sep
(49) |
Oct
(33) |
Nov
(25) |
Dec
(21) |
| 2008 |
Jan
(45) |
Feb
(13) |
Mar
(15) |
Apr
(12) |
May
(9) |
Jun
(33) |
Jul
(30) |
Aug
(7) |
Sep
(20) |
Oct
(17) |
Nov
(20) |
Dec
(10) |
| 2009 |
Jan
(8) |
Feb
(5) |
Mar
(12) |
Apr
(17) |
May
(19) |
Jun
(97) |
Jul
(77) |
Aug
(33) |
Sep
(24) |
Oct
(41) |
Nov
(16) |
Dec
(32) |
| 2010 |
Jan
(24) |
Feb
(14) |
Mar
(50) |
Apr
(71) |
May
(70) |
Jun
(64) |
Jul
(45) |
Aug
(62) |
Sep
(32) |
Oct
(4) |
Nov
(12) |
Dec
(2) |
| 2011 |
Jan
(1) |
Feb
(3) |
Mar
(4) |
Apr
(3) |
May
(6) |
Jun
(1) |
Jul
(4) |
Aug
(3) |
Sep
(4) |
Oct
(6) |
Nov
(3) |
Dec
(3) |
| 2012 |
Jan
(4) |
Feb
(8) |
Mar
(6) |
Apr
(10) |
May
(2) |
Jun
(3) |
Jul
(11) |
Aug
(10) |
Sep
(4) |
Oct
|
Nov
(1) |
Dec
(1) |
| 2013 |
Jan
(4) |
Feb
(1) |
Mar
(9) |
Apr
(1) |
May
(8) |
Jun
(2) |
Jul
(5) |
Aug
(2) |
Sep
|
Oct
(3) |
Nov
(10) |
Dec
(8) |
| 2014 |
Jan
(3) |
Feb
(12) |
Mar
(9) |
Apr
(12) |
May
(2) |
Jun
|
Jul
(3) |
Aug
(1) |
Sep
(1) |
Oct
(4) |
Nov
|
Dec
(2) |
| 2015 |
Jan
(1) |
Feb
(3) |
Mar
(4) |
Apr
(9) |
May
(2) |
Jun
(2) |
Jul
|
Aug
(2) |
Sep
(7) |
Oct
(9) |
Nov
(7) |
Dec
(9) |
| 2016 |
Jan
(7) |
Feb
(5) |
Mar
(5) |
Apr
(5) |
May
(8) |
Jun
(4) |
Jul
(5) |
Aug
(4) |
Sep
(6) |
Oct
(7) |
Nov
(2) |
Dec
(3) |
| 2017 |
Jan
(7) |
Feb
(8) |
Mar
(7) |
Apr
(3) |
May
(4) |
Jun
(3) |
Jul
(5) |
Aug
(8) |
Sep
(4) |
Oct
(2) |
Nov
(3) |
Dec
|
| 2018 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2019 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
| 2021 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2022 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
| 2024 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2025 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
(2) |
Aug
(5) |
Sep
(2) |
Oct
|
Nov
|
Dec
(1) |
| 2026 |
Jan
(1) |
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Keith D. <ke...@in...> - 2005-05-20 19:40:45
|
Garry,
Yes I've been meaning to take a look at this. Just no time yet.. It looks
interesting.
Hope you're enjoying using SWF :-) Keith
_____
From: spr...@li...
[mailto:spr...@li...] On Behalf Of
Boyce, Keith Garry
Sent: Friday, May 20, 2005 1:31 PM
To: Spr...@li...
Subject: [Springframework-developer] Object Graph Assembler proposal
feedback requested...
Hi Keith and Juergen,
A while ago I submitted a proposal in the forum for an Object Graph
Assembler and as of let I have received no feedback. I wanted to make sure
you guys understood my intent and what your thoughts were on the
implementation. <http://forum.springframework.org/viewtopic.php?t=5462>
http://forum.springframework.org/viewtopic.php?t=5462.
I submitted the code and created a JIRA at
http://opensource.atlassian.com/projects/spring/browse/SPR-945
BTW great presentation at
<http://static.springframework.org/spring/presentations/2004/spring-introduc
tion-to-lightweight-architecture/>
http://static.springframework.org/spring/presentations/2004/spring-introduct
ion-to-lightweight-architecture/. It was an excellent delivery.
Thanks,
Garry
|
|
From: Boyce, K. G. <Kei...@bc...> - 2005-05-20 17:33:02
|
This message is a PRIVATE communication. If you are not the intended recipient, please do not read, copy, or use it, and do not disclose it to others. Please notify the sender of the delivery error by replying to this message, and then delete it from your system. Thank you. |
|
From: Juergen H. <ju...@in...> - 2005-05-20 17:27:19
|
You don't need to use WebLogicJtaTransactionManager unless you intend to leverage WebLogic-specific (7.0+) JTA extensions. A plain JtaTransactionManager should be sufficient for typical usage. If you need transaction suspension, specify the corresponding "transactionManagerName" (see JtaTransactionManager's javadoc): this will enable PROPAGATION_REQUIRES_NEW and PROPAGATION_NOT_SUPPORTED. You could try to patch 1.1.5 accordingly, but I would recommend to use an upcoming nightly build or wait for 1.2.1 (which is scheduled for next Friday). Juergen -----Original Message----- From: spr...@li... [mailto:spr...@li...]On Behalf Of Dave Ballard Sent: Friday, May 20, 2005 7:20 PM To: spr...@li... Subject: Re: [Springframework-developer] Race condition with transaction synchronization? Hi Juergen, Thanks for looking into this and providing an insightful description of the problem. For me, this mix of EJB CMT and Spring tx demarcation is only a temporary situation as I transition away from EJB. I've got a service methods that are called from both the web tier (need Spring to start a transaction) and from a SLSB (EJB CMT starts transaction). My problem now is that Spring 1.2's WebLogicJtaTransactionManager is not compatible with WebLogic 6.1 (org.springframework.transaction.TransactionSystemException: Could not initialize WebLogicJtaTransactionManager because WebLogic API classes are not available; nested exception is java.lang.ClassNotFoundException: weblogic.transaction.UserTransaction.). Do you think that your fix below is something that could be patched into 1.1.5? I'll do it, but I don't want to waste my time if you don't think that it is a good idea. Thanks, Dave Juergen Hoeller wrote: >Hi Dave, > >I've just verified that your scenario can indeed lead to broken cleanup: > >If the rollback gets triggered from some other thread (i.e. not the thread >that created the transaction), the Hibernate SessionHolder cannot get >removed from the original thread. That is actually already expected, as it >can also happen in case of remote transaction propagation: Spring will >simply remove the current Hibernate Session from the SessionHolder in this >case, and reuse the SessionHolder when another transaction gets executed on >that thread. > >However, the above only works with direct JTA Session synchronization only. >If Spring transaction synchronization is involved too (that is, if >transactions get initiated from either EJB CMT or Spring transaction >demarcation, not just from EJB CMT), an IllegalStateException will be thrown >whenever a thread with such an empty SessionHolder is supposed to execute a >Spring-driven transaction. This is straightforward to reproduce in a test >case. > >I've just fixed this issue for both Hibernate 2.1 and Hibernate3, to be >committed today. The fix should be available in the next nightly build, and >will be released in Spring 1.2.1. > >Note that it's generally recommended to use *either* EJB CMT *or* >Spring-driven transactions. Spring's Session synchronization for Hibernate >will work nicely with EJB CMT only, without any Spring transaction >demarcation involved. Mixing both is nevertheless valid, therefore the above >fix is necessary. > >Thanks for reporting this! > >Juergen > > >-----Original Message----- >From: spr...@li... >[mailto:spr...@li...]On Behalf >Of Dave Ballard >Sent: Wednesday, May 18, 2005 10:41 PM >To: spr...@li... >Subject: Re: [Springframework-developer] Race condition with transaction >synchronization? > > >Hello, > >Sorry to respond to my own post, but if there's someone out there that >is familiar with SessionFactoryUtils, I would appreciate a little of >your time to discuss this issue. This appears to be a bug in the JTA >session synchronization code for hibernate. > >Thanks, >Dave > >Dave Ballard wrote: > > > >>Hello, >> >>I posted this on the forums, but costin and Rod suggested that I post >>it here. >> >>I'm using Spring Framework 1.1.5 with Hibernate on WebLogic Server >>6.1. I'm testing timeout scenarios, and I've run into an issue I need >>some help with. I'm slowly eliminating EJB's from my application, but >>I do have some legacy EJB code to deal with. In my scenario, my >>servlet is calling a SLSB, which in turn calls spring-managed >>transactional services. These transaction service join the CMT >>transaction created by the EJB container. I have: >> >>Code: >> >>1) A servlet calls SLSB with CMT. >>2) The SLSB calls SessionFactoryUtils.getSession(sessionFactory, true) >>-- This binds the hibernate session to the current thread >>3) The SLSB calls a spring-managed transactional service >>-- This bean uses the bound session as expected >>4) The SLSB calls another spring-managed transactional service >>-- This bean uses the bound session as expected >>5) The SLSB exits >>-- The TransactionSynchronizationManager unbinds the bound session as >>expected >> >> >>So the non-timeout scenario functions as expected. Now I introduce a >>timeout (by causing blocking in by database) prior to (3). With the >>timeout scenario, I encounter one of two results: >> >>Code: >> >>A) A spring HibernateJdbcException wrapping a weblogic >>TimedOutException as expected. >>B) An IllegalStateException Already value >>[org.springframework.orm.hibernate.SessionHolder@6f2304] for key >>[net.sf.hibernate.impl.SessionFactoryImpl@655ad0] bound to thread >>[ExecuteThread: '29' for queue: 'default'] >> >> >>Whether I get (A) or (B) is seemingly random. I've created a >>diagnostic version of SessionFactoryUtils to see what is happening in >>more detail. >>In scenario (B), it looks like WebLogic's transaction manager is >>grabbing another thread from the pool and is invoking spring's >>JtaSessionSynchronization.afterCompletion() which is resulting in >>doClose() being called. I've added a dumpStack() in doClose(), and >>here is what I see. The line numbers will be a little off because of >>my diagnostic code: >> >>Code: >> >>java.lang.Exception: Stack trace >> at java.lang.Thread.dumpStack(Thread.java:992) >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils.doClose(SessionFactor y >Utils.java:738) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils.closeSessionOrRegiste r >DeferredClose(SessionFactoryUtils.java:726) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils.access$300(SessionFac t >oryUtils.java:89) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils$SpringSessionSynchron i >zation.beforeCompletion(SessionFactoryUtils.java:867) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils$JtaSessionSynchroniza t >ion.afterCompletion(SessionFactoryUtils.java:978) > > >> at >> >> >> >weblogic.transaction.internal.ServerSCInfo.callAfterCompletions(ServerSCInf o >.java:464) > > >> at >> >> >> >weblogic.transaction.internal.ServerTransactionImpl.callAfterCompletions(Se r >verTransactionImpl.java:2139) > > >> at >> >> >> >weblogic.transaction.internal.ServerTransactionImpl.setRolledBack(ServerTra n >sactionImpl.java:2090) > > >> at >> >> >> >weblogic.transaction.internal.ServerTransactionImpl.globalRetryRollback(Ser v >erTransactionImpl.java:2188)DEBUG > > >>18:19:23,000 [ExecuteThread: '34' for queue: 'default'] [edemo_acme] >>(Transacti >> at >> >> >> >weblogic.transaction.internal.ServerTransactionImpl.globalRollback(ServerTr a >nsactionImpl.java:2080) > > >> at >> >> >> >weblogic.transaction.internal.TransactionImpl$1.execute(TransactionImpl.jav a >:1617) > > >> at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:159) >> at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:140) >> >> >>Meanwhile, the original timeout thread, who is in the middle of >>calling getSession(), and hasn't yet encountered the weblogic >>TimedOutException, >>tries to bind the session holder to the thread, and fails: >> >>Code: >> >>ERROR 18:19:23,046 [ExecuteThread: '34' for queue: 'default'] >>[edemo_acme] (TransactionAspectSupport.java:264) - Application >>exception overridden by rollback exception >>java.lang.IllegalStateException: Already value >>[org.springframework.orm.hibernate.SessionHolder@747db9] for key >>[net.sf.hibernate.impl.SessionFactoryImpl@606e55] bound to thread >>[ExecuteThread: '34' for queue: 'default'] >> at >> >> >> >org.springframework.transaction.support.TransactionSynchronizationManager.b i >ndResource(TransactionSynchronizationManager.java:147) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils.getSession(SessionFac t >oryUtils.java:346) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils.getSession(SessionFac t >oryUtils.java:266) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils.getSession(SessionFac t >oryUtils.java:223) > > >> at >> >> >> >org.springframework.orm.hibernate.HibernateInterceptor.invoke(HibernateInte r >ceptor.java:149) > > >> at >> >> >> >org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(Reflec t >iveMethodInvocation.java:144) > > >> at >> >> >> >org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopPr o >xy.java:174) > > >> at $Proxy93.findContract(Unknown Source) >> at >>mycode.ContractServiceImpl.findContract(ContractServiceImpl.java:59) >> ... >> >> >>It's not clear to me who the culprit is here, not being that familiar >>with JTA and Spring. Perhaps the beforeCompletion() called by the >>weblogic transaction manager is not cleaning up properly? Any ideas? >> >>Thanks for your help, >>Dave >> >> >>------------------------------------------------------- >>This SF.Net email is sponsored by Oracle Space Sweepstakes >>Want to be the first software developer in space? >>Enter now for the Oracle Space Sweepstakes! >>http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click >>_______________________________________________ >>Springframework-developer mailing list >>Spr...@li... >>https://lists.sourceforge.net/lists/listinfo/springframework-developer >> >> >> >> > > >------------------------------------------------------- >This SF.Net email is sponsored by Oracle Space Sweepstakes >Want to be the first software developer in space? >Enter now for the Oracle Space Sweepstakes! >http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click >_______________________________________________ >Springframework-developer mailing list >Spr...@li... >https://lists.sourceforge.net/lists/listinfo/springframework-developer > > > >------------------------------------------------------- >This SF.Net email is sponsored by Oracle Space Sweepstakes >Want to be the first software developer in space? >Enter now for the Oracle Space Sweepstakes! >http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click >_______________________________________________ >Springframework-developer mailing list >Spr...@li... >https://lists.sourceforge.net/lists/listinfo/springframework-developer > > > > ------------------------------------------------------- This SF.Net email is sponsored by Oracle Space Sweepstakes Want to be the first software developer in space? Enter now for the Oracle Space Sweepstakes! http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click _______________________________________________ Springframework-developer mailing list Spr...@li... https://lists.sourceforge.net/lists/listinfo/springframework-developer |
|
From: Dave B. <dba...@on...> - 2005-05-20 17:18:20
|
Hi Juergen, Thanks for looking into this and providing an insightful description of the problem. For me, this mix of EJB CMT and Spring tx demarcation is only a temporary situation as I transition away from EJB. I've got a service methods that are called from both the web tier (need Spring to start a transaction) and from a SLSB (EJB CMT starts transaction). My problem now is that Spring 1.2's WebLogicJtaTransactionManager is not compatible with WebLogic 6.1 (org.springframework.transaction.TransactionSystemException: Could not initialize WebLogicJtaTransactionManager because WebLogic API classes are not available; nested exception is java.lang.ClassNotFoundException: weblogic.transaction.UserTransaction.). Do you think that your fix below is something that could be patched into 1.1.5? I'll do it, but I don't want to waste my time if you don't think that it is a good idea. Thanks, Dave Juergen Hoeller wrote: >Hi Dave, > >I've just verified that your scenario can indeed lead to broken cleanup: > >If the rollback gets triggered from some other thread (i.e. not the thread >that created the transaction), the Hibernate SessionHolder cannot get >removed from the original thread. That is actually already expected, as it >can also happen in case of remote transaction propagation: Spring will >simply remove the current Hibernate Session from the SessionHolder in this >case, and reuse the SessionHolder when another transaction gets executed on >that thread. > >However, the above only works with direct JTA Session synchronization only. >If Spring transaction synchronization is involved too (that is, if >transactions get initiated from either EJB CMT or Spring transaction >demarcation, not just from EJB CMT), an IllegalStateException will be thrown >whenever a thread with such an empty SessionHolder is supposed to execute a >Spring-driven transaction. This is straightforward to reproduce in a test >case. > >I've just fixed this issue for both Hibernate 2.1 and Hibernate3, to be >committed today. The fix should be available in the next nightly build, and >will be released in Spring 1.2.1. > >Note that it's generally recommended to use *either* EJB CMT *or* >Spring-driven transactions. Spring's Session synchronization for Hibernate >will work nicely with EJB CMT only, without any Spring transaction >demarcation involved. Mixing both is nevertheless valid, therefore the above >fix is necessary. > >Thanks for reporting this! > >Juergen > > >-----Original Message----- >From: spr...@li... >[mailto:spr...@li...]On Behalf >Of Dave Ballard >Sent: Wednesday, May 18, 2005 10:41 PM >To: spr...@li... >Subject: Re: [Springframework-developer] Race condition with transaction >synchronization? > > >Hello, > >Sorry to respond to my own post, but if there's someone out there that >is familiar with SessionFactoryUtils, I would appreciate a little of >your time to discuss this issue. This appears to be a bug in the JTA >session synchronization code for hibernate. > >Thanks, >Dave > >Dave Ballard wrote: > > > >>Hello, >> >>I posted this on the forums, but costin and Rod suggested that I post >>it here. >> >>I'm using Spring Framework 1.1.5 with Hibernate on WebLogic Server >>6.1. I'm testing timeout scenarios, and I've run into an issue I need >>some help with. I'm slowly eliminating EJB's from my application, but >>I do have some legacy EJB code to deal with. In my scenario, my >>servlet is calling a SLSB, which in turn calls spring-managed >>transactional services. These transaction service join the CMT >>transaction created by the EJB container. I have: >> >>Code: >> >>1) A servlet calls SLSB with CMT. >>2) The SLSB calls SessionFactoryUtils.getSession(sessionFactory, true) >>-- This binds the hibernate session to the current thread >>3) The SLSB calls a spring-managed transactional service >>-- This bean uses the bound session as expected >>4) The SLSB calls another spring-managed transactional service >>-- This bean uses the bound session as expected >>5) The SLSB exits >>-- The TransactionSynchronizationManager unbinds the bound session as >>expected >> >> >>So the non-timeout scenario functions as expected. Now I introduce a >>timeout (by causing blocking in by database) prior to (3). With the >>timeout scenario, I encounter one of two results: >> >>Code: >> >>A) A spring HibernateJdbcException wrapping a weblogic >>TimedOutException as expected. >>B) An IllegalStateException Already value >>[org.springframework.orm.hibernate.SessionHolder@6f2304] for key >>[net.sf.hibernate.impl.SessionFactoryImpl@655ad0] bound to thread >>[ExecuteThread: '29' for queue: 'default'] >> >> >>Whether I get (A) or (B) is seemingly random. I've created a >>diagnostic version of SessionFactoryUtils to see what is happening in >>more detail. >>In scenario (B), it looks like WebLogic's transaction manager is >>grabbing another thread from the pool and is invoking spring's >>JtaSessionSynchronization.afterCompletion() which is resulting in >>doClose() being called. I've added a dumpStack() in doClose(), and >>here is what I see. The line numbers will be a little off because of >>my diagnostic code: >> >>Code: >> >>java.lang.Exception: Stack trace >> at java.lang.Thread.dumpStack(Thread.java:992) >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils.doClose(SessionFactory >Utils.java:738) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils.closeSessionOrRegister >DeferredClose(SessionFactoryUtils.java:726) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils.access$300(SessionFact >oryUtils.java:89) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils$SpringSessionSynchroni >zation.beforeCompletion(SessionFactoryUtils.java:867) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils$JtaSessionSynchronizat >ion.afterCompletion(SessionFactoryUtils.java:978) > > >> at >> >> >> >weblogic.transaction.internal.ServerSCInfo.callAfterCompletions(ServerSCInfo >.java:464) > > >> at >> >> >> >weblogic.transaction.internal.ServerTransactionImpl.callAfterCompletions(Ser >verTransactionImpl.java:2139) > > >> at >> >> >> >weblogic.transaction.internal.ServerTransactionImpl.setRolledBack(ServerTran >sactionImpl.java:2090) > > >> at >> >> >> >weblogic.transaction.internal.ServerTransactionImpl.globalRetryRollback(Serv >erTransactionImpl.java:2188)DEBUG > > >>18:19:23,000 [ExecuteThread: '34' for queue: 'default'] [edemo_acme] >>(Transacti >> at >> >> >> >weblogic.transaction.internal.ServerTransactionImpl.globalRollback(ServerTra >nsactionImpl.java:2080) > > >> at >> >> >> >weblogic.transaction.internal.TransactionImpl$1.execute(TransactionImpl.java >:1617) > > >> at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:159) >> at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:140) >> >> >>Meanwhile, the original timeout thread, who is in the middle of >>calling getSession(), and hasn't yet encountered the weblogic >>TimedOutException, >>tries to bind the session holder to the thread, and fails: >> >>Code: >> >>ERROR 18:19:23,046 [ExecuteThread: '34' for queue: 'default'] >>[edemo_acme] (TransactionAspectSupport.java:264) - Application >>exception overridden by rollback exception >>java.lang.IllegalStateException: Already value >>[org.springframework.orm.hibernate.SessionHolder@747db9] for key >>[net.sf.hibernate.impl.SessionFactoryImpl@606e55] bound to thread >>[ExecuteThread: '34' for queue: 'default'] >> at >> >> >> >org.springframework.transaction.support.TransactionSynchronizationManager.bi >ndResource(TransactionSynchronizationManager.java:147) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils.getSession(SessionFact >oryUtils.java:346) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils.getSession(SessionFact >oryUtils.java:266) > > >> at >> >> >> >org.springframework.orm.hibernate.SessionFactoryUtils.getSession(SessionFact >oryUtils.java:223) > > >> at >> >> >> >org.springframework.orm.hibernate.HibernateInterceptor.invoke(HibernateInter >ceptor.java:149) > > >> at >> >> >> >org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(Reflect >iveMethodInvocation.java:144) > > >> at >> >> >> >org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopPro >xy.java:174) > > >> at $Proxy93.findContract(Unknown Source) >> at >>mycode.ContractServiceImpl.findContract(ContractServiceImpl.java:59) >> ... >> >> >>It's not clear to me who the culprit is here, not being that familiar >>with JTA and Spring. Perhaps the beforeCompletion() called by the >>weblogic transaction manager is not cleaning up properly? Any ideas? >> >>Thanks for your help, >>Dave >> >> >>------------------------------------------------------- >>This SF.Net email is sponsored by Oracle Space Sweepstakes >>Want to be the first software developer in space? >>Enter now for the Oracle Space Sweepstakes! >>http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click >>_______________________________________________ >>Springframework-developer mailing list >>Spr...@li... >>https://lists.sourceforge.net/lists/listinfo/springframework-developer >> >> >> >> > > >------------------------------------------------------- >This SF.Net email is sponsored by Oracle Space Sweepstakes >Want to be the first software developer in space? >Enter now for the Oracle Space Sweepstakes! >http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click >_______________________________________________ >Springframework-developer mailing list >Spr...@li... >https://lists.sourceforge.net/lists/listinfo/springframework-developer > > > >------------------------------------------------------- >This SF.Net email is sponsored by Oracle Space Sweepstakes >Want to be the first software developer in space? >Enter now for the Oracle Space Sweepstakes! >http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click >_______________________________________________ >Springframework-developer mailing list >Spr...@li... >https://lists.sourceforge.net/lists/listinfo/springframework-developer > > > > |
|
From: Darren D. <da...@sh...> - 2005-05-19 22:22:59
|
1116541377
FAILED
[junit] Testcase: testProxiedUserInterfacesWithMultipleInterfaces took 0.141 sec
[junit] Testcase: testProxiedUserInterfacesWithNoInterface took 0.008 sec
[junit] Tests run: 15, Failures: 1, Errors: 0, Time elapsed: 33.172 sec
[junit] Testsuite: org.springframework.aop.framework.CglibProxyTests
[junit] Tests run: 15, Failures: 1, Errors: 0, Time elapsed: 33.172 sec
[junit] ------------- Standard Output ---------------
[junit] StopWatch '': running time (millis) = 20569
[junit] [class org.springframework.aop.framework.CglibProxyTests.testManyProxies: create 10000 proxies] took 20569=100%
[junit] ------------- ---------------- ---------------
[junit] Testcase: testNullConfig took 0.295 sec
[junit] Testcase: testNoTarget took 0.033 sec
[junit] Testcase: testProtectedMethodInvocation took 1.642 sec
[junit] Testcase: testProxyCanBeClassNotInterface took 1.255 sec
[junit] Testcase: testCglibProxyingGivesMeaningfulExceptionIfAskedToProxyNonvisibleClass took 0.054 sec
[junit] Testcase: testMethodInvocationDuringConstructor took 0.397 sec
[junit] Testcase: testUnadvisedProxyCreationWithCallDuringConstructor took 0.314 sec
[junit] Testcase: testMultipleProxies took 1.82 sec
[junit] Testcase: testWithNoArgConstructor took 0.353 sec
[junit] Testcase: testProxyAProxy took 0.742 sec
[junit] Testcase: testExceptionHandling took 0.466 sec
[junit] Testcase: testWithDependencyChecking took 4.768 sec
[junit] Testcase: testNoInterceptorsAndNoTarget took 0.001 sec
[junit] Testcase: testValuesStick took 0.169 sec
[junit] Testcase: testManyProxies took 20.783 sec
[junit] FAILED
[junit] Proxy creation was too slow
[junit] junit.framework.AssertionFailedError: Proxy creation was too slow
[junit] at org.springframework.aop.framework.AbstractAopProxyTests.testManyProxies(AbstractAopProxyTests.java:147)
This is an automated mail from one of the SF Compile Farm machines.
The machine name noted in the subject encountered a failure building
or running the Spring test suite. The last few lines of the output
were included for info.
NB: No further mail will be sent from this machine until a
manual reset occurs on the cf-shell machine, although builds will
continue as scheduled.
See http://springframework.sourceforge.net/test/ for further
information.
|
|
From: <al...@in...> - 2005-05-19 22:21:47
|
View results here -> http://opensource.jteam.nl/build/buildresults/spring?log=log20050520001619 |
|
From: Tim K. <tim...@vi...> - 2005-05-19 21:21:13
|
Hi, I was looking into integrating lookup-method in my context, and I was using the reference found here: http://static.springframework.org/spring/docs/1.2/reference/beans.html#beans -factory-method-injection After much tussling around with some weird XML error, and looking at some other examples pasted in the forums, I moved the <lookup-method> tag to appear after the <property> tags, and it all worked after that. So I think the example in the reference is misleading, since it places the <lookup-method> tag before the <property> tag, which apparently does not work for me (in Spring 1.2). So, does the order matter? If so, the reference example should be updated and the text to clearly state in what order it should appear in the <bean> declaration. Thanks. -tim |
|
From: <jm...@ch...> - 2005-05-19 21:05:06
|
Following the advice from Rod at: http://forum.springframework.org/viewtopic.php?t=3957 I have started work on implementing support for torque in Spring. Following the pattern of what is out there already i have created stubbed out classes for 2 packages: org.springframework.orm.torque -TorqueAccessor -TorqueCallback -TorqueOperations -TorqueJDBCException -TorqueTemplate org.springframework.orm.torque.support -TorqueDaoSupport Following the current design patterns in the other Spring ORM implementations, i coded the TorqueOperations interface. The methods defined in it are the methods that Torque makes available to it's persistence classes defined in org.apache.torque.util.BasePeer. In the template i plan to delegate the calls into template methods to a BasePeer object (POJO with all static methods). Something like this: Code: public List doSelect(org.apache.torque.util.Criteria criteria) throws DataAccessException { List returnList = null; try { returnList = this.getTorqueBasePeer().doSelect(criteria); } catch (TorqueException e) { convertTorqueAccessException(e); } return returnList; } Is this a correct approach? Is there any place i can share this code with others that are interested? -jm |
|
From: Craig W. <cr...@ha...> - 2005-05-19 17:25:53
|
> i'm more then willing to submit patches if someone could provide some > overall guidence on how they would like to see things evolve. I've got some ideas, but I'll leave it to others to provide their ideas as well. > which jira system should these ideas/patches be submitted too? spring > or > xdoclet? Definitely the XDoclet JIRA, as the module is an XDoclet module. Furthermore, many in the Spring camp are disinterested (or even dead-set against) the Spring XDoclet module. > > -- > -jae > > -----Original Message----- > From: spr...@li... > [mailto:spr...@li...] On Behalf > Of Craig Walls > Sent: Thursday, May 19, 2005 12:31 PM > To: spr...@li... > Subject: Re: [Springframework-developer] spring xdoclet module > > > I initially added the Spring tags. What's there is the result of what I > was using on a project, but nothing else. It has been my intent to go > back and look for opportunities to enhance it, but I simply haven't had > the time. > > I think that there's a lot of opportunity here, especially WRT to > creating tags for controllers. I'm thinking that instead of using > @spring.bean to declare a controller, you might have @spring.controller > which abstracts away all of the stuff that goes along with a controller. > Likewise, you've identified some opportunities with remoting. > > All of this is good stuff, but as I mentioned, my other priorities have > prevented me from revisiting this stuff. You should certainly feel free > to submit enhancement ideas in JIRA and perhaps someone could get around > to implementing your ideas. Or you could even submit patches. > >> >> are there any plans to add further enhancements to the xdoclet >> module for spring? is it even "maintained" by anyone involved directly >> w/ spring? >> >> i feel that the @spring.bean tag is somewhat limiting because it >> does not let me define a class name, and instead just assumes that it >> should create an entry for that class. while this is true most of the >> time, in instances where i might be using a MultiActionController, >> it'd be nice if i could specify the MethodNameResolver configuration >> in the same class since the two are directly related. >> >> there are also other minor additions, such as being able to generate >> >> remote interfaces from business interfaces when using remoting (i >> already achieve this through a simple doclet template), creating >> "standard" tags for some bean definitions (ie: jaxrpc proxy) that i >> feel would be great additions. is anyone else interested in these >> types of enhancements? >> >> -- >> -jae > > > > > > ------------------------------------------------------- > This SF.Net email is sponsored by Oracle Space Sweepstakes Want to be > the first software developer in space? > Enter now for the Oracle Space Sweepstakes! > http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click > _______________________________________________ > Springframework-developer mailing list > Spr...@li... > https://lists.sourceforge.net/lists/listinfo/springframework-developer > > > > ------------------------------------------------------- > This SF.Net email is sponsored by Oracle Space Sweepstakes > Want to be the first software developer in space? > Enter now for the Oracle Space Sweepstakes! > http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click > _______________________________________________ > Springframework-developer mailing list > Spr...@li... > https://lists.sourceforge.net/lists/listinfo/springframework-developer |
|
From: Jae G. <ja...@gn...> - 2005-05-19 16:44:18
|
i'm more then willing to submit patches if someone could provide some overall guidence on how they would like to see things evolve. which jira system should these ideas/patches be submitted too? spring or xdoclet? -- -jae -----Original Message----- From: spr...@li... [mailto:spr...@li...] On Behalf Of Craig Walls Sent: Thursday, May 19, 2005 12:31 PM To: spr...@li... Subject: Re: [Springframework-developer] spring xdoclet module I initially added the Spring tags. What's there is the result of what I was using on a project, but nothing else. It has been my intent to go back and look for opportunities to enhance it, but I simply haven't had the time. I think that there's a lot of opportunity here, especially WRT to creating tags for controllers. I'm thinking that instead of using @spring.bean to declare a controller, you might have @spring.controller which abstracts away all of the stuff that goes along with a controller. Likewise, you've identified some opportunities with remoting. All of this is good stuff, but as I mentioned, my other priorities have prevented me from revisiting this stuff. You should certainly feel free to submit enhancement ideas in JIRA and perhaps someone could get around to implementing your ideas. Or you could even submit patches. > > are there any plans to add further enhancements to the xdoclet > module for spring? is it even "maintained" by anyone involved directly > w/ spring? > > i feel that the @spring.bean tag is somewhat limiting because it > does not let me define a class name, and instead just assumes that it > should create an entry for that class. while this is true most of the > time, in instances where i might be using a MultiActionController, > it'd be nice if i could specify the MethodNameResolver configuration > in the same class since the two are directly related. > > there are also other minor additions, such as being able to generate > remote interfaces from business interfaces when using remoting (i > already achieve this through a simple doclet template), creating > "standard" tags for some bean definitions (ie: jaxrpc proxy) that i > feel would be great additions. is anyone else interested in these > types of enhancements? > > -- > -jae ------------------------------------------------------- This SF.Net email is sponsored by Oracle Space Sweepstakes Want to be the first software developer in space? Enter now for the Oracle Space Sweepstakes! http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click _______________________________________________ Springframework-developer mailing list Spr...@li... https://lists.sourceforge.net/lists/listinfo/springframework-developer |
|
From: Craig W. <cr...@ha...> - 2005-05-19 16:31:30
|
I initially added the Spring tags. What's there is the result of what I was using on a project, but nothing else. It has been my intent to go back and look for opportunities to enhance it, but I simply haven't had the time. I think that there's a lot of opportunity here, especially WRT to creating tags for controllers. I'm thinking that instead of using @spring.bean to declare a controller, you might have @spring.controller which abstracts away all of the stuff that goes along with a controller. Likewise, you've identified some opportunities with remoting. All of this is good stuff, but as I mentioned, my other priorities have prevented me from revisiting this stuff. You should certainly feel free to submit enhancement ideas in JIRA and perhaps someone could get around to implementing your ideas. Or you could even submit patches. > > are there any plans to add further enhancements to the xdoclet module > for > spring? is it even "maintained" by anyone involved directly w/ spring? > > i feel that the @spring.bean tag is somewhat limiting because it does > not > let me define a class name, and instead just assumes that it should > create an entry for that class. while this is true most of the time, in > instances where i might be using a MultiActionController, it'd be nice > if i could specify the MethodNameResolver configuration in the same > class since the two are directly related. > > there are also other minor additions, such as being able to generate > remote interfaces from business interfaces when using remoting (i > already achieve this through a simple doclet template), creating > "standard" tags for some bean definitions (ie: jaxrpc proxy) that i > feel would be great additions. is anyone else interested in these types > of enhancements? > > -- > -jae |
|
From: Steven D. <ste...@gm...> - 2005-05-19 15:40:47
|
Hi all,
I'm working on a bean factory language parser for Spring. This is an
example of the syntax:
abstractDataSource =3D new abstract
org.springframework.jdbc.datasource.DriverManagerDataSource;
abstractDataSource.driverClassName =3D 'org.hsqldb.jdbcDriver';
abstractDataSource.url =3D 'jdbc:hsqldb:hsql://localhost:';
abstractDataSource.username =3D 'sa';
abstractDataSource.password =3D '';
dataSource =3D new child of abstractDataSource;
sessionFactory =3D new org.springframework.orm.hibernate.LocalSessionFactor=
yBean;
sessionFactory.dataSource =3D dataSource;
sessionFactory.mappingResources =3D [ 'domain.hbm.xml' ];
sessionFactory.hibernateProperties =3D { 'hibernate.dialect' ->
'sf.hibernate.dialect.HSQLDialect' };
transactionManager =3D new
org.springframework.orm.hibernate.HibernateTransactionManager;
transactionManager.sessionFactory =3D sessionFactory;
transactionAttributes =3D new java.util.Properties({ '*' ->
'PROPAGATION_REQUIRED' });
The currently state of the parser can parse the example above being
the common Spring bean factory constructs. More advanced constructs
still need to be implemented like method replacement, static method
invocation, init and destroy methods, ... . I also have some
additional features in mind, functions being one example:
myProxy =3D proxy(myTarget, [ interceptor1, interceptor2 ]);
myDao =3D transactionProxy(target, transactionManager, { '*' ->
'PROPAGATION_REQUIRED });
The parser converts the syntax to a number of objects that need to be
converted somehow to an application context. This would require some
form of programmatic configuration of the application context. It's my
understanding this currently is not available, as discussed in this
post on the forum:
http://forum.springframework.org/viewtopic.php?t=3D5018
Currently I have two options to go ahead:
1) generate an xml syntax based on the parser syntax.
2) update/finish/improve/copycat the existing code in the sandbox or
any other code base and as such attempt to create a solid programmatic
configuration feature.
My personal preference is to go for the programmatic configuration
feature. Alas, I'm afraid I'm going to require the endorsement of the
Spring team to take up such a task. I've already looked at the code in
the sandbox and there's too many question marks in the comments to
make this feel like a strawl in the park.
Steven
--=20
"If you want to be a different fish, you gotta jump out of the school."
-- Captain Beefheart
|
|
From: Jae G. <ja...@gn...> - 2005-05-19 15:40:32
|
are there any plans to add further enhancements to the xdoclet module for spring? is it even "maintained" by anyone involved directly w/ spring? i feel that the @spring.bean tag is somewhat limiting because it does not let me define a class name, and instead just assumes that it should create an entry for that class. while this is true most of the time, in instances where i might be using a MultiActionController, it'd be nice if i could specify the MethodNameResolver configuration in the same class since the two are directly related. there are also other minor additions, such as being able to generate remote interfaces from business interfaces when using remoting (i already achieve this through a simple doclet template), creating "standard" tags for some bean definitions (ie: jaxrpc proxy) that i feel would be great additions. is anyone else interested in these types of enhancements? -- -jae |
|
From: <jo...@in...> - 2005-05-19 14:05:34
|
Thank you for contacting Inventum. We will respond to your email at the earliest. (Please do not respond to this auto-generated message) Best Regards, Inventum HR http://www.inventum.cc |
|
From: Juergen H. <ju...@in...> - 2005-05-19 06:34:25
|
Hi Dave, I've just verified that your scenario can indeed lead to broken cleanup: If the rollback gets triggered from some other thread (i.e. not the thread that created the transaction), the Hibernate SessionHolder cannot get removed from the original thread. That is actually already expected, as it can also happen in case of remote transaction propagation: Spring will simply remove the current Hibernate Session from the SessionHolder in this case, and reuse the SessionHolder when another transaction gets executed on that thread. However, the above only works with direct JTA Session synchronization only. If Spring transaction synchronization is involved too (that is, if transactions get initiated from either EJB CMT or Spring transaction demarcation, not just from EJB CMT), an IllegalStateException will be thrown whenever a thread with such an empty SessionHolder is supposed to execute a Spring-driven transaction. This is straightforward to reproduce in a test case. I've just fixed this issue for both Hibernate 2.1 and Hibernate3, to be committed today. The fix should be available in the next nightly build, and will be released in Spring 1.2.1. Note that it's generally recommended to use *either* EJB CMT *or* Spring-driven transactions. Spring's Session synchronization for Hibernate will work nicely with EJB CMT only, without any Spring transaction demarcation involved. Mixing both is nevertheless valid, therefore the above fix is necessary. Thanks for reporting this! Juergen -----Original Message----- From: spr...@li... [mailto:spr...@li...]On Behalf Of Dave Ballard Sent: Wednesday, May 18, 2005 10:41 PM To: spr...@li... Subject: Re: [Springframework-developer] Race condition with transaction synchronization? Hello, Sorry to respond to my own post, but if there's someone out there that is familiar with SessionFactoryUtils, I would appreciate a little of your time to discuss this issue. This appears to be a bug in the JTA session synchronization code for hibernate. Thanks, Dave Dave Ballard wrote: > Hello, > > I posted this on the forums, but costin and Rod suggested that I post > it here. > > I'm using Spring Framework 1.1.5 with Hibernate on WebLogic Server > 6.1. I'm testing timeout scenarios, and I've run into an issue I need > some help with. I'm slowly eliminating EJB's from my application, but > I do have some legacy EJB code to deal with. In my scenario, my > servlet is calling a SLSB, which in turn calls spring-managed > transactional services. These transaction service join the CMT > transaction created by the EJB container. I have: > > Code: > > 1) A servlet calls SLSB with CMT. > 2) The SLSB calls SessionFactoryUtils.getSession(sessionFactory, true) > -- This binds the hibernate session to the current thread > 3) The SLSB calls a spring-managed transactional service > -- This bean uses the bound session as expected > 4) The SLSB calls another spring-managed transactional service > -- This bean uses the bound session as expected > 5) The SLSB exits > -- The TransactionSynchronizationManager unbinds the bound session as > expected > > > So the non-timeout scenario functions as expected. Now I introduce a > timeout (by causing blocking in by database) prior to (3). With the > timeout scenario, I encounter one of two results: > > Code: > > A) A spring HibernateJdbcException wrapping a weblogic > TimedOutException as expected. > B) An IllegalStateException Already value > [org.springframework.orm.hibernate.SessionHolder@6f2304] for key > [net.sf.hibernate.impl.SessionFactoryImpl@655ad0] bound to thread > [ExecuteThread: '29' for queue: 'default'] > > > Whether I get (A) or (B) is seemingly random. I've created a > diagnostic version of SessionFactoryUtils to see what is happening in > more detail. > In scenario (B), it looks like WebLogic's transaction manager is > grabbing another thread from the pool and is invoking spring's > JtaSessionSynchronization.afterCompletion() which is resulting in > doClose() being called. I've added a dumpStack() in doClose(), and > here is what I see. The line numbers will be a little off because of > my diagnostic code: > > Code: > > java.lang.Exception: Stack trace > at java.lang.Thread.dumpStack(Thread.java:992) > at > org.springframework.orm.hibernate.SessionFactoryUtils.doClose(SessionFactory Utils.java:738) > > at > org.springframework.orm.hibernate.SessionFactoryUtils.closeSessionOrRegister DeferredClose(SessionFactoryUtils.java:726) > > at > org.springframework.orm.hibernate.SessionFactoryUtils.access$300(SessionFact oryUtils.java:89) > > at > org.springframework.orm.hibernate.SessionFactoryUtils$SpringSessionSynchroni zation.beforeCompletion(SessionFactoryUtils.java:867) > > at > org.springframework.orm.hibernate.SessionFactoryUtils$JtaSessionSynchronizat ion.afterCompletion(SessionFactoryUtils.java:978) > > at > weblogic.transaction.internal.ServerSCInfo.callAfterCompletions(ServerSCInfo .java:464) > > at > weblogic.transaction.internal.ServerTransactionImpl.callAfterCompletions(Ser verTransactionImpl.java:2139) > > at > weblogic.transaction.internal.ServerTransactionImpl.setRolledBack(ServerTran sactionImpl.java:2090) > > at > weblogic.transaction.internal.ServerTransactionImpl.globalRetryRollback(Serv erTransactionImpl.java:2188)DEBUG > 18:19:23,000 [ExecuteThread: '34' for queue: 'default'] [edemo_acme] > (Transacti > at > weblogic.transaction.internal.ServerTransactionImpl.globalRollback(ServerTra nsactionImpl.java:2080) > > at > weblogic.transaction.internal.TransactionImpl$1.execute(TransactionImpl.java :1617) > > at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:159) > at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:140) > > > Meanwhile, the original timeout thread, who is in the middle of > calling getSession(), and hasn't yet encountered the weblogic > TimedOutException, > tries to bind the session holder to the thread, and fails: > > Code: > > ERROR 18:19:23,046 [ExecuteThread: '34' for queue: 'default'] > [edemo_acme] (TransactionAspectSupport.java:264) - Application > exception overridden by rollback exception > java.lang.IllegalStateException: Already value > [org.springframework.orm.hibernate.SessionHolder@747db9] for key > [net.sf.hibernate.impl.SessionFactoryImpl@606e55] bound to thread > [ExecuteThread: '34' for queue: 'default'] > at > org.springframework.transaction.support.TransactionSynchronizationManager.bi ndResource(TransactionSynchronizationManager.java:147) > > at > org.springframework.orm.hibernate.SessionFactoryUtils.getSession(SessionFact oryUtils.java:346) > > at > org.springframework.orm.hibernate.SessionFactoryUtils.getSession(SessionFact oryUtils.java:266) > > at > org.springframework.orm.hibernate.SessionFactoryUtils.getSession(SessionFact oryUtils.java:223) > > at > org.springframework.orm.hibernate.HibernateInterceptor.invoke(HibernateInter ceptor.java:149) > > at > org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(Reflect iveMethodInvocation.java:144) > > at > org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopPro xy.java:174) > > at $Proxy93.findContract(Unknown Source) > at > mycode.ContractServiceImpl.findContract(ContractServiceImpl.java:59) > ... > > > It's not clear to me who the culprit is here, not being that familiar > with JTA and Spring. Perhaps the beforeCompletion() called by the > weblogic transaction manager is not cleaning up properly? Any ideas? > > Thanks for your help, > Dave > > > ------------------------------------------------------- > This SF.Net email is sponsored by Oracle Space Sweepstakes > Want to be the first software developer in space? > Enter now for the Oracle Space Sweepstakes! > http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click > _______________________________________________ > Springframework-developer mailing list > Spr...@li... > https://lists.sourceforge.net/lists/listinfo/springframework-developer > > ------------------------------------------------------- This SF.Net email is sponsored by Oracle Space Sweepstakes Want to be the first software developer in space? Enter now for the Oracle Space Sweepstakes! http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click _______________________________________________ Springframework-developer mailing list Spr...@li... https://lists.sourceforge.net/lists/listinfo/springframework-developer |
|
From: <al...@in...> - 2005-05-18 22:35:12
|
View results here -> http://opensource.jteam.nl/build/buildresults/spring?log=log20050519001558Lbuild.264 |
|
From: Dave B. <dba...@on...> - 2005-05-18 20:38:52
|
Hello, Sorry to respond to my own post, but if there's someone out there that is familiar with SessionFactoryUtils, I would appreciate a little of your time to discuss this issue. This appears to be a bug in the JTA session synchronization code for hibernate. Thanks, Dave Dave Ballard wrote: > Hello, > > I posted this on the forums, but costin and Rod suggested that I post > it here. > > I'm using Spring Framework 1.1.5 with Hibernate on WebLogic Server > 6.1. I'm testing timeout scenarios, and I've run into an issue I need > some help with. I'm slowly eliminating EJB's from my application, but > I do have some legacy EJB code to deal with. In my scenario, my > servlet is calling a SLSB, which in turn calls spring-managed > transactional services. These transaction service join the CMT > transaction created by the EJB container. I have: > > Code: > > 1) A servlet calls SLSB with CMT. > 2) The SLSB calls SessionFactoryUtils.getSession(sessionFactory, true) > -- This binds the hibernate session to the current thread > 3) The SLSB calls a spring-managed transactional service > -- This bean uses the bound session as expected > 4) The SLSB calls another spring-managed transactional service > -- This bean uses the bound session as expected > 5) The SLSB exits > -- The TransactionSynchronizationManager unbinds the bound session as > expected > > > So the non-timeout scenario functions as expected. Now I introduce a > timeout (by causing blocking in by database) prior to (3). With the > timeout scenario, I encounter one of two results: > > Code: > > A) A spring HibernateJdbcException wrapping a weblogic > TimedOutException as expected. > B) An IllegalStateException Already value > [org.springframework.orm.hibernate.SessionHolder@6f2304] for key > [net.sf.hibernate.impl.SessionFactoryImpl@655ad0] bound to thread > [ExecuteThread: '29' for queue: 'default'] > > > Whether I get (A) or (B) is seemingly random. I've created a > diagnostic version of SessionFactoryUtils to see what is happening in > more detail. > In scenario (B), it looks like WebLogic's transaction manager is > grabbing another thread from the pool and is invoking spring's > JtaSessionSynchronization.afterCompletion() which is resulting in > doClose() being called. I've added a dumpStack() in doClose(), and > here is what I see. The line numbers will be a little off because of > my diagnostic code: > > Code: > > java.lang.Exception: Stack trace > at java.lang.Thread.dumpStack(Thread.java:992) > at > org.springframework.orm.hibernate.SessionFactoryUtils.doClose(SessionFactoryUtils.java:738) > > at > org.springframework.orm.hibernate.SessionFactoryUtils.closeSessionOrRegisterDeferredClose(SessionFactoryUtils.java:726) > > at > org.springframework.orm.hibernate.SessionFactoryUtils.access$300(SessionFactoryUtils.java:89) > > at > org.springframework.orm.hibernate.SessionFactoryUtils$SpringSessionSynchronization.beforeCompletion(SessionFactoryUtils.java:867) > > at > org.springframework.orm.hibernate.SessionFactoryUtils$JtaSessionSynchronization.afterCompletion(SessionFactoryUtils.java:978) > > at > weblogic.transaction.internal.ServerSCInfo.callAfterCompletions(ServerSCInfo.java:464) > > at > weblogic.transaction.internal.ServerTransactionImpl.callAfterCompletions(ServerTransactionImpl.java:2139) > > at > weblogic.transaction.internal.ServerTransactionImpl.setRolledBack(ServerTransactionImpl.java:2090) > > at > weblogic.transaction.internal.ServerTransactionImpl.globalRetryRollback(ServerTransactionImpl.java:2188)DEBUG > 18:19:23,000 [ExecuteThread: '34' for queue: 'default'] [edemo_acme] > (Transacti > at > weblogic.transaction.internal.ServerTransactionImpl.globalRollback(ServerTransactionImpl.java:2080) > > at > weblogic.transaction.internal.TransactionImpl$1.execute(TransactionImpl.java:1617) > > at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:159) > at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:140) > > > Meanwhile, the original timeout thread, who is in the middle of > calling getSession(), and hasn't yet encountered the weblogic > TimedOutException, > tries to bind the session holder to the thread, and fails: > > Code: > > ERROR 18:19:23,046 [ExecuteThread: '34' for queue: 'default'] > [edemo_acme] (TransactionAspectSupport.java:264) - Application > exception overridden by rollback exception > java.lang.IllegalStateException: Already value > [org.springframework.orm.hibernate.SessionHolder@747db9] for key > [net.sf.hibernate.impl.SessionFactoryImpl@606e55] bound to thread > [ExecuteThread: '34' for queue: 'default'] > at > org.springframework.transaction.support.TransactionSynchronizationManager.bindResource(TransactionSynchronizationManager.java:147) > > at > org.springframework.orm.hibernate.SessionFactoryUtils.getSession(SessionFactoryUtils.java:346) > > at > org.springframework.orm.hibernate.SessionFactoryUtils.getSession(SessionFactoryUtils.java:266) > > at > org.springframework.orm.hibernate.SessionFactoryUtils.getSession(SessionFactoryUtils.java:223) > > at > org.springframework.orm.hibernate.HibernateInterceptor.invoke(HibernateInterceptor.java:149) > > at > org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:144) > > at > org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:174) > > at $Proxy93.findContract(Unknown Source) > at > mycode.ContractServiceImpl.findContract(ContractServiceImpl.java:59) > ... > > > It's not clear to me who the culprit is here, not being that familiar > with JTA and Spring. Perhaps the beforeCompletion() called by the > weblogic transaction manager is not cleaning up properly? Any ideas? > > Thanks for your help, > Dave > > > ------------------------------------------------------- > This SF.Net email is sponsored by Oracle Space Sweepstakes > Want to be the first software developer in space? > Enter now for the Oracle Space Sweepstakes! > http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click > _______________________________________________ > Springframework-developer mailing list > Spr...@li... > https://lists.sourceforge.net/lists/listinfo/springframework-developer > > |
|
From: John L. <jl...@ar...> - 2005-05-18 18:05:13
|
Tim, What you are looking for is a way to map requests to a variety of different controllers all within a single portlet. This is easily done, although there is not yet a standard class available for doing this in Spring Portlet MVC. You need a class that decends from AbstractPortletControllerMapping to do this. At least three of us have independently developed our own version of an "action" based mapping class that lets you declare a request parameter that indicates which controller you want to end up in. We will work on a unified one that should become part of Portlet MVC soon. In the mean time, send me an email directly at jl...@ar... and I will send you something you can use in the meantime. Also, make sure you look at the enhanced classes already available on the Wiki site for a more complete set of controller options: http://opensource.atlassian.com/confluence/spring/display/JSR168/ John Lewis > -----Original Message----- > From: spr...@li... > [mailto:spr...@li...] On Behalf > Of Tim Kettering > Sent: Tuesday, May 17, 2005 4:00 PM > To: spr...@li... > Subject: [Springframework-developer] Support for state/controller > chaining in Portlets? (not quite webflow) > > > Hi everyone, > > I'm just throwing this out here to see what other people have to say. I > can see from the list that there are a few developers actively working > on portal solutions using Spring MVC. We are starting on our first > project using this as well, and one of the issues I'm trying to figure > out now is the matter of maintaining state in a portlet. > > > In a typical CRUD example, if we have a portlet to display, edit and > maange information about a certain object, like a Book. We'd have view, > edit and delete functionality for example. > > > In a typical non-portlet webapp, we could easily split those up across > different servlets for fine-grained areas of responsibility. > > > But it's not as simple with portlets, because there are limitations on > what can be done, and essentially, all requests would need to go thru a > single portlet configuration. > > > So, it no longer become sufficient to configure a simple portlet > controller for a portlet. There needs to be a way to maintain state and > to delegate the request/response process to different types of > controllers depending on the state. Like a View page would need to go > thru a derivation of BaseCommandController, an Edit page would go thru > SimpleFormController. > > > And not to mention adding yet another dimension when considering portlet > modes as well! > > This article at IBM Developerworks pretty much covers the same issue I > am bringing up: > > http://www-106.ibm.com/developerworks/websphere/library/techarticles/031 > 2_ha > nis/hanis1.html > > I did look at Spring's WebFlow a few days ago to see if it could address > our issue, but in the Webflow FAQ, it pretty much states that WebFlow > should not be used in cases where the user will be using back-button, or > indeterminate actions not within a strict flow. > > > So that kinda leaves me back at square one. After some discussion with > my co-worker, I would imagine that this is a common problem for any > Spring portlet developer creating more than just simple portlet > functionality. And that as Spring portlet support matures, this will be > a more common issue for everyone. Hence this email to the list. > > > I'm now wondering how some of you have addressed this problem, and > whether there is a need for Spring's portlet support, to be in Spring > 1.3 to include some way to configure and facilitate a state process, > maybe even based on WebFlow's state machine - although I have only given > WebFlow's state functionality a brief look. > > Thanks in advance, > > -tim > > > > ------------------------------------------------------- > This SF.Net email is sponsored by Oracle Space Sweepstakes Want to be > the first software developer in space? > Enter now for the Oracle Space Sweepstakes! > http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click > _______________________________________________ > Springframework-developer mailing list > Spr...@li... > https://lists.sourceforge.net/lists/listinfo/springframework-developer > > > This message is a PRIVATE communication. > If you are not the intended recipient, please do not read, copy, > or use it, and do not disclose it to others. Please notify the > sender of the delivery error by replying to this message, and then > delete it from your system. Thank you. > > > ------------------------------------------------------- > This SF.Net email is sponsored by Oracle Space Sweepstakes > Want to be the first software developer in space? > Enter now for the Oracle Space Sweepstakes! > http://ads.osdn.com/?ad_idt12&alloc_id344&op=click |
|
From: Keith D. <ke...@in...> - 2005-05-18 15:14:21
|
Yes that will work.
-----Original Message-----
From: spr...@li...
[mailto:spr...@li...] On Behalf =
Of
Scott Battaglia
Sent: Wednesday, May 18, 2005 8:20 AM
To: spr...@li...
Subject: Re: [Springframework-developer] RE: spring webflow in progress =
pr3
features - seeking feedback
Would that <view-state id=3D"myViewState"=20
redirect=3D"myRedirectView?foo=3D${flowScope.foo}" /> be able to handle=20
something like
<view-state id=3D"myViewState" redirect=3D"${flowScope.redirectUrl}" />
i.e. redirect to a URL provided to it rather than a known redirect URL?
Thanks
-Scott
Scott Battaglia
Application Developer, Architecture & Engineering Team
Enterprise Systems and Services, Rutgers University
v: 732.445.0097 | f: 732.445.5493 | sco...@ru...
Keith Donald wrote:
>Right, the redirect attribute would be there as a convenience to having =
to
>parse string prefixes using the 'view' attribute.
>
>Keith
>
>-----Original Message-----
>From: spr...@li...
>[mailto:spr...@li...] On =
Behalf Of
>Lachezar Dobrev
>Sent: Wednesday, May 18, 2005 4:14 AM
>To: spr...@li...
>Subject: Re: [Springframework-developer] RE: spring webflow in progress =
pr3
>features - seeking feedback
>
> Well...
> Do you need to do this:
>
> =20
>
>> <view-state id=3D"myViewState"
>>redirect=3D"myRedirectView?foo=3D${flowScope.foo}"/>=20
>> =20
>>
>
> Currently I have done:
> <end-state id=3D"normalEndGoBackToBeginning" =
view=3D"redirect:/home.do" />
>
>
>-------------------------------------------------------
>This SF.Net email is sponsored by Oracle Space Sweepstakes
>Want to be the first software developer in space?
>Enter now for the Oracle Space Sweepstakes!
>http://ads.osdn.com/?ad_idt12&alloc_id=16344&op=3Dick
>_______________________________________________
>Springframework-developer mailing list
>Spr...@li...
>https://lists.sourceforge.net/lists/listinfo/springframework-developer
>
>
>
>-------------------------------------------------------
>This SF.Net email is sponsored by Oracle Space Sweepstakes
>Want to be the first software developer in space?
>Enter now for the Oracle Space Sweepstakes!
>http://ads.osdn.com/?ad_idt12&alloc_id=16344&op=3Dclick
>_______________________________________________
>Springframework-developer mailing list
>Spr...@li...
>https://lists.sourceforge.net/lists/listinfo/springframework-developer
> =20
>
-------------------------------------------------------
This SF.Net email is sponsored by Oracle Space Sweepstakes
Want to be the first software developer in space?
Enter now for the Oracle Space Sweepstakes!
http://ads.osdn.com/?ad_id=3D7412&alloc_id=3D16344&op=3Dclick
_______________________________________________
Springframework-developer mailing list
Spr...@li...
https://lists.sourceforge.net/lists/listinfo/springframework-developer
|
|
From: Scott B. <sco...@ru...> - 2005-05-18 12:19:57
|
Would that <view-state id="myViewState"
redirect="myRedirectView?foo=${flowScope.foo}" /> be able to handle
something like
<view-state id="myViewState" redirect="${flowScope.redirectUrl}" />
i.e. redirect to a URL provided to it rather than a known redirect URL?
Thanks
-Scott
Scott Battaglia
Application Developer, Architecture & Engineering Team
Enterprise Systems and Services, Rutgers University
v: 732.445.0097 | f: 732.445.5493 | sco...@ru...
Keith Donald wrote:
>Right, the redirect attribute would be there as a convenience to having to
>parse string prefixes using the 'view' attribute.
>
>Keith
>
>-----Original Message-----
>From: spr...@li...
>[mailto:spr...@li...] On Behalf Of
>Lachezar Dobrev
>Sent: Wednesday, May 18, 2005 4:14 AM
>To: spr...@li...
>Subject: Re: [Springframework-developer] RE: spring webflow in progress pr3
>features - seeking feedback
>
> Well...
> Do you need to do this:
>
>
>
>> <view-state id="myViewState"
>>redirect="myRedirectView?foo=${flowScope.foo}"/>
>>
>>
>
> Currently I have done:
> <end-state id="normalEndGoBackToBeginning" view="redirect:/home.do" />
>
>
>-------------------------------------------------------
>This SF.Net email is sponsored by Oracle Space Sweepstakes
>Want to be the first software developer in space?
>Enter now for the Oracle Space Sweepstakes!
>http://ads.osdn.com/?ad_idt12&alloc_id344&op=ick
>_______________________________________________
>Springframework-developer mailing list
>Spr...@li...
>https://lists.sourceforge.net/lists/listinfo/springframework-developer
>
>
>
>-------------------------------------------------------
>This SF.Net email is sponsored by Oracle Space Sweepstakes
>Want to be the first software developer in space?
>Enter now for the Oracle Space Sweepstakes!
>http://ads.osdn.com/?ad_idt12&alloc_id344&op=click
>_______________________________________________
>Springframework-developer mailing list
>Spr...@li...
>https://lists.sourceforge.net/lists/listinfo/springframework-developer
>
>
|
|
From: Keith D. <ke...@in...> - 2005-05-18 10:42:58
|
Right, the redirect attribute would be there as a convenience to having =
to
parse string prefixes using the 'view' attribute.
Keith
-----Original Message-----
From: spr...@li...
[mailto:spr...@li...] On Behalf =
Of
Lachezar Dobrev
Sent: Wednesday, May 18, 2005 4:14 AM
To: spr...@li...
Subject: Re: [Springframework-developer] RE: spring webflow in progress =
pr3
features - seeking feedback
Well...
Do you need to do this:
> <view-state id=3D"myViewState"
> redirect=3D"myRedirectView?foo=3D${flowScope.foo}"/>=20
Currently I have done:
<end-state id=3D"normalEndGoBackToBeginning" =
view=3D"redirect:/home.do" />
-------------------------------------------------------
This SF.Net email is sponsored by Oracle Space Sweepstakes
Want to be the first software developer in space?
Enter now for the Oracle Space Sweepstakes!
http://ads.osdn.com/?ad_idt12&alloc_id=16344&op=3Dick
_______________________________________________
Springframework-developer mailing list
Spr...@li...
https://lists.sourceforge.net/lists/listinfo/springframework-developer
|
|
From: <mic...@as...> - 2005-05-18 09:34:47
|
>=20 > Message: 1 > From: "Keith Donald" <ke...@in...> > To: <spr...@li...> > Date: Tue, 17 May 2005 23:02:38 -0400 > Subject: [Springframework-developer] RE: spring webflow in=20 > progress pr3 features - seeking feedback ... > A few additional comments: >=20 >=20 > On #1 below we could have simple view setup action support as follows: >=20 > <view-state id=3D"displaySearchCriteria" view=3D"searchCriteria"> >=20 > <action bean=3D"phonebookActions" method=3D"setupSearchCriteriaForm"/> >=20 > </view-state> >=20 > That would of course assume there was only a 'success' action=20 > result possibility, which seems appropriate for most setup=20 > actions (e.g to populate reference data drop downs) If you=20 > need to handle error cases, then you'd need to use the=20 > display-criteria elemtn with a if-false attribute. >=20 > =20 IMHO this could be better achieved by centralized error handling = specific for flow - or inherited from parent flow. This feature is still = missing and I assume that it could solve many error handling situations. = I proposed this requirement on user-list as well as on forum and the = idea was to involve similar error handling mechanism to one in Spring = Web. The base difference would be only in mapping exception/error to = certain view in flow instead of view id to be used by SpringWeb = ViewResolver. This solution is not complex yet, but could be easily designed to = elegant and plugable solution of centralized flow error handling.=20 Thank you, Michal Links to my previous posts: http://sourceforge.net/mailarchive/message.php?msg_id=3D11479934 http://forum.springframework.org/viewtopic.php?t=3D4881&highlight=3D |
|
From: Erwin V. <erw...@er...> - 2005-05-18 08:30:55
|
Back button use and all kinds of other browser trickery like refresh and=20 new-window (CTRL-N) are 'fixed' if you use a continuations based flow=20 storage strategy, e.g. PortletSessionContinuationFlowExecutionStorage or=20 ClientContinuationFlowExecutionStorage. Still, we see webflow as a solution to problems where you need 'controlle= d=20 navigation' iso 'free browsing'. Erwin Vervaet erw...@er... ----- Original Message -----=20 From: "Boyce, Keith Garry" <Kei...@bc...> To: <spr...@li...> Sent: Tuesday, May 17, 2005 10:37 PM Subject: RE: [Springframework-developer] Support for state/controller=20 chaining in Portlets? (not quite webflow) I created a portlet app with webflow. I read that back button functionality is fixed but I have't tested it yet. -----Original Message----- From: spr...@li... [mailto:spr...@li...] On Behalf Of Tim Kettering Sent: Tuesday, May 17, 2005 4:00 PM To: spr...@li... Subject: [Springframework-developer] Support for state/controller chaining in Portlets? (not quite webflow) Hi everyone, I'm just throwing this out here to see what other people have to say. I can see from the list that there are a few developers actively working on portal solutions using Spring MVC. We are starting on our first project using this as well, and one of the issues I'm trying to figure out now is the matter of maintaining state in a portlet. In a typical CRUD example, if we have a portlet to display, edit and maange information about a certain object, like a Book. We'd have view, edit and delete functionality for example. In a typical non-portlet webapp, we could easily split those up across different servlets for fine-grained areas of responsibility. But it's not as simple with portlets, because there are limitations on what can be done, and essentially, all requests would need to go thru a single portlet configuration. So, it no longer become sufficient to configure a simple portlet controller for a portlet. There needs to be a way to maintain state and to delegate the request/response process to different types of controllers depending on the state. Like a View page would need to go thru a derivation of BaseCommandController, an Edit page would go thru SimpleFormController. And not to mention adding yet another dimension when considering portlet modes as well! This article at IBM Developerworks pretty much covers the same issue I am bringing up: http://www-106.ibm.com/developerworks/websphere/library/techarticles/031 2_ha nis/hanis1.html I did look at Spring's WebFlow a few days ago to see if it could address our issue, but in the Webflow FAQ, it pretty much states that WebFlow should not be used in cases where the user will be using back-button, or indeterminate actions not within a strict flow. So that kinda leaves me back at square one. After some discussion with my co-worker, I would imagine that this is a common problem for any Spring portlet developer creating more than just simple portlet functionality. And that as Spring portlet support matures, this will be a more common issue for everyone. Hence this email to the list. I'm now wondering how some of you have addressed this problem, and whether there is a need for Spring's portlet support, to be in Spring 1.3 to include some way to configure and facilitate a state process, maybe even based on WebFlow's state machine - although I have only given WebFlow's state functionality a brief look. Thanks in advance, -tim ------------------------------------------------------- This SF.Net email is sponsored by Oracle Space Sweepstakes Want to be the first software developer in space? Enter now for the Oracle Space Sweepstakes! http://ads.osdn.com/?ad_id=3D7412&alloc_id=3D16344&op=3Dclick _______________________________________________ Springframework-developer mailing list Spr...@li... https://lists.sourceforge.net/lists/listinfo/springframework-developer This message is a PRIVATE communication. If you are not the intended recipient, please do not read, copy, or use it, and do not disclose it to others. Please notify the sender of the delivery error by replying to this message, and then delete it from your system. Thank you. ------------------------------------------------------- This SF.Net email is sponsored by Oracle Space Sweepstakes Want to be the first software developer in space? Enter now for the Oracle Space Sweepstakes! http://ads.osdn.com/?ad_idt12&alloc_id=16344&op=3Dick _______________________________________________ Springframework-developer mailing list Spr...@li... https://lists.sourceforge.net/lists/listinfo/springframework-developer |
|
From: Erwin V. <erw...@er...> - 2005-05-18 08:20:40
|
Regarding the view state: with named entry actions we could have =
everything without even doing stuff like the "display-criteria" with =
"if-false" and stuff like that. See my earlier mail.
Erwin Vervaet
erw...@er...
----- Original Message -----=20
From: Keith Donald=20
To: spr...@li...=20
Sent: Wednesday, May 18, 2005 5:02 AM
Subject: [Springframework-developer] RE: spring webflow in progress =
pr3 features - seeking feedback
A few additional comments:
=20
On #1 below we could have simple view setup action support as follows:
=20
<view-state id=3D"displaySearchCriteria" view=3D"searchCriteria">
<action bean=3D"phonebookActions" method=3D"setupSearchCriteriaForm"/>
</view-state>
=20
That would of course assume there was only a 'success' action result =
possibility, which seems appropriate for most setup actions (e.g to =
populate reference data drop downs) If you need to handle error cases, =
then you'd need to use the display-criteria elemtn with a if-false =
attribute.
=20
One other feature I forgot to mention is the new ViewDescriptorCreator =
strategy, allowing full dynamic control over the selection of a view and =
all supporting model data when a view state is rendered. This is a =
powerful thing, for use like:
=20
<view-state id=3D"myViewState" view=3D"myStaticView"/>=20
<view-state id=3D"myViewState" =
view-creator=3D"samples.MyCustomViewDescriptorCreator"/>=20
<view-state id=3D"myViewState" =
redirect=3D"myRedirectView?foo=3D${flowScope.foo}"/>
=20
The first definition uses a SimpleViewDescriptorCreator that simply =
selects the same view each time. The second definition selects a custom =
ViewDescriptorCreator implementation (the most flexible). The third =
leverages a RedirectViewDescriptorCreator capable of resolving redirect =
parameters from the flow request context using something like OGNL =
expressions.
=20
Keith
=20
-------------------------------------------------------------------------=
-----
From: Keith Donald [mailto:ke...@in...]=20
Sent: Tuesday, May 17, 2005 9:17 PM
To: 'spr...@li...'
Subject: spring webflow in progress pr3 features - seeking feedback
=20
SWF PR3 is expected to add some significant new features. Some of =
these are still in progress, but we want to get them out now for =
feedback. want to make sure these are right.
=20
Here they are:
=20
1.. view state "display criteria" - EXPERIMENTAL=20
=20
We are experimenting with display TransitionCriteria associatable with =
a ViewState, to be tested after the state is entered but before a view =
descriptor is returned for resolution and rendering. This allows you to =
execute arbitrary view pre-render logic before the view is displayed, =
reducing the need for an explicit action state to execute such logic. =
In addition, if the display criteria test fails, a transition to another =
state (like an error state) may be executed.
=20
This is realized in its simplest form in the DTD as follows:
=20
<view-state id=3D"displaySearchCriteria" view=3D"searchCriteria">
<display-criteria if-false=3D"myErrorState">
<action bean=3D"phonebookActions" =
method=3D"setupSearchCriteriaForm"/>
</display-criteria>
</view-state>
=20
It could get as involved as:
=20
<view-state id=3D"displaySearchCriteria" view=3D"searchCriteria">
<display-criteria if-false=3D"myErrorState">
<action-criteria true=3D"customTrueEventId" =
false=3D"customFalseEventId">
<action bean=3D"phonebookActions" =
method=3D"setupSearchCriteriaForm"/>
<action bean=3D"phonebookActions" =
method=3D"setupSearchCriteriaFormSecondActionMethod"/>
</action-criteria>
</display-criteria>
</view-state>
=20
2.. annotated objects: flows, states, transitions, actions - NEARLY =
DONE=20
=20
All definition objects (instances of Flow, State, Transition, Action) =
can now be qualified (aka annotated) with properties - metadata. This =
should open the door for all kinds of stuff from role-based state =
security checks to dynamic state decision logic based on transitional =
context. We're also adding full support for from-string property type =
conversion (with type aliasing) using the new data binding =
infrastructure.
=20
This is realized in the xml definition as follows:
=20
<flow || state || action || transition>
<property name=3D"foo" value=3D"12345" type=3D"int"/>
<property name=3D"bar" value=3D"some_custom_type" =
type=3D"myCustomTypeAlias"/>
<property name=3D"foo2" value=3D"some_other_custom_type" =
type=3D"com.mycompany.MyFullyQualifiedType"/>=20
</.>
=20
This relies on a converter installed to convert from string to the =
target type, with optional type aliasing to reduce typing.
=20
3.. attribute mapping from xml flow definition - NEARLY DONE=20
=20
It's now possible to specify input/output mappings for subflows =
directly from within the xml definition, reducing the need to =
instantiate a custom attribute mapper instance.
=20
This realized in multiple ways as follows:
=20
<subflow-state id=3D"enterPassengerInformation" flow=3D"passenger">=20
<attribute-mapper>=20
<input name=3D"someInputAttributeName"/>
<input name=3D"someOtherInputAttributeName" =
as=3D"someAdaptedInputAttributeName"/>=20
<input value=3D"${requestScope.someAttribute}" =
source-type=3D"string" as=3D"someAdaptedInputAttributeName" =
target-type=3D"int"/>=20
<output name=3D"someOutputAttributeName"/>=20
<output name=3D"someOutputAttributeName" =
as=3D"someAdaptedOutputAttributeName"/>
.
</attribute-mapper>=20
</subflow-state>
=20
=20
4.. flow loaders - EXPERIMENTAL=20
=20
There's really no benefit I see to have Flows exported in the web =
application context. A FlowAssembler could easily accept a group of =
flow builder classnames and/or references to XML flow definition =
resources and produce fully-configured Flow instances locatable by a =
FlowLocator. This would eliminate the need to define a FlowFactoryBean =
per Flow definition: you could define all the flows of your app in a =
single bean definition, e.g:
=20
<bean id=3D"flowLoader" =
class=3D"org.springframework.web.flow.config.FlowLoader"/>
<property name=3D"locations">
<list>
<value>classpath:myflow.xml</value>
<value>classpath:flows/*.xml</value>
</list>
<property name=3D"classes">
<list>
<value>com.mycompany.MyFlowBuilder</value>
</list>
</property>
</bean>
=20
What do you think? Note the data binding stuff is completely =
independent of webflow and really belongs as an enhancement to the core =
in future Spring releases.
=20
Keith=20
|
|
From: Lachezar D. <l.d...@gm...> - 2005-05-18 08:13:43
|
Well...
Do you need to do this:
> <view-state id=3D"myViewState"
> redirect=3D"myRedirectView?foo=3D${flowScope.foo}"/>=20
Currently I have done:
<end-state id=3D"normalEndGoBackToBeginning" view=3D"redirect:/home.do" /=
>
|