|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jdiameter.client.impl.router.RouterImpl
public class RouterImpl
| Nested Class Summary | |
|---|---|
protected class |
RouterImpl.AnswerEntry
|
protected class |
RouterImpl.RedirectEntry
|
| Field Summary | |
|---|---|
static int |
ALL_APPLICATION
|
static int |
ALL_HOST
|
static int |
ALL_REALM
|
static int |
ALL_SESSION
|
static int |
ALL_USER
|
protected IConcurrentFactory |
concurrentFactory
|
static int |
DONT_CACHE
|
protected boolean |
isStopped
|
protected MetaData |
metaData
|
static int |
REALM_AND_APPLICATION
|
int |
REDIRECT_TABLE_SIZE
|
protected java.util.concurrent.ScheduledFuture |
redirectEntryHandler
|
protected java.util.concurrent.ScheduledExecutorService |
redirectScheduler
|
protected java.util.concurrent.ConcurrentHashMap<RouterImpl.RedirectEntry,RouterImpl.RedirectEntry> |
redirectTable
|
protected java.lang.Runnable |
redirectTask
|
static int |
REQUEST_TABLE_CLEAR_SIZE
|
static int |
REQUEST_TABLE_SIZE
|
protected java.util.Map<java.lang.Long,RouterImpl.AnswerEntry> |
requestEntryTable
|
protected java.util.concurrent.locks.ReadWriteLock |
requestLock
|
protected java.util.List<java.lang.Long> |
requestSortedEntryTable
|
| Constructor Summary | |
|---|---|
RouterImpl(IConcurrentFactory concurrentFactory,
Configuration config,
MetaData aMetaData)
|
|
| Method Summary | |
|---|---|
protected boolean |
checkRealm(java.lang.String name)
|
void |
destroy()
Release all resources |
IPeer |
getPeer(IMessage message,
IPeerTable manager)
Return peer from inner peer table by predefined pameters |
protected IPeer |
getPeerPredProcessing(IMessage message,
java.lang.String destRealm,
java.lang.String destHost)
|
java.lang.String |
getRealmForPeer(java.lang.String destHost)
Return realm of peer by fqdn |
protected java.lang.String[] |
getRealmPeers(java.lang.String key)
|
protected java.util.Set<java.lang.String> |
getRealmsName()
|
java.lang.String[] |
getRequestRouteInfo(long hopByHopIdentifier)
Return Request route info |
protected void |
init()
|
protected void |
loadConfiguration(Configuration config)
|
protected void |
redirectProcessing(IMessage message,
java.lang.String destRealm,
java.lang.String destHost)
|
void |
registerRequestRouteInfo(IMessage request)
Register route information by received request. |
protected IPeer |
selectPeer(java.util.List<IPeer> avaliblePeers)
|
void |
start()
Start inner time facilities |
void |
stop()
Stop inner time facilities |
void |
updateRedirectInformation(IMessage answer)
Update redirect information |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int DONT_CACHE
public static final int ALL_SESSION
public static final int ALL_REALM
public static final int REALM_AND_APPLICATION
public static final int ALL_APPLICATION
public static final int ALL_HOST
public static final int ALL_USER
protected MetaData metaData
public final int REDIRECT_TABLE_SIZE
protected java.util.concurrent.ConcurrentHashMap<RouterImpl.RedirectEntry,RouterImpl.RedirectEntry> redirectTable
protected IConcurrentFactory concurrentFactory
protected java.util.concurrent.ScheduledExecutorService redirectScheduler
protected java.lang.Runnable redirectTask
protected java.util.concurrent.ScheduledFuture redirectEntryHandler
public static final int REQUEST_TABLE_SIZE
public static final int REQUEST_TABLE_CLEAR_SIZE
protected java.util.concurrent.locks.ReadWriteLock requestLock
protected java.util.Map<java.lang.Long,RouterImpl.AnswerEntry> requestEntryTable
protected java.util.List<java.lang.Long> requestSortedEntryTable
protected boolean isStopped
| Constructor Detail |
|---|
public RouterImpl(IConcurrentFactory concurrentFactory,
Configuration config,
MetaData aMetaData)
| Method Detail |
|---|
protected void init()
protected void loadConfiguration(Configuration config)
public void registerRequestRouteInfo(IMessage request)
IRouter
registerRequestRouteInfo in interface IRouterrequest - requestpublic java.lang.String[] getRequestRouteInfo(long hopByHopIdentifier)
IRouter
getRequestRouteInfo in interface IRouterhopByHopIdentifier - hop By Hop Indentifier
public void updateRedirectInformation(IMessage answer)
throws InternalException,
RouteException
IRouter
updateRedirectInformation in interface IRouteranswer - redirect answer message
InternalException
RouteException
public IPeer getPeer(IMessage message,
IPeerTable manager)
throws RouteException,
AvpDataException
IRouter
getPeer in interface IRoutermessage - message with routed avpsmanager - instance of peer manager
RouteException
AvpDataException
protected IPeer getPeerPredProcessing(IMessage message,
java.lang.String destRealm,
java.lang.String destHost)
public void start()
IRouter
start in interface IRouterpublic void stop()
IRouter
stop in interface IRouterpublic void destroy()
IRouter
destroy in interface IRouterprotected IPeer selectPeer(java.util.List<IPeer> avaliblePeers)
protected void redirectProcessing(IMessage message,
java.lang.String destRealm,
java.lang.String destHost)
throws AvpDataException
AvpDataExceptionpublic java.lang.String getRealmForPeer(java.lang.String destHost)
IRouter
getRealmForPeer in interface IRouterdestHost - host name
protected boolean checkRealm(java.lang.String name)
protected java.util.Set<java.lang.String> getRealmsName()
protected java.lang.String[] getRealmPeers(java.lang.String key)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||