SeaweedFS is a distributed storage system for object storage (S3), file systems, Iceberg table buckets, and Lance vector buckets, designed to handle billions of files with O(1) disk access and effortless horizontal scaling.
Go blob-storagecloud-drivedistributed-file-systemdistributed-storageerasure-codingfusehadoop-hdfshdfskuberneteslancelancedbobject-storageposixs3s3-storageseaweedfstiered-file-systemvector-search
fix: Resolve inconsistent usage of error variables (#10060)
mumingl16c3f5c81674
diff --git a/weed/filer/mysql2/mysql2_store.go b/weed/filer/mysql2/mysql2_store.goindex d1f13b9aee..b4845ec074 100644--- a/weed/filer/mysql2/mysql2_store.go+++ b/weed/filer/mysql2/mysql2_store.go@@ -80,9 +80,11 @@ func (store *MysqlStore2) initialize(createTable, upsertQuery string, enableUpsevar dbErr errorstore.DB, dbErr = sql.Open("mysql", sqlUrl)if dbErr != nil {- store.DB.Close()+ if store.DB != nil {+ store.DB.Close()+ }store.DB = nil- return fmt.Errorf("can not connect to %s error:%v", adaptedSqlUrl, err)+ return fmt.Errorf("can not connect to %s error:%w", adaptedSqlUrl, dbErr)}store.DB.SetMaxIdleConns(maxIdle)