portal entry

select a category, or use search below
(searches all categories and all time range)

Guide to configure JNDI datasource in ColdFusion

| View in Portal
July 30, 2019 12:58:58 PM GMT
<p>Here’s a guide to show you how to configure JNDI datasource in ColdFusion 2018. 1. Get the JDBC Driver The JDBC Driver needs to be placed in ColdFusion2018/cfusion/lib folder. 2. context.xml configuration Add a resource block before the closing tag </Context> in the context.xml present at ColdFusion2018/cfusion/runtime/conf , which defines database connection detail : <Resource name=”jdbc/test” auth=”Container” type=”javax.sql.DataSource” maxActive=”50″ maxIdle=”30″ maxWait=”10000″ username=”username” password=”password” driverClassName=”com.mysql.jdbc.Driver” url=”jdbc:mysql://localhost:3306/test”/> For more information on the attributes please refer to https://tomcat.apache.org/tomcat-9.0-doc/jndi-datasource-examples-howto.html. For setting isolation level use the defaultTransactionIsolation attribute. […]</p>
<p>The post <a rel="nofollow" href="https://coldfusion.adobe.com/2019/07/guide-configure-jndi-datasource-coldfusion/">Guide to configure JNDI datasource in ColdFusion</a> appeared first on <a rel="nofollow" href="https://coldfusion.adobe.com">ColdFusion</a>.</p>
Labels: Adobe ColdFusion 10, Adobe ColdFusion 11, Adobe ColdFusion 2016, Adobe ColdFusion 2018, Application Datasource, Data Source, JNDI, Question, Uncategorized, coldfusion 10, coldfusion 11, coldfusion 2016, coldfusion 2018, data source


Interesting, Priyank. Can you offer a sentence or two about what scenarios may lead one to want to do this? Is there some benefit to using a JNDI-defined datasource, where a CF-provided one (or the "other JDBC" option) won't work for folks? I just ask because I'd hate to see some folks think this is something they SHOULD do, when the existing options may suffice. Perhaps you had a user who had a real need for this. I'm just saying it would be helpful to hear the need, as well as this solution to it. :-) Thanks.
Comment by Charlie Arehart
2193 | July 30, 2019 03:53:33 PM GMT
Hi Charlie, We have users who still would like to use JNDI data source who are either migrating from WebSphere environment to Standalone installation of CF. We offered them to use the JDBC option however they want to stick to JNDI data source. I don't see any benefit over "Other JDBC". Maybe the way users have written their application calling the JNDI. I published this blog because the old blog was deleted during the migration.
2196 | July 30, 2019 04:29:24 PM GMT
Great. That explains it reasonably. Thanks.
Comment by Charlie Arehart
2204 | July 31, 2019 03:56:08 AM GMT