Timeline : modify DB column and modify concern logic 79/28379/3
authorjungwook.ryu <jungwook.ryu@samsung.com>
Mon, 6 Oct 2014 09:11:22 +0000 (18:11 +0900)
committerjungwook.ryu <jungwook.ryu@samsung.com>
Mon, 6 Oct 2014 10:30:15 +0000 (19:30 +0900)
TIMELINE_TARGET_PROCESS binaryPath -> binaryID

Change-Id: I10797d9ac7e3945cfb4432ed55241a0968a78b6b
Signed-off-by: jungwook.ryu <jungwook.ryu@samsung.com>
org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/info/screenshot/ScreenShotDBTable.java
org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/TargetProcessDBTable.java
org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/UIEventDBTable.java
org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/chart/HeapChart.java
org.tizen.dynamicanalyzer/src/org/tizen/dynamicanalyzer/ui/timeline/common/TimelineChartManager.java

index ba640fd..a4b831b 100644 (file)
@@ -35,11 +35,12 @@ import java.util.List;
 import org.tizen.dynamicanalyzer.database.DBColumn;
 import org.tizen.dynamicanalyzer.database.DBConstants;
 import org.tizen.dynamicanalyzer.database.DBTable;
+import org.tizen.dynamicanalyzer.util.Logger;
 
 public class ScreenShotDBTable extends DBTable {
        private static final String TABLENAME = "TIMELINE_SCREENSHOT";
        
-       private final static int MAX_IMAGEPATH_LEN = 1024; 
+       private final static int MAX_IMAGEPATH_LEN = 32;
        
        public static enum COLUMN {
                CAPTURE_TIME,
@@ -58,7 +59,7 @@ public class ScreenShotDBTable extends DBTable {
 
        public ScreenShotDBTable() {
                addColumn(new DBColumn(CAPTURE_TIME, DBConstants.NOT_NULL, DBConstants.LONG));
-               addColumn(new DBColumn(IMAGE_FILE_PATH, DBConstants.NOT_NULL, DBConstants.VARCHAR, MAX_IMAGEPATH_LEN));
+               addColumn(new DBColumn(IMAGE_FILE_PATH, DBConstants.EMPTY, DBConstants.VARCHAR, MAX_IMAGEPATH_LEN));
                addColumn(new DBColumn(IMAGE_ORIENTATION, DBConstants.NOT_NULL, DBConstants.INTEGER));
                setIndexColumn(COLUMN.CAPTURE_TIME.ordinal());
        }
@@ -73,7 +74,13 @@ public class ScreenShotDBTable extends DBTable {
                } else {
                        try {
                                prep.setLong(1, (Long) (rowData.get(COLUMN.CAPTURE_TIME.ordinal())));
-                               prep.setString(2, (String) (rowData.get(COLUMN.IMAGE_FILE_PATH.ordinal())));
+                               // Check string overflow
+                               String image_file = (String) (rowData.get(COLUMN.IMAGE_FILE_PATH.ordinal()));
+                               if (image_file != null && image_file.length() > MAX_IMAGEPATH_LEN) {
+                                       Logger.error("Overflow occurs MAX_IMAGEPATH_LEN in ScreenShotDBTable : " + image_file);
+                                       image_file = null;
+                               }
+                               prep.setString(2, image_file);
                                prep.setInt(3, (Integer) (rowData.get(COLUMN.IMAGE_ORIENTATION.ordinal())));
                        } catch (SQLException e) {
                                e.printStackTrace();
index 7b1b13b..1fe254e 100644 (file)
@@ -49,7 +49,7 @@ public class TargetProcessDBTable extends DBTable {
                MEMORY_PSS,
                THREAD_COUNT,
                HEAP_ALLOCATION_TOTAL_BYTE,
-               HEAP_ALLOCATION_NAME,
+               HEAP_ALLOCATION_BINARY_ID,
                HEAP_ALLOCATION_BYTE,
                THREAD_ID,
                THREAD_LOAD
@@ -64,11 +64,10 @@ public class TargetProcessDBTable extends DBTable {
        public static final String MEMORY_PSS = "MEMORY_PSS";
        public static final String THREAD_COUNT = "THREAD_COUNT";
        public static final String HEAP_ALLOCATION_TOTAL_BYTE = "HEAP_ALLOCATION_TOTAL_BYTE";
-       public static final String HEAP_ALLOCATION_NAME = "HEAP_ALLOCATION_NAME";
+       public static final String HEAP_ALLOCATION_BINARY_ID = "HEAP_ALLOCATION_BINARY_ID";
        public static final String HEAP_ALLOCATION_BYTE = "HEAP_ALLOCATION_BYTE";
        public static final String THREAD_ID = "THREAD_ID";
        public static final String THREAD_LOAD = "THREAD_LOAD";
-       public static final int HEAP_ALLOCATION_NAME_LEN = 256;
 
        @Override
        public String getTableName() {
@@ -85,8 +84,7 @@ public class TargetProcessDBTable extends DBTable {
                addColumn(new DBColumn(MEMORY_PSS, DBConstants.EMPTY, DBConstants.LONG));
                addColumn(new DBColumn(THREAD_COUNT, DBConstants.EMPTY, DBConstants.INTEGER));
                addColumn(new DBColumn(HEAP_ALLOCATION_TOTAL_BYTE, DBConstants.EMPTY, DBConstants.LONG));
-               addColumn(new DBColumn(HEAP_ALLOCATION_NAME, DBConstants.EMPTY, DBConstants.VARCHAR_ARRAY,
-                               HEAP_ALLOCATION_NAME_LEN));
+               addColumn(new DBColumn(HEAP_ALLOCATION_BINARY_ID, DBConstants.EMPTY, DBConstants.INTEGER_ARRAY));
                addColumn(new DBColumn(HEAP_ALLOCATION_BYTE, DBConstants.EMPTY, DBConstants.BIGINT_ARRAY));
                addColumn(new DBColumn(THREAD_ID, DBConstants.EMPTY, DBConstants.INTEGER_ARRAY));
                addColumn(new DBColumn(THREAD_LOAD, DBConstants.EMPTY, DBConstants.FLOAT_ARRAY));
@@ -111,10 +109,9 @@ public class TargetProcessDBTable extends DBTable {
                                prep.setLong(++index, (Long) (rowData.get(COLUMN.MEMORY_SHARED.ordinal())));
                                prep.setLong(++index, (Long) (rowData.get(COLUMN.MEMORY_PSS.ordinal())));
                                prep.setInt(++index, (Integer) (rowData.get(COLUMN.THREAD_COUNT.ordinal())));
-                               prep.setLong(++index,
-                                               (Long) (rowData.get(COLUMN.HEAP_ALLOCATION_TOTAL_BYTE.ordinal())));
-                               setArrayToPreparedStatement(COLUMN.HEAP_ALLOCATION_NAME.ordinal(),
-                                               DBConstants.VARCHAR, prep, rowData);
+                               prep.setLong(++index, (Long) (rowData.get(COLUMN.HEAP_ALLOCATION_TOTAL_BYTE.ordinal())));
+                               setArrayToPreparedStatement(COLUMN.HEAP_ALLOCATION_BINARY_ID.ordinal(), 
+                                               DBConstants.INTEGER, prep, rowData);
                                setArrayToPreparedStatement(COLUMN.HEAP_ALLOCATION_BYTE.ordinal(),
                                                DBConstants.LONG, prep, rowData);
                                setArrayToPreparedStatement(COLUMN.THREAD_ID.ordinal(), DBConstants.INTEGER, prep,
@@ -143,7 +140,7 @@ public class TargetProcessDBTable extends DBTable {
                        row.add(Long.valueOf(rs.getLong(7)));
                        row.add(Integer.valueOf(rs.getInt(8)));
                        row.add(Long.valueOf(rs.getLong(9)));
-                       row.add(getArrayFromResultSet(rs, 10, String.valueOf(0)));
+                       row.add(getArrayFromResultSet(rs, 10, Integer.valueOf(0)));
                        row.add(getArrayFromResultSet(rs, 11, Long.valueOf(0)));
                        row.add(getArrayFromResultSet(rs, 12, Integer.valueOf(0)));
                        row.add(getArrayFromResultSet(rs, 13, Float.valueOf(0)));
index 61aec49..1ed8c3e 100644 (file)
@@ -35,11 +35,12 @@ import java.util.List;
 import org.tizen.dynamicanalyzer.database.DBColumn;
 import org.tizen.dynamicanalyzer.database.DBConstants;
 import org.tizen.dynamicanalyzer.database.DBTable;
+import org.tizen.dynamicanalyzer.util.Logger;
 
 public class UIEventDBTable extends DBTable {
        private static final String TABLENAME = "TIMELINE_UIEVENT";
        
-       private final static int MAX_INFO_LEN = 256
+       private final static int MAX_INFO_LEN = 64
        
        public static enum COLUMN {
                EVENT_TIME,
@@ -89,7 +90,13 @@ public class UIEventDBTable extends DBTable {
                                prep.setInt(3, (Integer) (rowData.get(COLUMN.DETAIL_TYPE.ordinal())));
                                prep.setInt(4, (Integer) (rowData.get(COLUMN.POINT_X.ordinal())));
                                prep.setInt(5, (Integer) (rowData.get(COLUMN.POINT_Y.ordinal())));
-                               prep.setString(6, (String) (rowData.get(COLUMN.INFO_STRING.ordinal())));
+                               // Check string overflow
+                               String info = (String) (rowData.get(COLUMN.INFO_STRING.ordinal()));
+                               if (info != null && info.length() > MAX_INFO_LEN) {
+                                       Logger.error("Overflow occurs INFO_STRING in UIEventDBTable : " + info);
+                                       info = info.substring(0, MAX_INFO_LEN);
+                               }
+                               prep.setString(6, info);
                                prep.setInt(7, (Integer) (rowData.get(COLUMN.INFO_INTEGER.ordinal())));
                        } catch (SQLException e) {
                                e.printStackTrace();
index 463eb75..5cafa9a 100644 (file)
@@ -63,12 +63,16 @@ import org.tizen.dynamicanalyzer.widgets.popupMenu.DAPopupMenu;
 public class HeapChart extends TimelineChart {
        private static HeapChart instance = null;
 
-       private List<String> librarySequenceList = new ArrayList<String>();
-       // Map<PID, Map<binaryPath, DAChartSeries>>
-       private Map<Integer, Map<String, DAChartSeries>> seriesPerProcessMap = new HashMap<Integer, Map<String, DAChartSeries>>();
+       private List<Integer> librarySequenceList = new ArrayList<Integer>();
+       // Map<PID, Map<binaryID, DAChartSeries>>
+       private Map<Integer, Map<Integer, DAChartSeries>> seriesPerProcessMap = 
+                       new HashMap<Integer, Map<Integer, DAChartSeries>>();
        private DAChartBoardItem parentBoardItem;
        private List<DAChartBoardItem> childBoardItemList = new ArrayList<DAChartBoardItem>();
 
+       private static final int totalAllocSeriesID = -100;
+       private static final int appAllocSeriesID = -10;
+       
        public static HeapChart getInstance() {
                if (instance == null) {
                        instance = new HeapChart();
@@ -76,16 +80,15 @@ public class HeapChart extends TimelineChart {
                return instance;
        }
 
-       private Map<String, DAChartSeries> createChartSeries(int pid) {
-               Map<String, DAChartSeries> chartSeriesMap = new HashMap<String, DAChartSeries>();
+       private Map<Integer, DAChartSeries> createChartSeries(int pid) {
+               Map<Integer, DAChartSeries> chartSeriesMap = new HashMap<Integer, DAChartSeries>();
                /*
                 * Add total allocation
                 */
                DAChartSeries totalAllocationSeries = new DAChartSeries(
                                TimelineChartLabels.HEAP_CHART_SERIES_NAME_TOTAL_ALLOCATION,
                                DAChartSeries.SERIES_STYLE_AREA, ColorResources.SERIES_COLOR_HEAP_SYSTEM);
-               chartSeriesMap.put(TimelineChartLabels.HEAP_CHART_SERIES_NAME_TOTAL_ALLOCATION,
-                               totalAllocationSeries);
+               chartSeriesMap.put(totalAllocSeriesID, totalAllocationSeries);
                /*
                 * Add additional library allocation
                 */
@@ -102,7 +105,7 @@ public class HeapChart extends TimelineChart {
                                if (null != libObj) {
                                        DAChartSeries libraryAllocSeries = new DAChartSeries(libraryPath,
                                                        DAChartSeries.SERIES_STYLE_AREA);
-                                       chartSeriesMap.put(libraryPath, libraryAllocSeries);
+                                       chartSeriesMap.put(libObj.getBinaryID(), libraryAllocSeries);
                                }
                        }
                }
@@ -112,8 +115,7 @@ public class HeapChart extends TimelineChart {
                DAChartSeries targetAllocationSeries = new DAChartSeries(
                                TimelineChartLabels.HEAP_CHART_SERIES_NAME_APP_ALLOCATION,
                                DAChartSeries.SERIES_STYLE_AREA, ColorResources.SERIES_COLOR_HEAP_USER);
-               chartSeriesMap.put(TimelineChartLabels.HEAP_CHART_SERIES_NAME_APP_ALLOCATION,
-                               targetAllocationSeries);
+               chartSeriesMap.put(appAllocSeriesID, targetAllocationSeries);
 
                return chartSeriesMap;
        }
@@ -168,7 +170,7 @@ public class HeapChart extends TimelineChart {
                /*
                 * Clear series items
                 */
-               Iterator<Map<String, DAChartSeries>> iterPerPID = seriesPerProcessMap.values().iterator();
+               Iterator<Map<Integer, DAChartSeries>> iterPerPID = seriesPerProcessMap.values().iterator();
                while (iterPerPID.hasNext()) {
                        Iterator<DAChartSeries> iterSeries = iterPerPID.next().values().iterator();
                        while (iterSeries.hasNext()) {
@@ -191,7 +193,7 @@ public class HeapChart extends TimelineChart {
                         * First process, use parentBoardItem.
                         */
                        if (seriesPerProcessMap.isEmpty()) {
-                               Map<String, DAChartSeries> seriesMap = createChartSeries(pid);
+                               Map<Integer, DAChartSeries> seriesMap = createChartSeries(pid);
                                seriesPerProcessMap.put(pid, seriesMap);
                                setChartSeries(chart, seriesMap);
                                final String processName = AnalyzerUtil.getProcessName(pid.intValue());
@@ -208,7 +210,7 @@ public class HeapChart extends TimelineChart {
                         * If new Process created, Create ChartBoardItem, Chart, Series.
                         */
                        else if (seriesPerProcessMap.get(pid) == null) {
-                               final Map<String, DAChartSeries> seriesMap = createChartSeries(pid);
+                               final Map<Integer, DAChartSeries> seriesMap = createChartSeries(pid);
                                seriesPerProcessMap.put(pid, seriesMap);
                                Display.getDefault().syncExec(new Runnable() {
                                        @Override
@@ -227,7 +229,7 @@ public class HeapChart extends TimelineChart {
                                });
                        }
 
-                       Map<String, DAChartSeries> seriesMap = seriesPerProcessMap.get(pid);
+                       Map<Integer, DAChartSeries> seriesMap = seriesPerProcessMap.get(pid);
                        for (int i = 0; i < data.size(); i++) {
                                List<Object> row = data.get(i);
                                double time = (Long) row.get(TargetProcessDBTable.COLUMN.SAMPLING_TIME.ordinal())
@@ -236,14 +238,13 @@ public class HeapChart extends TimelineChart {
                                                .get(TargetProcessDBTable.COLUMN.HEAP_ALLOCATION_TOTAL_BYTE.ordinal());
 
                                @SuppressWarnings("unchecked")
-                               List<Object> binaryPathList = (List<Object>) row
-                                               .get(TargetProcessDBTable.COLUMN.HEAP_ALLOCATION_NAME.ordinal());
+                               List<Object> binaryIDList = (List<Object>) row
+                                               .get(TargetProcessDBTable.COLUMN.HEAP_ALLOCATION_BINARY_ID.ordinal());
                                @SuppressWarnings("unchecked")
                                List<Object> binaryAllocList = (List<Object>) row
                                                .get(TargetProcessDBTable.COLUMN.HEAP_ALLOCATION_BYTE.ordinal());
 
-                               DAChartSeries totalAllocSeries = seriesMap
-                                               .get(TimelineChartLabels.HEAP_CHART_SERIES_NAME_TOTAL_ALLOCATION);
+                               DAChartSeries totalAllocSeries = seriesMap.get(totalAllocSeriesID);
                                totalAllocSeries.addSeriesItem(new DAChartSeriesItem(time, totalAlloc, Formatter
                                                .toByteFormat(totalAlloc)));
                                long targetAlloc = (Long) binaryAllocList.get(0); // target
@@ -252,8 +253,7 @@ public class HeapChart extends TimelineChart {
                                                                                                                                        // located
                                                                                                                                        // at first
                                                                                                                                        // index.
-                               DAChartSeries appAllocSeries = seriesMap
-                                               .get(TimelineChartLabels.HEAP_CHART_SERIES_NAME_APP_ALLOCATION);
+                               DAChartSeries appAllocSeries = seriesMap.get(appAllocSeriesID);
                                appAllocSeries.addSeriesItem(new DAChartSeriesItem(time, targetAlloc, Formatter
                                                .toByteFormat(targetAlloc)));
 
@@ -269,12 +269,12 @@ public class HeapChart extends TimelineChart {
                                 */
                                long beforeLibraryAlloc = 0; // need to accumulate
                                for (int ii = 0; ii < librarySequenceList.size(); ii++) {
-                                       String libraryPath = librarySequenceList.get(ii);
-                                       DAChartSeries allocSeries = seriesMap.get(libraryPath);
+                                       Integer libraryID = librarySequenceList.get(ii);
+                                       DAChartSeries allocSeries = seriesMap.get(libraryID);
                                        if (allocSeries == null) {      // this process don't use this binary
                                                continue;
                                        }
-                                       int index = binaryPathList.indexOf(libraryPath);
+                                       int index = binaryIDList.indexOf(libraryID);
                                        long libraryAlloc = 0;
                                        if (index > 0) {
                                                libraryAlloc = (Long) binaryAllocList.get(index);
@@ -287,22 +287,20 @@ public class HeapChart extends TimelineChart {
                }
        }
 
-       private void setChartSeries(DAChart chart, Map<String, DAChartSeries> seriesMap) {
-               chart.addSeries(seriesMap.get(TimelineChartLabels.HEAP_CHART_SERIES_NAME_TOTAL_ALLOCATION));
-               Iterator<String> iterSeries = seriesMap.keySet().iterator();
+       private void setChartSeries(DAChart chart, Map<Integer, DAChartSeries> seriesMap) {
+               chart.addSeries(seriesMap.get(totalAllocSeriesID));
+               Iterator<Integer> iterSeries = seriesMap.keySet().iterator();
                while (iterSeries.hasNext()) {
-                       String libraryPath = iterSeries.next();
-                       if (libraryPath.equals(TimelineChartLabels.HEAP_CHART_SERIES_NAME_TOTAL_ALLOCATION)
-                                       || libraryPath
-                                                       .equals(TimelineChartLabels.HEAP_CHART_SERIES_NAME_APP_ALLOCATION)) {
+                       Integer binaryID = iterSeries.next();
+                       if (binaryID < 0) {
                                continue;
                        }
-                       chart.addSeries(seriesMap.get(libraryPath));
-                       if (librarySequenceList.indexOf(libraryPath) < 0) {
-                               librarySequenceList.add(libraryPath);
+                       chart.addSeries(seriesMap.get(binaryID));
+                       if (librarySequenceList.indexOf(binaryID) < 0) {
+                               librarySequenceList.add(binaryID);
                        }
                }
-               chart.addSeries(seriesMap.get(TimelineChartLabels.HEAP_CHART_SERIES_NAME_APP_ALLOCATION));
+               chart.addSeries(seriesMap.get(appAllocSeriesID));
        }
 
        @Override
index 287b4f7..978b0c4 100644 (file)
@@ -58,7 +58,6 @@ import org.tizen.dynamicanalyzer.swap.model.data.SystemData;
 import org.tizen.dynamicanalyzer.swap.model.data.UIEventData;
 import org.tizen.dynamicanalyzer.ui.common.TimelineChartMouseEventListener;
 import org.tizen.dynamicanalyzer.ui.common.TimelineChartMouseTrackAdapter;
-import org.tizen.dynamicanalyzer.ui.info.screenshot.ScreenShotDBTable;
 import org.tizen.dynamicanalyzer.ui.info.screenshot.ScreenshotDataManager;
 import org.tizen.dynamicanalyzer.ui.timeline.CustomDataDBTable;
 import org.tizen.dynamicanalyzer.ui.timeline.SystemDataDBTable;
@@ -117,11 +116,12 @@ public class TimelineChartManager extends PageDataManager implements IDAChartSer
        private static final int MEM_API_TYPE_ALLOC = 0;
        private static final int MEM_API_TYPE_FREE = 1;
        private static final int MEM_USER = 2;
+       private static final int appAllocSeriesID = -10;
 
        // Map<PID, target Allocation Byte>
        private Map<Integer, Long> allocByteMap = new HashMap<Integer, Long>();
-       // Map<PID, Map<binaryPath, Allocation Byte>>
-       private Map<Integer, Map<String, Long>> libraryAllocByteMap = new HashMap<Integer, Map<String, Long>>();
+       // Map<PID, Map<binaryID, Allocation Byte>>
+       private Map<Integer, Map<Integer, Long>> libraryAllocByteMap = new HashMap<Integer, Map<Integer, Long>>();
        // Map<Address, Allocation Byte>
        private HashMap<Long, Long> allocationSeriesDataSetMap = new HashMap<Long, Long>();
 
@@ -404,7 +404,7 @@ public class TimelineChartManager extends PageDataManager implements IDAChartSer
                                if (allocByteMap.get(logData.getPid()) == null) {
                                        allocByteMap.put(Integer.valueOf(logData.getPid()), new Long(0));
                                        libraryAllocByteMap.put(Integer.valueOf(logData.getPid()),
-                                                       new HashMap<String, Long>());
+                                                       new HashMap<Integer, Long>());
                                }
 
                                int memApiType = logData.getMemoryApiType();
@@ -414,22 +414,21 @@ public class TimelineChartManager extends PageDataManager implements IDAChartSer
                                /*
                                 * Check library allocation
                                 */
-                               String binaryPath = null;
+                               BinaryInfo binaryInfo = null;
                                Project project = Global.getProject();
                                ProcessMemoryMap pmap = project.getProcessInformation(logData.getPid())
                                                .getProcessMemoryMap(logData.getTime());
                                if (pmap != null) {
                                        LibraryObject lib = pmap.getLibraryByAddress(logData.getCallerPcAddr());
                                        if (lib != null && lib != pmap.getMainbinary()) {
-                                               BinaryInfo binfo = project.getDeviceStatusInfo().getBinaryInfo(
+                                               binaryInfo = project.getDeviceStatusInfo().getBinaryInfo(
                                                                lib.getBinaryID());
-                                               binaryPath = binfo.getTargetBinaryPath();
                                        }
                                }
 
                                if (errorNo == 0 && MEM_USER == internalFlag) {
                                        if (MEM_API_TYPE_ALLOC == memApiType || MEM_API_TYPE_FREE == memApiType) {
-                                               addNewSeriesUserAllocData(memApiType, logData, binaryPath);
+                                               addNewSeriesUserAllocData(memApiType, logData, binaryInfo);
                                        }
                                }
                        }
@@ -552,26 +551,25 @@ public class TimelineChartManager extends PageDataManager implements IDAChartSer
                                                /*
                                                 * Set inform for Heap allocation
                                                 */
-                                               List<Object> binaryPathList = new ArrayList<Object>();
+                                               List<Object> binaryIDList = new ArrayList<Object>();
                                                List<Object> allocByteList = new ArrayList<Object>();
-                                               binaryPathList
-                                                               .add(TimelineChartLabels.HEAP_CHART_SERIES_NAME_APP_ALLOCATION);
+                                               binaryIDList.add(appAllocSeriesID);
                                                if (allocByteMap.get(process.getPid()) == null) {
                                                        allocByteList.add(new Long(0));
                                                } else {
                                                        allocByteList.add(allocByteMap.get(process.getPid()));
                                                }
-                                               Map<String, Long> libraryList = libraryAllocByteMap.get(process.getPid());
+                                               Map<Integer, Long> libraryList = libraryAllocByteMap.get(process.getPid());
                                                if (libraryList == null) {
-                                                       libraryList = new HashMap<String, Long>();
+                                                       libraryList = new HashMap<Integer, Long>();
                                                }
-                                               Iterator<String> iter = libraryList.keySet().iterator();
+                                               Iterator<Integer> iter = libraryList.keySet().iterator();
                                                while (iter.hasNext()) {
-                                                       String binaryPath = iter.next();
-                                                       binaryPathList.add(binaryPath);
-                                                       allocByteList.add(libraryList.get(binaryPath));
+                                                       Integer binaryID = iter.next();
+                                                       binaryIDList.add(binaryID);
+                                                       allocByteList.add(libraryList.get(binaryID));
                                                }
-                                               dbTargetProcessData.add(binaryPathList);
+                                               dbTargetProcessData.add(binaryIDList);
                                                dbTargetProcessData.add(allocByteList);
 
                                                /*
@@ -625,7 +623,7 @@ public class TimelineChartManager extends PageDataManager implements IDAChartSer
                }
        }
 
-       private void addNewSeriesUserAllocData(int fdApiType, MemoryData log, String libraryPath) {
+       private void addNewSeriesUserAllocData(int fdApiType, MemoryData log, BinaryInfo libraryInfo) {
                long size = 0;
                Long allocByte = allocByteMap.get(log.getPid());
 
@@ -637,14 +635,14 @@ public class TimelineChartManager extends PageDataManager implements IDAChartSer
                if (MEM_API_TYPE_ALLOC == fdApiType) {
                        try {
                                size = log.getSize();
-                               if (libraryPath == null) {
+                               if (libraryInfo == null) {
                                        allocByteMap.put(log.getPid(), allocByte + size);
                                } else {
-                                       Long libraryAllocByte = libraryAllocByteMap.get(log.getPid()).get(libraryPath);
+                                       Long libraryAllocByte = libraryAllocByteMap.get(log.getPid()).get(libraryInfo.getID());
                                        if (libraryAllocByte == null) {
                                                libraryAllocByte = new Long(0);
                                        }
-                                       libraryAllocByteMap.get(log.getPid()).put(libraryPath, libraryAllocByte + size);
+                                       libraryAllocByteMap.get(log.getPid()).put(libraryInfo.getID(), libraryAllocByte + size);
                                }
                                allocationSeriesDataSetMap.put(address, size);
                        } catch (NumberFormatException ne) {
@@ -656,11 +654,11 @@ public class TimelineChartManager extends PageDataManager implements IDAChartSer
                        }
                        size = allocationSeriesDataSetMap.get(address);
 
-                       if (libraryPath == null) {
+                       if (libraryInfo == null) {
                                allocByteMap.put(log.getPid(), allocByte - size);
                        } else {
-                               Long libraryAllocByte = libraryAllocByteMap.get(log.getPid()).get(libraryPath);
-                               libraryAllocByteMap.get(log.getPid()).put(libraryPath, libraryAllocByte - size);
+                               Long libraryAllocByte = libraryAllocByteMap.get(log.getPid()).get(libraryInfo.getID());
+                               libraryAllocByteMap.get(log.getPid()).put(libraryInfo.getID(), libraryAllocByte - size);
                        }
                }
        }