private void putChannelNotifications()

in aws-codeguruprofiler-profilinggroup/src/main/java/software/amazon/codeguruprofiler/profilinggroup/CreateHandler.java [86:98]


    private void putChannelNotifications(final AmazonWebServicesClientProxy proxy, final Logger logger,
                                         final String pgName, final String awsAccountId, List<Channel> anomalyDetectionNotificationConfiguration) {
        safelyInvokeApi(() -> {
            try {
                addChannelNotifications(pgName, anomalyDetectionNotificationConfiguration, proxy, profilerClient);
            } catch (CodeGuruProfilerException addChannelNotificationException) {
                logger.log(format("%s [%s] for accountId [%s] has failed when adding Channel Notification, trying to delete the profiling group!",
                        ResourceModel.TYPE_NAME, pgName, awsAccountId));
                deleteProfilingGroup(proxy, logger, pgName, awsAccountId, addChannelNotificationException);
                throw addChannelNotificationException;
            }
        });
    }