Approach 1:
What is the classpath set for server?
If server classpath is set to include "<complete_path>/MyProject" and
if MyServlet.class file is kept under "<complete_path>/MyProject/com/its/serv" directory
then
you should be able to access servlet with URL:
http://localhost:8080/MyProject/com.its.serv.MyServlet Approach 2:
I believe when servlet is to be accessed through web.xml, it should be first "deployed" on the server or
should be kept under correct directory of already deployed web application (like DefaultWebApplication in case of Tomcat).
If your servlet is not under already deployed web application directory, you should first deploy it as war file.
Servlet from a deployed application should be accessed with following URL:
http://<server_name>:<port>/<Appli Name Given while deploying>/<servlet>
I am also new to servlet programming, so please do let me know if any of above help.