Class Chain.SiteTransfer
- java.lang.Object
-
- edu.isi.pegasus.planner.transfer.refiner.Chain.SiteTransfer
-
- Enclosing class:
- Chain
private static class Chain.SiteTransfer extends java.lang.Object
A container to manage the transfer jobs that are needed to be done on a single site. The container maintains the bundles and controls the distribution of a transfer job amongst the bundles in a round robin manner. Each bundle itself is actually a chain of transfer jobs.
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.List
mBundles
The list ofChain
object.private int
mCapacity
The maximum number of transfer jobs that are allowed for this particular site.private int
mNext
The index of the bundle to which the next transfer for the site would be added to.private java.lang.String
mSite
The site for which these transfers are grouped.
-
Constructor Summary
Constructors Constructor Description SiteTransfer()
The default constructor.SiteTransfer(java.lang.String pool, int bundle)
Convenience constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
addTransfer(java.lang.String txJobName)
Adds a file transfer to the appropriate TransferChain.java.lang.String
toString()
Returns the textual description of the object.
-
-
-
Field Detail
-
mCapacity
private int mCapacity
The maximum number of transfer jobs that are allowed for this particular site. This should correspond to the bundle factor.
-
mNext
private int mNext
The index of the bundle to which the next transfer for the site would be added to.
-
mSite
private java.lang.String mSite
The site for which these transfers are grouped.
-
mBundles
private java.util.List mBundles
The list ofChain
object. Each bundle is actually a chain of transfer nodes.
-
-
Constructor Detail
-
SiteTransfer
public SiteTransfer()
The default constructor.
-
SiteTransfer
public SiteTransfer(java.lang.String pool, int bundle)
Convenience constructor.- Parameters:
pool
- the pool name for which transfers are being grouped.bundle
- the number of logical bundles that are to be created per site. it directly translates to the number of transfer jobs that can be running at a particular site
-
-
Method Detail
-
addTransfer
public java.lang.String addTransfer(java.lang.String txJobName)
Adds a file transfer to the appropriate TransferChain. The file transfers are added in a round robin manner underneath.- Parameters:
txJobName
- the name of the transfer job.- Returns:
- the last transfer job in the chain before the current job was added, null in case the job is the first in the chain
-
toString
public java.lang.String toString()
Returns the textual description of the object.- Overrides:
toString
in classjava.lang.Object
- Returns:
- the textual description.
-
-