Save This Page
Home » activemq-parent-5.3.1-source-release » org.apache » activemq » kaha » impl » async » [javadoc | source]
org.apache.activemq.kaha.impl.async
public class: AsyncDataManager [javadoc | source]
java.lang.Object
   org.apache.activemq.kaha.impl.async.AsyncDataManager

Direct Known Subclasses:
    ReadOnlyAsyncDataManager

Manages DataFiles
Field Summary
public static final  int CONTROL_RECORD_MAX_LENGTH     
public static final  int ITEM_HEAD_RESERVED_SPACE     
public static final  int ITEM_HEAD_SPACE     
public static final  int ITEM_HEAD_OFFSET_TO_SOR     
public static final  int ITEM_FOOT_SPACE     
public static final  int ITEM_HEAD_FOOT_SPACE     
public static final  byte[] ITEM_HEAD_SOR     
public static final  byte[] ITEM_HEAD_EOR     
public static final  byte DATA_ITEM_TYPE     
public static final  byte REDO_ITEM_TYPE     
public static final  String DEFAULT_DIRECTORY     
public static final  String DEFAULT_ARCHIVE_DIRECTORY     
public static final  String DEFAULT_FILE_PREFIX     
public static final  int DEFAULT_MAX_FILE_LENGTH     
public static final  int DEFAULT_CLEANUP_INTERVAL     
public static final  int PREFERED_DIFF     
protected static  Scheduler scheduler     
protected final  Map<WriteKey, WriteCommand> inflightWrites     
protected  File directory     
protected  File directoryArchive     
protected  String filePrefix     
protected  ControlFile controlFile     
protected  boolean started     
protected  boolean useNio     
protected  int maxFileLength     
protected  int preferedFileLength     
protected  DataFileAppender appender     
protected  DataFileAccessorPool accessorPool     
protected  Map<Integer, DataFile> fileMap     
protected  Map<File, DataFile> fileByFileMap     
protected  DataFile currentWriteFile     
protected  Location mark     
protected final  AtomicReference<Location> lastAppendLocation     
protected  Runnable cleanupTask     
protected final  AtomicLong storeSize     
protected  boolean archiveDataLogs     
Constructor:
 public AsyncDataManager() 
 public AsyncDataManager(AtomicLong storeSize) 
Method from org.apache.activemq.kaha.impl.async.AsyncDataManager Summary:
addInterestInFile,   addInterestInFile,   allocateLocation,   cleanup,   close,   consolidateDataFiles,   consolidateDataFilesNotIn,   consolidateDataFilesNotIn,   delete,   getCurrentDataFileId,   getDataFile,   getDirectory,   getDirectoryArchive,   getDiskSize,   getDiskSizeUntil,   getFile,   getFilePrefix,   getFiles,   getInflightWrites,   getLastAppendLocation,   getMark,   getMaxFileLength,   getNextLocation,   getNextLocation,   getNextLocation,   isArchiveDataLogs,   isUseNio,   lock,   read,   recoveryCheck,   removeInterestInFile,   removeInterestInFile,   removeLocation,   setArchiveDataLogs,   setDirectory,   setDirectoryArchive,   setFilePrefix,   setLastAppendLocation,   setMark,   setMaxFileLength,   setUseNio,   start,   storeState,   toString,   unmarshallState,   update,   write,   write,   write
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.activemq.kaha.impl.async.AsyncDataManager Detail:
 public synchronized  void addInterestInFile(int file) throws IOException 
 synchronized  void addInterestInFile(DataFile dataFile) 
 synchronized DataFile allocateLocation(Location location) throws IOException 
 synchronized  void cleanup() 
 public synchronized  void close() throws IOException 
 public synchronized  void consolidateDataFiles() throws IOException 
 public synchronized  void consolidateDataFilesNotIn(Set<Integer> inUse,
    Set<Integer> inProgress) throws IOException 
 public synchronized  void consolidateDataFilesNotIn(Set<Integer> inUse,
    Integer lastFile) throws IOException 
 public synchronized boolean delete() throws IOException 
 public synchronized Integer getCurrentDataFileId() 
 synchronized DataFile getDataFile(Location item) throws IOException 
 public File getDirectory() 
 public File getDirectoryArchive() 
 public synchronized long getDiskSize() 
 public synchronized long getDiskSizeUntil(Location startPosition) 
 synchronized File getFile(Location item) throws IOException 
 public String getFilePrefix() 
 public Set<File> getFiles() 
    Get a set of files - only valid after start()
 public Map<WriteKey, WriteCommand> getInflightWrites() 
 public Location getLastAppendLocation() 
 public synchronized Location getMark() throws IllegalStateException 
 public int getMaxFileLength() 
 public synchronized Location getNextLocation(Location location) throws IOException, IllegalStateException 
 public synchronized Location getNextLocation(File file,
    Location lastLocation,
    boolean thisFileOnly) throws IllegalStateException, IOException 
 public synchronized Location getNextLocation(DataFile dataFile,
    Location lastLocation,
    boolean thisFileOnly) throws IOException, IllegalStateException 
 public boolean isArchiveDataLogs() 
 public boolean isUseNio() 
 public  void lock() throws IOException 
 public synchronized ByteSequence read(Location location) throws IOException, IllegalStateException 
 protected Location recoveryCheck(DataFile dataFile,
    Location location) throws IOException 
 public synchronized  void removeInterestInFile(int file) throws IOException 
 synchronized  void removeInterestInFile(DataFile dataFile) throws IOException 
 public synchronized  void removeLocation(Location location) throws IOException 
 public  void setArchiveDataLogs(boolean archiveDataLogs) 
 public  void setDirectory(File directory) 
 public  void setDirectoryArchive(File directoryArchive) 
 public  void setFilePrefix(String filePrefix) 
 public  void setLastAppendLocation(Location lastSyncedLocation) 
 public  void setMark(Location location,
    boolean sync) throws IOException, IllegalStateException 
 public  void setMaxFileLength(int maxFileLength) 
 public  void setUseNio(boolean useNio) 
 public synchronized  void start() throws IOException 
 protected synchronized  void storeState(boolean sync) throws IOException 
 public String toString() 
 protected  void unmarshallState(ByteSequence sequence) throws IOException 
 public  void update(Location location,
    ByteSequence data,
    boolean sync) throws IOException 
 public synchronized Location write(ByteSequence data,
    boolean sync) throws IOException, IllegalStateException 
 public synchronized Location write(ByteSequence data,
    Runnable onComplete) throws IOException, IllegalStateException 
 public synchronized Location write(ByteSequence data,
    byte type,
    boolean sync) throws IOException, IllegalStateException