public PrimaryBackupSession getOrCreateSession(long sessionId, MemberId memberId) {
    PrimaryBackupSession session = sessions.get(sessionId);
    if (session == null) {
      session = createSession(sessionId, memberId);
    }
    return session;
  }
public PrimaryBackupSession getOrCreateSession ( long sessionId , MemberId memberId ) { PrimaryBackupSession session = sessions . get ( sessionId ) ; if ( session == null ) { session = createSession ( sessionId , memberId ) ; } return session ; }
Gets or creates a service session.

@param sessionId the session to create
@param memberId  the owning node ID
@return the service session