public abstract class BasicWebAppActor<T extends BasicWebAppActor,C extends BasicWebAppConfig>
extends org.nustaq.kontraktor.Actor<T>
implements org.nustaq.kontraktor.remoting.base.SessionResurrector
| Modifier and Type | Field and Description |
|---|---|
static String |
BABEL_SERVER_JS_PATH |
static String |
BASH_EXEC |
protected Map<String,BasicWebSessionActor> |
sessions |
protected ISessionStorage |
sessionStorage |
protected org.nustaq.kontraktor.Scheduler[] |
sessionThreads |
static String |
WEBAPP_DIR |
__cbQueue, __clientConnection, __connections, __currentDispatcher, __mailbox, __mailboxCapacity, __mbCapacity, __publishTarget, __remoteId, __scheduler, __self, __stopped, __ticketMachine, connection, sender, userData, zzRoutingGCEnabled, zzServerMsgCallback| Constructor and Description |
|---|
BasicWebAppActor() |
| Modifier and Type | Method and Description |
|---|---|
protected org.nustaq.kontraktor.IPromise<BasicWebSessionActor> |
createSession(String user,
String sessionId,
BasicAuthenticationResult authenticationResult) |
protected ISessionStorage |
createSessionStorage(C config) |
protected org.nustaq.kontraktor.IPromise<BasicAuthenticationResult> |
getCredentials(String user,
String pw,
String jwt)
does a lookup for a user record using 'user' as key.
|
protected org.nustaq.kontraktor.IPromise<String> |
getDirectRequestResponse(String path)
simplified, override handleDirectRequest() for full control+access to http header and response type
|
protected org.nustaq.kontraktor.IPromise<BasicWebSessionActor> |
getSession(String user,
String sessionId,
BasicAuthenticationResult authenticationResult) |
protected abstract Class |
getSessionClazz() |
protected org.nustaq.kontraktor.IPromise<BasicWebSessionActor> |
getSessionForReanimation(String user,
String sessionId) |
ISessionStorage |
getSessionStorage() |
void |
handleDirectRequest(io.undertow.server.HttpServerExchange exchange)
reply a request catched by interceptor, note this is server dependent and bound to undertow.
|
void |
init(C config) |
org.nustaq.kontraktor.IPromise<Object[]> |
login(String user,
String pw,
String jwt)
returns an array of [session actorproxy, userdata]
|
void |
notifySessionEnd(BasicWebSessionActor session) |
org.nustaq.kontraktor.IPromise<org.nustaq.kontraktor.Actor> |
reanimate(String sessionId,
long remoteRefId)
An existing spa client made a request after being inactive for a long time.
|
__addDeadLetter, __addRemoteConnection, __addStopHandler, __dispatchRemoteCall, __enqueueCall, __getCachedMethod, __removeRemoteConnection, __stop, __stopImpl, __submit, ask, askMsg, asyncstop, checkThread, close, closeCurrentClient, current, cyclic, delayed, execInThreadPool, execute, getActor, getActorRef, getCallbackSize, getConnections, getCurrentDispatcher, getFactory, getMailboxSize, getQSizes, getReport, getScheduler, getSubMonitorables, getUntypedRef, hasStopped, inside, inThread, isCallbackQPressured, isEmpty, isMailboxPressured, isProxy, isPublished, isRemote, isStopped, ping, router$clientPing, self, serialOn, setServerMsgCallback, stop, stopSafeClose, tell, tellMsg, unpublish, zzkrouterLostClient, zzRoutingRefGCAddDeadLetter, all, all, all, allMapped, AsActor, AsActor, AsActor, AsActor, AsUntypedActor, awaitAll, awaitAll, awaitAll, awaitAll, complete, complete, DeadLetters, InThread, isComplete, isCont, isError, isErrorOrComplete, isResult, isTimeout, promise, race, race, reject, resolve, resolve, stream, SubmitDelayed, yield, yield, yieldCallbackspublic static String WEBAPP_DIR
public static String BASH_EXEC
public static String BABEL_SERVER_JS_PATH
protected org.nustaq.kontraktor.Scheduler[] sessionThreads
protected ISessionStorage sessionStorage
protected Map<String,BasicWebSessionActor> sessions
public void init(C config)
protected ISessionStorage createSessionStorage(C config)
public org.nustaq.kontraktor.IPromise<Object[]> login(String user, String pw, String jwt)
user - pw - jwt - protected org.nustaq.kontraktor.IPromise<BasicAuthenticationResult> getCredentials(String user, String pw, String jwt)
pw - jwt - protected org.nustaq.kontraktor.IPromise<BasicWebSessionActor> getSessionForReanimation(String user, String sessionId)
protected org.nustaq.kontraktor.IPromise<BasicWebSessionActor> getSession(String user, String sessionId, BasicAuthenticationResult authenticationResult)
protected org.nustaq.kontraktor.IPromise<BasicWebSessionActor> createSession(String user, String sessionId, BasicAuthenticationResult authenticationResult)
protected abstract Class getSessionClazz()
public org.nustaq.kontraktor.IPromise<org.nustaq.kontraktor.Actor> reanimate(String sessionId, long remoteRefId)
reanimate in interface org.nustaq.kontraktor.remoting.base.SessionResurrectorsessionId - remoteRefId - sessionId - remoteRefId - public void notifySessionEnd(BasicWebSessionActor session)
public ISessionStorage getSessionStorage()
public void handleDirectRequest(io.undertow.server.HttpServerExchange exchange)
exchange - Copyright © 2017. All rights reserved.