Added coloured logs and fixed a concurrency bug in the localpubsub adapter

This commit is contained in:
2024-02-06 18:44:45 -07:00
parent e44c858ab3
commit 53e2254795
10 changed files with 61 additions and 25 deletions

View File

@ -13,6 +13,7 @@ import (
"goth.stack/api"
"goth.stack/lib"
"goth.stack/lib/pubsub"
"goth.stack/pages"
)
@ -27,7 +28,7 @@ func main() {
_, err := lib.RedisClient.Ping(context.Background()).Result()
// Initialize pubsub
var pubSub lib.PubSub
var pubSub pubsub.PubSub
if err != nil {
log.Printf("Failed to connect to Redis: %v", err)
log.Println("Falling back to LocalPubSub")