Skip to content

Commit

Permalink
chore: Adding stack trace for errors in fetching tenant from redis to…
Browse files Browse the repository at this point in the history
… debug the root cause
  • Loading branch information
trishaanand committed Jan 24, 2025
1 parent c814353 commit c6e9088
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,8 @@ public Mono<Tenant> getDefaultTenant() {
.tap(Micrometer.observation(observationRegistry))
.flatMap(tenant -> repository.setUserPermissionsInObject(tenant).switchIfEmpty(Mono.just(tenant)))
.onErrorResume(e -> {
log.error("Error fetching default tenant from redis!", e);
e.printStackTrace();
log.error("Error fetching default tenant from redis : {}", e.getMessage());
// If there is an error fetching the tenant from the cache, then evict the cache and fetching from
// the db. This handles the case for deserialization errors. This prevents the entire instance to
// go down if tenant cache is corrupted.
Expand Down

0 comments on commit c6e9088

Please sign in to comment.