mirror of
https://github.com/gofiber/storage.git
synced 2025-10-05 16:48:25 +08:00
Updated config
This commit is contained in:
@@ -27,9 +27,14 @@ type SchemaInfo struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// New creates a new Cassandra storage instance
|
// New creates a new Cassandra storage instance
|
||||||
func New(cfg Config) *Storage {
|
func New(cnfg Config) *Storage {
|
||||||
|
|
||||||
|
// Default config
|
||||||
|
cfg := configDefault(cnfg)
|
||||||
|
|
||||||
// Create cluster config
|
// Create cluster config
|
||||||
cluster := gocql.NewCluster(cfg.Hosts...)
|
cluster := gocql.NewCluster(cfg.Hosts...)
|
||||||
|
cluster.Consistency = cfg.Consistency
|
||||||
|
|
||||||
// Don't set keyspace initially - we need to create it first
|
// Don't set keyspace initially - we need to create it first
|
||||||
// We'll connect to system keyspace first
|
// We'll connect to system keyspace first
|
||||||
|
Reference in New Issue
Block a user