|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.shibboleth.metadata.pipeline.AbstractComponent
net.shibboleth.metadata.pipeline.BaseStage<ItemType>
net.shibboleth.metadata.pipeline.BaseIteratingStage<DomElementItem>
net.shibboleth.metadata.dom.saml.PullUpCacheDurationStage
public class PullUpCacheDurationStage
For each Item collection element that is a SAML EntitiesDescriptor this stage will scan all descendant EntitiesDescriptors and EntityDescriptors, determine the shortest cache duration, set that on the root EntitiesDescriptor and remove the cache duration from all descendants.
| Field Summary | |
|---|---|
private long |
maxCacheDuration
The maximum cache duration in milliseconds. |
private long |
minCacheDuration
The minimum cache duration in milliseconds. |
| Constructor Summary | |
|---|---|
PullUpCacheDurationStage()
|
|
| Method Summary | |
|---|---|
protected boolean |
doExecute(DomElementItem item)
Processes a given Item. |
long |
getMaximumCacheDuration()
Gets the maximum cache duration in milliseconds. |
long |
getMinimumCacheDuration()
Gets the minimum cache duration in milliseconds. |
protected Long |
getShortestCacheDuration(Element descriptor)
Gets the shorts cache duration for a given entity and entities descriptor an all its descendant descriptors. |
protected void |
setCacheDuration(Element descriptor,
Long cacheDuration)
Sets the cache duration on the given descriptor. |
void |
setMaximumCacheDuration(long duration)
Sets the maximum cache duration in milliseconds. |
void |
setMinimumCacheDuration(long duration)
Sets the minimum cache duration in milliseconds. |
| Methods inherited from class net.shibboleth.metadata.pipeline.BaseIteratingStage |
|---|
doExecute |
| Methods inherited from class net.shibboleth.metadata.pipeline.BaseStage |
|---|
execute |
| Methods inherited from class net.shibboleth.metadata.pipeline.AbstractComponent |
|---|
doInitialize, equals, getId, getInitializationInstant, hashCode, initialize, isInitialized, setId |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface net.shibboleth.metadata.pipeline.Component |
|---|
getId, getInitializationInstant, initialize, isInitialized |
| Field Detail |
|---|
private long minCacheDuration
0
private long maxCacheDuration
| Constructor Detail |
|---|
public PullUpCacheDurationStage()
| Method Detail |
|---|
public long getMinimumCacheDuration()
public void setMinimumCacheDuration(long duration)
duration - the minimum cache duration in millisecondspublic long getMaximumCacheDuration()
public void setMaximumCacheDuration(long duration)
duration - maximum cache duration in milliseconds, must be greater than 0
protected boolean doExecute(DomElementItem item)
throws StageProcessingException
doExecute in class BaseIteratingStage<DomElementItem>item - Item on which to operate
StageProcessingException - thrown if there is a problem with the stage processingprotected Long getShortestCacheDuration(Element descriptor)
descriptor - descriptor from which to get the shortest cache duration
protected void setCacheDuration(Element descriptor,
Long cacheDuration)
minCacheDuration then the minimum cache
duration is set. If the given cache duration is greater than maxCacheDuration then the maximum cache
duration is set. Otherwise the given cache duration is set.
descriptor - entity or entities descriptor to receive the cache duration, never nullcacheDuration - cache duration to be set, may be null
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||