get node information for suanpan microservice
Project description
介绍
使用算盘部署非流计算节点时,可以用 spapp 来获得节点的配置信息,包括
user_id, app_id, node_id 等环境变量
右面板的参数配置
模板的 graph 信息
安装
pip install spapp
Usage
获取环境变量
from spapp import env
if __name__ == "__main__":
print('user_id', env.user_id)
print('app_id', env.app_id)
获取右面板参数,single_text 是右面板参数的名字
from spapp import params
if __name__ == "__main__":
print('single_text', params.get('single_text'))
支持
如果有使用问题或者有其他微服务方面的需求,欢迎联系 mocheng.lgy@xuelangyun.com
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
spapp-0.0.2.tar.gz
(3.4 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
spapp-0.0.2-py3-none-any.whl
(4.4 kB
view details)
File details
Details for the file spapp-0.0.2.tar.gz.
File metadata
- Download URL: spapp-0.0.2.tar.gz
- Upload date:
- Size: 3.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.7.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9eb6448eaa91fa4d89094d1a551334c7c31ecb465c75cf7f1346d203264aceba
|
|
| MD5 |
748e69b3b84b58c44ce628a9f5319027
|
|
| BLAKE2b-256 |
3107d39378e6cf2fec6c1ebe7e8feb7f0a6e67c7dbf75ac3bde0ceed8a4e2d29
|
File details
Details for the file spapp-0.0.2-py3-none-any.whl.
File metadata
- Download URL: spapp-0.0.2-py3-none-any.whl
- Upload date:
- Size: 4.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.7.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a0e42ee1d8897bb04c0a69af0ebf7e0080b730efa948df865d9da9d78f892ca4
|
|
| MD5 |
da6d557a6159dadad8790c315b49ed31
|
|
| BLAKE2b-256 |
8a380ff4f850c42de8b2c6f3c3e6455c3ad86e92cccdfbb1e86eccfbcb7346b3
|