Class AutoDeployedFilesManager
- java.lang.Object
-
- org.glassfish.deployment.autodeploy.AutoDeployedFilesManager
-
public class AutoDeployedFilesManager extends Object
Contains the status of list of files that have been autodeployed.- Author:
- Mahesh Rangamani
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
AutoDeployedFilesManager.UndeployRequestedFile
-
Field Summary
Fields Modifier and Type Field Description static Logger
deplLogger
protected String
statDir
-
Constructor Summary
Constructors Modifier Constructor Description AutoDeployedFilesManager()
protected
AutoDeployedFilesManager(String s)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected static File
appToUndeployRequestFile(File f)
protected static File
appToUndeployRequestFile(File autodeployDir, File f)
void
deleteDeployedFileInfo(File f)
File[]
getFilesForDeployment(File[] latestFiles)
Compare the list of files with the current status info and determine the files that need to be deployedFile[]
getFilesForUndeployment(File[] latestFiles)
Compare the list of files with the current status info and determine the apps that need to be undeployed.static AutoDeployedFilesManager
loadStatus(File statusDir)
Create an instance from the persisted file in the specified directory.static AutoDeployedFilesManager
loadStatus(String autoDeploymentDir)
void
setDeployedFileInfo(File f)
Update the status of the file as deployed.void
writeStatus()
-
-
-
Constructor Detail
-
AutoDeployedFilesManager
public AutoDeployedFilesManager()
-
AutoDeployedFilesManager
protected AutoDeployedFilesManager(String s)
-
-
Method Detail
-
loadStatus
public static AutoDeployedFilesManager loadStatus(File statusDir) throws Exception
Create an instance from the persisted file in the specified directory.- Parameters:
statusDir
- Directory in which the status file is to read.- Returns:
- Throws:
Exception
-
loadStatus
public static AutoDeployedFilesManager loadStatus(String autoDeploymentDir) throws Exception
- Throws:
Exception
-
setDeployedFileInfo
public void setDeployedFileInfo(File f) throws Exception
Update the status of the file as deployed.- Parameters:
f
-- Throws:
Exception
-
deleteDeployedFileInfo
public void deleteDeployedFileInfo(File f) throws Exception
- Throws:
Exception
-
getFilesForDeployment
public File[] getFilesForDeployment(File[] latestFiles)
Compare the list of files with the current status info and determine the files that need to be deployed- Parameters:
latestFiles
-- Returns:
-
getFilesForUndeployment
public File[] getFilesForUndeployment(File[] latestFiles)
Compare the list of files with the current status info and determine the apps that need to be undeployed.- Parameters:
latestFiles
-- Returns:
-
appToUndeployRequestFile
protected static File appToUndeployRequestFile(File autodeployDir, File f)
-
-