Win a copy of Svelte and Sapper in Action this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

How to start and deploy a servlet on Tomcat

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can someone please give a noob step by step instructions on how to start a servlet with Tomcat from the installing of Java sdk (and since we are here what sdk do I need for programming servlets, will Java SE will suffice or do I need Java EE?), installing Tomcat, configuring the environment variables ... all the way to testing and succesfully running the servlet.

Any material you will give me (links, tutorials, a post with step by step instructions etc.) will greatly be appreciated. Thank you in advance!
 
Ranch Hand
Posts: 81
IBM DB2 Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You will need java EE...and eclipse (or netbeans...)

Try googling "java ee tutorial tomcat"

you will find a lot of hits, for example this one :

http://www.javahotchocolate.com/wtp-tutorials/wtp-tutorial.html

explained from beginning to end...step by step...

 
Sebastian Dan
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you very much! I think this will help me a lot.
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you are not already comfortable with an IDE such as NetBeans do NOT try to learn a new IDE at the same time as you learn servlets. It is tricky enough already.

Download the Tomcat server - you do NOT need a full JEE package. Install Tomcat as an application, NOT a service. Tomcat comes with the servlet-api.jar library you will need in addition to the standard Java library. Tomcat also comes with extensive documentation and a number of examples you will find very helpful.

Bill
 
Sebastian Dan
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'll take your advice into consideration and I will get my hands "dirty" by programming and deploying my first servlets the hard way but just for the sake of the discussion why my Eclipse IDE for Java EE Developers doesn't want to start and instead it gives me a message "Failed to create the Java Virtual Machine"? I have Java SE 1.6 installed and another version of Eclipse (but this other version is for standard Java, not EE) that works fine.
 
olivier dutranoit
Ranch Hand
Posts: 81
IBM DB2 Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i think you will have to edit your eclipse.ini file to solve this problem. Could be something with the launcher settings...
 
We cannot change unless we survive, but we will not survive unless we change. Evolving tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic