Here's the endpoint

<jaxws:endpoint
            id="MyServiceRQ"
            name="{http://www.mycompany.com/websvcs}MyServicePortType";
            address="/websvc/"
            implementor="#myServicePortType"

wsdlLocation="classpath:com/mycompany/websvcs/wsdl/MyServiceRQ.wsdl">
        <jaxws:properties>
            <entry key="allow-multiplex-endpoint" value="true"/>
        </jaxws:properties>
        <jaxws:dataBinding>
            <bean class="org.apache.cxf.xmlbeans.XmlBeansDataBinding"/>
        </jaxws:dataBinding>
    </jaxws:endpoint>

and here's the bean in cxf.xml

<bean id="myServicePortType" class="com.mycompany.MyServicePortTypeImpl"
scope="prototype">
        <property name="privateFareService" ref="privateFareService"/>
        <property name="privateRuleService" ref="privateRuleService"/>
        <property name="sessionFactory" ref="sessionFactory"/>
    </bean>

You see that the scope is already "prototype", not "singleton", so how come
CXF makes the implementor singleton?

Reply via email to