Hi all,
So I am upgrading from SAP JCO 2 to 3 and have implemented my own DestinationDataProvider. I register it with Environment.registerDestinationDataProvider. This is in a tomcat environment with many WARs, many of which connect to SAP using JCO and hold their own connection details. I've started getting IllegalStateException:
DestinationDataProvider already registered [com.hre.sapjco.rfc.SapJcoDestinationDataProvider]
and then came across this:
JCO 3.0.6 on Tomcat server with multiple apps connecting to SAP
The question is that I find has not been answered adequately is how do I do this in an environment with many wars.
Environment has no way of returning the registered DestinationDataProvider in order to add new connection details. I cannot just ignore the error because then the registered DestinationDataProvider will not have my connection properties.
Is it even correct that Environment is shared across the whole tomcat or am I experiencing a different problem? How is it doing this? Is there any way around this?
Regards,
Melion