|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectgoldengate.ftp.core.config.FtpConfiguration
public abstract class FtpConfiguration

Abstract class for configuration
| Field Summary | |
|---|---|
int |
BLOCKSIZE
Size by default of block size for receive/sending files. |
Class<? extends BusinessHandler> |
businessHandler
Which class will be used for BusinessHandler |
int |
CLIENT_THREAD
Default number of threads in pool for Client part. |
Class<? extends DataBusinessHandler> |
dataBusinessHandler
Which class will be used for DataBusinessHandler |
static long |
DEFAULT_GLOBAL_LIMIT
Default global limit 512Mbit |
static long |
DEFAULT_SESSION_LIMIT
Default session limit 64Mbit, so up to 8 full simultaneous clients |
protected long |
delayLimit
Delay in ms between two checks |
boolean |
deleteOnAbort
Should the file be deleted when the transfer is aborted on STOR like commands |
Class<?> |
fromClass
Which class owns this configuration |
boolean |
isShutdown
True if the service is going to shutdown |
long |
maxGlobalMemory
Max global memory limit: default is 4GB |
int |
SERVER_THREAD
Default number of threads in pool for Server. |
protected long |
serverChannelReadLimit
Limit in Read byte/s to apply by session to the FTP Server |
protected long |
serverChannelWriteLimit
Limit in Write byte/s to apply by session to the FTP Server |
protected long |
serverGlobalReadLimit
Limit in Read byte/s to apply globally to the FTP Server |
protected long |
serverGlobalWriteLimit
Limit in Write byte/s to apply globally to the FTP Server |
long |
TIMEOUTCON
Nb of milliseconds after connection is in timeout |
static boolean |
USEJDK6
True if use of JDK6 or upper, False if JDK5. |
| Constructor Summary | |
|---|---|
FtpConfiguration(Class<?> classtype,
Class<? extends BusinessHandler> businessHandler,
Class<? extends DataBusinessHandler> dataBusinessHandler,
goldengate.common.file.FileParameterInterface fileParameter)
Simple constructor |
|
| Method Summary | |
|---|---|
void |
bindLock()
In bind/unbind operation, lock |
void |
bindUnlock()
In bind/unbind operation, unlock |
void |
changeNetworkLimit(long writeLimit,
long readLimit)
Reset the global monitor for bandwidth limitation and change future channel monitors with values divided by 10 (channel = global / 10) |
boolean |
checkPassword(String password)
Check the password for Shutdown |
void |
computeNbThreads()
Compute number of threads for both client and server from the real number of available processors (double + 1) if the value is less than 64 threads. |
void |
delFtpSession(InetAddress ipOnly,
InetSocketAddress fullIp)
Remove the FtpSession |
String |
getBaseDirectory()
|
Class<? extends DataBusinessHandler> |
getDataBusinessHandler()
|
long |
getDelayLimit()
|
goldengate.common.file.FileParameterInterface |
getFileParameter()
|
File |
getFileProperty(String key)
|
FtpInternalConfiguration |
getFtpInternalConfiguration()
|
FtpSession |
getFtpSession(org.jboss.netty.channel.Channel channel,
boolean active)
Return and remove the FtpSession |
int |
getIntProperty(String key)
|
Lock |
getLock()
|
abstract int |
getNextRangePort()
Return the next available port for passive connections. |
Object |
getProperty(String key)
|
String |
getServerAddress()
|
long |
getServerChannelReadLimit()
|
long |
getServerChannelWriteLimit()
|
long |
getServerGlobalReadLimit()
|
long |
getServerGlobalWriteLimit()
|
int |
getServerPort()
|
String |
getStringProperty(String key)
|
String |
getUniqueExtension()
|
boolean |
hasFtpSession(InetAddress ipOnly,
InetSocketAddress fullIp)
Test if the couple of addresses is already in the context |
abstract void |
inShutdownProcess()
Shutdown process is on going |
void |
releaseResources()
To use if any external resources are to be released when shutting down |
void |
serverStartup()
Init internal configuration |
void |
setBaseDirectory(String dir)
|
void |
setFileProperty(String key,
File f)
|
void |
setIntProperty(String key,
int i)
|
void |
setNewFtpSession(InetAddress ipOnly,
InetSocketAddress fullIp,
FtpSession session)
Add a session from a couple of addresses |
void |
setPassword(String password)
|
void |
setProperty(String key,
Object o)
|
void |
setServerAddress(String address)
|
void |
setServerPort(int port)
|
void |
setStringProperty(String key,
String s)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final boolean USEJDK6
public static long DEFAULT_SESSION_LIMIT
public static long DEFAULT_GLOBAL_LIMIT
public volatile boolean isShutdown
public int SERVER_THREAD
public int CLIENT_THREAD
public Class<?> fromClass
public Class<? extends DataBusinessHandler> dataBusinessHandler
public Class<? extends BusinessHandler> businessHandler
public long TIMEOUTCON
public int BLOCKSIZE
protected long serverGlobalWriteLimit
protected long serverGlobalReadLimit
protected long serverChannelWriteLimit
protected long serverChannelReadLimit
protected long delayLimit
public boolean deleteOnAbort
public long maxGlobalMemory
| Constructor Detail |
|---|
public FtpConfiguration(Class<?> classtype,
Class<? extends BusinessHandler> businessHandler,
Class<? extends DataBusinessHandler> dataBusinessHandler,
goldengate.common.file.FileParameterInterface fileParameter)
classtype - OwnerbusinessHandler - class that will be used for BusinessHandlerdataBusinessHandler - class that will be used for DataBusinessHandlerfileParameter - the FileParameterInterface to used| Method Detail |
|---|
public String getStringProperty(String key)
throws FtpUnknownFieldException
key -
FtpUnknownFieldException
public int getIntProperty(String key)
throws FtpUnknownFieldException
key -
FtpUnknownFieldException
public File getFileProperty(String key)
throws FtpUnknownFieldException
key -
FtpUnknownFieldException
public Object getProperty(String key)
throws FtpUnknownFieldException
key -
FtpUnknownFieldExceptionpublic int getServerPort()
public String getServerAddress()
public long getServerGlobalWriteLimit()
public long getServerChannelWriteLimit()
public long getServerGlobalReadLimit()
public long getServerChannelReadLimit()
public long getDelayLimit()
public boolean checkPassword(String password)
password -
public abstract int getNextRangePort()
public String getBaseDirectory()
public void setStringProperty(String key,
String s)
key - s -
public void setIntProperty(String key,
int i)
key - i -
public void setFileProperty(String key,
File f)
key - f -
public void setProperty(String key,
Object o)
key - o - public void setServerPort(int port)
port - the new portpublic void setServerAddress(String address)
address - the address to use while answering for addresspublic void setBaseDirectory(String dir)
dir - the new base directorypublic void setPassword(String password)
password - the new password for shutdownpublic Class<? extends DataBusinessHandler> getDataBusinessHandler()
public void serverStartup()
public void changeNetworkLimit(long writeLimit,
long readLimit)
writeLimit - readLimit - public void computeNbThreads()
public Lock getLock()
public void bindLock()
public void bindUnlock()
public FtpInternalConfiguration getFtpInternalConfiguration()
public void setNewFtpSession(InetAddress ipOnly,
InetSocketAddress fullIp,
FtpSession session)
ipOnly - fullIp - session -
public FtpSession getFtpSession(org.jboss.netty.channel.Channel channel,
boolean active)
channel - active -
public void delFtpSession(InetAddress ipOnly,
InetSocketAddress fullIp)
ipOnly - fullIp -
public boolean hasFtpSession(InetAddress ipOnly,
InetSocketAddress fullIp)
ipOnly - fullIp -
public goldengate.common.file.FileParameterInterface getFileParameter()
public String getUniqueExtension()
public void releaseResources()
public abstract void inShutdownProcess()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||