阿里ocs客户端与spring集成,生命周期由spring管理

时间:2018-01-15 05:54:41
【文件属性】:

文件名称:阿里ocs客户端与spring集成,生命周期由spring管理

文件大小:3.6MB

文件格式:RAR

更新时间:2018-01-15 05:54:41

阿里 ocs spring集成 xmemcached spymemcached

阿里ocs的java客户端demo,我测试了xmemcached和spymemcached。两个都可用,但xmc可以交由spring管理client对象的生命周期,而spymc却是spring能创建但无法关闭,研究结果为:用xmc来做客户端,需注意的地方就是spring配置文件中要使用:plain和BinaryCommandFactory。 ocs spring xmemcached spymemcached(本机测试用memcached1.4.13版本)


【文件预览】:
TestSpringXmemcached
----src()
--------com()
--------applicationContext.xml(5KB)
----.project(396B)
----classes()
--------com()
--------applicationContext.xml(5KB)
----.classpath(1KB)
----lib()
--------spring-asm-3.1.0.RELEASE.jar(52KB)
--------log4j-1.2.16.jar(470KB)
--------commons-pool-1.5.5.jar(98KB)
--------spring-context-support-3.1.0.RELEASE.jar(104KB)
--------commons-pool2-2.2.jar(106KB)
--------spring-tx-3.1.0.RELEASE.jar(240KB)
--------spring-aop-3.1.0.RELEASE.jar(324KB)
--------commons-logging.jar(37KB)
--------spring-beans-3.1.0.RELEASE.jar(575KB)
--------xmemcached-1.4.2.jar(430KB)
--------spring-core-3.1.0.RELEASE.jar(432KB)
--------spring-expression-3.1.0.RELEASE.jar(172KB)
--------spring-context-3.1.0.RELEASE.jar(810KB)
--------spring-data-redis-1.0.0.RELEASE.jar(344KB)
--------slf4j-api-1.7.5.jar(25KB)
----readme.txt(503B)

网友评论

  • 有一定的参考价值
  • 代码没有什么实用价值
  • 有一定的参考价值
  • 不是不好,而是和题目不一致。 阿里云当前OCS 是1.4.3 版本以后的,有SASL。 本代码没有体现出来。 最后我还是用aliyun自己提供的代码做的测试。