|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object be.ac.ulg.montefiore.run.totem.domain.model.impl.BandwidthSharingBandwidthManagement
public class BandwidthSharingBandwidthManagement
This class manages link bandwidth. Lsps can be added or remove temporarily to see the effect on reservable bandwidth.
Lsp can also be added or removed permanently, changing the reservation in the links.
It uses bandwidth sharing on links. Backup-to-backup and primary-to-backup bandwidth sharing.
This class can be used only on domain that uses only one class type.
Creation date: 3/11/2006
Constructor Summary | |
---|---|
BandwidthSharingBandwidthManagement(Domain domain)
Create a new BandwidthSharingBandwidthManagement object to use with the given domain. |
Method Summary | |
---|---|
void |
addLsp(Lsp lsp)
Add lsp reservation. |
void |
addLspTemp(Lsp lsp)
Adds a lsp temporarily. |
void |
cancelChanges()
Cancel changes made by adding and removing lsp temporarily. |
float |
computeOversubscription()
|
java.lang.String |
getDomainLabelUse()
|
java.util.List<Lsp> |
getPreemptList(Lsp lsp)
Returns an empty list. |
float |
getReservableBandwidth(int priority,
Link link,
java.util.Set<Link> protectedLinks)
Returns the maximum reservable bandwidth at priority level priority for a
lsp traversing the link link . |
void |
init()
Initialise the Bandwidth Management object with the lsps already present in the domain. |
void |
printDomainLabelUse()
|
void |
recomputeRbw(Link link)
Recompute the reservable bandwidth (rbw array) of the link link |
void |
removeLsp(Lsp lsp)
Removes lsp reservation. |
void |
removeLspTemp(Lsp lsp)
Removes a lsp temporarily. |
boolean |
usePreemption()
returns false. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BandwidthSharingBandwidthManagement(Domain domain) throws DiffServConfigurationException
domain
-
DiffServConfigurationException
- if the domain contains more than on class typeMethod Detail |
---|
public void init() throws LinkCapacityExceededException
init
in interface BandwidthManagement
LinkCapacityExceededException
- if the calculated bandwidth exceed link capacitypublic java.util.List<Lsp> getPreemptList(Lsp lsp)
getPreemptList
in interface BandwidthManagement
lsp
-
public void addLsp(Lsp lsp) throws DiffServConfigurationException, LspNotFoundException, LinkCapacityExceededException
addLsp
in interface BandwidthManagement
lsp
-
LinkCapacityExceededException
DiffServConfigurationException
LspNotFoundException
- if the argument is a backup lsp and the primary lsp cannot be found in the domainpublic void removeLsp(Lsp lsp) throws DiffServConfigurationException, LspNotFoundException, LinkCapacityExceededException
removeLsp
in interface BandwidthManagement
lsp
-
DiffServConfigurationException
LspNotFoundException
LinkCapacityExceededException
public void removeLspTemp(Lsp lsp) throws DiffServConfigurationException, LspNotFoundException, LinkCapacityExceededException
#getReservableBandwidth(int, Link, java.util.Set)
method is called.
This can be undone by a call to cancelChanges()
.
removeLspTemp
in interface BandwidthManagement
lsp
-
LinkCapacityExceededException
DiffServConfigurationException
LspNotFoundException
public void addLspTemp(Lsp lsp) throws DiffServConfigurationException, LspNotFoundException, LinkCapacityExceededException
#getReservableBandwidth(int, Link, java.util.Set)
method is called.
This can be undone by a call to cancelChanges()
.
addLspTemp
in interface BandwidthManagement
lsp
-
LinkCapacityExceededException
DiffServConfigurationException
LspNotFoundException
public void cancelChanges()
cancelChanges
in interface BandwidthManagement
public float getReservableBandwidth(int priority, Link link, java.util.Set<Link> protectedLinks)
priority
for a
lsp traversing the link link
. If protectedLinks
is given, the reservable bandwidth for
a backup lsp protecting those links is returned, otherwise, a primary lsp is assumed.
Cij - [Pij + Bij(Lmn) - Fij(Lmn)]
among protected links Lmn for backup lsps.
getReservableBandwidth
in interface BandwidthManagement
priority
- link
- protectedLinks
-
public boolean usePreemption()
usePreemption
in interface BandwidthManagement
public void recomputeRbw(Link link) throws LinkCapacityExceededException
link.
Warning: all rbw values should be set to 0 before calling this method.
- Specified by:
recomputeRbw
in interface BandwidthManagement
- Parameters:
link
-
- Throws:
LinkCapacityExceededException
public java.lang.String getDomainLabelUse()
public void printDomainLabelUse()
public float computeOversubscription()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |