Combination View Flat View Tree View
Threads [ Previous | Next ]
GAurav j Patil
Spring based portlet is not rendering the portlet...
February 18, 2008 12:32 AM
Answer

GAurav j Patil

Rank: New Member

Posts: 20

Join Date: September 4, 2007

Recent Posts

Hi,

I am developing portlet based on Spring.I am new to Spring.So i am developing portlet side by side while leaning Spring...

So far i have developed a protlet using Spring web portlet MVC....and its working also...but now i have started extending that

portlet to provide new functionality... I hope you(the one who is answering this) know the spring framework....

in one of the classes i am extending AbstractController..it contains two methods which i am overriding in there...

1.public void handleActionRequestInternal(ActionRequest request, ActionResponse response)

2.public ModelAndView handleRenderRequestInternal(ActionRequest request, ActionResponse response)

so as per theory after

<a href="<portlet:actionURL>
<portlet:param name="action" value="viewMail"/>
</portlet:actionURL>">
Check Mails
</a>,

the DispatcherPortlet must call Action method of the controller and it is doing it ...

but according to theory when action happens after that rendering is bound to happen....so here is the problem....

In my portlet its not calling render method to render the portlet after execution of Action method....

and it is happening for this particular class only.....


these r the classes and their status..

Login extends SimpleFormController.............working fine

SendMailController extends SimpleFormController.....working fine

ViewMailController extends AbstractController ...... wen action url is sent then this class only executes Action method but doesn't render the portlet(means it renders but doesnt use its own render method , it goes for view mode mapping and there it find Login class's mapping for view mode and calls the render method of Login class instead of calling its own one...) and wen render url is sent then this class executes render method of its own ,which is perfectly fine according to theory......

I hope u must have understood my problem......class is not using its own render method for rendering the portlet after Action method..........

Regards,
Gaurav