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

当前最新版本编译失败,tag的v16版本编译成功 #24

Closed
kissthink opened this issue Feb 1, 2019 · 15 comments
Closed

当前最新版本编译失败,tag的v16版本编译成功 #24

kissthink opened this issue Feb 1, 2019 · 15 comments

Comments

@kissthink
Copy link

kissthink commented Feb 1, 2019

go版本号

root@7209df7aeb96:/usr/src/myapp/easyProxy# go version
go version go1.9.7 linux/amd64
root@7209df7aeb96:/usr/src/myapp/easyProxy#

编译报错
go build cmd/proxy_client/proxy_client.go
提示找不到utils包

尝试复制utils文件夹到对应目录,会报错更多信息。。。
还请指点下如果能正常编译出来,谢谢!

如果采用 git checkout tag v.17 再进行编译,可以成功生成bin文件。 不过和当前版本应该有很多不一样,那个是客户端和服务端都在一个可执行程序里面。

@kissthink
Copy link
Author

我重新运行了一次,今天居然可以了 !!!

root@7209df7aeb96:/go/src/github.com/cnlh# go get github.com/cnlh/easyProxy
package github.com/cnlh/easyProxy: no Go files in /go/src/github.com/cnlh/easyProxy
root@7209df7aeb96:/go/src/github.com/cnlh# ls
easyProxy
root@7209df7aeb96:/go/src/github.com/cnlh# cd easyProxy/
root@7209df7aeb96:/go/src/github.com/cnlh/easyProxy# ls
LICENSE README.md bridge client cmd conf image server utils web
root@7209df7aeb96:/go/src/github.com/cnlh/easyProxy# go build cmd/proxy_
proxy_client/ proxy_server/
root@7209df7aeb96:/go/src/github.com/cnlh/easyProxy# go build cmd/proxy_client/proxy_client.go
root@7209df7aeb96:/go/src/github.com/cnlh/easyProxy#
root@7209df7aeb96:/go/src/github.com/cnlh/easyProxy#
root@7209df7aeb96:/go/src/github.com/cnlh/easyProxy# go build cmd/proxy_server/proxy_server.go
root@7209df7aeb96:/go/src/github.com/cnlh/easyProxy#
root@7209df7aeb96:/go/src/github.com/cnlh/easyProxy#
root@7209df7aeb96:/go/src/github.com/cnlh/easyProxy#

@kissthink
Copy link
Author

关闭这个问题把。。。太诡异了。 是不是跟新代码了?

@kissthink
Copy link
Author

另外文档需要升级一下 目录结构变了。。。

go get github.com/cnlh/easyProxy
go build cmd/proxy_client/proxy_client.go
go build cmd/proxy_server/proxy_server.go

@kissthink
Copy link
Author

另外release里面,没有下载编译好的文件,还是源码,希望修正下

@cnlh
Copy link
Collaborator

cnlh commented Feb 1, 2019

release有编译好的,各个版本都有,难道你那不显示?

@kissthink
Copy link
Author

现在有了,昨天还没有。。。

@kissthink
Copy link
Author

提一个bug,查看编辑功能点击直接白版

客户端管理=》查看编辑

这类链接 client/edit?id=2

@cnlh
Copy link
Collaborator

cnlh commented Feb 1, 2019

是否这个id不存在或者信息有误?我没有发现这个错误,建议你看server端下日志

@kissthink
Copy link
Author

id是存在的

debug模式下显示这个错误

2019/02/02 16:02:01.496 [D] [server.go:2619] | 182.51**| 200 | 36.178386ms| match| GET /client/list r:/client/list/*
2019/02/02 16:02:08.156 [D] [controller.go:282] template Execute err: template: client/edit.html:49:52: executing "client/edit.html" at <.c.Cnf.Mux>: can't evaluate field Mux in type utils.Config
2019/02/02 16:02:08.156 [E] [server.go:2619] template: client/edit.html:49:52: executing "client/edit.html" at <.c.Cnf.Mux>: can't evaluate field Mux in type utils.Config
2019/02/02 16:02:08.156 [D] [server.go:2619] | 182.51.**| 200 | 2.230583ms| match| GET /client/edit r:/client/edit/

2019/02/02 16:02:08.312 [D] [server.go:2619] | 182.51.| 404 | 191.744µs| nomatch| GET /favicon.ico
2019/02/02 16:02:10.477 [D] [server.go:2619] | 182.51.
| 200 | 41.031053ms| match| GET /client/list r:/client/list/

还有一个新问题,稳定性有问题。

2019/02/01 17:15:11.459 [D] [server.go:2619] | 58.132***| 404 | 234.082µs| nomatch| GET /web.php
2019/02/02 01:20:51 数据压缩格式错误

挂机测试,没有活过1天进程就死了。

@kissthink
Copy link
Author

查看代码发现 ,是此处报错,是不是获取的配置有问题?

//判断压缩方式
func GetCompressType(compress string) (int, int) {
switch compress {
case "":
return COMPRESS_NONE_DECODE, COMPRESS_NONE_ENCODE
case "snappy":
return COMPRESS_SNAPY_DECODE, COMPRESS_SNAPY_ENCODE
default:
log.Fatalln("数据压缩格式错误")
}
return COMPRESS_NONE_DECODE, COMPRESS_NONE_ENCODE
}

@kissthink
Copy link
Author

还有一个问题 第一次链接很慢 有时候就没有反应 但是第二次就很快 。 如果再隔一段时间不访问,然后再进行访问的首次又是很慢,第二次会立马变正常。、
这个算是一个bug么?

@cnlh
Copy link
Collaborator

cnlh commented Feb 2, 2019

你的是否是从老版本直接升级过来的?conf下的文件必须得清空才行,不能用以前的 ,因为变动较大,不兼容

@cnlh
Copy link
Collaborator

cnlh commented Feb 2, 2019

向你邮件发送了微信,方便的话可以加我一下

@cnlh
Copy link
Collaborator

cnlh commented Feb 2, 2019

这种情况进程被杀死,可能是产生错误,建议你看下日志,如果日志没有错误,考虑是你的系统进程管理问题,我们是生产环境可以稳定长期运行的

@cnlh
Copy link
Collaborator

cnlh commented Feb 2, 2019

连接很慢暂时考虑到的是你客户端与你的目标创建tcp连接比较慢,建议检查下相关环境,可以继续沟通。

@cnlh cnlh closed this as completed Mar 26, 2019
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

2 participants