mirror of
https://github.com/saveweb/solar_tracker.git
synced 2024-09-19 03:05:29 -07:00
force zstd first
This commit is contained in:
parent
1a7719426c
commit
72ee93802d
3
main.go
3
main.go
@ -20,7 +20,8 @@ func connect_to_mongodb() {
|
||||
fmt.Println("Connecting to MongoDB...")
|
||||
fmt.Println("MONGODB_URI: len=", len(MONGODB_URI))
|
||||
serverAPI := options.ServerAPI(options.ServerAPIVersion1)
|
||||
opts := options.Client().ApplyURI(MONGODB_URI).SetServerAPIOptions(serverAPI).SetAppName("solar-tracker")
|
||||
opts := options.Client().ApplyURI(MONGODB_URI).SetServerAPIOptions(serverAPI).SetAppName("solar-tracker").SetCompressors([]string{"zstd", "zlib", "snappy"})
|
||||
fmt.Println("AppName: ", *opts.AppName)
|
||||
fmt.Println("Compressors: ", opts.Compressors)
|
||||
|
||||
client, err := mongo.Connect(context.TODO(), opts)
|
||||
|
Loading…
Reference in New Issue
Block a user