AVM now configures itself via Spring. Also adjusted jndi-client and catalina-virtual

to be semi-not-broken.  The current limitation is that you've got to start tomcat from
$TOMCAT_HOME for things to work (fix soon).


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/WCM-DEV2/root@3267 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Britt Park
2006-06-29 21:37:17 +00:00
parent 7d940d08e1
commit 106273bde8
15 changed files with 261 additions and 114 deletions

View File

@@ -30,7 +30,7 @@ import org.hibernate.Session;
* in the AVM repository. These orphans arise from purge operations.
* @author britt
*/
class OrphanReaper implements Runnable
public class OrphanReaper implements Runnable
{
/**
* The HibernateTxn instance.
@@ -68,12 +68,16 @@ class OrphanReaper implements Runnable
*/
private Thread fThread;
/**
* The Hibernate helper to use.
*/
private HibernateHelper fHibernateHelper;
/**
* Create one with default parameters.
*/
public OrphanReaper()
{
fTransaction = new HibernateTxn(HibernateHelper.GetSessionFactory());
fInactiveBaseSleep = 30000;
fActiveBaseSleep = 1000;
fBatchSize = 50;
@@ -110,11 +114,21 @@ class OrphanReaper implements Runnable
fBatchSize = size;
}
/**
* Set the HibernateHelper to use.
* @param helper The helper to use.
*/
public void setHibernateHelper(HibernateHelper helper)
{
fHibernateHelper = helper;
}
/**
* Start things up after configuration is complete.
*/
public void init()
{
fTransaction = new HibernateTxn(fHibernateHelper.getSessionFactory());
fThread = new Thread(this);
fThread.start();
}