| Author |
Tomcat server.xml mapping
|
Tanvi Ch
Greenhorn
Joined: Mar 15, 2010
Posts: 2
|
|
Hi,
I need some help to understand application
i have a server.xml file in that i have a part of code as follows
<Context path="" docBase="C:\Samp\http" debug="0" reloadable="true" crossContext="true">
<Realm className="org.apache.catalina.realm.MemoryRealm"/>
<Environment name="param/DealerDAOClass" value="com.Samp.dlr.dao.dlrDAO" type="java.lang.String" override="false"/>
<Environment name="param/MarketDAOClass" value="com.Samp.mr.dao.mrDAO" type="java.lang.String" override="false"/>
<Environment name="param/ReferenceDAOClass" value="com.Samp.rt.dao.rtDAO" type="java.lang.String" override="false"/>
<Resource name="jdbc/sampDB" auth="Container" type="javax.sql.DataSource"/>
and i have two java classes one is xxDAO.java class which has the line of code as
String className = "com.Samp.dlr.dao.dlrDAO"";
dlrDAO= (dlrDAO) Class.forName(className).newInstance();
and one more is yyy.java class which has declaration as
public static final String DLR_DAO_CLASS =
"java:comp/env/param/DealerDAOClass";
can anybody help me to understand how the JDBC connectivity happens here. how the mapping taken place between server.xml, xxDAO.java and yyy.java.?
this is urgent for me.
|
 |
 |
|
|
subject: Tomcat server.xml mapping
|
|
|