|
Lightweight Bartering Grid | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectlbg.peer.strategy.scheduling.consumption.CommonConsumptionScheduling
public abstract class CommonConsumptionScheduling
Reliability-ranked use of Consumption Grants.
| Constructor Summary | |
|---|---|
CommonConsumptionScheduling(Peer managed_peer,
Scheduler scheduler)
|
|
| Method Summary | |
|---|---|
protected static boolean |
assertConsumptionGrantsAvailability(ConsumptionGrantsContainer c_g,
int peer_idx)
|
protected abstract LocalQueueCursor |
getLocalQueueCursor()
Local Queue Cursor accessor. |
protected abstract Ranking |
rankSuppliers(ConsumptionGrantsContainer c_g,
RequestContainer rc)
Rank Suppliers. |
int |
scheduleConsumptionTasks()
ConsumptionSchedulingPolicy implementation. |
protected RequestContainer |
scheduleFirstConsumptionTask()
Schedules first queued Local Task as a Consumption Task. |
protected RequestContainer |
scheduleNextConsumptionTask(LocalQueueCursor lqc)
Schedules next queued Local Task as a Consumption Task. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public CommonConsumptionScheduling(Peer managed_peer,
Scheduler scheduler)
throws GridException
GridException| Method Detail |
|---|
public java.lang.String toString()
toString in class java.lang.Object
public int scheduleConsumptionTasks()
throws GridException
Note: this implementation requires that getLocalQueueCursor() returns a non-null reference to an existing Local Queue Cursor.
scheduleConsumptionTasks in interface ConsumptionSchedulingPolicyGridException - if an error occurs
while using Consumption Grants to schedule Consumption Tasks
protected abstract Ranking rankSuppliers(ConsumptionGrantsContainer c_g,
RequestContainer rc)
throws GridException
c_g - collected Consumption Grants containerrc - target Task container
GridException - if a problem occured while ranking Suppliersprotected abstract LocalQueueCursor getLocalQueueCursor()
protected RequestContainer scheduleFirstConsumptionTask()
throws GridException
GridException - if there is no Consumption Task to schedule
protected RequestContainer scheduleNextConsumptionTask(LocalQueueCursor lqc)
throws GridException
lqc - Local Queue Cursor
GridException - if a parameter is illegal
protected static boolean assertConsumptionGrantsAvailability(ConsumptionGrantsContainer c_g,
int peer_idx)
throws GridException
GridException
|
Lightweight Bartering Grid | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Copyright (c) 2005-2008, Cyril Briquet, parts Xavier Dalem.