【问题标题】:Are there any open-source references for the web2py remote-procedure-calls?web2py 远程过程调用是否有任何开源参考?
【发布时间】:2011-10-07 22:56:43
【问题描述】:

web2pyremote procedure calls(即@service.run)是否有任何开源参考资料可以从中获取信息并将其发布到数据库中的表中?

【问题讨论】:

  • 我不确定,但如果您在mailing list 上发布更多详细信息,可能会有人提供帮助。
  • 我认为这实际上与 App Engine 没有任何关系,不是吗?
  • 我打算部署到 GAE,但是是的,也许标签是错误的。对不起。

标签: python rpc web2py


【解决方案1】:

@service.run 不是很有用,它更适合在您继续使用 xmlrpc 或 soap 或 jsonrpc 之前进行测试,而不是其他任何东西。你应该使用一个宁静的界面来满足你的要求。例如:

db.define_table('mytable,Field('name'))

@request.restful()
def callme():
    def GET(id):
        return db.mytable(id)
    def POST(name):
        return db.mytable.insert(name=name)
    return locals()

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2022-07-08
    • 2013-07-11
    • 2023-03-30
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-01-04
    • 1970-01-01
    相关资源
    最近更新 更多