|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.gcube.accounting.ut.UsageTrackerRestAPI
public class UsageTrackerRestAPI
A client-side class for accessing the Usage Tracker
| Constructor Summary | |
|---|---|
UsageTrackerRestAPI(String uri)
|
|
| Method Summary | |
|---|---|
void |
clear()
Deprecated. this operation is for development/testing purposes only. It will be removed in future releases |
void |
deleteUsageRecord(org.gcube.accounting.datamodel.UsageRecord record)
|
FilterRating |
getFilterRating(Report r)
|
long |
getNumberOfRecords(String query)
Return the number of the usage records matching the given query |
Collection<AggregatedResult> |
getReport(Report r)
|
Collection<Consumer> |
getTrackedConsumers()
|
Collection<ResourceScope> |
getTrackedResourceScopes()
|
Collection<ResourceType> |
getTrackedResourceTypes()
|
Collection<UpdateInfo> |
getUpdateInfo()
Query the Usage Tracker for update information from each infrastructure (resource owner) |
Collection<org.gcube.accounting.datamodel.UsageRecord> |
getUsageRecords(String query)
Return the usage records matching the given query and aggregation fields for sorting/pagination purposes Example: resourceType=job&resourceScope=testing&sortField=startTime&paginationStartPage=1&paginationRecords=6 Aggregation fields ====================== sortField : field on which you want to order the results sortOrder : sort criteria (asc/desc) paginationStartRecord : start record of the pagination paginationRecords : number of records per page |
Collection<User> |
getUsers()
Deprecated. this operation is for development/testing purposes only. It will be removed in future releases |
void |
insertUsageRecord(org.gcube.accounting.datamodel.AbstractDelegateUsageRecord ur)
Insert the new given usage record |
void |
insertUsageRecord(org.gcube.accounting.datamodel.RawUsageRecord ur)
Insert the given storage-specific usage record |
void |
insertUsageRecord(org.gcube.accounting.datamodel.UsageRecord ur)
Insert the new given usage record |
void |
insertUsageRecords(Collection<org.gcube.accounting.datamodel.UsageRecord> records)
Insert a set of usage records |
static void |
main(String[] args)
|
static GregorianCalendar |
randomDate()
|
void |
setUserToken(String username,
String password)
|
void |
setUserToken(String username,
String password,
String delegator)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public UsageTrackerRestAPI(String uri)
uri - the URI of the Usage Tracker| Method Detail |
|---|
public void insertUsageRecords(Collection<org.gcube.accounting.datamodel.UsageRecord> records)
records - public void insertUsageRecord(org.gcube.accounting.datamodel.UsageRecord ur)
ur - public void insertUsageRecord(org.gcube.accounting.datamodel.AbstractDelegateUsageRecord ur)
ur - public void insertUsageRecord(org.gcube.accounting.datamodel.RawUsageRecord ur)
ur - public Collection<org.gcube.accounting.datamodel.UsageRecord> getUsageRecords(String query)
query - must have the form: name=value&name>value&kname=value&...
public Collection<UpdateInfo> getUpdateInfo()
public Collection<User> getUsers()
public Collection<Consumer> getTrackedConsumers()
public Collection<ResourceType> getTrackedResourceTypes()
public Collection<ResourceScope> getTrackedResourceScopes()
public long getNumberOfRecords(String query)
query -
public void clear()
public void deleteUsageRecord(org.gcube.accounting.datamodel.UsageRecord record)
public void setUserToken(String username,
String password)
public void setUserToken(String username,
String password,
String delegator)
public Collection<AggregatedResult> getReport(Report r)
public FilterRating getFilterRating(Report r)
public static void main(String[] args)
public static GregorianCalendar randomDate()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||