Configure Tomcat for JavaBeans & classes
Posted on 2002-07-28
Developing a web application on Tomcat 4.0 with JSPs in a M-V-C structure, I am using several JavaBeans to encapsulate various data objects, but currently on a very steep learning curve.
The JavaBean (a Java class file) is not currently being recognised by Tomcat. I have tried to put the files concerned in the <<install>>/common/classes directory and in the application <<appl>>/WEB-INF/classes directory - both with no success. I have added the correct <Context> object to the <<install>>/conf/server.xml file that points to my application directory. There seems to be a lot of information about adding servlets to the local <<appl>>/WEB-INF/web.xml file, but does not seem to be an equivalent XML definition for a Java class/bean.
Surely there must be a simple way for Tomcat to recognise Java class files???
Looking forward to any help on this.