feat: fixed missing cache params (#1340)

Signed-off-by: AlexsJones <alexsimonjones@gmail.com>
This commit is contained in:
Alex Jones
2024-12-04 10:30:57 +00:00
committed by GitHub
parent c3f448693d
commit 1363219b1b
3 changed files with 8 additions and 2 deletions

View File

@@ -6,6 +6,7 @@ import (
"context"
"errors"
"google.golang.org/grpc"
"os"
)
var _ ICache = (*InterplexCache)(nil)
@@ -35,6 +36,10 @@ func (c *InterplexCache) Configure(cacheInfo CacheProvider) error {
func (c *InterplexCache) Store(key string, data string) error {
if os.Getenv("INTERPLEX_LOCAL_MODE") != "" {
c.configuration.ConnectionString = "localhost:8084"
}
conn, err := grpc.NewClient(c.configuration.ConnectionString, grpc.WithInsecure(), grpc.WithBlock())
defer conn.Close()
if err != nil {