[SERVLET_SPEC-4] Clarification on javadoc and spec examples on AsyncContext#dispatch() Created: 27/Jul/11  Updated: 22/Dec/11  Resolved: 22/Dec/11

Status: Closed
Project: servlet-spec
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major
Reporter: Shing Wai Chan Assignee: Shing Wai Chan
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

In javadoc of javax.servlet.AsyncContext#dispatch(), we have
...
getRequestDispatcher("/url/B").forward(request,response);
...
getRequestDispatcher("/url/B").forward(request,response);

It should be
request.getRequestDispatcher("/url/B").forward(request,response);
or
servletContext.getRequestDispatcher("/url/B").forward(request,response);

In p.15 of spec pdf file, there is a similar issue.
Also, one may like to add "//" for comment and additional information from javadoc.



 Comments   
Comment by Shing Wai Chan [ 29/Jul/11 ]

In p14 of Servlet 3.0 spec, we have
"public void addListener(asyncListener, req, res) - Registers the
listener for notifications of time out, error and complete with the most ..."

"public void addListener(asyncListener) - Registers the given listener
for notifications of time out, error and complete with the most recent ..."

It should also the onStartAsync here.

Also, in p14, we have "buy may be used in order to release any resources".
The "buy" should be "but" here.

Comment by Shing Wai Chan [ 15/Dec/11 ]

The javadoc is fixed:
Sending javax.servlet/src/main/java/javax/servlet/AsyncContext.java
Sending javax.servlet/src/main/java/javax/servlet/ServletRequest.java
Transmitting file data ..
Committed revision 51595.

Comment by Shing Wai Chan [ 22/Dec/11 ]

Sending servletobjects.fm
Transmitting file data .
Committed revision 3.

Generated at Fri Jul 29 19:34:13 UTC 2016 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.