Win a copy of Pipeline as Code this week in the Cloud/Virtualization 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
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Rob Spoor
  • Henry Wong
  • Liutauras Vilda
Saloon Keepers:
  • Tim Moores
  • Carey Brown
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
Bartenders:
  • Frits Walraven
  • Himai Minh
  • Jj Roberts

Is j2ee required for servlet?

 
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, i have already installed j2se 1.6 and apache tomcat 5. I running successfully JSP page. But trouble with servlet. Is j2EE is needed to successfully run servlet? Thanks in advance.
 
Ranch Hand
Posts: 1585
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

To run a Servlet or a JSP, you don't need a fully compliant J2EE Application Server, you just need a web container like Tomcat to run a web component ...

Best of luck ...
 
Marshal
Posts: 67510
173
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"Max Ant", please check your private messages for an important message from me.
 
Bear Bibeault
Marshal
Posts: 67510
173
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What problems are you encountering? Is it in compiling or in running the servlets?

As pointed out, you don't need anything more than Tomcat and J2SE.
 
Madhusudan Banik
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Firstly i get compilation error due to some HttpServlet related classes. Then i add the classpath variable servlet-api.jar form the tomcat\common\lib\ and the program compiles successfully. But now i get 404 not found error from the browser.
I make these
put Hello.class file into webapps\ex1\WEB-INF\classes\
and make a web.xml file and put it webapps\ex1\WEB-INF\
and from the browser http://localhost:8080/ex1/Hello

It get me the 404 file not found error.
I need to dig it why this happens.
Any advice will be appreciated.
 
Madhusudan Banik
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My problem was solved.
It's wordpad related problem.
I edit my web.xml file using wordpad and its add some extra character which give me these trouble.
 
Wanna see my flashlight? How about this tiny ad?
SKIP - a book about connecting industrious people with elderly land owners
https://coderanch.com/t/skip-book
reply
    Bookmark Topic Watch Topic
  • New Topic