list_sessions
async
¶
list_sessions(
*,
config_overrides: Optional[AsyncEMRClientConfig] = None,
cluster_id: Optional[ClusterId] = None,
session_states: Optional[SessionStateList] = None,
next_token: Optional[String] = None,
max_results: Optional[MaxResultsNumber] = None,
) -> ListSessionsOutput
Lists the sessions on a cluster. You can filter the results by session state. Newer sessions are returned first.
Parameters:
-
cluster_id(Optional[ClusterId], default:None) –The ID of the cluster to list sessions for.
-
session_states(Optional[SessionStateList], default:None) –An optional filter that limits the results to sessions in the specified states.
-
next_token(Optional[String], default:None) –The pagination token returned by a previous
ListSessionscall. Use it to retrieve the next page of results. -
max_results(Optional[MaxResultsNumber], default:None) –The maximum number of sessions to return in each page of results.
Raises:
-
InternalServerException–This exception occurs when there is an internal failure in the Amazon EMR service.
-
InvalidRequestException–This exception occurs when there is something wrong with user input.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_emr/_services/async_emr.py
2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 | |