Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(140)

Issue 969041: Support chain style paramaters fror accel servlet

Can't Edit
Can't Publish+Mail
Start Review
Created:
15 years, 9 months ago by zhoresh
Modified:
15 years, 8 months ago
Reviewers:
johnfargo, shindig.remailer
Base URL:
http://svn.apache.org/repos/asf/shindig/trunk
Visibility:
Public.

Description

To support relative urls in an accelerate page we should support chained style paramaters. For example: http://shindig.org/gadgets/accel//http://www.cnn.com/ It does not resolve the issue of no host but absolute pass. I also left open the support of added params to the servlet

Patch Set 1 #

Total comments: 3

Patch Set 2 : Use getServletPath as suggested #

Patch Set 3 : Use UriBuilder to parse the request #

Total comments: 2

Patch Set 4 : Add parsing of paramaters in chain style (also fix cache control time) #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+150 lines, -25 lines) Patch
java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/HtmlAccelServlet.java View 1 2 3 9 chunks +70 lines, -4 lines 3 comments Download
java/gadgets/src/test/java/org/apache/shindig/gadgets/servlet/HtmlAccelServletTest.java View 1 2 3 9 chunks +80 lines, -21 lines 0 comments Download

Messages

Total messages: 13
zhoresh
15 years, 9 months ago (2010-04-21 22:35:46 UTC) #1
johnfargo
http://codereview.appspot.com/969041/diff/1/3 File java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/HtmlAccelServlet.java (right): http://codereview.appspot.com/969041/diff/1/3#newcode237 java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/HtmlAccelServlet.java:237: String path = req.getRequestURI(); slight preference to use the ...
15 years, 9 months ago (2010-04-21 22:47:48 UTC) #2
zhoresh
On Wed, Apr 21, 2010 at 3:47 PM, <johnfargo@gmail.com> wrote: > > http://codereview.appspot.com/969041/diff/1/3 > File ...
15 years, 9 months ago (2010-04-22 00:13:11 UTC) #3
Paul Lindner
If we agree to move to servlet-api-2.5 we can use getContextPath() http://java.sun.com/javaee/5/docs/api/javax/servlet/ServletContext.html#getContextPath() On Apr 21, ...
15 years, 9 months ago (2010-04-22 00:38:43 UTC) #4
zhoresh
On Wed, Apr 21, 2010 at 5:38 PM, Paul Lindner <lindner@inuus.com> wrote: > If we ...
15 years, 9 months ago (2010-04-22 00:44:07 UTC) #5
zhoresh
Use getServletPath as suggested
15 years, 9 months ago (2010-04-23 01:43:23 UTC) #6
zhoresh
Use UriBuilder to parse the request
15 years, 9 months ago (2010-04-23 03:26:58 UTC) #7
johnfargo
Looks pretty good; one last question. http://codereview.appspot.com/969041/diff/11001/12002 File java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/HtmlAccelServlet.java (right): http://codereview.appspot.com/969041/diff/11001/12002#newcode114 java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/HtmlAccelServlet.java:114: data = fetch(uri, ...
15 years, 9 months ago (2010-04-23 03:52:28 UTC) #8
johnfargo
one more nit while I'm at it. http://codereview.appspot.com/969041/diff/11001/12002 File java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/HtmlAccelServlet.java (right): http://codereview.appspot.com/969041/diff/11001/12002#newcode229 java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/HtmlAccelServlet.java:229: private Uri ...
15 years, 9 months ago (2010-04-23 08:11:57 UTC) #9
zhoresh
The change remove the support for refresh and container intentionally. I don't think it add ...
15 years, 9 months ago (2010-04-23 16:47:19 UTC) #10
zhoresh
Add parsing of paramaters in chain style (also fix cache control time)
15 years, 9 months ago (2010-04-23 18:24:31 UTC) #11
johnfargo
Final nits and minor suggestions. LGTM in general; fix what you wish and submit (first ...
15 years, 9 months ago (2010-04-29 22:23:17 UTC) #12
zhoresh
15 years, 8 months ago (2010-04-30 16:34:34 UTC) #13
All done and submitted!

On 2010/04/29 22:23:17, johnfargo wrote:
> Final nits and minor suggestions. LGTM in general; fix what you wish and
submit
> (first CL submitted I believe!)
> 
> http://codereview.appspot.com/969041/diff/16002/18002
> File
>
java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/HtmlAccelServlet.java
> (right):
> 
> http://codereview.appspot.com/969041/diff/16002/18002#newcode112
>
java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/HtmlAccelServlet.java:112:
> // Create request to hanlde parsed params
> nit: s/hanlde/handle/
> 
> http://codereview.appspot.com/969041/diff/16002/18002#newcode117
>
java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/HtmlAccelServlet.java:117:
> return requestParams.get(name).get(0);
> nit: this does a double-lookup. I'd just do:
> List<String> values = reqParams.get(name);
> if (values != null && values.size() > 0) return values.get(0);
> 
> http://codereview.appspot.com/969041/diff/16002/18002#newcode170
>
java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/HtmlAccelServlet.java:170:
> return requestParams.get(name).get(0);
> could just use dataWrapper.getParameter(name)
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b