You should be able to use a naming convention for the beans (e.g. "myBeanX" and "myBeanY")
User user = //get the user
MyBean bean = (MyBean) context.getBean("myBean"+user.getCenter()); ...
Type: Posts; User: ram_2000; Keyword(s):
You should be able to use a naming convention for the beans (e.g. "myBeanX" and "myBeanY")
User user = //get the user
MyBean bean = (MyBean) context.getBean("myBean"+user.getCenter()); ...
You can always use the parent attribute.
<bean id="baseId" class="yourpkg.yourclass" abstract="true">
...can specify any properties that should be reused...
</bean>
<bean id="myId"...
I had to add getSqlMapClient().startTransaction() call before the start batch call.
Its odd that i have to call startTransaction explicitly even though a local transaction is already active (...
I'm using iBatis SqlMapClientDaoSupport for my DAO.
public void batchInsertCustomer( final List customerList )
{
getSqlMapClientTemplate().execute(new...
I have a need to handle multiple date formats in the same bean factory. How can i do this with Spring ? Is there a way to register a property editor only for a specific bean ?
Thanks,
Ram.
I need access to Principal in my Service (implemented as a POJO).
I would use 'EJBContext.getCallerPrincipal()' in the EJB....but how can i get access to the principle in a POJO?
Can Spring...
This is the default behaviour in Spring....If you don't specify a property in the bean definition, Spring will not call the setter method.
<bean id="abc" class="abc">
<property...
I have a case where some methods in a business interface will be invoked synchronously via EJB and some asynchronously via JMS. The client code will only use the business interface and will not be...
The EJB spec explicitly mentions (in section 17.3.4)
Its good to hear that it works with all AppServers....I'm just worried that this may change with the next release of the AppServer (I'm...
Delay your initialization of Spring (ApplicationContext or BeanFactory) to after the client receives the topology, then you can easily implement a BeanFactoryPostProcessor that replaces tokens...
Juergen,
I'm planning to use CMT.
Is there any way to just use the rollback functionality ( based on Exception) provided by the Spring TransactionProxy (without propagation, isolation level and...
Small correction...I didn't really need the "endpointAddress" attribute. I was playing with tcpmon and changed the port number in the WSDL and forgot about it....When i used the "endpointAddress",...
lucas,
The difference i can see is that you specified "wsdlTargetNamespace".
Your spring "namespaceUri" has to match the "wsdlTargetNamespace". Once you do this you also need to specify the...
Here is a sample configuration i used. I used it against the "stock" sample in the AXIS samples folder. You can look at the GetQuote.wsdl and deploy.wsdd in the 'stock' samples folder.
<bean...
cig,
Try the following:
<property name="serviceName"><value>HelloWorldService</value></property>
(no urn: in the service name)
<property name="namespaceUri"><value>urn</value></property>
I just looked at the jpetstore sample that uses AXIS.
Any reason why the "AxisPortProxyFactoryBean" is specific to this sample. Can we not make it generic to take a list of mappings to register....
Has anybody used AXIS JAX-RPC implementation with Spring ? I couldn't find any documentation on this.
I'm trying to implement a "wrapped" sytle service. Any help will be greatly appreciated.
How about using a Singleton context factory on deserialization (based on the serialized file name)....so if there are n beans that are deserialized they will be able to share the same sigleton...
I think Serialization is important...
Instead of serializing the entire factory and all the bean definitions, can we somehow just serialize what is required for deserialize. Maybe even just allow...
You can use HotSwappableTargetSource. You have to call swap() method whenever you want to swap the implemenation.
I'm assuming both your beans implement a common interface.
Ram.
Update:
-----------
This doesn't happen when using "autoproxy"....but only when using the "ProxyFactoryBean"
Why is the constructor called twice when using CGLIB proxy beans.
I have a System.out.println in the constructor:
System.out.println("*** inside constructor : " + this);
I can see the...
I got this to work using "targetSource" and using "org.springframework.aop.target.PrototypeTargetSource" implementation class.
Two levels of indirection for something very simple.
<beans>
...
Thanks for your quick reply Colin.
RE: >>>> "So the problem is that you are trying to create a prototype proxy, which also by definition means a prototype target is needed, but you are feeding in...
I using 1.1 RC1
I have a simple bean definition like below:
<beans>
<bean id="businesslogicbean"
class="org.springframework.aop.framework.ProxyFactoryBean">
<property...