推荐学习书目
› Learn Python the Hard Way
Python Sites
› PyPI - Python Package Index
› http://diveintopython.org/toc/index.html
› Pocoo
值得关注的项目
› PyPy
› Celery
› Jinja2
› Read the Docs
› gevent
› pyenv
› virtualenv
› Stackless Python
› Beautiful Soup
› 结巴中文分词
› Green Unicorn
› Sentry
› Shovel
› Pyflakes
› pytest
Python 编程
› pep8 Checker
Styles
› PEP 8
› Google Python Style Guide
› Code Style from The Hitchhiker's Guide
ri0day
V2EX  ›  Python

memcache 如何做到跨语言访问

  •  
  •   ri0day ·
    ri0day · Dec 13, 2011 · 5765 views
    This topic created in 5404 days ago, the information mentioned may be changed or developed.
    memcache 能做到跨语言访问么。如果vaule 是简答的文本是没有问题。可以用key读出来。如果vaule是数组,字典或者其他对象。是否有什么办法可以做到跨语言识别vaule呢。

    比如我用python 将一个字典或者一个数组 存到memcache里。然后我用.net 或者php 去get这个key。如何正确的解析vaule呢
    6 replies  •  1970-01-01 08:00:00 +08:00
    iammutex
        1
    iammutex  
       Dec 13, 2011
    语不出来是因为客户端使用了本语言自己的序列化手段,存之前自己转成一些通用的格式就OK了,比如最简单的转成json,几乎每种语言都能支持。
    icyflash
        2
    icyflash  
       Dec 13, 2011
    json+1
    roymax
        3
    roymax  
       Dec 13, 2011
    定义好你的序列化协议进行解包与封包。

    常用的可以选择的序列化方式包括:
    * json
    * xml
    * google protobuf
    * hessian
    * 字节码
    zenwong
        4
    zenwong  
       Dec 13, 2011
    json
    xml
    text
    ....
    gavingeng
        5
    gavingeng  
       Dec 15, 2011
    json
    xml
    ....
    mlzboy
        6
    mlzboy  
       Dec 15, 2011
    thrift
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   2894 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 47ms · UTC 14:07 · PVG 22:07 · LAX 07:07 · JFK 10:07
    ♥ Do have faith in what you're doing.