Developing Web Applications with Eclipse and Tomcat - PowerPoint PPT Presentation

1 / 7
About This Presentation
Title:

Developing Web Applications with Eclipse and Tomcat

Description:

Eclipse Tomcat launcher plug-in ... Download and install Tomcat from http://tomcat.apache.org/download-55.cgi ... You will see the greetings page from Tomcat. ... – PowerPoint PPT presentation

Number of Views:210
Avg rating:3.0/5.0
Slides: 8
Provided by: Nad972
Category:

less

Transcript and Presenter's Notes

Title: Developing Web Applications with Eclipse and Tomcat


1
  • Developing Web Applications with Eclipse and
    Tomcat
  • Prepared by Nadya Kuzmina

2
Components 1
  • (Of course) Eclipse
  • Java SDK
  • Tomcat
  • Eclipse Tomcat launcher plug-in by Sysdeo

3
Installing Components
  • Download and install the latest version of Java
    SDK (e.g. from http//java.sun.com/javase/download
    s/index.jsp)
  • Set up JAVA_HOME environment variable to point to
    the installation directory of the Java SDK.
  • Download and install Tomcat from
    http//tomcat.apache.org/download-55.cgi
  • Test your Tomcat installation by going to
    ltCATALINA_HOMEgt/bin directory and starting Tomcat
    with startup.bat.
  • Next, open localhost8080 in your browser.
  • You will see the greetings page from Tomcat.
  • Download the Eclipse Tomcat launcher plug-in by
    Sysdeo from http//www.sysdeo.com/eclipse/tomcatpl
    ugin
  • Unzip the plugin into Eclipse/plug-ins directory.
  • Start Eclipse with java -jar startup.jar -clean
    once after the plugin installation.
  • Tomcats icons should be present on the toolbar
    in Eclipse.

4
Configure Eclipse to Work with Tomcat 1
  • Set the Java SDK that you installed in the
    previous step to be the default JRE for Eclipse
  • Window-gtPreferences Java-gtInstalled JREs
  • Set the Tomcat plug-in to work with Tomcat
  • Window-gtPreferences Tomcat
  • Set Tomcat Home to point to your installation of
    Tomcat.

5
Test your Configuration 1
  • Follow the instructions in 1.

6
Web Archive Organization 2
  • .html, .jsp, etc.
  • /WEB-INF/web.xml - The Web Application Deployment
    Descriptor for your application. This is an XML
    file describing the servlets and other components
    that make up your application, along with any
    initialization parameters and container-managed
    security constraints that you want the server to
    enforce for you.
  • /WEB-INF/classes/ - This directory contains any
    Java class files (and associated resources)
    required for your application, including both
    servlet and non-servlet classes, that are not
    combined into JAR files. If your classes are
    organized into Java packages, you must reflect
    this in the directory hierarchy under
    /WEB-INF/classes/. For example, a Java class
    named com.mycompany.mypackage. MyServlet would
    need to be stored in a file named
    /WEB-INF/classes/com/mycompany/mypackage/MyServlet
    .class.
  • /WEB-INF/lib/ - This directory contains JAR files
    that contain Java class files (and associated
    resources) required for your application, such as
    third party class libraries or JDBC drivers.

7
References
  • Geoffrey Duck Using Eclipse as a development
    environment with Jakarta Tomcat,
    http//www-128.ibm.com/developerworks/library/os-e
    ctom/
  • Apache Tomcat 5.5 Application Developers Guide,
    http//tomcat.apache.org/tomcat-5.5-doc/appdev/dep
    loyment.html
Write a Comment
User Comments (0)
About PowerShow.com