Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsGeneralPHPASPPerlColdFusionFlashHTML, CSS, ScriptsBrowsers

Webmaster Forum / ColdFusion / Advanced Techniques / August 2006



Tip: Looking for answers? Try searching our database.

Using JRUN Datasource from CF

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
jimmatts2 - 30 Aug 2006 15:46 GMT
I am running CF 6.1 on top of JRUN4.  I've also have some java code that is
packaged in a jar and available for invocation from CF.  I would like to use a
JRUN datasource from that Java code.  Is this possible?
<newbie /> - 30 Aug 2006 18:19 GMT
I don't see why not.

I have never actually done this but I imagine you would need to do something
like this...

Create (JNDI) dsn using JRun Admin.
Create CF dsn in CF Admin specifying Driver  as J2EE Datasource (JNDI).

You should now be able to do a JNDI lookup in your java code and/or use the
CF dsn in your coldfusion code.

Good luck!
jimmatts2 - 30 Aug 2006 23:25 GMT
I've tried what you are suggesting but I don't believe it is available.  

I've used the "hidden" APIs and I am only seeing the data source set up in
ColdFusion, not JRUN.

<cfscript>
  factory = createObject("java", "coldfusion.server.ServiceFactory");
</cfscript>

 <cfset ds=factory.getDataSourceService()>
 
 <cfdump var="#ds.getNames()#">
ksmith - 31 Aug 2006 02:50 GMT
Datasources created in the JRun admin under cfusion's server instance should then be visible in the CFAdmin.  There should be no special steps required.
jimmatts2 - 31 Aug 2006 04:39 GMT
Hmmm ... I have a datasource on the "default" JRUN server instanced called:
"DAwactlg"
-----------------------------------------------
JDBC Data Sources
 Actions        Data Source Name        Database Driver  
       
 Edit Verify Delete         DAwactlg         macromedia.jdbc.MacromediaDriver  
-----------------------------------------------

I also have a different ColdFusion data source in the ColdFusion app running
in the "default" server.  

--------------------------
 Connected Data Sources
  Actions        Data Source Name         Driver        Status  
  W09ORD    Oracle  
---------------------------

The JRUN configured DSN called "DAwactlg" is not showing in the CF Admin.

Thoughts?
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.