Internal API endpoint¶
The real API, exposed as web pages or REST API.
-
class
zoe_api.api_endpoint.
APIEndpoint
(master_api, sql_manager: zoe_lib.state.sql_manager.SQLManager)¶ The APIEndpoint class.
-
execution_by_id
(user: Union[None, zoe_lib.state.user.User], execution_id: int) → zoe_lib.state.execution.Execution¶ Lookup an execution by its ID.
-
execution_count
(user: zoe_lib.state.user.User, **filters)¶ Count the number of executions optionally filtered.
-
execution_delete
(user: zoe_lib.state.user.User, exec_id: int)¶ Delete an execution.
-
execution_endpoints
(user: zoe_lib.state.user.User, execution: zoe_lib.state.execution.Execution)¶ Return a list of the services and public endpoints available for a certain execution.
-
execution_list
(user: zoe_lib.state.user.User, **filters)¶ Generate a optionally filtered list of executions.
-
execution_start
(user: zoe_lib.state.user.User, exec_name, application_description)¶ Start an execution.
-
execution_terminate
(user: zoe_lib.state.user.User, exec_id: int, reason: str)¶ Terminate an execution.
-
quota_by_id
(quota_id) → zoe_lib.state.quota.Quota¶ Finds a quota in the database looking it up by its id.
-
quota_by_name
(quota) → zoe_lib.state.quota.Quota¶ Finds a quota in the database looking it up by its name.
-
quota_delete
(user: zoe_lib.state.user.User, quota_id: int)¶ Deletes the quota identified by the ID.
-
quota_list
(user: zoe_lib.state.user.User, **filters) → List[zoe_lib.state.quota.Quota]¶ Generate a optionally filtered list of quotas.
-
quota_new
(user: zoe_lib.state.user.User, quota_data) → int¶ Creates a new quota.
-
quota_update
(user: zoe_lib.state.user.User, quota_id, quota_data)¶ Update a quota.
-
role_by_id
(role_id) → zoe_lib.state.role.Role¶ Finds a role in the database looking it up by its id.
-
role_by_name
(role) → zoe_lib.state.role.Role¶ Finds a role in the database looking it up by its name.
-
role_delete
(user: zoe_lib.state.user.User, role_id: int)¶ Deletes the role identified by the ID.
-
role_list
(user: zoe_lib.state.user.User, **filters) → List[zoe_lib.state.role.Role]¶ Generate a optionally filtered list of roles.
-
role_new
(user: zoe_lib.state.user.User, role_data) → int¶ Creates a new role.
-
role_update
(user: zoe_lib.state.user.User, role_id: int, role_data)¶ Update a role.
-
service_by_id
(user: zoe_lib.state.user.User, service_id: int) → zoe_lib.state.service.Service¶ Lookup a service by its ID.
-
service_list
(user: zoe_lib.state.user.User, **filters)¶ Generate a optionally filtered list of services.
-
service_logs
(user: zoe_lib.state.user.User, service_id)¶ Retrieve the logs for the given service. If stream is True, a file object is returned, otherwise the log contents as a str object.
-
statistics_scheduler
()¶ Retrieve statistics about the scheduler.
-
user_by_id
(user: zoe_lib.state.user.User, user_id: int) → zoe_lib.state.user.User¶ Finds a user in the database looking it up by its username.
-
user_by_name
(username) → zoe_lib.state.user.User¶ Finds a user in the database looking it up by its username.
-
user_delete
(user: zoe_lib.state.user.User, user_id: int)¶ Deletes the user identified by the ID.
-
user_list
(user: zoe_lib.state.user.User, **filters) → List[zoe_lib.state.user.User]¶ Generate a optionally filtered list of users.
-
user_new
(user: zoe_lib.state.user.User, username: str, email: str, role_id: int, quota_id: int, auth_source: str, fs_uid: int) → int¶ Creates a new user.
-
user_update
(user: zoe_lib.state.user.User, user_id, user_data)¶ Update a user.
-
verify_runtime_limit
()¶ Scan the active executions and kill all those that exceed the runtime_limit quota.
-
zapp_validate
(application_description)¶ Validates the passed ZApp description against the supported schema.
-