public interface SessionService
Modifier and Type | Method and Description |
---|---|
void |
deleteSession(String id,
boolean forceCleanup)
Deletes a SAS session with the option to force cleanup, which stops the remote SAS process (if necessary) and cleans up
the transient workspace (if it exists).
|
void |
deleteSessions(Set<String> ids,
boolean forceCleanup)
Deletes the SAS sessions with the specified identifiers with the option to force cleanup that will stop the remote SAS processes (if necessary) and cleanup
the transient workspaces (if they exist).
|
SasSession |
endSession(String id)
Ends a SAS session.
|
Set<SasSession> |
getAllSessions()
Gets a list of all of the SAS sessions for all of the users.
|
Set<SasSession> |
getCurrentUserSessions()
Gets a list of all of the SAS sessions for the current user.
|
String |
getListingContents(String id)
Gets the SAS listing file for the SAS session, if the size of the file does not exceed 5 megabytes (5,242,880 bytes).
|
long |
getListingSize(String id)
Gets the size (in bytes) of the listing file for the SAS session.
|
String |
getLogContents(String id)
Gets the SAS log file contents for the SAS session, if the size of the file does not exceed 5 megabytes (5,242,880 bytes).
|
long |
getLogSize(String id)
Gets the size (in bytes) of the log file for the SAS session.
|
SasSession |
getSession(String id)
Gets the SAS session with the identifier.
|
Set<SasSession> |
getSessionsByUser(String userId)
Gets a list of the SAS sessions for the user with the identifier.
|
String |
saveListingToCurrentUserWorkspace(String id,
String lstPath)
Saves the SAS listing file for the SAS session to the current user's workspace, in the specified location.
|
String |
saveLogToCurrentUserWorkspace(String id,
String logPath)
Saves the SAS log file for the SAS session to the current user's workspace, in the specified location.
|
void deleteSession(String id, boolean forceCleanup) throws SessionNotFoundException, SessionException
id
- the identifier of the SAS session.forceCleanup
- indicates whether to stop the remote SAS process (if necessary) and cleanup the transient workspace (if it exists).SessionNotFoundException
- thrown when the SAS session with the identifier does not exist.SessionException
- thrown when there is an issue deleting the SAS session.SasSession endSession(String id) throws SessionNotFoundException, SessionException
id
- the identifier of the SAS session.SessionNotFoundException
- thrown when the SAS session with the identifier does not exist.SessionException
- thrown if there is an issue ending the SAS session.void deleteSessions(Set<String> ids, boolean forceCleanup)
ids
- the SAS sessions.forceCleanup
- indicates whether to stop the remote SAS process (if necessary) and cleanup the transient workspace (if it exists).Set<SasSession> getAllSessions()
Set<SasSession> getCurrentUserSessions()
SasSession getSession(String id) throws SessionNotFoundException
id
- the identifier that represents the SAS sessionSessionNotFoundException
- thrown when the SAS session does not exist.String getLogContents(String id) throws SessionNotFoundException, SessionException
id
- the identifier of the SAS session.SessionNotFoundException
- thrown when the SAS session does not exist.SessionException
- thrown when there is an issue getting the contents of the SAS log file.long getLogSize(String id) throws SessionNotFoundException, SessionException
id
- the identifier of the SAS session.SessionNotFoundException
- thrown when the SAS session does not exist.SessionException
- thrown when there is an issue getting the size of the SAS log file.String getListingContents(String id) throws SessionNotFoundException, SessionException
id
- the identifier of the SAS session.SessionNotFoundException
- thrown when the SAS session does not exist.SessionException
- thrown when there is an issue getting the contents of the SAS listing file.long getListingSize(String id) throws SessionNotFoundException, SessionException
id
- the identifier of the SAS session.SessionNotFoundException
- thrown when the SAS session does not exist.SessionException
- thrown when there is an issue getting the size of the SAS listing fileSet<SasSession> getSessionsByUser(String userId)
userId
- identifier of the user who started the SAS session.String saveLogToCurrentUserWorkspace(String id, String logPath) throws SessionNotFoundException, SessionException
id
- the identifier of the SAS session.logPath
- the full path of destination log file.SessionNotFoundException
- thrown when the SAS session does not exist.SessionException
- thrown when there is an issue saving the contents of the SAS log file.String saveListingToCurrentUserWorkspace(String id, String lstPath) throws SessionNotFoundException, SessionException
id
- the identifier of the SAS session.lstPath
- the full path of SAS listing file.SessionNotFoundException
- thrown when the SAS session does not exist.SessionException
- thrown when there is an issue saving the contents of the SAS log file.Copyright (c) 2019, SAS Institute Inc., Cary, NC, USA