You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@shindig.apache.org by "Kai Feng Zhang (JIRA)" <ji...@apache.org> on 2010/11/03 03:18:24 UTC

[jira] Created: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
---------------------------------------------------------------------------------------------------------------------

                 Key: SHINDIG-1460
                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
             Project: Shindig
          Issue Type: Improvement
          Components: Javascript 
    Affects Versions: 3.0.0
            Reporter: Kai Feng Zhang
             Fix For: 3.0.0
         Attachments: common_container_1101.patch

Working sample page on the new container, there are some issues we have to fix:

1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
mapping of the rpc handler is "gadgets.metadata".

2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
constants.js. Currently the patch provide one in the sample page.

3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
"//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
e=%25nocache%25"

The url began with two slashes. we have to remove them.

One approach is changing it when generating the iframeurl on the server side, in the file of
"DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
src, in the file of "gadgets_holder.js".

Currently the patch is based on the second approach.

----

A new patch including following fixes and a sample page:

1. make gadgets.metadata.get can return the gadget's metadata
2. delete the slashes before the iframeurl
3. add pubsub-2 support in the common container
4. fix the security token issue if the gadget requires
"security-token" feature.

----

Latest patch:
1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
in service.js

2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Re: [jira] Created: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by Michael Hermanto <mh...@gmail.com>.
On Tue, Nov 2, 2010 at 7:18 PM, Kai Feng Zhang (JIRA) <ji...@apache.org>wrote:

> Bug fix and improvement for common container: make gadgets can be rendered
> successfully with the new common container
>
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>         Attachments: common_container_1101.patch
>
> Working sample page on the new container, there are some issues we have to
> fix:
>
> 1. client side called "osapi.gadgets.metadata.get", but server side can't
> find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
>

Can it just be endPoint in
shindig.container.Service.prototype.initializeOsapi_() not configured
properly?
ie: is apiHost_ and apiPath_ specified as to what you want?


>
> 2. when creating the new metadatarequest in "util.js" in the new container,
> it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide
> one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
>

window.__CONTAINER is initialized by init.js. This piggy-backs on the query
param &container= when common container JS is script sourced via Shindig
feature-serving servlet with /gadgets/js/container.js?c=1&container=xxx.
 init.js is already part of container.js, and get executed after all
container JS.


> 3. after the above issues are  fixed, the returned iframeurl in metadata is
> something like this
> "//
> http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
>
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
>
> The url began with two slashes. we have to remove them.
>


> One approach is changing it when generating the iframeurl on the server
> side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client
> side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
>

Please change on the server side, in DefaultIframeUriManager (or in your
class extending it). Client side should just consume the URL verbatim, and
no longer munge on it.
However, I'd need to see the actual code change, so uploading your changes
to codereview.appspot.com will be great.


> Currently the patch is based on the second approach.
>
> ----
>
> A new patch including following fixes and a sample page:
>
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
>
> ----
>
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
>
> 2. remove the leading "//" of the url to server side
>
> --
> This message is automatically generated by JIRA.
> -
> You can reply to this email to add a comment to the issue online.
>
>

Re: [jira] Created: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by Michael Hermanto <mh...@gmail.com>.
On Tue, Nov 2, 2010 at 7:18 PM, Kai Feng Zhang (JIRA) <ji...@apache.org>wrote:

> Bug fix and improvement for common container: make gadgets can be rendered
> successfully with the new common container
>
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>         Attachments: common_container_1101.patch
>
> Working sample page on the new container, there are some issues we have to
> fix:
>
> 1. client side called "osapi.gadgets.metadata.get", but server side can't
> find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
>

Can it just be endPoint in
shindig.container.Service.prototype.initializeOsapi_() not configured
properly?
ie: is apiHost_ and apiPath_ specified as to what you want?


>
> 2. when creating the new metadatarequest in "util.js" in the new container,
> it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide
> one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
>

window.__CONTAINER is initialized by init.js. This piggy-backs on the query
param &container= when common container JS is script sourced via Shindig
feature-serving servlet with /gadgets/js/container.js?c=1&container=xxx.
 init.js is already part of container.js, and get executed after all
container JS.


> 3. after the above issues are  fixed, the returned iframeurl in metadata is
> something like this
> "//
> http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
>
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
>
> The url began with two slashes. we have to remove them.
>


> One approach is changing it when generating the iframeurl on the server
> side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client
> side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
>

Please change on the server side, in DefaultIframeUriManager (or in your
class extending it). Client side should just consume the URL verbatim, and
no longer munge on it.
However, I'd need to see the actual code change, so uploading your changes
to codereview.appspot.com will be great.


> Currently the patch is based on the second approach.
>
> ----
>
> A new patch including following fixes and a sample page:
>
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
>
> ----
>
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
>
> 2. remove the leading "//" of the url to server side
>
> --
> This message is automatically generated by JIRA.
> -
> You can reply to this email to add a comment to the issue online.
>
>

[jira] Commented: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "sun qiao yun (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12928110#action_12928110 ] 

sun qiao yun commented on SHINDIG-1460:
---------------------------------------

To make it more clear, following list are what we did in the patch:

1. change the getMetadata request from  "osapi.gadgets.metadata.get" to "osapi.gadgets.metadata" in service.js.

2. add pubsub-2 support in container.

3. remove the leading "//" when generating iframeUrl.

4. fix the security token issue if the gadget requires security-token feature.

5. need provide the container value in the sample page.

> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch, common_container_1104.patch
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "Kai Feng Zhang (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kai Feng Zhang updated SHINDIG-1460:
------------------------------------

    Attachment: common_container_1101.patch

Latest patch:
1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
in service.js

2. remove the leading "//" of the url to server side

> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "sun qiao yun (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12928214#action_12928214 ] 

sun qiao yun commented on SHINDIG-1460:
---------------------------------------

Please review the code at : http://codereview.appspot.com/2897041/
Thanks!

> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch, common_container_1104.patch
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "sun qiao yun (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

sun qiao yun updated SHINDIG-1460:
----------------------------------

    Attachment: common_container_1105.patch
                sample.html

A sample page created with the common container, put three gadgets on the same page. Following features will be tested: osapi, pubsub-2.

> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch, common_container_1104.patch, common_container_1105.patch, sample.html
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "sun qiao yun (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12928105#action_12928105 ] 

sun qiao yun commented on SHINDIG-1460:
---------------------------------------

@Michael, thanks for the comments.
1. shindig.container.Service.prototype.initializeOsapi_() configured gadgets.metadata.get, but can't map to the server side implementation, except we change the key from "gadgets.metadata" to "gadgets.metadata.get" on server side, which can be done by adding a name attribute to the Operation description. To keep the consistency, we did the change on the client side.

2. yes, window._CONTAINER is initialized by init.js, and we add the vaule in the sample page just as what you said. As this vaule is not required by the old container,  we put it here just to emphasize it.

3. The url change is done onserver side in DefaultIframeUriManager .

> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] [Closed] (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "Paul Lindner (Closed) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Paul Lindner closed SHINDIG-1460.
---------------------------------


part of 2.5.0-beta1 release.

                
> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 2.5.0-beta1
>            Reporter: Kai Feng Zhang
>             Fix For: 2.5.0-beta1
>
>         Attachments: common_container_1101.patch, common_container_1104.patch, common_container_1105.patch, common_container_1108.patch, sample.html
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

--
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

        

[jira] Resolved: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "Paul Lindner (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Paul Lindner resolved SHINDIG-1460.
-----------------------------------

    Resolution: Fixed

patched by mhermanto. Thanks!


> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch, common_container_1104.patch, common_container_1105.patch, common_container_1108.patch, sample.html
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "Kai Feng Zhang (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12928094#action_12928094 ] 

Kai Feng Zhang edited comment on SHINDIG-1460 at 11/3/10 11:56 PM:
-------------------------------------------------------------------

I upload the patch here: http://codereview.appspot.com/2889041/   , please get a review..thanks.

      was (Author: zhangkf):
    I upload the patch here: http://codereview.appspot.com/2889041/, please get a review..thanks.
  
> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch, common_container_1104.patch
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "Kai Feng Zhang (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kai Feng Zhang updated SHINDIG-1460:
------------------------------------

    Comment: was deleted

(was: I upload the patch here: http://codereview.appspot.com/2889041/   , please get a review..thanks.)

> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch, common_container_1104.patch
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "Michael Hermanto (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12927933#action_12927933 ] 

Michael Hermanto commented on SHINDIG-1460:
-------------------------------------------



Can it just be endPoint in
shindig.container.Service.prototype.initializeOsapi_() not configured
properly?
ie: is apiHost_ and apiPath_ specified as to what you want?



window.__CONTAINER is initialized by init.js. This piggy-backs on the query
param &container= when common container JS is script sourced via Shindig
feature-serving servlet with /gadgets/js/container.js?c=1&container=xxx.
 init.js is already part of container.js, and get executed after all
container JS.





Please change on the server side, in DefaultIframeUriManager (or in your
class extending it). Client side should just consume the URL verbatim, and
no longer munge on it.
However, I'd need to see the actual code change, so uploading your changes
to codereview.appspot.com will be great.




> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "sun qiao yun (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

sun qiao yun updated SHINDIG-1460:
----------------------------------

    Attachment: common_container_1104.patch

latest patch

> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch, common_container_1104.patch
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "Christiaan Hees (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12927795#action_12927795 ] 

Christiaan Hees commented on SHINDIG-1460:
------------------------------------------

Can it also handle https? I see only a check for "http" in the patch for DefaultIframeUriManager.


> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "Han Nguyen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12927843#action_12927843 ] 

Han Nguyen commented on SHINDIG-1460:
-------------------------------------

@Christiaan, it check for string starts with "http" so it should handle https.

@ Kai, thanks for the patch, could you post the patch on code review pls? http://codereview.appspot.com


> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "sun qiao yun (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

sun qiao yun updated SHINDIG-1460:
----------------------------------

    Attachment: common_container_1108.patch

a latest patch

> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch, common_container_1104.patch, common_container_1105.patch, common_container_1108.patch, sample.html
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SHINDIG-1460) Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container

Posted by "Kai Feng Zhang (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-1460?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12928094#action_12928094 ] 

Kai Feng Zhang commented on SHINDIG-1460:
-----------------------------------------

I upload the patch here: http://codereview.appspot.com/2889041/, please get a review..thanks.

> Bug fix and improvement for common container: make gadgets can be rendered successfully with the new common container
> ---------------------------------------------------------------------------------------------------------------------
>
>                 Key: SHINDIG-1460
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-1460
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Javascript 
>    Affects Versions: 3.0.0
>            Reporter: Kai Feng Zhang
>             Fix For: 3.0.0
>
>         Attachments: common_container_1101.patch
>
>
> Working sample page on the new container, there are some issues we have to fix:
> 1. client side called "osapi.gadgets.metadata.get", but server side can't find that method, the key in the
> mapping of the rpc handler is "gadgets.metadata".
> 2. when creating the new metadatarequest in "util.js" in the new container, it used 'container':
> window.__CONTAINER, but window.__CONTAINER is undefined, we need provide one in the sample page or define it in the
> constants.js. Currently the patch provide one in the sample page.
> 3. after the above issues are  fixed, the returned iframeurl in metadata is something like this
> "//http://localhost:8080/gadgets/ifr?url=http%3A%2F%2Flocalhost%3A8080%2Fcontainer%2Fsample-pubsub-2-publisher.xml&
> amp;container=default&view=%25view%25&lang=%25lang%25&country=%25country%25&debug=%25debug%25&nocach
> e=%25nocache%25"
> The url began with two slashes. we have to remove them.
> One approach is changing it when generating the iframeurl on the server side, in the file of
> "DefaultIframeUriManager", another approach is changing it on the client side when setting it to the iframe
> src, in the file of "gadgets_holder.js".
> Currently the patch is based on the second approach.
> ----
> A new patch including following fixes and a sample page:
> 1. make gadgets.metadata.get can return the gadget's metadata
> 2. delete the slashes before the iframeurl
> 3. add pubsub-2 support in the common container
> 4. fix the security token issue if the gadget requires
> "security-token" feature.
> ----
> Latest patch:
> 1. change osapi.gadgets.metadata.get to osapi.gadgets.metadata
> in service.js
> 2. remove the leading "//" of the url to server side

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.