Direct Messages
4 Active
AK
Alex Kumar
LEAD
Online & available for peer coding
End-to-end encrypted peer messaging
Hey Alex! Did you manage to test the Redis clustering failover scenario under load?
2h ago• Delivered
AK
Yes! We saw a 350ms blip during sentinel master re-election, but circuit breakers caught 99% of requests.
1h ago
Awesome. What mechanism are you using for distributed lock renewal?
1h ago• Delivered
AK
go
func AcquireLock(ctx context.Context, client *redis.Client, key string, ttl time.Duration) (string, error) {
token := uuid.New().String()
ok, err := client.SetNX(ctx, "lock:"+key, token, ttl).Result()
if err != nil || !ok {
return "", ErrLockBusy
}
// Launch renewal heartbeat goroutine
go renewLock(ctx, client, key, token, ttl)
return token, nil
}10m ago
AK
Alex Kumar
@alexkumar
LEAD
Total XP:12.8K XP
Rank:#2 Global
Streak:32 Days
Solved:234 Problems
Tech Stack
JavaSpring BootKubernetesAWSKafkaRedisPostgreSQL