Gaea python client
- git clone https://github.com/aducode/Gaeapy.git
- cd Gaeapy
- python setup.py install
from gaea.core import String, Int, Serializer, serializer
from gaea.core import service, operation
from gaea.client import proxy
serializer(name=String, age=Int)
class Persion(Serializer):
"""
Persion类
"""
pass
@proxy(('127.0.0.1', 9090))
@service()
class PersionService(object):
@operation(name='getPersionById', args=(Int,), ret=Persion)
def get_persion_by_id(persion_id):
pass
if __name__ == '__main__':
persion_service = PersionService()
persion = persion_service.get_persion_by_id(0)
- 支持枚举类型
- 规范异常
- 支持Serializable类继承关系