[Contents] [Prev] [Next] [Index] [Report an Error] [No Frames]


Example: Bucket VTA

In this example each subscriber has a bucket account, that is, an account that is periodically measured and refilled depending on the usage of the account.

In this example, there are two bucket sizes:

The rate at which the buckets are refilled depends on usage. If the subscriber is staying within the behaving rate, the bucket account is refilled at the rate of 2 gigabytes per week. If the subscriber is exceeding the behaving rate, the bucket account is refilled at the rate of 1 gigabyte per week:

Events for Bucket VTA

The bucket VTA example has the following events:

Event Handlers for Bucket VTA

The bucket VTA includes the following event handlers.

GetBucket Event Handler

The GetBucket event handler retrieves the balance of the bucket account when the subscriber logs in.

RefillBucketWithBehavingRate Event Handler

The RefillBucketWithBehavingRate event handler refills the bucket with the behaving rate and starts the behaving service if the bucket account has a positive balance.

UpdateBehavingUsage Event Handler

The UpdateBehavingUsage event handler updates the bucket account with the usage from the behaving service.

ToMisbehaving Event Handler

The ToMisbehaving event handler changes the subscriber to misbehaving mode when the bucket has zero or negative balance.

Database Engine Processor for Bucket VTA

The bucket VTA contains a database engine processor that is configured as follows.

Account Update Scripts

The database engine processor contains two account update scripts:

Subscriber Account

The subscriber account sets the initial balance of the account to 2147483648 and sets the initial status of the account to active.

Service Accounts

The service account has the following usage metric.

SAE Proxy Processor for Bucket VTA

The SAE proxy processor is set to enabled.

Actions for Bucket VTA

The bucket VTA includes the following actions.

GetBucketBalance Action

The GetBucketBalance action retrieves account balances.

CalcUsage Action

The CalcUsage action calculates usage in the service-tracking event using the usage metric configured for the service.

UpdateBucketForBehaving Action

The UpdateBucketForBehaving action debits usage of the behaving service from the bucket account.

RefillBucketWithBehavingRate Action

The RefillBucketWithBehavingRate action refills the bucket with the behaving rate.

StartMisbehavingService Action

The StartMisbehavingService action starts the misbehaving service.

StopBehavingService Action

The StopBehavingService action stops the behaving service.



[Contents] [Prev] [Next] [Index] [Report an Error] [No Frames]