Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Web.xml not displayed in Netbeans 6.9.1 instead sun-web.xml is being displayed

 
Vishal Hegde
Ranch Hand
Posts: 1077
Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Web.xml not displayed in Netbeans 6.9.1 instead sun-web.xml is being displayed, Is Sun-Web.xml the same as web.xml or else I need to add web.xml to do the servlet mapping???
 
Peter Johnson
author
Bartender
Posts: 5852
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which version of Java EE, or actually, which version of the Servlet spec? Java EE 6, which uses Servlet 3.0, no longer requires a web.xml.

I suspect that the sun-web.xml is specific for Glassfish.
 
Nitin Surana
Ranch Hand
Posts: 129
Java Netbeans IDE Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's just because while creating a new web project you are choosing GlassFish as Server. If you want to have web.xml then choose Tomcat as your server while creating the project.
 
Vishal Hegde
Ranch Hand
Posts: 1077
Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Nitin Surana wrote:It's just because while creating a new web project you are choosing GlassFish as Server. If you want to have web.xml then choose Tomcat as your server while creating the project.


I am just clicking on New Project is there an option thats bydefault selected for server which i can change
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic