Skip to content

Commit aa9a495

Browse files
committed
handle SNS exception during startup
1 parent 871e788 commit aa9a495

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/main/java/scorekeep/WebConfig.java

+4-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,10 @@ public Filter SimpleCORSFilter() {
1717

1818
static {
1919
if ( System.getenv("NOTIFICATION_EMAIL") != null ){
20-
Sns.createSubscription();
20+
try { Sns.createSubscription(); }
21+
catch (Exception e ) {
22+
logger.warn("Failed to create subscription for email "+ System.getenv("NOTIFICATION_EMAIL"));
23+
}
2124
}
2225
}
2326
}

0 commit comments

Comments
 (0)