Python 的微服务框架 Nameko

码农软件 · 软件分类 · 微服务框架 · 2019-03-18 07:26:31

软件介绍

Nameko 是一个 Python 的微服务框架,可以让你专注于应用逻辑。

主要特性:

    • AMQP RPC and Events (pub-sub)

    • HTTP GET, POST & websockets

    • 简化开发的命令行工具

    • 单元和集成测试工具

    示例代码:

# helloworld.py

from nameko.rpc import rpc

class GreetingService:
    name = "greeting_service"

    @rpc
    def hello(self, name):
        return "Hello, {}!".format(name)

运行方法:

$ nameko run helloworld
starting services: greeting_service
...

测试:

$ nameko shell
>>> n.rpc.greeting_service.hello(name="ナメコ")
'Hello, ナメコ!'

本文地址:https://www.codercto.com/soft/d/1593.html

Complete Web Monitoring

Complete Web Monitoring

Alistair Croll、Sean Power / O'Reilly Media / June 29, 2009 / GBP 39.99

Do you know the true value of your website to your organization? i??Complete Web Monitoringi?? shows you how to integrate several different views of your online business - including analytics, back-en......一起来看看 《Complete Web Monitoring》 这本书的介绍吧!

RGB转16进制工具
RGB转16进制工具

RGB HEX 互转工具

随机密码生成器
随机密码生成器

多种字符组合密码

html转js在线工具
html转js在线工具

html转js在线工具