Skip to content

Commit 2cb106a

Browse files
authored
[CHORE] Send a message to indicate sentry is started (stellar#1670)
This is to indicate the sentry is activated instead of waiting for an exception to happen.
1 parent fdf04a7 commit 2cb106a

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

platform/src/main/java/org/stellar/anchor/platform/configurator/SentryConfigAdapter.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
package org.stellar.anchor.platform.configurator;
22

3+
import static io.sentry.Sentry.captureMessage;
34
import static org.stellar.anchor.util.Log.*;
45
import static org.stellar.anchor.util.StringHelper.*;
56

@@ -30,6 +31,11 @@ void initSentry(ConfigMap config, String dsn, String sentryEnv) {
3031
options.setTracesSampleRate(1.0);
3132
options.setEnableUncaughtExceptionHandler(true);
3233
});
34+
35+
captureMessage(
36+
String.format(
37+
"Sentry agent initialized. release:%s, environment: %s, debug: %s",
38+
config.getString("sentry.release"), sentryEnv, config.getBoolean("sentry.debug")));
3339
}
3440

3541
String getAuthToken() {

0 commit comments

Comments
 (0)