Action Tracking Service update

Keep a record of which machine an action is currently running on, so for a cluster situation you know where you actions are


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@21482 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Nick Burch
2010-07-29 11:10:41 +00:00
parent 44e18c2d81
commit 77967ef61b
2 changed files with 21 additions and 4 deletions

View File

@@ -20,6 +20,7 @@ package org.alfresco.repo.action;
import static org.alfresco.repo.action.ActionServiceImplTest.assertBefore;
import java.net.InetAddress;
import java.util.Date;
import javax.transaction.UserTransaction;
@@ -171,7 +172,12 @@ public class ActionTrackingServiceImplTest extends TestCase
assertEquals(null, d.getPersistedActionRef());
assertEquals(null, d.getStartedAt());
// TODO Check machine details
// Check the machine details
// Should be "IP : Name"
InetAddress localhost = InetAddress.getLocalHost();
String machineName = localhost.getHostAddress() + " : " +
localhost.getHostName();
assertEquals(machineName, d.getRunningOn());
}
/** Running an action gives it an execution ID */