You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2020/04/16 11:59:35 UTC
[GitHub] [incubator-apisix] 342379784 opened a new issue #1467: request
help:
342379784 opened a new issue #1467: request help:
URL: https://github.com/apache/incubator-apisix/issues/1467
### Issue description
1.我在linux上装了redis驱动,然后自己写的lua代码测试连接redis成功。
2.我先写了一个插件,配置到apisix里,能正常启动,插件加载成功,我在web页面看到了我写的插件
[3.然后我在第二步的插件里加入redis连接的代码,启动失败,提示找不到redis model

,错误日志见图片
猜测:这个错误是plugin.lua报出来的,是不是我在我写的lua文件引入后,还需要再apisix代码的某一处也需要引入
i am chinese,english is so bad,please switch chinese,thanks
Looking forward to your reply
### Environment
* apisix version (cmd: `apisix version`):1.1
* OS:centos7
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-apisix] moonming commented on issue #1467: request help:
Posted by GitBox <gi...@apache.org>.
moonming commented on issue #1467: request help:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616010179
Since I can't see your code, I'm guessing it's the path require issue.
You can refer to other plug-ins that have introduced redis components
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-apisix] 342379784 commented on issue #1467: request
help:
Posted by GitBox <gi...@apache.org>.
342379784 commented on issue #1467: request help:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616011631
是的,我前天忽然发现有别的插件引用了redis,参考代码修改了下,可以正常引用redis了0.0。
但是又碰到了一个问题,我自己写好的插件,已经能显示在页面中的插件列表里了,在ruter里添加后点击保存的时候提示没有这个插件,你看截图
目前我只在conf/config.yaml配置过,我猜测是不是还要在别的文件里配置,但是不知道在哪里配,github上的文档也没找见。。。
------------------ 原始邮件 ------------------
发件人: "Wen Ming"<notifications@github.com>;
发送时间: 2020年4月19日(星期天) 上午10:27
收件人: "apache/incubator-apisix"<incubator-apisix@noreply.github.com>;
抄送: "想个ID真费劲"<342379784@qq.com>;"Author"<author@noreply.github.com>;
主题: Re: [apache/incubator-apisix] request help: (#1467)
Since I can't see your code, I'm guessing it's the path require issue.
You can refer to other plug-ins that have introduced redis components
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-apisix] 342379784 commented on issue #1467: request
help:
Posted by GitBox <gi...@apache.org>.
342379784 commented on issue #1467: request help:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616024801
这样子,我试试,谢谢。
------------------ 原始邮件 ------------------
发件人: "Wen Ming"<notifications@github.com>;
发送时间: 2020年4月19日(星期天) 中午12:02
收件人: "apache/incubator-apisix"<incubator-apisix@noreply.github.com>;
抄送: "想个ID真费劲"<342379784@qq.com>;"Author"<author@noreply.github.com>;
主题: Re: [apache/incubator-apisix] request help: (#1467)
please check your own plugin from Admin API. The dashboard maybe not
support your plugin well.
Thanks,
Ming Wen
Twitter: _WenMing
朱英俊 <notifications@github.com> 于2020年4月19日周日 下午12:00写道:
> 文档中plugin_name,priority属性已经修改,config.yaml文件也加上了配置。页面上的plugin下拉列表也有了我自己写的插件,但是保存的时候提示找不到,还应该在哪里配置,或者修改别的之类的吗
>
>
>
>
>
> ------------------&nbsp;原始邮件&nbsp;------------------
> 发件人:&nbsp;"Wen Ming"<notifications@github.com&gt;;
> 发送时间:&nbsp;2020年4月19日(星期天) 中午11:17
> 收件人:&nbsp;"apache/incubator-apisix"<incubator-apisix@noreply.github.com&gt;;
>
> 抄送:&nbsp;"想个ID真费劲"<342379784@qq.com&gt;;"Author"<author@noreply.github.com&gt;;
>
> 主题:&nbsp;Re: [apache/incubator-apisix] request help: (#1467)
>
>
>
>
>
>
> please refer to
> https://github.com/apache/incubator-apisix/blob/master/doc/plugin-develop.md
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub, or unsubscribe.
>
> —
> You are receiving this because you commented.
> Reply to this email directly, view it on GitHub
> <https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616022663>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AGJZBK5C75G4DL5DOB7XTRTRNJZONANCNFSM4MJSIFFA>
> .
>
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-apisix] moonming commented on issue #1467: request help:
Posted by GitBox <gi...@apache.org>.
moonming commented on issue #1467: request help:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616022995
please check your own plugin from Admin API. The dashboard maybe not
support your plugin well.
Thanks,
Ming Wen
Twitter: _WenMing
朱英俊 <no...@github.com> 于2020年4月19日周日 下午12:00写道:
> 文档中plugin_name,priority属性已经修改,config.yaml文件也加上了配置。页面上的plugin下拉列表也有了我自己写的插件,但是保存的时候提示找不到,还应该在哪里配置,或者修改别的之类的吗
>
>
>
>
>
> ------------------ 原始邮件 ------------------
> 发件人: "Wen Ming"<notifications@github.com>;
> 发送时间: 2020年4月19日(星期天) 中午11:17
> 收件人: "apache/incubator-apisix"<incubator-apisix@noreply.github.com>;
>
> 抄送: "想个ID真费劲"<342379784@qq.com>;"Author"<author@noreply.github.com>;
>
> 主题: Re: [apache/incubator-apisix] request help: (#1467)
>
>
>
>
>
>
> please refer to
> https://github.com/apache/incubator-apisix/blob/master/doc/plugin-develop.md
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub, or unsubscribe.
>
> —
> You are receiving this because you commented.
> Reply to this email directly, view it on GitHub
> <https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616022663>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AGJZBK5C75G4DL5DOB7XTRTRNJZONANCNFSM4MJSIFFA>
> .
>
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [apisix] spacewander closed issue #1467: request help:
Posted by GitBox <gi...@apache.org>.
spacewander closed issue #1467:
URL: https://github.com/apache/apisix/issues/1467
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] spacewander commented on issue #1467: request help:
Posted by GitBox <gi...@apache.org>.
spacewander commented on issue #1467:
URL: https://github.com/apache/apisix/issues/1467#issuecomment-744333757
Consider solved as the author didn't reply.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-apisix] 342379784 commented on issue #1467: request
help:
Posted by GitBox <gi...@apache.org>.
342379784 commented on issue #1467: request help:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616022663
文档中plugin_name,priority属性已经修改,config.yaml文件也加上了配置。页面上的plugin下拉列表也有了我自己写的插件,但是保存的时候提示找不到,还应该在哪里配置,或者修改别的之类的吗
------------------ 原始邮件 ------------------
发件人: "Wen Ming"<notifications@github.com>;
发送时间: 2020年4月19日(星期天) 中午11:17
收件人: "apache/incubator-apisix"<incubator-apisix@noreply.github.com>;
抄送: "想个ID真费劲"<342379784@qq.com>;"Author"<author@noreply.github.com>;
主题: Re: [apache/incubator-apisix] request help: (#1467)
please refer to https://github.com/apache/incubator-apisix/blob/master/doc/plugin-develop.md
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-apisix] moonming commented on issue #1467: request help:
Posted by GitBox <gi...@apache.org>.
moonming commented on issue #1467: request help:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616016929
please refer to https://github.com/apache/incubator-apisix/blob/master/doc/plugin-develop.md
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-apisix] 342379784 commented on issue #1467: request help:
Posted by GitBox <gi...@apache.org>.
342379784 commented on issue #1467:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616382233
ruter保存插件时提示”unknown [zyyt-auth]“,错误应该在这个文件报出来的,文件位置:lua/apisix/admin/plugins.lua。
代码里的require("apisix.plugin"),它这个是加载的什么
------------------ 原始邮件 ------------------
发件人: "YuanSheng Wang"<notifications@github.com>;
发送时间: 2020年4月20日(星期一) 中午1:26
收件人: "apache/incubator-apisix"<incubator-apisix@noreply.github.com>;
抄送: "想个ID真费劲"<342379784@qq.com>;"Author"<author@noreply.github.com>;
主题: Re: [apache/incubator-apisix] request help: (#1467)
please provide more information about your patch for this plugin.
we need it for confirming where is the problem.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-apisix] membphis edited a comment on issue #1467: request help:
Posted by GitBox <gi...@apache.org>.
membphis edited a comment on issue #1467:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-646966546
> 下面是一些截图,希望对找错有帮助
we can not get any picture when you replied by email. please mainly use English in public channel.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-apisix] membphis commented on issue #1467: request help:
Posted by GitBox <gi...@apache.org>.
membphis commented on issue #1467:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616318428
please provide more information about your patch for this plugin.
we need it for confirming where is the problem.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-apisix] 342379784 commented on issue #1467: request help:
Posted by GitBox <gi...@apache.org>.
342379784 commented on issue #1467:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616277724
朋友,我通过adminapi设置自己写的插件,还是提示找不到,可能不是dashboard的原因吧,还有别的可能性吗
------------------ 原始邮件 ------------------
发件人: "Wen Ming"<notifications@github.com>;
发送时间: 2020年4月19日(星期天) 中午12:02
收件人: "apache/incubator-apisix"<incubator-apisix@noreply.github.com>;
抄送: "想个ID真费劲"<342379784@qq.com>;"Author"<author@noreply.github.com>;
主题: Re: [apache/incubator-apisix] request help: (#1467)
please check your own plugin from Admin API. The dashboard maybe not
support your plugin well.
Thanks,
Ming Wen
Twitter: _WenMing
朱英俊 <notifications@github.com> 于2020年4月19日周日 下午12:00写道:
> 文档中plugin_name,priority属性已经修改,config.yaml文件也加上了配置。页面上的plugin下拉列表也有了我自己写的插件,但是保存的时候提示找不到,还应该在哪里配置,或者修改别的之类的吗
>
>
>
>
>
> ------------------&nbsp;原始邮件&nbsp;------------------
> 发件人:&nbsp;"Wen Ming"<notifications@github.com&gt;;
> 发送时间:&nbsp;2020年4月19日(星期天) 中午11:17
> 收件人:&nbsp;"apache/incubator-apisix"<incubator-apisix@noreply.github.com&gt;;
>
> 抄送:&nbsp;"想个ID真费劲"<342379784@qq.com&gt;;"Author"<author@noreply.github.com&gt;;
>
> 主题:&nbsp;Re: [apache/incubator-apisix] request help: (#1467)
>
>
>
>
>
>
> please refer to
> https://github.com/apache/incubator-apisix/blob/master/doc/plugin-develop.md
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub, or unsubscribe.
>
> —
> You are receiving this because you commented.
> Reply to this email directly, view it on GitHub
> <https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616022663>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AGJZBK5C75G4DL5DOB7XTRTRNJZONANCNFSM4MJSIFFA>
> .
>
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-apisix] 342379784 commented on issue #1467: request help:
Posted by GitBox <gi...@apache.org>.
342379784 commented on issue #1467:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616301103
这是我的配置和报错提示
------------------ 原始邮件 ------------------
发件人: "Wen Ming"<notifications@github.com>;
发送时间: 2020年4月19日(星期天) 中午12:02
收件人: "apache/incubator-apisix"<incubator-apisix@noreply.github.com>;
抄送: "想个ID真费劲"<342379784@qq.com>;"Author"<author@noreply.github.com>;
主题: Re: [apache/incubator-apisix] request help: (#1467)
please check your own plugin from Admin API. The dashboard maybe not
support your plugin well.
Thanks,
Ming Wen
Twitter: _WenMing
朱英俊 <notifications@github.com> 于2020年4月19日周日 下午12:00写道:
> 文档中plugin_name,priority属性已经修改,config.yaml文件也加上了配置。页面上的plugin下拉列表也有了我自己写的插件,但是保存的时候提示找不到,还应该在哪里配置,或者修改别的之类的吗
>
>
>
>
>
> ------------------&nbsp;原始邮件&nbsp;------------------
> 发件人:&nbsp;"Wen Ming"<notifications@github.com&gt;;
> 发送时间:&nbsp;2020年4月19日(星期天) 中午11:17
> 收件人:&nbsp;"apache/incubator-apisix"<incubator-apisix@noreply.github.com&gt;;
>
> 抄送:&nbsp;"想个ID真费劲"<342379784@qq.com&gt;;"Author"<author@noreply.github.com&gt;;
>
> 主题:&nbsp;Re: [apache/incubator-apisix] request help: (#1467)
>
>
>
>
>
>
> please refer to
> https://github.com/apache/incubator-apisix/blob/master/doc/plugin-develop.md
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub, or unsubscribe.
>
> —
> You are receiving this because you commented.
> Reply to this email directly, view it on GitHub
> <https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616022663>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AGJZBK5C75G4DL5DOB7XTRTRNJZONANCNFSM4MJSIFFA>
> .
>
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-apisix] membphis commented on issue #1467: request help:
Posted by GitBox <gi...@apache.org>.
membphis commented on issue #1467:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-646966546
> 下面是一些截图,希望对找错有帮助
we can not get any picture when you replied by email.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-apisix] 342379784 commented on issue #1467: request help:
Posted by GitBox <gi...@apache.org>.
342379784 commented on issue #1467:
URL: https://github.com/apache/incubator-apisix/issues/1467#issuecomment-616346515
1.我仿照key-auth写了个插件,名叫zyyt-auth,引用了redis和md5
2.zyyt-auth.lua文件中的plugin_name,priority属性已经修改,config.yaml文件也加上了配置。
3.dashboard中插件的下拉列表也出现了我写的插件
4.然后在dashboard的consumers里保存插件成功
5.然后再ruter里保存插件失败,尝试使用curl访问admin api同样失败
6.我复制的kay-auth.lua文件,更名为zyyt-auth.lua。然后引入了redis和md5,修改plugin_name,priority属性和截图中红色框中的部分
7.以上是我所有的操作
下面是一些截图,希望对找错有帮助
------------------ 原始邮件 ------------------
发件人: "YuanSheng Wang"<notifications@github.com>;
发送时间: 2020年4月20日(星期一) 中午1:26
收件人: "apache/incubator-apisix"<incubator-apisix@noreply.github.com>;
抄送: "想个ID真费劲"<342379784@qq.com>;"Author"<author@noreply.github.com>;
主题: Re: [apache/incubator-apisix] request help: (#1467)
please provide more information about your patch for this plugin.
we need it for confirming where is the problem.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org