Skip to content
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

启用Socks代理以后,回答的输出不再是Stream流了吗? #259

Closed
caneman opened this issue Mar 3, 2023 · 6 comments
Closed

Comments

@caneman
Copy link

caneman commented Mar 3, 2023

之前的版本,答案是一个个蹦出来的,用户体验上从输入到输出不用等很久。

加了Socks代理以后,现在是问完问题会等待一会儿,等所有的答案接受完毕后,前端再一下子全部输出,用户体验上其实不是很好,有种很卡很慢的感觉。

个人感觉,问答总时长不变的情况下,逐字输出让人感觉整个体验会更流畅一些。

是我网络/环境原因还是说这块确实有改动?

PS: 2.9.1和dev分支都存在这个现象

@BruceHan98
Copy link

我用了socks代理,通过http访问可以实现流输出,通过https访问就不行,不知道是哪里的问题

@shansing
Copy link
Contributor

shansing commented Mar 4, 2023

不知道你们是否用了 Nginx 作反向代理。我的情况是有 Nginx 作反代,几乎没有打字机效果。参考 #153 ,我在反代块加上了下面两行配置:

keepalive_timeout 10s;
proxy_buffering off;

之后就有顺畅的打字效果了。供参考。

@BruceHan98
Copy link

不知道你们是否用了 Nginx 作反向代理。我的情况是有 Nginx 作反代,几乎没有打字机效果。参考 #153 ,我在反代块加上了下面两行配置:

keepalive_timeout 10s;
proxy_buffering off;

之后就有顺畅的打字效果了。供参考。

是的,在nginx添加这两行就可以了,感谢!👍

@caneman
Copy link
Author

caneman commented Mar 4, 2023

不知道你们是否用了 Nginx 作反向代理。我的情况是有 Nginx 作反代,几乎没有打字机效果。参考 #153 ,我在反代块加上了下面两行配置:

keepalive_timeout 10s;
proxy_buffering off;

之后就有顺畅的打字效果了。供参考。

确实如此👍

@caneman caneman closed this as completed Mar 4, 2023
@opticalix
Copy link

opticalix commented Mar 5, 2023

请问是在docker-compose/nginx/nginx.conf加吗? 我是使用docker-compose部署的

不知道你们是否用了 Nginx 作反向代理。我的情况是有 Nginx 作反代,几乎没有打字机效果。参考 #153 ,我在反代块加上了下面两行配置:

keepalive_timeout 10s;
proxy_buffering off;

之后就有顺畅的打字效果了。供参考。

是的,在nginx添加这两行就可以了,感谢!👍

@BruceHan98
Copy link

请问是在docker-compose/nginx/nginx.conf加吗? 我是使用docker-compose部署的

不知道你们是否用了 Nginx 作反向代理。我的情况是有 Nginx 作反代,几乎没有打字机效果。参考 #153 ,我在反代块加上了下面两行配置:

keepalive_timeout 10s;
proxy_buffering off;

之后就有顺畅的打字效果了。供参考。

是的,在nginx添加这两行就可以了,感谢!👍

我没有用docker-compose部署,我是在服务器的/etc/nginx/nginx.conf中添加的,你可以都试一下

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants