|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.lang.Thread org.openmrs.hl7.Hl7InArchivesMigrateThread
public class Hl7InArchivesMigrateThread
Separate thread to move the hl7 in archives from the database tables to the filesystem. It is highly recommended to start this thread by calling "startHl7ArchiveMigration(UserContext)" method in the service layer as opposed to calling the thread's start() method to ensure the thread is started after making all the necessary checks.
HL7Service#startHl7ArchiveMigration()}
Nested Class Summary | |
---|---|
static class |
Hl7InArchivesMigrateThread.Status
The different states this thread can be in at a given point during migration |
Nested classes/interfaces inherited from class java.lang.Thread |
---|
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler |
Field Summary |
---|
Fields inherited from class java.lang.Thread |
---|
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Constructor Summary | |
---|---|
Hl7InArchivesMigrateThread()
Constructor to initialize variables |
Method Summary | |
---|---|
static java.lang.Integer |
getDaysKept()
|
static java.lang.Integer |
getNumberOfFailedTransfers()
Gets the number of failed transfers during migration, this could be that the system couldn't write them to the file system or couldn't be deleted from the database. |
static java.lang.Integer |
getNumberTransferred()
|
static Hl7InArchivesMigrateThread.Status |
getTransferStatus()
|
UserContext |
getUserContext()
|
static boolean |
isActive()
|
void |
run()
|
static void |
setActive(boolean active)
|
static void |
setDaysKept(java.lang.Integer daysKept)
|
static void |
stopMigration()
convenience method to set transfer status and active flag to stop migration |
Methods inherited from class java.lang.Thread |
---|
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Hl7InArchivesMigrateThread()
Method Detail |
---|
public static java.lang.Integer getDaysKept()
public static void setDaysKept(java.lang.Integer daysKept)
daysKept
- the daysKept to setpublic static boolean isActive()
public static void setActive(boolean active)
active
- the active to setpublic void run()
run
in interface java.lang.Runnable
run
in class java.lang.Thread
Runnable.run()
public static void stopMigration()
public static Hl7InArchivesMigrateThread.Status getTransferStatus()
public static java.lang.Integer getNumberTransferred()
public static java.lang.Integer getNumberOfFailedTransfers()
public UserContext getUserContext()
|
OpenMRS-1.7.x | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |