Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

struts

 
bren jas
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
what is the different of execute and processRequest method
 
Sumit Malik
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi moon moon,

I hope Mark Spritzler woudnt like the way you have registered with your name

Second issue would be posting your query in the wrong forum. You should have posted this question in struts forum.

Anyway, lets come to the question and the answer is :

WebContainer(tomcat) do deploy a object as a standard implementation of RequestDispatcher(interface) that allows it to listen the incoming request from the client and forward to the server resource for processing. ActionServlet(in struts) which is responsible for taking care of all incoming response and do send response back to client. Internally it call ApplicationDispather object which has processrequest method to process request and send it to appropiate action(as defined in your mapping file struts-config.xml)

We know we have to write our business logic inside execute(overided method of Action class) method to complete the picture of struts.

So execute method comes into play when we are defining our business logic and performexecute comes into play when main servlet is handling the incoming request and sending back the response.

I hope this would clear your doubt


Cheers !!!
Sumit Malik
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic