okay, then here is my feedback notes after studying chapter 10 of the user's guide.
1- quoting from users guide:
"every interceptor must call the proceed() method otherwise the entity would not be written"
if the context.proceed() method must be called by each interceptor, shouldn't it be called internally by jersey.
the code that calls the method aroundWriteTo() method, can simply call context.proceed() method after that invocation.
2- shouldn't zipping and unzipping be automatically done by jersey, instead of letting developers define their own Interceptors to compress and decompress entity body, it will be much easier for them to have built-in ready to use interceptors that make the task easier to them.
3- name-bound filter or interceptors:
the current procedure for defining name-bound filters or interceptors is:
1- define a custom annotation
2- annotate the annotation with @NameBinding
3- annotate the filter with the custom-defined annotation
4- annotate any resource method(s) that the filter or interceptor must be applied on.
wouldn't it be easier to apply filters or interceptors to resource methods using only existing annotations (without defining additional ones)
something like:
@GET
@Path("too-much-data")
@Filter(GZIPWriterInterceptor.class)
public String getVeryLongString() {
String str = ... // very long string
return str;
}
this would eliminate the first 3 steps defined above.