Groovy Documentation

com.ace.mws.mam
[Groovy] Class UsageRecord

java.lang.Object
  com.ace.mws.mam.UsageRecord

class UsageRecord

A usage record tracks the usage of resources and services on your system, recording the charge and the details of the usage in a usage record.

Usage Record quotes can be used to determine how much it will cost to use a resource or service. Provided the cost-only option is not specified, this step will additionally verify that the submitter has sufficient funds and meets all the allocation policy requirements for the usage, and can be used at the submission of the usage request as an early filter to prevent the usage from getting blocked when it tries to obtain a lien to start later. If a guaranteed quote is requested, a quote id is returned and can be used in the subsequent charge to guarantee the rates that were used to form the original quote. A guaranteed quote has the side effect of creating a quote record and a permanent usage record. A quote id will be returned which can be used with the lien and charge to claim the quoted charge rates. A cost-only quote can be used to determine how much would be charged for usage without verifying sufficient funds or checking to see if the charge could succeed.

A usage lien can be used to place a hold on the user's fund before usage starts to ensure that the credits will be there when it completes. The replace option may be specified if you want the new lien to replace existing liens of the same instance name (associated with the same usage record). The modify option may be specified to dynamically extend any existing lien with the same instance name with the specified characteristics instead of creating a new one.

A usage charge debits the appropriate allocations based on the attributes of the usage. The charge is calculated based on factors including the resources and services used, the usage time, and other quality-based factors. By default, any liens associated with the charge will be removed. The incremental option may be specified if you want associated liens to be reduced instead of removed. If a usage record already exists for the instance being charged it will be updated with the data properties passed in with the charge request, otherwise a new usage record will be created.

Authors:
jpratt


Field Summary
private String charge

The cumulative amount charged

private Long id

The unique usage record identifier.

private String instance

The usage record instance name.

private String qualityOfService

The quality of service associated with the usage.

private Long quote

The associated quote id.

private String stage

The last affecting action.

private String type

The usage record type.

private String user

The user name associated with the usage.

 
Constructor Summary
UsageRecord()

 
Method Summary
String getCharge()

The cumulative amount charged

Long getId()

The unique usage record identifier.

String getInstance()

The usage record instance name.

String getQualityOfService()

The quality of service associated with the usage.

Long getQuote()

The associated quote id.

String getStage()

The last affecting action.

String getType()

The usage record type.

String getUser()

The user name associated with the usage.

void setCharge(String charge)

The cumulative amount charged

void setId(Long id)

The unique usage record identifier.

void setInstance(String instance)

The usage record instance name.

void setQualityOfService(String qualityOfService)

The quality of service associated with the usage.

void setQuote(Long quote)

The associated quote id.

void setStage(String stage)

The last affecting action.

void setType(String type)

The usage record type.

void setUser(String user)

The user name associated with the usage.

String toString()

 
Methods inherited from class Object
wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll
 

Field Detail

charge

private String charge
The cumulative amount charged


id

private Long id
The unique usage record identifier.


instance

private String instance
The usage record instance name. (i.e. job id)


qualityOfService

private String qualityOfService
The quality of service associated with the usage.


quote

private Long quote
The associated quote id.


stage

private String stage
The last affecting action.(i.e. Create, Quote, Reserve, Query)


type

private String type
The usage record type.


user

private String user
The user name associated with the usage.


 
Constructor Detail

UsageRecord

UsageRecord()


 
Method Detail

getCharge

String getCharge()
The cumulative amount charged


getId

Long getId()
The unique usage record identifier.


getInstance

String getInstance()
The usage record instance name. (i.e. job id)


getQualityOfService

String getQualityOfService()
The quality of service associated with the usage.


getQuote

Long getQuote()
The associated quote id.


getStage

String getStage()
The last affecting action.(i.e. Create, Quote, Reserve, Query)


getType

String getType()
The usage record type.


getUser

String getUser()
The user name associated with the usage.


setCharge

void setCharge(String charge)
The cumulative amount charged


setId

void setId(Long id)
The unique usage record identifier.


setInstance

void setInstance(String instance)
The usage record instance name. (i.e. job id)


setQualityOfService

void setQualityOfService(String qualityOfService)
The quality of service associated with the usage.


setQuote

void setQuote(Long quote)
The associated quote id.


setStage

void setStage(String stage)
The last affecting action.(i.e. Create, Quote, Reserve, Query)


setType

void setType(String type)
The usage record type.


setUser

void setUser(String user)
The user name associated with the usage.


toString

String toString()


 

Groovy Documentation