Imagine the following environment:
- First server with an SQL Database
- Second server with a Lucee web application
- Third server with a Adobe Coldfusion web application
Can I create a datasource on Lucee (server 2) and a datasource on Adobe Coldfusion (server 3) pointing both on the same SQL Database on server 1?
Instinctively, of course I say yes, but I would like your opinion. Can there be problems?
Basically, as long as the application uses
cftransaction as opposed to
cflock when needed for db related stuff, there shouldn’t be a problem
Oh, I hadn’t thought of the cflock.
Great, thank you!
To be clear, he said “as opposed to cflock” meaning CFLock would not be an acceptable means of synchronizing transactions. But forget about that for now. The general answer to your question is, “yes, of course it will work”. DB servers designed to have hundreds of client connections to them! It really doesn’t matter whether you have a dozen adobe servers, a dozen Lucee servers, or half and half. Every CF server already has more than one pooled connection in the first place. It’s also worth noting, there’s no synchronization “problem” you could have from two CF servers connecting to the same DB server that you wouldn’t already inherently have with just two pages (threads) using the DB at the same time over two separate JDBC connections.
Thank you for your feedback guys!