Skip to content

Commit

Permalink
chore: attempting to get some buckets cleanup info
Browse files Browse the repository at this point in the history
  • Loading branch information
BenWhitehead committed Sep 11, 2024
1 parent 51d5832 commit 7ce98ea
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public static void doCleanup(String bucketName, Storage s) {
}

public static void doCleanup(String bucketName, Storage s, StorageControlClient ctrl) {
LOGGER.fine("Starting bucket cleanup...");
LOGGER.info("Starting bucket cleanup: " + bucketName);
String projectId = s.getOptions().getProjectId();
try {
// TODO: probe bucket existence, a bad test could have deleted the bucket
Expand Down Expand Up @@ -132,10 +132,12 @@ public static void doCleanup(String bucketName, Storage s, StorageControlClient
s.delete(bucketName, BucketSourceOption.userProject(projectId));
} else {
LOGGER.warning(
String.format("Unable to delete bucket due to previous failed %s deletes", failed));
String.format(
"Unable to delete bucket %s due to previous failed %s deletes",
bucketName, failed));
}

LOGGER.fine("Bucket cleanup complete");
LOGGER.info("Bucket cleanup complete: " + bucketName);
} catch (Exception e) {
LOGGER.log(Level.SEVERE, e, () -> "Error during bucket cleanup.");
}
Expand Down

0 comments on commit 7ce98ea

Please sign in to comment.