-
Notifications
You must be signed in to change notification settings - Fork 9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add email into access log for shadowsocks and vmess #1767
Conversation
这个功能挺好的,尤其是在一个用户有多个ip地址的情况下 |
确实好,这个什么时候发布? |
我觉得可以设置为可选项,需要的人可以开启这个功能。 |
嗯,应该添加一个选择项,mux部分我没太看懂,可以添加email信息进去么? |
理论上是可以的,不然通过email进行流量统计没办法实现 |
现在有没有程序会去抓取这个log然后进行处理么?这个修改改变了输出的格式,分析log的程序会出现问题吧。 |
96fd27f
to
b8f7d9c
Compare
设置,我想的是在 "app/log/config.proto", 添加配置
@kslr @xiaokangwang 看一下还有别的更好的方式么? |
我觉得这种修改最难的点在于如何在 JSON 配置文件中安排这个开关,因为那面向用户,也要求版本间兼容,你不可能这个版本加上去后,觉得不好,下个版本又修改或者撤回,那很麻烦。 我的建议是不需要在 JSON 配置里加入开关,考虑到 @xiaokangwang 的担忧,我觉得那并不算什么大问题,写抓取程序的开发者升级后对应修改就可以,因为 access log 的字段并没有规范文档,v2ray 没必要一定保证它的一致性,其它类似的修改也方便很多,比如有个 PR 也在 access log 里加入了 inbound tag 或 outbound tag。 另外如果要合并,小更改建议重新 push 到一个 commit 里,方便其它开发者查看 master 上的更改。 |
b8f7d9c
to
dd048bf
Compare
我把log合并了一下。 |
现在并不清楚是否有人使用了V2Ray这里的日志。但是我觉得其他程序应该是使用API来访问这里的功能的吧。如果有人使用程序来抓取的话,这里应该是要么正则匹配失败,要么是把email放到放到域名里面。 |
现在比较担心的是一些程序可能会缺少维护,导致突然不能用。 @kslr 你觉得可以通过把这个修改列入changelog,来避免这个修改对于其他程序的影响么? |
这玩意讨论半天 |
不好意思,我刚刚看到新消息。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Based on @kslr 's opinion, I believe this pull request is ready to be merged.
@Gondnat 我已经升级到最新了,但是没有email,怎么让打印email? 我看到这个功能已经发布了呢 |
4.20.0没有包括这个改动 |
如果你立刻需要,就只能按照指南先行编译。 |
收到,谢谢 |
请问 添加email这个功能大约 什么时候发版本 |
Can I ask you how should I activate this feature? I can's see the email, in log file. |
An also, how should I set email for users?! |
给 shadowsocks 和 vmess 的 access log 里添加了 email 字段,效果如下,如果没有设置 email,则不会显示。
![image](https://user-images.githubusercontent.com/5820275/59733796-afd63b80-9281-11e9-8f7a-183f7d5ac1ac.png)
mux模式暂时也无法显示。