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

Issue 4423064: CR for SHINDIG-1525 Enable shindig to run on non-ROOT context path

Can't Edit
Can't Publish+Mail
Start Review
Created:
14 years, 9 months ago by henry.saputra
Modified:
11 years, 3 months ago
Reviewers:
dev-remailer
Base URL:
http://svn.apache.org/repos/asf/shindig/trunk/
Visibility:
Public.

Description

Create new code review entry for Li Xu to fix the svn repo. Please see details in the jira: https://issues.apache.org/jira/browse/SHINDIG-1525

Patch Set 1 #

Total comments: 8
Unified diffs Side-by-side diffs Delta from patch set Stats (+296 lines, -215 lines) Patch
config/container.js View 6 chunks +23 lines, -17 lines 0 comments Download
content/samplecontainer/examples/commoncontainer/assembler.js View 2 chunks +2 lines, -2 lines 0 comments Download
content/samplecontainer/examples/commoncontainer/gadgetCollections.json View 1 chunk +4 lines, -4 lines 0 comments Download
content/samplecontainer/examples/commoncontainer/index.html View 1 chunk +0 lines, -168 lines 0 comments Download
content/samplecontainer/examples/commoncontainer/index.jsp View 1 chunk +171 lines, -0 lines 0 comments Download
content/samplecontainer/examples/commoncontainer/viewController.js View 1 chunk +5 lines, -1 line 0 comments Download
features/src/main/javascript/features/container/gadget_holder.js View 5 chunks +25 lines, -2 lines 2 comments Download
features/src/main/javascript/features/container/init.js View 2 chunks +5 lines, -3 lines 2 comments Download
features/src/main/javascript/features/shindig.container/feature.xml View 1 chunk +1 line, -0 lines 0 comments Download
features/src/main/javascript/features/shindig.container/shindig-container.js View 5 chunks +24 lines, -6 lines 0 comments Download
features/src/main/javascript/features/shindig.uri/uri.js View 1 chunk +1 line, -1 line 2 comments Download
java/common/src/main/java/org/apache/shindig/common/servlet/GuiceServletContextListener.java View 2 chunks +14 lines, -1 line 0 comments Download
java/common/src/main/java/org/apache/shindig/config/JsonContainerConfig.java View 2 chunks +3 lines, -2 lines 0 comments Download
java/common/src/main/java/org/apache/shindig/config/JsonContainerConfigLoader.java View 5 chunks +10 lines, -5 lines 0 comments Download
java/common/src/test/java/org/apache/shindig/config/JsonContainerConfigLoaderTest.java View 1 chunk +1 line, -1 line 0 comments Download
java/gadgets/src/main/java/org/apache/shindig/gadgets/oauth/OAuthModule.java View 2 chunks +6 lines, -2 lines 2 comments Download
java/social-api/src/test/java/org/apache/shindig/social/SocialApiTestsGuiceModule.java View 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 3
henry.saputra
http://codereview.appspot.com/4423064/diff/1/features/src/main/javascript/features/container/gadget_holder.js File features/src/main/javascript/features/container/gadget_holder.js (right): http://codereview.appspot.com/4423064/diff/1/features/src/main/javascript/features/container/gadget_holder.js#newcode90 features/src/main/javascript/features/container/gadget_holder.js:90: osapi.container.GadgetHolder.prototype.relayPath_ = null; shouldnt this be defaulted to /gadgets/files/container/rpc_relay.html ...
14 years, 9 months ago (2011-04-25 22:32:12 UTC) #1
Li Xu
Henry, thanks for reviewing the patch. I uploaded another patch for you to review under ...
14 years, 8 months ago (2011-05-02 21:25:33 UTC) #2
Li Xu
14 years, 8 months ago (2011-05-02 21:31:19 UTC) #3
thanks for reviewing the patch. please see reply below.

A new patch is uploaded under this issue:
http://codereview.appspot.com/4430047/

http://codereview.appspot.com/4423064/diff/1/features/src/main/javascript/fea...
File features/src/main/javascript/features/container/gadget_holder.js (right):

http://codereview.appspot.com/4423064/diff/1/features/src/main/javascript/fea...
features/src/main/javascript/features/container/gadget_holder.js:90:
osapi.container.GadgetHolder.prototype.relayPath_ = null;
On 2011/04/25 22:32:12, henry.saputra wrote:
> shouldnt this be defaulted to /gadgets/files/container/rpc_relay.html ?

Yes, it's defined in container.js so context root can be resolved on the server
end 
and available to common container on the client side.
  "container" : {
    "relayPath": "${CONTEXT_ROOT}/gadgets/files/container/rpc_relay.html"
  }

http://codereview.appspot.com/4423064/diff/1/features/src/main/javascript/fea...
File features/src/main/javascript/features/container/init.js (right):

http://codereview.appspot.com/4423064/diff/1/features/src/main/javascript/fea...
features/src/main/javascript/features/container/init.js:33: 'jsonProxyUrl':
'http://%host%'+window.__CONTEXT_ROOT+'/gadgets/makeRequest',
On 2011/04/25 22:32:12, henry.saputra wrote:
> Where is the window.__CONTEXT_ROOT defined?

window.__CONTEXT_ROOT is defined under index.jsp so it can be available to all
the client side js.
<script type="text/javascript">
window.__CONTEXT_ROOT = '<%=request.getContextPath()%>';
</script>
Please suggest if there's better place to hold this on client side

http://codereview.appspot.com/4423064/diff/1/features/src/main/javascript/fea...
File features/src/main/javascript/features/shindig.uri/uri.js (right):

http://codereview.appspot.com/4423064/diff/1/features/src/main/javascript/fea...
features/src/main/javascript/features/shindig.uri/uri.js:230: setPath:
function(path) { if (path != null ) { path_ = (path[0] === '/' ? '' : '/') +
path; } return bundle; },
On 2011/04/25 22:32:12, henry.saputra wrote:
> Need to check for undefined

Done.

http://codereview.appspot.com/4423064/diff/1/java/gadgets/src/main/java/org/a...
File
java/gadgets/src/main/java/org/apache/shindig/gadgets/oauth/OAuthModule.java
(right):

http://codereview.appspot.com/4423064/diff/1/java/gadgets/src/main/java/org/a...
java/gadgets/src/main/java/org/apache/shindig/gadgets/oauth/OAuthModule.java:127:
store.setDefaultCallbackUrl(config.getString(ContainerConfig.DEFAULT_CONTAINER,
"shindig.signing.global-callback-url"));
On 2011/04/25 22:32:12, henry.saputra wrote:
> Not sure why you change this to look from container. The value is in the
> shindig.properties.

thanks for catching this. It's missing from container.js in the patch submitted.
It supposed to be added  to container.js. so context_root can be resolved there
"shindig.signing.global-callback-url" :
"http://${SERVER_HOST}:${SERVER_PORT}/${CONTEXT_ROOT}gadgets/oauthcallback",
Sign in to reply to this message.

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