• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Orion/Tomcat servlet example?

 
Ranch Hand
Posts: 76
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm trying to prepare for the servlet portion of the assignments, and since Orion is history, I downloaded Tomcat 7 and it's installed and running. But for the life of me, I cannot create any kind of example servlet. I'm just wanting to make sure I understand the basics of deploying a webapp servlet when the time comes. But there's just nothing that works? Every tutorial I go over fails in some way.

http://cs.calstatela.edu/~abbott/Courses/CS_320b/Running%20a%20Servlet%20under%20Tomcat.html

This one here, for example, does NOT work. I compile the .java file just fine, move it to the directory, enter the correct URL, and I get a bad request page. And that's really my best attempt. I mean, I dunno, do you just need an IDE until you get used to this or what? It's like beating my head against a brick wall trying to do this manually, and nothing has worked yet...
 
Jack Moore Iii
Ranch Hand
Posts: 76
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
So, anyway, I tried http://www.devmanuals.com/tutorials/java/servlet/configuringservletintotomcat6.html and it finally worked. I guess you need a web.xml for every servlet and any servlet that goes in the webapps directory has to be included in the url unless it's in the ROOT directory. Kinda took all day to figure out something so simple, ugh. And NOW, I can write "Hello World"! Technical ignorance is painful, that was like taking a brain dump ...
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic