[JIRA] Created: (JOST-183) AbstractReloadingMetadataProvider code for maxRefreshDelay doesn't match documentation

Rod Widdowson (JIRA) noreply at shibboleth.net
Mon Mar 12 17:00:16 GMT 2012


AbstractReloadingMetadataProvider code for maxRefreshDelay doesn't match documentation
--------------------------------------------------------------------------------------

                 Key: JOST-183
                 URL: https://issues.shibboleth.net/jira/browse/JOST-183
             Project: OpenSAML 2 - Java
          Issue Type: Bug
            Reporter: Rod Widdowson
            Assignee: Chad La Joie
            Priority: Minor


So I would just go and change the documentation, but I think the doco describes a better thing than the code actually does:

The doco says:

1) Determine the earliest date/time of all validUntil and cacheDuration + now
2) If that time is before now, schedule a refresh in minRefreshDelay + now. Stop.
3) If that time is after now + maxRefreshDelay, schedule the a refresh in now + maxRefreshDelay. Stop.
4) Compute the difference between now and time determined in step one.
5) Multiply that number by the refreshDelayFactor to get the delay interval
6) Schedule the next refresh in now + computed delay interval

What the code does AFICS is
1) Determine the earliest date/time of all (validUntil) and (cacheDuration + now) and (now + maxRefreshDelay)
2) If that time is before now, schedule a refresh in minRefreshDelay + now. Stop.
3) Compute the difference between now and time determined in step one.
4) Multiply that number by the refreshDelayFactor to get the delay interval
5) Schedule the next refresh in now + computed delay interval

I actually spotted this when testing the DS with a ridiculously short maxRefreshDelay (5 minutes) and was actually getting a refresh every 3M45S.




--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the commits mailing list