use of com.iplanet.dpro.session.share.SessionRequest in project OpenAM by OpenRock.
the class Session method addInternalSessionListener.
/**
* Add listener to Internal Session.
*/
public void addInternalSessionListener() {
try {
if (SessionNotificationHandler.handler == null) {
SessionNotificationHandler.handler = new SessionNotificationHandler();
PLLClient.addNotificationHandler(SESSION_SERVICE, SessionNotificationHandler.handler);
}
String url = WebtopNaming.getNotificationURL().toString();
if (isLocal()) {
sessionService.addSessionListener(sessionID, url);
} else {
SessionRequest sreq = new SessionRequest(SessionRequest.AddSessionListener, sessionID.toString(), false);
sreq.setNotificationURL(url);
requests.sendRequestWithRetry(getSessionServiceURL(), sreq, this);
}
} catch (Exception e) {
//todo : something! :-D
}
}
Aggregations