Win a copy of Microservices Testing (Live Project) this week in the Spring 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Liutauras Vilda
  • Henry Wong
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Mikalai Zaikin
  • Himai Minh

com.ibm.servlet.engine webapp. NoTarget ForURIException: No target servlet config

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
When Iam calling a servlet from my jsp page Iam getting the following error:
com.ibm.servlet. engine. webapp NoTargetFor URIException: No target servlet configured for uri: /comnServlet.
Iam calling the servlet from my jsp page as follows:
<FORM id="w_Testwindow1" METHOD="POST" ACTION="http://ss0247/FIM/servlet/comnServlet" >
public void forwardToJsp(String toJsp, HttpServletRequest req, HttpServletResponse res)
{
System.out.println("***inside forwardtojsp ");
RequestDispatcher rd1;
rd1 = getServletContext().getRequestDispatcher("/"+toJsp);
System.out.println("***After request dispatcher ");

try{
//forward the req to jsp page to be displayed
//// System.out.println("back to wrapper2");
System.out.println("***sing-- b4 forward ");
rd1.forward(req,res);
System.out.println("***sing-- after forward ");
}
catch(Exception e)
{
////log("CATCHING EXCEPTION on FORWARD POINT 1" + e);
System.out.println("The error in forward jsp is due to"+e);
e.printStackTrace();
}
}
After the control goes to the common servlet it fails at rd1.forward(req,res); and it throws the following exception.
com. ibm.servlet. engine.webapp. NoTargetForURIException: No target servlet configured for uri: /comnServlet.
Please get back to me and tell me what am I to do ......
 
Ranch Hand
Posts: 265
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Can u tell me Which application Server r u using?
 
author and deputy
Posts: 3150
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Check whether the servlet exist at correct classes directory,if not check ur web.xml whether it the servlet mapping for comnServlet is correct.
Regards
Balaji
 
Ranch Hand
Posts: 2823
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Singar,
Welcome to the JavaRanch! Please adjust your display name to meet
the JavaRanch Naming Policy. You can change it here.
Thanks!
and welcome to the JavaRanch!
 
permaculture is a more symbiotic relationship with nature so I can be even lazier. Read tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic