session_manager_driver
drunc.session_manager.session_manager_driver
Driver for the session manager service.
Classes
SessionManagerDriver(address, token)
Provides an interface to the session manager service.
This class provides the client-side methods required to interact with a remote session manager service, via gRPC connections.
Create a new session manager driver instance.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
address
|
str
|
The address of the session manager service. |
required |
token
|
Token
|
The token for authentication. |
required |
**kwargs
|
Additional keyword arguments for the driver. |
required |
Source code in drunc/session_manager/session_manager_driver.py
Methods:
describe(timeout=60)
Describe the session manager service.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
timeout
|
int | float
|
The timeout for the gRPC call in seconds. |
60
|
Returns:
| Type | Description |
|---|---|
Description
|
A response containing the description of the service. |
Source code in drunc/session_manager/session_manager_driver.py
list_all_configs(timeout=60)
List all available configurations in the session manager.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
timeout
|
int | float
|
The timeout for the gRPC call in seconds. |
60
|
Returns:
| Type | Description |
|---|---|
AllConfigKeys
|
A response containing all available configuration keys. |
Source code in drunc/session_manager/session_manager_driver.py
list_all_sessions(timeout=60)
List all active sessions managed by the session manager.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
timeout
|
int | float
|
The timeout for the gRPC call in seconds. |
60
|
Returns:
| Type | Description |
|---|---|
AllActiveSessions
|
A response containing a list of all active sessions. |
Source code in drunc/session_manager/session_manager_driver.py
load_session(file, session_id, timeout=60)
Load a session based on the provided configuration key.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
file
|
str
|
The file containing the session to load. |
required |
session_id
|
str
|
The ID of the session to load. |
required |
timeout
|
int | float
|
The timeout for the gRPC call in seconds. |
60
|
Returns:
| Name | Type | Description |
|---|---|---|
LoadSessionResponse |
LoadSessionResponse
|
A response containing loaded session metadata. |