gpt4 book ai didi

mongodb - 导入mongo驱动程序golang时的net/http TLS握手超时

转载 作者:行者123 更新时间:2023-12-01 22:23:02 34 4
gpt4 key购买 nike

导入用于golang的官方mongo db驱动程序时,收到net / http TLS握手超时错误。

go get go.mongodb.org/mongo-driver/mongo

我得到以下回应
go: found go.mongodb.org/mongo-driver/mongo in go.mongodb.org/mongo-driver v1.3.3
go: downloading github.com/klauspost/compress v1.9.5
../pkg/mod/go.mongodb.org/mongo-driver@v1.3.3/x/mongo/driver/compression.go:16:2: github.com/klauspost/compress@v1.9.5: Get "https://storage.googleapis.com/proxy-golang-org-prod/6d1974c4504adb60-github.com:klauspost:compress-v1.9.5.zip?Expires=1589817362&GoogleAccessId=gcs-urlsigner-prod%40golang-modproxy.iam.gserviceaccount.com&Signature=srzNvLvGM%2BKbAJhtmgjaHE6IjyZLy5JZAQNIgN3oVQis5BEsetWpzu0uPqoxb0bqounoXFKV0COgkR0J%2FjcTenPcihBp0WiZua%2FrHvoLIGRRUgDxPJPs3gniTu2bxqf4aj4BfkTOTH9Hez9QKevGcVGSzkMsB9KsNMbcjnNN2uVJcgfUC4b29xZpEYhXt2mGXqMnU3jflnyRUkK9QDzPArOgbVjZp9bO0RQIs%2BMhiMt822NoZBhOdXCFhrtNie89SQJpELJAIC5r7P8pezU8pUJeQgugXfpgYBmtiH1H5Cvf9xh7v2Bfd3I96wSfUWkrCtceFfG5Xe6CSVmhPjFoeQ%3D%3D": net/http: TLS handshake timeout

我可以导入其他golang库就好了。我该如何解决?

最佳答案

您收到的错误通过以下方式显示了go get代理:

https://storage.googleapis.com/proxy-golang-org-prod/...

并且该代理连接正在超时。

因此,请尝试禁用代理。您可以根据每个请求临时执行此操作,如下所示:
GOPROXY="direct" go get go.mongodb.org/mongo-driver/mongo

关于mongodb - 导入mongo驱动程序golang时的net/http TLS握手超时,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/61856164/

34 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com