| Interface | Description |
|---|---|
| AccountingService |
Service used to configure the Accounting
|
| ExpressionFilterTarget<T extends ExpressionTarget> |
Interface for ExpressionTarget factories that can generate filters based on a
PropExpression |
| ExpressionTargetFactory<T extends ExpressionTarget> |
Interface that combines
ExpressionFilterTarget and
PropertyTargetFactory and supports the generation of
SQLExpressions. |
| ExpressionTargetGenerator<T extends ExpressionTarget> |
An
PropertyTargetGenerator where the target is an ExpressionTarget |
| ReductionProducer<UR extends ExpressionTarget> | |
| UsageProducer<UR extends UsageRecord> |
Interface implemented by classes that can provide Usage information to the reports.
|
| UsageRecord |
Interface implemented by all individual usage records.
|
| UsageRecordListener |
Interface for factory classes that need to see
record insertion/deletion for example aggregate tables or
budget managers.
|
| Class | Description |
|---|---|
| ColName |
Simple parameter class for building tables from properties.
|
| DateReductionTarget |
A
ReductionTarget operating on Dates. |
| ErrorSet |
Collection of error messages.
|
| ErrorSet.Detail | |
| ErrorSet.Entry | |
| ExpressionTargetTableMaker<E extends ExpressionTarget,F extends ExpressionTargetGenerator<E>> |
Class to build a table of expressions values with one row per record.
|
| IndexReduction |
A
ReductionTarget that generates an index value similar to an SQL GROUP BY clause. |
| JobTableMaker<UR extends UsageRecord> |
Class to build a table of per-job information.
|
| NumberAverageReductionTarget |
A
ReductionTarget operating on numbers that generate an
average. |
| NumberMaxReductionTarget |
A
ReductionTarget operating on numbers. |
| NumberMinReductionTarget |
A
ReductionTarget operating on numbers. |
| NumberReductionTarget | |
| NumberSumReductionTarget |
A
ReductionTarget operating on numbers. |
| OverlapHandler<T extends UsageRecord> |
Class that implements the logic of overlap calculations.
|
| PropertyInfoMaker |
Generates human readable summary of how properties are implemented for
a particular
UsageProducer |
| ReductionMapResult |
Result of a multiple reduction.
|
| ReductionTarget<T> |
A ReductionTarget represents a
Reduction of a PropExpression over set of records. |
| UsageManager<UR extends UsageRecord> |
A composite
UsageProducer that combines results from several
underlying UsageProducers. |
| Enum | Description |
|---|---|
| Reduction |
Reduction operators.
|
| Exception | Description |
|---|---|
| IllegalReductionException |
Exception thrown when an illegal reduction is requested
|
The aim of these classes is to support general accounting and report generation with a variety of deployment and accounting models.
The key item here is an accounting record. This contains a combination of different kinds of data:
This naturally leads us towards having implementation classes for different providers of factual information and augmenting them (by extension or composition) with the local policy. In practice some of the derived information needs to be stored and cannot just be generated on the fly from the factual data. Charging data needs to reflect the actual charge made in case charging parameters are changed. Also any derived quantities that will be used for record selection may need to be recorded with the record for performance reasons. In some cases raw data from different data sources needs to be combined. For example to add a log of which executables are running to the basic information in a batch accounting log.
There are different types of resource quantity we need to consider:
OverlapHandler.
The lowest common denominator of accounting record is something like:
However this could represent many different things depending on the system. E.g.
Many accounting operations require that some subset of the accounting records is selected. Usually by date-range and some record properties and a chart or table produced of one of the Extrinsic properties often divided into classes based on additional job properties. For example a table of CPU-time grouped by project.
We need to abstract out these different concepts to allow common code that can cope with the different quantities and properties supported by different accounting schemes. In addition we sometimes want to support aggregate reports over multiple types of accounting scheme. In which case we need a combining object that implements the same basic interface but only exposes those quantities and properties that are common to all the underlying schemes.
In order to support multiple accounting schemes at the same time we need a UsageManager
class to present a unified view of the tables from the different schemes.
Standard accounting only uses the functionality of UsageRecord.
Accounting data is queried via the UsageProducer interface.
UsageManager has to implement this interface.
The Factory classes for the various sub-classes of UsageRecord also need to present
a standard interface for the UsageManager to use. This is also UsageProducer
interface.
Because we wish to support aggregate operations over multiple tables we introduce an additional level of data
abstraction over that used by Repository/Record. Instead of identifying quantities by their database field name
we use PropertyTags. These are translated into objects from uk.ac.epcc.model.data.expr by the underlying classes. This allows properties
to be represented by different field names in different tables. Properties can also be used to reference complex expressions PropExpressions involving multiple
table fields.