Class InitializerState
- java.lang.Object
- 
- org.keycloak.models.sessions.infinispan.entities.SessionEntity
- 
- org.keycloak.models.sessions.infinispan.initializer.InitializerState
 
 
- 
- All Implemented Interfaces:
- Serializable
 
 @SerializeWith(ExternalizerImpl.class) public class InitializerState extends SessionEntity Note that this state is NOT thread safe. Currently it is only used from single thread so it's fine but further optimizations might need to revisit this (seeInfinispanCacheInitializer).- Author:
- Marek Posolda
- See Also:
- Serialized Form
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classInitializerState.ExternalizerImpl
 - 
Constructor SummaryConstructors Constructor Description InitializerState(int segmentsCount)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)intgetProgressIndicator()Return indication of progress - changes upon progressintgetSegmentsCount()Getter for the segments count.List<Integer>getSegmentsToLoad(int segmentToLoad, int maxSegmentCount)Return next un-finished segments in the next row of segments.inthashCode()booleanisFinished()Return true just if computation is entirely finished (all segments are true)voidmarkSegmentFinished(int index)StringtoString()- 
Methods inherited from class org.keycloak.models.sessions.infinispan.entities.SessionEntitygetRealmId, mergeRemoteEntityWithLocalEntity, setRealmId
 
- 
 
- 
- 
- 
Method Detail- 
getSegmentsCountpublic int getSegmentsCount() Getter for the segments count.- Returns:
- The number of segments of the state
 
 - 
isFinishedpublic boolean isFinished() Return true just if computation is entirely finished (all segments are true)
 - 
getProgressIndicatorpublic int getProgressIndicator() Return indication of progress - changes upon progress
 - 
getSegmentsToLoadpublic List<Integer> getSegmentsToLoad(int segmentToLoad, int maxSegmentCount) Return next un-finished segments in the next row of segments.- Parameters:
- segmentToLoad- The segment we are loading
- maxSegmentCount- The max segment to load
- Returns:
- The list of segments to work on this step
 
 - 
markSegmentFinishedpublic void markSegmentFinished(int index) 
 - 
hashCodepublic int hashCode() - Specified by:
- hashCodein class- SessionEntity
 
 - 
equalspublic boolean equals(Object obj) - Specified by:
- equalsin class- SessionEntity
 
 
- 
 
-