public class AbandonedConfig
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private boolean |
logAbandoned
Determines whether or not to log stack traces for application code
which abandoned a Statement or Connection.
|
private java.io.PrintWriter |
logWriter
PrintWriter to use to log information on abandoned objects.
|
private boolean |
removeAbandoned
Whether or not a connection is considered abandoned and eligible
for removal if it has been idle longer than the removeAbandonedTimeout
|
private int |
removeAbandonedTimeout
Timeout in seconds before an abandoned connection can be removed
|
Constructor and Description |
---|
AbandonedConfig() |
Modifier and Type | Method and Description |
---|---|
boolean |
getLogAbandoned()
Flag to log stack traces for application code which abandoned
a Statement or Connection.
|
java.io.PrintWriter |
getLogWriter()
Returns the log writer being used by this configuration to log
information on abandoned objects.
|
boolean |
getRemoveAbandoned()
Flag to remove abandoned connections if they exceed the
removeAbandonedTimeout.
|
int |
getRemoveAbandonedTimeout()
Timeout in seconds before an abandoned connection can be removed.
|
void |
setLogAbandoned(boolean logAbandoned)
Flag to log stack traces for application code which abandoned
a Statement or Connection.
|
void |
setLogWriter(java.io.PrintWriter logWriter)
Sets the log writer to be used by this configuration to log
information on abandoned objects.
|
void |
setRemoveAbandoned(boolean removeAbandoned)
Flag to remove abandoned connections if they exceed the
removeAbandonedTimeout.
|
void |
setRemoveAbandonedTimeout(int removeAbandonedTimeout)
Timeout in seconds before an abandoned connection can be removed.
|
private boolean removeAbandoned
private int removeAbandonedTimeout
private boolean logAbandoned
private java.io.PrintWriter logWriter
public boolean getRemoveAbandoned()
public void setRemoveAbandoned(boolean removeAbandoned)
removeAbandoned
- true means abandoned connections will be
removedpublic int getRemoveAbandonedTimeout()
public void setRemoveAbandonedTimeout(int removeAbandonedTimeout)
removeAbandonedTimeout
- abandoned timeout in secondspublic boolean getLogAbandoned()
public void setLogAbandoned(boolean logAbandoned)
logAbandoned
- true turns on abandoned stack trace loggingpublic java.io.PrintWriter getLogWriter()
public void setLogWriter(java.io.PrintWriter logWriter)
logWriter
- The new log writer