asos-1.0.8
توضیحات
A scheduler of stuff (ASOS)
| ویژگی | مقدار |
|---|---|
| سیستم عامل | OS Independent |
| نام فایل | asos-1.0.8 |
| نام | asos |
| نسخه کتابخانه | 1.0.8 |
| نگهدارنده | [] |
| ایمیل نگهدارنده | [] |
| نویسنده | Pavel Kim |
| ایمیل نویسنده | hello@pavelkim.ru |
| آدرس صفحه اصلی | https://github.com/python-asos/ |
| آدرس اینترنتی | https://pypi.org/project/asos/ |
| مجوز | - |
A scheduler of stuff (ASOS)
====================
This is a task manager, sort of. Supports plugins for storage and for executors.
Configuration
-------------
Takes quite few parameters:
```json
{
"uuid": "current_instance_name",
"storage_plugin": "mysql"
}
```
Storage plugins
---------------
Should implement two methods:
1. Get all active tasks
2. Add a result of task execution
```python
class Storage():
def get_tasks(self):
return {task_id: task, ...}
def add(self, task_id, task, env, result, dump=None):
return True
```
Executor plugins
----------------
Does the actual work. The name of plugin should match a `task_type` field.
```python
class Executor():
def do(self, task, env):
return result, dump
```
Tasks
-----
Task objects represent tasks that need to be done. Should contain all additional parameters, required by your plugins.
```json
{
"task_type": executor_plugin_name,
"task_interval": 60,
"additional_param": "value"
}
```
زبان مورد نیاز
| مقدار | نام |
|---|---|
| >=3.6 | Python |
نحوه نصب
نصب پکیج whl asos-1.0.8:
pip install asos-1.0.8.whl
نصب پکیج tar.gz asos-1.0.8:
pip install asos-1.0.8.tar.gz