URI mapper plugin for struts2

2010-04-19 Thread Unmesh joshi
Hi, I have been using struts for an year now and I always thought that expecting name and namespace of the action in URI is very limiting to application developers. It makes it very difficult to have actions mapping to UriTemplates like http://www.example.com/{foo}/{bar}/{baz}. Some times (as i

UriTemplates support in Struts.

2010-03-08 Thread Unmesh joshi
Hi, We wanted to expose Restful URLs as explained in (http://uritemplate.codeplex.com/). Currently struts has two action mappers which support Restful urls. RestFul2ActionMapper and Rest plugin's action mapper. The problem with Restful2 action mapper is that it expects parameter names in url e.

RE: user Digest 27 Nov 2009 09:04:42 -0000 Issue 8940

2009-11-27 Thread Unmesh joshi
>> The default etag value of the object's hashcode is really only meant >> as a helpful default to get you going. I'd highly recommend setting >> your own etag value with something like the underlying db row's >> timestamp or whatever. I think this default implementation is very misleading and you

Use of hashcode as ETag in Rest plugin.

2009-11-26 Thread Unmesh joshi
Hi, Rest plugin's DefaultHttpHeaders class uses hashCode of the model object (if the action is model driven) or hascode of the action object.I guess its a wrong assumption to make that two different objects will have different hashcodes. So we can have same hashcode even if model objects are no

Storing model objects for POST-REDIRECT-GET

2009-11-02 Thread Unmesh joshi
Hi, MessageStoreInterceptor is very handy in preserving error messages. This is very useful in POST-REDIRECT-GET pattern. An action handling POST can store action errors which are available for action/view processing GET request after POST.Many times we also need to preserve values entered by u

Servlet filter as front controller

2009-10-07 Thread Unmesh joshi
Hi,Struts2 uses servlet filter org.apache.struts2.dispatcher.ng.filter.StrutsExecuteFilter as front controller, rather than having a servlet act as front controller. Is there any specific advantage of using servlet filter over servlet (as in struts 1.1)? Thanks,Unmesh

Usecases for ModelDriven interface

2009-05-05 Thread Unmesh joshi
Hi, I am using struts2 on my current project and find ModelDriven interface very inconvenient. The intent of the interface is documented as, "it helps directly populating domain model". But if the domain model is little more complex than a simple bean, it becomes very inconvinient. e.g. If