Billing Settings

Modified on Wed, 21 Oct at 9:12 AM

The Billing settings group controls how au2mator Asset Management runs its billing, when a run is considered problematic, and how long billing log entries are kept. All settings on this page are configured in Settings → Billing and apply to the whole installation.


TABLE OF CONTENTS



Overview

Billing settings fall into four groups. The first decides whether billing runs on its own, the second and third decide when au2mator warns you about a run, and the fourth keeps the billing log from growing without limit.

There are 17 settings in total:

  • Automatic Billing – 3 settings that schedule unattended billing runs.
  • Alert Thresholds – 3 settings that classify a finished run as Warning or Critical.
  • Performance Thresholds – 2 settings that raise performance warnings in the run log.
  • Log Retention – 9 settings that control the nightly cleanup of billing log entries.
Changing a threshold does not re-evaluate runs that already finished. New values apply to the next run only.


Automatic Billing

By default au2mator never starts a billing run on its own – every run is triggered manually. Enable automatic billing if you want runs to happen on a fixed schedule.

  • AutoBillingEnabled – master switch for unattended runs. Default: disabled.
  • AutoBillingSchedule – when the run starts, as a cron expression. Default: 0 6 * * * (every day at 06:00).
  • AutoBillingNotifyAdminOnCompletion – send a notification to administrators once a run has finished. Default: disabled.
Automatic billing is switched OFF after installation. If you expect runs to happen by themselves and nothing appears under Billing Run, check this setting first.


Schedule automatic billing outside your business hours. A run touches every asset in scope, and a large environment can keep the database busy for several minutes.


Alert Thresholds

When a billing run finishes, au2mator compares the result against these three thresholds and labels the run accordingly. The label is what you see in the Billing Run overview.

  • BillingErrorCountCriticalThreshold – number of errors at which the run is marked Critical. Default: 10.
  • BillingSkipRateWarningPercent – share of skipped assets (in percent) at which the run is marked at least Warning. Default: 30.
  • BillingSlowRunWarningMs – total run duration in milliseconds at which the run is marked at least Warning. Default: 300000 (5 minutes).
A high skip rate usually means assets could not be matched to a cost center, not that billing failed. The reason for every skipped asset is written to the run log.


Performance Thresholds

These two settings do not change the run result. They decide when au2mator writes a performance warning into the run log, so you can see which part of a run is slow.

  • BillingSlowRunThresholdMs – total run duration at which a PERF_SLOW_RUN warning is logged. Default: 300000 (5 minutes).
  • BillingSlowRuleThresholdMs – duration of a single billing rule at which a PERF_SLOW_RULE warning is logged. Default: 60000 (1 minute).
If a run is slow but no single rule is, the cost is spread across many rules. If one rule dominates, check how broad its scope is.


Log Retention

Every billing run writes log entries, and on a large installation this table grows quickly. A cleanup job runs once per night and deletes entries that are older than the retention window for their log level.

General

  • BillingRetentionEnabled – master switch for the nightly cleanup. Default: enabled.
  • BillingRetentionRunAtTimeUtc – time of day the cleanup runs, in UTC. Default: 03:00.

Retention per log level (in days)

  • BillingRetentionDebugDays – Default: 7.
  • BillingRetentionInfoDays – Default: 90.
  • BillingRetentionWarningDays – Default: 365.
  • BillingRetentionErrorDays – applies to both Error and Critical entries. Default: 730 (2 years).
  • BillingRetentionSkipReasonDays – Default: 2555 (7 years).
BillingRetentionSkipReasonDays takes precedence over the per-level windows. An entry explaining why an asset was not billed is kept for the full period regardless of its log level, because that answer is often needed long after the run itself.


Cleanup safety limits

  • BillingRetentionBatchSize – how many rows are deleted per batch. Keeps transactions and locks small. Default: 1000.
  • BillingRetentionMaxBatchesPerRun – maximum number of batches in one nightly pass, so a single cleanup can never delete without limit. Default: 500.
With the default values one nightly pass removes at most 500,000 rows. If your log has grown far beyond that, the cleanup works through it over several nights instead of in one long-running transaction.


Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article