Re: 请问openresty要用lua连接oracle数据库应该怎么做?

240 views
Skip to first unread message

Yichun Zhang (agentzh)

unread,
Oct 8, 2013, 2:49:33 PM10/8/13
to 何振科, openresty
Hello!

2013/10/8 何振科:
> 最近用您的openresty 写web API
> 性能特别高,项目中有向oracle连接获取数据库,发现不支持,请问有什么方法让openresty的lua支持连接oracle?
>

Oracle 的通讯协议不开放,所以我们不能像实现 lua-resty-mysql 那样自己用纯 Lua 实现一个 100% 非阻塞的
lua-resty-oracle 驱动。

我可以想到的一种折衷的做法是使用 Oracle 官方的 OCI 库做一个数据库代理中间层,这个中间层使用某种开放的数据库协议,然后再让
openresty 和这个中间层通信。

同时抄送给 openresty 中文邮件列表:https://groups.google.com/group/openresty

建议你也加入此列表并在那里交流这样的问题,谢谢合作!

Regards,
-agentzh

wd

unread,
Oct 8, 2013, 9:59:16 PM10/8/13
to open...@googlegroups.com, 何振科
很早之前不是说晓哲他们在做 oracle 的连接么?是没做还是没公开?


2013/10/9 Yichun Zhang (agentzh) <age...@gmail.com>

--
--
邮件来自列表“openresty”,专用于技术讨论!
订阅: 请发空白邮件到 openresty...@googlegroups.com
发言: 请发邮件到 open...@googlegroups.com
退订: 请发邮件至 openresty+...@googlegroups.com
归档: http://groups.google.com/group/openresty
官网: http://openresty.org/
仓库: https://github.com/agentzh/ngx_openresty
教程: http://openresty.org/download/agentzh-nginx-tutorials-zhcn.html

Yichun Zhang (agentzh)

unread,
Oct 8, 2013, 10:05:37 PM10/8/13
to openresty
Hello!

2013/10/8 wd:
> 很早之前不是说晓哲他们在做 oracle 的连接么?是没做还是没公开?
>

使用 Oracle 自己的 OCI 库作非阻塞通信存在一些技术困难。见这里晓哲自己的解释:

https://groups.google.com/d/msg/openresty/LQCQ_S4o2IE/dQ2cg9KcvDcJ

Regards,
-agentzh
Reply all
Reply to author
Forward
0 new messages