|
From: Jaga <v.j...@gm...> - 2008-06-09 09:42:47
|
Actual code snippet where the bean is being referred. <?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd"> <bean id="assetExposureReportController" class="com.sp.cms.cdointerface.portlet.controller.AssetExposureReportController" scope="prototype"> <property name="sessionForm" value="true"/> <property name="commandName"><value>formBean</value></property> <property name="commandClass"><value>com.sp.cms.cdointerface.portlet.form.AssetExposureReportFormBean</value></property> </bean> On accessing this bean in multiple browsers, recently accessed instance's value is retrieved across the browsers. -- Jag Jaga wrote: > > hi, > > When I tried with the prototype scope in spring, on opening two browsers > there > is only one instance is created. > > Hence the value of the recently accessed instance by the user is > retrieved. > > version used: spring-beans-2.0.xsd > > Snippet: > > <?xml version="1.0" encoding="UTF-8"?> > <beans xmlns="http://www.springframework.org/schema/beans" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xsi:schemaLocation="http://www.springframework.org/schema/beans > http://www.springframework.org/schema/beans/spring-beans-2.0.xsd"> > > <bean id="obj1" class="com.dto.Class1" scope="prototype"> > </bean> > > Please help. > > -- View this message in context: http://www.nabble.com/Protype-Scope-of-Spring-Bean---creates-problematic-singleton-instance-tp17727103p17729307.html Sent from the springframework-developer mailing list archive at Nabble.com. |