DWR

DWR fails to identify lazy init beans

Details

  • Type: Bug Bug
  • Status: Resolved Resolved
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 3.0.M1
  • Fix Version/s: 2.0.10, 3.0.RC1, 3.0.RC2
  • Component/s: Spring
  1. DWRSpringLazyInit.zip
    (7 kB)
    Jose Noheda
    27/May/08 9:25 AM

Issue Links

Activity

Hide
Jose Noheda added a comment - 27/May/08 9:25 AM

Sample project showing the issue

Show
Jose Noheda added a comment - 27/May/08 9:25 AM Sample project showing the issue
Jose Noheda made changes - 27/May/08 9:25 AM
Field Original Value New Value
Attachment DWRSpringLazyInit.zip [ 10100 ]
Hide
Pablo Krause added a comment - 28/May/08 7:04 PM

A breif explanation of the behaviour and sample code:

There are 2 beans defined in Spring: Hello and Goodby.
Goodby is declared as lazy-init="true".
Each bean prints a message when they are instantiated.
When the application starts, and the Spring context gets loaded, only Hello bean gets instantiated as can be seen by the message ">>> Hello bean instantiated. <<<" that gets printed.
So far so good, but when I invoke the Hello bean through dwr, the Goodby bean gets instantiated (which shouldn't, as it is lazy) as can be seen by the message being printed ">>> Goodby bean instantiated. <<<".
This happens as soon as I point my browser to the web app since the index.html uses Hello.js. This also happens if you point your browser to http://localhost:8080/DWRSpringLazyInit/dwr/test/Hello or http://localhost:8080/DWRSpringLazyInit/dwr/.

Show
Pablo Krause added a comment - 28/May/08 7:04 PM A breif explanation of the behaviour and sample code: There are 2 beans defined in Spring: Hello and Goodby. Goodby is declared as lazy-init="true". Each bean prints a message when they are instantiated. When the application starts, and the Spring context gets loaded, only Hello bean gets instantiated as can be seen by the message ">>> Hello bean instantiated. <<<" that gets printed. So far so good, but when I invoke the Hello bean through dwr, the Goodby bean gets instantiated (which shouldn't, as it is lazy) as can be seen by the message being printed ">>> Goodby bean instantiated. <<<". This happens as soon as I point my browser to the web app since the index.html uses Hello.js. This also happens if you point your browser to http://localhost:8080/DWRSpringLazyInit/dwr/test/Hello or http://localhost:8080/DWRSpringLazyInit/dwr/.
Jose Noheda made changes - 29/May/08 8:38 AM
Status Open [ 1 ] In Progress [ 3 ]
Jose Noheda made changes - 29/May/08 9:08 AM
Fix Version/s 3.0 [ 10025 ]
Status In Progress [ 3 ] Resolved [ 5 ]
Resolution Fixed [ 1 ]
David Marginian made changes - 02/Feb/12 7:17 AM
Link This issue relates to DWR-561 [ DWR-561 ]
David Marginian made changes - 02/Feb/12 7:29 AM
Fix Version/s 3.0.RC2 [ 10090 ]
Fix Version/s 3.0.RC1 [ 10051 ]
Fix Version/s 3.0 [ 10025 ]
David Marginian made changes - 02/Feb/12 7:30 AM
Fix Version/s 2.0.10 [ 10132 ]
Fix Version/s 3.0.RC1 [ 10051 ]
Fix Version/s 3.0.RC2 [ 10090 ]
David Marginian made changes - 02/Feb/12 7:30 AM
Fix Version/s 3.0.RC2 [ 10090 ]
Fix Version/s 3.0.RC1 [ 10051 ]

People

Dates

  • Created:
    27/May/08 9:25 AM
    Updated:
    02/Feb/12 7:30 AM
    Resolved:
    29/May/08 9:08 AM