public class FSBasedRetiredTokenPersister extends Object implements TokenPersister
| Modifier and Type | Field and Description |
|---|---|
protected int |
maxTokensInMemory |
protected String |
securityTokenStorageFilePath |
protected TokenStorage |
tokenStorage |
TOKEN_PERSISTER_KEY| Constructor and Description |
|---|
FSBasedRetiredTokenPersister() |
| Modifier and Type | Method and Description |
|---|---|
void |
deleteToken(String tokenId)
Remove the token, given the token id.
|
List<String> |
getRetiredTokens(List<Token> inMemoryTokens)
Obtain the list of tokens that are to be persisted.
|
boolean |
isTokenExist(String tokenID)
Check whether a particular token exists in persistence storage given the token id.
|
boolean |
isTokensExist()
To check whether any retired tokens are persisted, before performing any operations to
manipulate tokens.
|
void |
notifyPersistence()
Notify the persister when persistence needs to happen.
|
void |
persistToken(Token token)
Persist a single token
|
void |
persistTokens(Token[] retiredTokens)
Persist an array of tokens
|
Token |
retrieveToken(String tokenId)
Read a token given it's id.
|
String[] |
retrieveTokenIDs()
Obtain the list of token IDs in persistence.
|
Token[] |
retrieveTokens()
Read all the persisted tokens.
|
void |
run()
When an object implementing interface
Runnable is used
to create a thread, starting the thread causes the object's
run method to be called in that separately executing
thread. |
void |
setConfiguration(AbstractIssuerConfig config)
Pass persister configuration to be set in the persister implementation.
|
void |
setMessageContext(org.apache.axis2.context.MessageContext msgContext)
Set message context in order to get access to message/config context properties.
|
void |
updateToken(Token token)
Update the given token in persistence.
|
protected String securityTokenStorageFilePath
protected int maxTokensInMemory
protected TokenStorage tokenStorage
public boolean isTokensExist()
TokenPersisterisTokensExist in interface TokenPersisterpublic boolean isTokenExist(String tokenID)
TokenPersisterisTokenExist in interface TokenPersisterpublic void persistTokens(Token[] retiredTokens) throws TrustException
TokenPersisterpersistTokens in interface TokenPersisterretiredTokens - array of security tokensTrustExceptionpublic void persistToken(Token token) throws TrustException
TokenPersisterpersistToken in interface TokenPersisterTrustExceptionpublic Token[] retrieveTokens()
TokenPersisterretrieveTokens in interface TokenPersisterpublic Token retrieveToken(String tokenId) throws TrustException
TokenPersisterretrieveToken in interface TokenPersisterTrustExceptionpublic String[] retrieveTokenIDs()
TokenPersisterretrieveTokenIDs in interface TokenPersisterpublic void updateToken(Token token) throws TrustException
TokenPersisterupdateToken in interface TokenPersisterTrustExceptionpublic void deleteToken(String tokenId) throws TrustException
TokenPersisterdeleteToken in interface TokenPersisterTrustExceptionpublic void setConfiguration(AbstractIssuerConfig config) throws TrustException
TokenPersistersetConfiguration in interface TokenPersisterTrustExceptionpublic void setMessageContext(org.apache.axis2.context.MessageContext msgContext)
TokenPersistersetMessageContext in interface TokenPersisterpublic void notifyPersistence()
TokenPersisternotifyPersistence in interface TokenPersisterpublic List<String> getRetiredTokens(List<Token> inMemoryTokens)
inMemoryTokens - list of tokens currently resides in memory.public void run()
Runnable is used
to create a thread, starting the thread causes the object's
run method to be called in that separately executing
thread.
The general contract of the method run is that it may
take any action whatsoever.run in interface RunnableThread.run()Copyright © 2005–2019 Apache Software Foundation. All rights reserved.