java - Switch the servlet from one app to another -
i have 2 applications web1 , web2 , want switch web1/servlet1 web2/servlet2 . requirements are
- request received web1/servlet1.(1st application)
- token generated ,add in header , passed web2/servlet2 (2nd application) along url change
i have tried below no success.
the call made web2/servlet2 not switched.(url not changed) ,i want upon switching should load second application
servletcontext s=request.getservletcontext().getcontext("/web2"); requestdispatcher dis=s.getrequestdispatcher("/servlet2"); dis.forward(request, response);
also,i have added attribute in tomcat context
crosscontext="true"
Comments
Post a Comment