----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/2525/#review2859 -----------------------------------------------------------
A couple of questions, but in general this looks good to me. http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js <https://reviews.apache.org/r/2525/#comment6392> What happens if TOKEN_REFRESH_INTERVAL is defined to be greater than the TTL for the tokens, i.e., 1 hour? Shouldn't we really take the smallest of the two when figuring out when to refresh? http://svn.apache.org/repos/asf/shindig/trunk/java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/GadgetsHandlerService.java <https://reviews.apache.org/r/2525/#comment6391> Here you use "tokenttl" all lower-case but in the container.js code you use "tokenTTL". I'm assuming this isn't breaking because the code is case insensitive, but it would be nice for consistency. - Stanton On 2011-10-26 14:31:43, Dan Dumont wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/2525/ > ----------------------------------------------------------- > > (Updated 2011-10-26 14:31:43) > > > Review request for shindig. > > > Summary > ------- > > This change adds the token TTL to the metadata request for a gadget needing > token refresh. > The container uses the token's ttl to manage the refresh cycle of tokens. > > Refresh cycle impl was changed from setInterval to setTimeout because if > intervals are missed due to inability to schedule them > (suspend/sleep/hibernate/busy) > they will *all* be executed in order when able. > > A few TODO's in the code I did not have time to address. > One is configurable token TTL values via ContainerConfig. Another is better > managing refresh cycle when using tokens any of which may have varying > expirations. > > > This addresses bug SHINDIG-1646. > https://issues.apache.org/jira/browse/SHINDIG-1646 > > > Diffs > ----- > > > http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container.util/constant.js > 1189191 > > http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container.util/util.js > 1189191 > > http://svn.apache.org/repos/asf/shindig/trunk/features/src/main/javascript/features/container/container.js > 1189191 > > http://svn.apache.org/repos/asf/shindig/trunk/java/common/src/main/java/org/apache/shindig/auth/AbstractSecurityToken.java > 1189191 > > http://svn.apache.org/repos/asf/shindig/trunk/java/common/src/main/java/org/apache/shindig/auth/BasicSecurityTokenCodec.java > 1189191 > > http://svn.apache.org/repos/asf/shindig/trunk/java/common/src/main/java/org/apache/shindig/auth/BlobCrypterSecurityTokenCodec.java > 1189191 > > http://svn.apache.org/repos/asf/shindig/trunk/java/common/src/main/java/org/apache/shindig/auth/DefaultSecurityTokenCodec.java > 1189191 > > http://svn.apache.org/repos/asf/shindig/trunk/java/common/src/main/java/org/apache/shindig/auth/SecurityTokenCodec.java > 1189191 > > http://svn.apache.org/repos/asf/shindig/trunk/java/common/src/test/java/org/apache/shindig/auth/UrlParameterAuthenticationHandlerTest.java > 1189191 > > http://svn.apache.org/repos/asf/shindig/trunk/java/common/src/test/java/org/apache/shindig/common/testing/FakeGadgetToken.java > 1189191 > > http://svn.apache.org/repos/asf/shindig/trunk/java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/GadgetsHandlerApi.java > 1189191 > > http://svn.apache.org/repos/asf/shindig/trunk/java/gadgets/src/main/java/org/apache/shindig/gadgets/servlet/GadgetsHandlerService.java > 1189191 > > http://svn.apache.org/repos/asf/shindig/trunk/java/gadgets/src/test/java/org/apache/shindig/gadgets/servlet/GadgetsHandlerServiceTest.java > 1189191 > > Diff: https://reviews.apache.org/r/2525/diff > > > Testing > ------- > > Tests updated to cope with interface changes. All tests pass. > > > Thanks, > > Dan > >
