You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@shindig.apache.org by Stanton Sievers <si...@gmail.com> on 2012/11/04 00:12:55 UTC
Review Request: If metadata and tokens are preloaded,
the security token TTL from the metadata is used
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/7857/
-----------------------------------------------------------
Review request for shindig and Dan Dumont.
Description
-------
>From the Jira:
When using the "preloadMetadatas" and "preloadTokens" optional config when constructing an osapi.container.Container, the token refresh schedule will be based on the TTL of whatever is in "preloadMetadatas" and not "preloadTokens".
This addresses bug SHINDIG-1880.
https://issues.apache.org/jira/browse/SHINDIG-1880
Diffs
-----
http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js 1405426
http://svn.apache.org/repos/asf/shindig/trunk/features/src/test/javascript/features/container/container_test.js 1405426
Diff: https://reviews.apache.org/r/7857/diff/
Testing
-------
Wrote some new JSUnits to cover this use case. These are included in the patch. Some of the "window.setTimeout" code in the JSUnit is odd, but it's the only way I could get it to not puke with reference errors saying that "setTimeout" is undefined when it is called in osapi.container.Container.scheduleRefreshTokens_.
Thanks,
Stanton Sievers
Re: Review Request: If metadata and tokens are preloaded,
the security token TTL from the metadata is used
Posted by Henry Saputra <hs...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/7857/#review13103
-----------------------------------------------------------
http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js
<https://reviews.apache.org/r/7857/#comment28238>
Small nit to update the comment header reflecting the actual param name opt_tokenResponse
- Henry Saputra
On Nov. 4, 2012, 3:40 p.m., Stanton Sievers wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/7857/
> -----------------------------------------------------------
>
> (Updated Nov. 4, 2012, 3:40 p.m.)
>
>
> Review request for shindig, Dan Dumont and Matt Franklin.
>
>
> Description
> -------
>
> From the Jira:
> When using the "preloadMetadatas" and "preloadTokens" optional config when constructing an osapi.container.Container, the token refresh schedule will be based on the TTL of whatever is in "preloadMetadatas" and not "preloadTokens".
>
>
> This addresses bug SHINDIG-1880.
> https://issues.apache.org/jira/browse/SHINDIG-1880
>
>
> Diffs
> -----
>
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js 1405426
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/test/javascript/features/container/container_test.js 1405426
>
> Diff: https://reviews.apache.org/r/7857/diff/
>
>
> Testing
> -------
>
> Wrote some new JSUnits to cover this use case. These are included in the patch. Some of the "window.setTimeout" code in the JSUnit is odd, but it's the only way I could get it to not puke with reference errors saying that "setTimeout" is undefined when it is called in osapi.container.Container.scheduleRefreshTokens_.
>
>
> Thanks,
>
> Stanton Sievers
>
>
Re: Review Request: If metadata and tokens are preloaded,
the security token TTL from the metadata is used
Posted by Ryan Baxter <rb...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/7857/#review13101
-----------------------------------------------------------
Ship it!
Ship It!
- Ryan Baxter
On Nov. 4, 2012, 3:40 p.m., Stanton Sievers wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/7857/
> -----------------------------------------------------------
>
> (Updated Nov. 4, 2012, 3:40 p.m.)
>
>
> Review request for shindig, Dan Dumont and Matt Franklin.
>
>
> Description
> -------
>
> From the Jira:
> When using the "preloadMetadatas" and "preloadTokens" optional config when constructing an osapi.container.Container, the token refresh schedule will be based on the TTL of whatever is in "preloadMetadatas" and not "preloadTokens".
>
>
> This addresses bug SHINDIG-1880.
> https://issues.apache.org/jira/browse/SHINDIG-1880
>
>
> Diffs
> -----
>
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js 1405426
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/test/javascript/features/container/container_test.js 1405426
>
> Diff: https://reviews.apache.org/r/7857/diff/
>
>
> Testing
> -------
>
> Wrote some new JSUnits to cover this use case. These are included in the patch. Some of the "window.setTimeout" code in the JSUnit is odd, but it's the only way I could get it to not puke with reference errors saying that "setTimeout" is undefined when it is called in osapi.container.Container.scheduleRefreshTokens_.
>
>
> Thanks,
>
> Stanton Sievers
>
>
Re: Review Request: If metadata and tokens are preloaded,
the security token TTL from the metadata is used
Posted by Stanton Sievers <si...@gmail.com>.
> On Nov. 6, 2012, 7:27 a.m., Matt Franklin wrote:
> > http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js, line 472
> > <https://reviews.apache.org/r/7857/diff/1/?file=185211#file185211line472>
> >
> > This enforces a contract for the PRELOAD_TOKENS property of the preload data where the token response MUST have a TTL if a token exists for a particular gadget.
> >
> > If this is the intent, that is fine. If not, it might be better to fall back to the metadata response TTL in the event that a token doesn't have a TTL.
I think the implied contract is fine with PRELOAD_TOKENS because the format of the preloaded data is that of a TokenResponse, which by definition has a TTL attribute.
- Stanton
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/7857/#review13129
-----------------------------------------------------------
On Nov. 4, 2012, 3:40 p.m., Stanton Sievers wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/7857/
> -----------------------------------------------------------
>
> (Updated Nov. 4, 2012, 3:40 p.m.)
>
>
> Review request for shindig, Dan Dumont and Matt Franklin.
>
>
> Description
> -------
>
> From the Jira:
> When using the "preloadMetadatas" and "preloadTokens" optional config when constructing an osapi.container.Container, the token refresh schedule will be based on the TTL of whatever is in "preloadMetadatas" and not "preloadTokens".
>
>
> This addresses bug SHINDIG-1880.
> https://issues.apache.org/jira/browse/SHINDIG-1880
>
>
> Diffs
> -----
>
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js 1405426
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/test/javascript/features/container/container_test.js 1405426
>
> Diff: https://reviews.apache.org/r/7857/diff/
>
>
> Testing
> -------
>
> Wrote some new JSUnits to cover this use case. These are included in the patch. Some of the "window.setTimeout" code in the JSUnit is odd, but it's the only way I could get it to not puke with reference errors saying that "setTimeout" is undefined when it is called in osapi.container.Container.scheduleRefreshTokens_.
>
>
> Thanks,
>
> Stanton Sievers
>
>
Re: Review Request: If metadata and tokens are preloaded,
the security token TTL from the metadata is used
Posted by Matt Franklin <mf...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/7857/#review13129
-----------------------------------------------------------
http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js
<https://reviews.apache.org/r/7857/#comment28288>
This enforces a contract for the PRELOAD_TOKENS property of the preload data where the token response MUST have a TTL if a token exists for a particular gadget.
If this is the intent, that is fine. If not, it might be better to fall back to the metadata response TTL in the event that a token doesn't have a TTL.
- Matt Franklin
On Nov. 4, 2012, 3:40 p.m., Stanton Sievers wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/7857/
> -----------------------------------------------------------
>
> (Updated Nov. 4, 2012, 3:40 p.m.)
>
>
> Review request for shindig, Dan Dumont and Matt Franklin.
>
>
> Description
> -------
>
> From the Jira:
> When using the "preloadMetadatas" and "preloadTokens" optional config when constructing an osapi.container.Container, the token refresh schedule will be based on the TTL of whatever is in "preloadMetadatas" and not "preloadTokens".
>
>
> This addresses bug SHINDIG-1880.
> https://issues.apache.org/jira/browse/SHINDIG-1880
>
>
> Diffs
> -----
>
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js 1405426
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/test/javascript/features/container/container_test.js 1405426
>
> Diff: https://reviews.apache.org/r/7857/diff/
>
>
> Testing
> -------
>
> Wrote some new JSUnits to cover this use case. These are included in the patch. Some of the "window.setTimeout" code in the JSUnit is odd, but it's the only way I could get it to not puke with reference errors saying that "setTimeout" is undefined when it is called in osapi.container.Container.scheduleRefreshTokens_.
>
>
> Thanks,
>
> Stanton Sievers
>
>
Re: Review Request: If metadata and tokens are preloaded,
the security token TTL from the metadata is used
Posted by Stanton Sievers <si...@gmail.com>.
> On Nov. 5, 2012, 2:05 p.m., Dan Dumont wrote:
> > LGTM.
> > If testing with a functional settimeout is something you want to do, I had implemented it here in the attached patch: https://issues.apache.org/jira/browse/SHINDIG-1864
> > This patch hasn't made it in.
I don't need setTimeout to be functional, I just need it to now blow up when I run the JSUnit. :)
- Stanton
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/7857/#review13091
-----------------------------------------------------------
On Nov. 4, 2012, 3:40 p.m., Stanton Sievers wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/7857/
> -----------------------------------------------------------
>
> (Updated Nov. 4, 2012, 3:40 p.m.)
>
>
> Review request for shindig, Dan Dumont and Matt Franklin.
>
>
> Description
> -------
>
> From the Jira:
> When using the "preloadMetadatas" and "preloadTokens" optional config when constructing an osapi.container.Container, the token refresh schedule will be based on the TTL of whatever is in "preloadMetadatas" and not "preloadTokens".
>
>
> This addresses bug SHINDIG-1880.
> https://issues.apache.org/jira/browse/SHINDIG-1880
>
>
> Diffs
> -----
>
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js 1405426
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/test/javascript/features/container/container_test.js 1405426
>
> Diff: https://reviews.apache.org/r/7857/diff/
>
>
> Testing
> -------
>
> Wrote some new JSUnits to cover this use case. These are included in the patch. Some of the "window.setTimeout" code in the JSUnit is odd, but it's the only way I could get it to not puke with reference errors saying that "setTimeout" is undefined when it is called in osapi.container.Container.scheduleRefreshTokens_.
>
>
> Thanks,
>
> Stanton Sievers
>
>
Re: Review Request: If metadata and tokens are preloaded,
the security token TTL from the metadata is used
Posted by Dan Dumont <dd...@us.ibm.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/7857/#review13091
-----------------------------------------------------------
Ship it!
LGTM.
If testing with a functional settimeout is something you want to do, I had implemented it here in the attached patch: https://issues.apache.org/jira/browse/SHINDIG-1864
This patch hasn't made it in.
- Dan Dumont
On Nov. 4, 2012, 3:40 p.m., Stanton Sievers wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/7857/
> -----------------------------------------------------------
>
> (Updated Nov. 4, 2012, 3:40 p.m.)
>
>
> Review request for shindig, Dan Dumont and Matt Franklin.
>
>
> Description
> -------
>
> From the Jira:
> When using the "preloadMetadatas" and "preloadTokens" optional config when constructing an osapi.container.Container, the token refresh schedule will be based on the TTL of whatever is in "preloadMetadatas" and not "preloadTokens".
>
>
> This addresses bug SHINDIG-1880.
> https://issues.apache.org/jira/browse/SHINDIG-1880
>
>
> Diffs
> -----
>
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js 1405426
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/test/javascript/features/container/container_test.js 1405426
>
> Diff: https://reviews.apache.org/r/7857/diff/
>
>
> Testing
> -------
>
> Wrote some new JSUnits to cover this use case. These are included in the patch. Some of the "window.setTimeout" code in the JSUnit is odd, but it's the only way I could get it to not puke with reference errors saying that "setTimeout" is undefined when it is called in osapi.container.Container.scheduleRefreshTokens_.
>
>
> Thanks,
>
> Stanton Sievers
>
>
Re: Review Request: If metadata and tokens are preloaded,
the security token TTL from the metadata is used
Posted by Stanton Sievers <si...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/7857/#review13152
-----------------------------------------------------------
Ship it!
Committed revision 1406188
- Stanton Sievers
On Nov. 6, 2012, 1:18 p.m., Stanton Sievers wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/7857/
> -----------------------------------------------------------
>
> (Updated Nov. 6, 2012, 1:18 p.m.)
>
>
> Review request for shindig, Dan Dumont and Matt Franklin.
>
>
> Description
> -------
>
> From the Jira:
> When using the "preloadMetadatas" and "preloadTokens" optional config when constructing an osapi.container.Container, the token refresh schedule will be based on the TTL of whatever is in "preloadMetadatas" and not "preloadTokens".
>
>
> This addresses bug SHINDIG-1880.
> https://issues.apache.org/jira/browse/SHINDIG-1880
>
>
> Diffs
> -----
>
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js 1405426
> http://svn.apache.org/repos/asf/shindig/trunk/features/src/test/javascript/features/container/container_test.js 1405426
>
> Diff: https://reviews.apache.org/r/7857/diff/
>
>
> Testing
> -------
>
> Wrote some new JSUnits to cover this use case. These are included in the patch. Some of the "window.setTimeout" code in the JSUnit is odd, but it's the only way I could get it to not puke with reference errors saying that "setTimeout" is undefined when it is called in osapi.container.Container.scheduleRefreshTokens_.
>
>
> Thanks,
>
> Stanton Sievers
>
>
Re: Review Request: If metadata and tokens are preloaded,
the security token TTL from the metadata is used
Posted by Stanton Sievers <si...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/7857/
-----------------------------------------------------------
(Updated Nov. 6, 2012, 1:18 p.m.)
Review request for shindig, Dan Dumont and Matt Franklin.
Changes
-------
Addressing Henry's issue.
Description
-------
>From the Jira:
When using the "preloadMetadatas" and "preloadTokens" optional config when constructing an osapi.container.Container, the token refresh schedule will be based on the TTL of whatever is in "preloadMetadatas" and not "preloadTokens".
This addresses bug SHINDIG-1880.
https://issues.apache.org/jira/browse/SHINDIG-1880
Diffs (updated)
-----
http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js 1405426
http://svn.apache.org/repos/asf/shindig/trunk/features/src/test/javascript/features/container/container_test.js 1405426
Diff: https://reviews.apache.org/r/7857/diff/
Testing
-------
Wrote some new JSUnits to cover this use case. These are included in the patch. Some of the "window.setTimeout" code in the JSUnit is odd, but it's the only way I could get it to not puke with reference errors saying that "setTimeout" is undefined when it is called in osapi.container.Container.scheduleRefreshTokens_.
Thanks,
Stanton Sievers
Re: Review Request: If metadata and tokens are preloaded,
the security token TTL from the metadata is used
Posted by Stanton Sievers <si...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/7857/
-----------------------------------------------------------
(Updated Nov. 4, 2012, 3:40 p.m.)
Review request for shindig, Dan Dumont and Matt Franklin.
Changes
-------
Adding Matt Franklin to the review, as I think Rave may be a stakeholder in this behavior.
Description
-------
>From the Jira:
When using the "preloadMetadatas" and "preloadTokens" optional config when constructing an osapi.container.Container, the token refresh schedule will be based on the TTL of whatever is in "preloadMetadatas" and not "preloadTokens".
This addresses bug SHINDIG-1880.
https://issues.apache.org/jira/browse/SHINDIG-1880
Diffs
-----
http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js 1405426
http://svn.apache.org/repos/asf/shindig/trunk/features/src/test/javascript/features/container/container_test.js 1405426
Diff: https://reviews.apache.org/r/7857/diff/
Testing
-------
Wrote some new JSUnits to cover this use case. These are included in the patch. Some of the "window.setTimeout" code in the JSUnit is odd, but it's the only way I could get it to not puke with reference errors saying that "setTimeout" is undefined when it is called in osapi.container.Container.scheduleRefreshTokens_.
Thanks,
Stanton Sievers