[
https://issues.apache.org/jira/browse/SHINDIG-1548?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13258182#comment-13258182
]
[email protected] commented on SHINDIG-1548:
--------------------------------------------------------
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/4818/#review7066
-----------------------------------------------------------
Overall looks good. Just a few minor things. Please also clean up your tabs,
they should be spaces. If you are using Eclipse use the templates here
http://svn.apache.org/repos/asf/shindig/trunk/etc/eclipse/. They will help
make sure your formatting is correct.
http://svn.apache.org/repos/asf/shindig/trunk/java/gadgets/src/main/java/org/apache/shindig/gadgets/config/CoreUtilConfigContributor.java
<https://reviews.apache.org/r/4818/#comment15670>
need one more space for this comment
http://svn.apache.org/repos/asf/shindig/trunk/java/gadgets/src/main/java/org/apache/shindig/gadgets/config/CoreUtilConfigContributor.java
<https://reviews.apache.org/r/4818/#comment15671>
I prefer if you do TEMPLATES_FEATURE_NAME.equals and
REQUIRE_LIBRARY_PARAM.equals because those will never be null. Also does case
matter here?
http://svn.apache.org/repos/asf/shindig/trunk/java/gadgets/src/main/java/org/apache/shindig/gadgets/config/CoreUtilConfigContributor.java
<https://reviews.apache.org/r/4818/#comment15673>
use Lists.newArrayList()
- Ryan
On 2012-04-20 02:53:53, Erik Bi wrote:
bq.
bq. -----------------------------------------------------------
bq. This is an automatically generated e-mail. To reply, visit:
bq. https://reviews.apache.org/r/4818/
bq. -----------------------------------------------------------
bq.
bq. (Updated 2012-04-20 02:53:53)
bq.
bq.
bq. Review request for Ryan Baxter, Dan Dumont and Stanton Sievers.
bq.
bq.
bq. Summary
bq. -------
bq.
bq. per spec, Gadget should be able to use relative URL to define the
template-libray, but right now when it uses this approach, client side will end
up making a /gadgets/makeRequest call and passes in the relative URL value and
fails with an HTTP status of 400.
bq.
bq. Solution:
bq. At client side, the opensocial-template feature will get the
template-library URL value from global variable "features", so in this patch it
updates the process of generating the init JS which will be passed back to
client side to init the "features" variable(in Class
"org.apache.shindig.gadgets.config.CoreUtilConfigContributor"), adds some
specific logic to handle "template-library" parameter, convert the relative url
to an absolute one.
bq.
bq.
bq. This addresses bug shindig-1548.
bq. https://issues.apache.org/jira/browse/shindig-1548
bq.
bq.
bq. Diffs
bq. -----
bq.
bq.
http://svn.apache.org/repos/asf/shindig/trunk/java/gadgets/src/main/java/org/apache/shindig/gadgets/config/CoreUtilConfigContributor.java
1327432
bq.
bq. Diff: https://reviews.apache.org/r/4818/diff
bq.
bq.
bq. Testing
bq. -------
bq.
bq.
bq. Thanks,
bq.
bq. Erik
bq.
bq.
> Shindig does not accept relative URLs for template libraries
> ------------------------------------------------------------
>
> Key: SHINDIG-1548
> URL: https://issues.apache.org/jira/browse/SHINDIG-1548
> Project: Shindig
> Issue Type: Bug
> Components: Java
> Affects Versions: 2.0.2, 2.5.0-beta1
> Reporter: Craig McClanahan
>
> Section 15.1 of the OpenSocial Templating Spec (version 1.1 at
> <http://opensocial-resources.googlecode.com/svn/spec/1.1/OpenSocial-Templating.xml#rfc.section.15.1>,
> version 2.0 draft at
> <http://opensocial-resources.googlecode.com/svn/spec/2.0/OpenSocial-Templating.xml#rfc.section.15.1>
> states that, when interpreting the URL in a template library request like
> this:
> {code}
> <Require feature="opensocial-templates">
> <Param name="requireLibrary">templates.xml</Param>
> </Require>
> {code}
> that "Relative URLs are interpreted in relation to the location of the Gadget
> Spec XML file." However, Shindig currently generates a /gadgets/makeRequest
> call and passes in the relative URL value ("templates.xml") and fails with an
> HTTP status of 400 (Bad Request) because this URL does not start with "http:"
> or "https:".
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira