Initial commit: Open sourcing all of the Maple Open Technologies code.

This commit is contained in:
Bartlomiej Mika 2025-12-02 14:33:08 -05:00
commit 755d54a99d
2010 changed files with 448675 additions and 0 deletions

View file

@ -0,0 +1,23 @@
package cache
import (
"go.uber.org/zap"
"codeberg.org/mapleopentech/monorepo/cloud/maplefile-backend/config"
"github.com/gocql/gocql"
)
// ProvideRedisCache provides a Redis cache instance
func ProvideRedisCache(cfg *config.Config, logger *zap.Logger) (RedisCacher, error) {
return NewRedisCache(cfg, logger)
}
// ProvideCassandraCache provides a Cassandra cache instance
func ProvideCassandraCache(session *gocql.Session, logger *zap.Logger) CassandraCacher {
return NewCassandraCache(session, logger)
}
// ProvideTwoTierCache provides a two-tier cache instance
func ProvideTwoTierCache(redisCache RedisCacher, cassandraCache CassandraCacher, logger *zap.Logger) TwoTierCacher {
return NewTwoTierCache(redisCache, cassandraCache, logger)
}