Low Balance Notifications

Jelastic PaaS can automatically notify end-users about account balance running low and the necessity of refill to avoid hosted projects disruption. Herewith, depending on your preferences, emails can be sent based on:

Note: These notifications won’t be sent for users with the auto-refill option enabled.

Static Threshold

To enable and configure the automatic notification provisioning based on the static threshold, perform the following steps:

1. Log in as cluster admin into your JCA panel and provide the account.personal.min.threshold quota for your user groups (if needed, can be adjusted per customer). The specified value sets the funds threshold to start sending notifications about low balance.

personal threshold quota

Tip: This quota is available for the billing groups only and can be set to 0 for disabling the feature.

2. Next, you can set the frequency of the notifications by adjusting the cron expression for the qjob.threshold_notification.cron_schedule job in System Settings (Expert Mode).

threshold notification job

This job compares if the account balance is lower than the account.personal.min.threshold quota and notifies the billing user (no more than once a day). The default “0 15 * * * ?” value runs the job on the 15th minute of every hour.

3. If needed, customize the appropriate billing_account_needs_refill email template.

threshold email template
That’s it! The notifications about low balance based on the static threshold are configured.

Consumption Analysis

The consumption-based notifications about balance shortage are done by the qjob.predict_deactivation_accs.cron_schedule job based on the following System Settings in the JCA:

1. A period (i.e. a number of the most recent days) to calculate the average consumption for, which is provided in the account.avg.usage.period setting.

average usage period setting
2. Next, the obtained average consumption is compared with the current account balance considering the account.minbalance quota to get the expected value for the number of remaining active days.

account minimum balance quota

For example, if the current balance is 100, the average consumption 12 per day and the account.minbalance is zero, the expectation is 8 days.

3. Now, the expectation is compared with a list of the notification periods provided via the account.notification.periods setting.

notification periods by consumption setting

If the value matches with any of the listed periods, the notification is sent to the appropriate user account.

4. You can customize the frequency of the job execution with the appropriate qjob.predict_deactivation_accs.cron_schedule setting.

predict account deactivation job

It is run on the 15th minute of every hour by default. Herewith, the notification is sent no more than once a day.

5. If needed, customize the appropriate billing_account_needs_refill_in_days email template.

consumption email template
Now, your customers will be notified on the low balance based on their personal consumption level.