list_sessions
¶
list_sessions(
work_group: WorkGroupName,
*,
config_overrides: Optional[AthenaClientConfig] = None,
state_filter: Optional[SessionState] = None,
max_results: Optional[MaxSessionsCount] = None,
next_token: Optional[SessionManagerToken] = None,
) -> ListSessionsResponse
Lists the sessions in a workgroup that are in an active state like CREATING, CREATED, IDLE, or BUSY. Newer sessions are listed first; older sessions are listed later.
Parameters:
-
work_group(WorkGroupName) –The workgroup to which the session belongs.
-
state_filter(Optional[SessionState], default:None) –A filter for a specific session state. A description of each state follows.
CREATING- The session is being started, including acquiring resources.CREATED- The session has been started.IDLE- The session is able to accept a calculation.BUSY- The session is processing another task and is unable to accept a calculation.TERMINATING- The session is in the process of shutting down.TERMINATED- The session and its resources are no longer running.DEGRADED- The session has no healthy coordinators.FAILED- Due to a failure, the session and its resources are no longer running. -
max_results(Optional[MaxSessionsCount], default:None) –The maximum number of sessions to return.
-
next_token(Optional[SessionManagerToken], default:None) –A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextTokenfrom the response object of the previous page call.
Raises:
-
InternalServerException–Indicates a platform issue, which may be due to a transient condition or outage.
-
InvalidRequestException–Indicates that something is wrong with the input to the request. For example, a required parameter may be missing or out of range.
-
ResourceNotFoundException–A resource, such as a workgroup, was not found.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_athena/_services/athena.py
3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 | |