Package com.tagtraum.perf.gcviewer.model

Examples of com.tagtraum.perf.gcviewer.model.GCModel$FileInformation


        IMP_LOGGER.addHandler(handler);
        DATA_READER_FACTORY_LOGGER.addHandler(handler);

        final InputStream in = getInputStream("SampleSun1_7_0_40PrintGCCause.txt");
        final DataReader reader = new DataReaderSun1_6_0G1(in, GcLogType.SUN1_7G1);
        GCModel model = reader.read();

        assertEquals("gc pause", 0.077938, model.getPause().getMax(), 0.000000001);
        GCEvent heap = (GCEvent) model.getEvents().next();
        assertEquals("heap", 32*1024, heap.getPreUsed());
        // test parsing of decimal values
        assertEquals("heap", 7136, (double)heap.getPostUsed(), 1e2);
        assertEquals("heap", 88.0*1024*1024, (double)heap.getTotal(), 1e2);

View Full Code Here


        IMP_LOGGER.addHandler(handler);
        DATA_READER_FACTORY_LOGGER.addHandler(handler);

        final InputStream in = getInputStream("SampleSun1_7_0_40PrintGCCause2.txt");
        final DataReader reader = new DataReaderSun1_6_0G1(in, GcLogType.SUN1_7G1);
        GCModel model = reader.read();

        assertEquals("count", 1, model.size());
        GCEvent event = (GCEvent) model.get(0);
        assertEquals("type name", "GC pause (G1 Evacuation Pause) (young) (to-space exhausted)", event.getTypeAsString());
        assertEquals("gc pause", 0.0398848, model.getPause().getMax(), 0.000000001);
    }
View Full Code Here

        // parse one detailed event with a mixed line (concurrent event starts in the middle of an stw collection)
        // 2012-02-24T03:49:09.100-0800: 312.402: [GC pause (young)2012-02-24T03:49:09.378-0800: 312.680: [GC concurrent-mark-start]
        //  (initial-mark), 0.28645100 secs]
        final InputStream in = getInputStream("SampleSun1_7_0G1_DateStamp_Detailed-mixedLine1.txt");
        final DataReader reader = new DataReaderSun1_6_0G1(in, GcLogType.SUN1_7G1);
        GCModel model = reader.read();
       
        assertEquals("nummber of events", 2, model.size());
        assertEquals("number of pauses", 1, model.getPause().getN());
        assertEquals("gc pause sum", 0.28645100, model.getPause().getSum(), 0.000000001);
        assertEquals("gc memory", 17786*1024 - 17147*1024, model.getFreedMemoryByGC().getMax());
    }
View Full Code Here

        IMP_LOGGER.addHandler(handler);
        DATA_READER_FACTORY_LOGGER.addHandler(handler);
       
        final InputStream in = getInputStream("SampleSun1_7_0G1_DateStamp_Detailed-mixedLine2.txt");
        final DataReader reader = new DataReaderSun1_6_0G1(in, GcLogType.SUN1_7G1);
        GCModel model = reader.read();
       
        assertEquals("number of events", 3, model.size());
        assertEquals("number of warnings", 0, handler.getCount());
        assertEquals("concurrent event type", Type.G1_CONCURRENT_MARK_START.toString(), model.getConcurrentGCEvents().next().getTypeAsString());
        assertEquals("number of pauses", 2, model.getPause().getN());
        assertEquals("gc pause max", 0.28031200, model.getPause().getMax(), 0.000000001);
        assertEquals("gc memory", 20701*1024 - 20017*1024, model.getFreedMemoryByGC().getMax());
    }
View Full Code Here

        // parse one detailed event with a mixed line
        // -> concurrent event occurs somewhere in the detail lines below the stw event

        final InputStream in = getInputStream("SampleSun1_7_0G1_DateStamp_Detailed-mixedLine3.txt");
        final DataReader reader = new DataReaderSun1_6_0G1(in, GcLogType.SUN1_7G1);
        GCModel model = reader.read();
       
        assertEquals("nummber of events", 2, model.size());
        assertEquals("concurrent event type", Type.G1_CONCURRENT_MARK_START.toString(), model.getConcurrentGCEvents().next().getTypeAsString());
        assertEquals("number of pauses", 1, model.getPause().getN());
        assertEquals("gc pause sum", 0.08894900, model.getPause().getSum(), 0.000000001);
        assertEquals("gc memory", 29672*1024 - 28733*1024, model.getFreedMemoryByGC().getMax());
    }
View Full Code Here

    @Test
    public void testParseGenCon() throws Exception {
        // TODO refactor JRockit DataReader
        InputStream in = getInputStream("SampleJRockit1_4_2gencon.txt");
        DataReader reader = new DataReaderJRockit1_5_0(in);
        GCModel model = reader.read();
       
        assertEquals("count", 123, model.size());
       
        GCEvent event = (GCEvent) model.get(0);
        assertEquals("timestamp", 77.737, event.getTimestamp(), 0.000001);
        assertEquals("name", Type.JROCKIT_NURSERY_GC.getName(), event.getExtendedType().getName());
        assertEquals("before", 630435, event.getPreUsed());
        assertEquals("after", 183741, event.getPostUsed());
        assertEquals("total", 1048576, event.getTotal());
View Full Code Here

    @Test
    public void testParseGenConBig() throws Exception {
        // TODO refactor JRockit DataReader
        InputStream in = getInputStream("SampleJRockit1_4_2gencon-big.txt");
        DataReader reader = new DataReaderJRockit1_5_0(in);
        GCModel model = reader.read();
       
        assertEquals("count", 32420, model.size());
       
        GCEvent event = (GCEvent) model.get(0);
        assertEquals("timestamp", 9.385, event.getTimestamp(), 0.000001);
        assertEquals("name", Type.JROCKIT_NURSERY_GC.getName(), event.getExtendedType().getName());
        assertEquals("before", 123930, event.getPreUsed());
        assertEquals("after", 27087, event.getPostUsed());
        assertEquals("total", 1048576, event.getTotal());
View Full Code Here

    @Test
    public void testParseParallel() throws Exception {
        // TODO refactor JRockit DataReader
        InputStream in = getInputStream("SampleJRockit1_4_2parallel.txt");
        DataReader reader = new DataReaderJRockit1_5_0(in);
        GCModel model = reader.read();
       
        assertEquals("count", 92, model.size());
       
        GCEvent event = (GCEvent) model.get(0);
        assertEquals("timestamp", 226.002, event.getTimestamp(), 0.000001);
        assertEquals("name", Type.JROCKIT_GC.getName(), event.getExtendedType().getName());
        assertEquals("before", 1048576, event.getPreUsed());
        assertEquals("after", 133204, event.getPostUsed());
        assertEquals("total", 1048576, event.getTotal());
View Full Code Here

    @Test
    public void testParsePrioPauseTime() throws Exception {
        // TODO refactor JRockit DataReader
        InputStream in = getInputStream("SampleJRockit1_4_2priopausetime.txt");
        DataReader reader = new DataReaderJRockit1_5_0(in);
        GCModel model = reader.read();
       
        assertEquals("count", 1867, model.size());
       
        GCEvent event = (GCEvent) model.get(0);
        assertEquals("timestamp", 12.622, event.getTimestamp(), 0.000001);
        assertEquals("name", Type.JROCKIT_GC.getName(), event.getExtendedType().getName());
        assertEquals("before", 320728, event.getPreUsed());
        assertEquals("after", 130908, event.getPostUsed());
        assertEquals("total", 358400, event.getTotal());
View Full Code Here

    @Test
    public void testParseTsGCReportGencon() throws Exception {
        InputStream in = getInputStream("SampleJRockit1_4_2ts-gcreport-gencon.txt");
        DataReader reader = new DataReaderJRockit1_4_2(in);
        GCModel model = reader.read();
       
        assertEquals("count", 63, model.size());
       
        GCEvent event = (GCEvent) model.get(0);
        assertEquals("timestamp", 13.594, event.getTimestamp(), 0.000001);
        assertEquals("name", Type.JROCKIT_NURSERY_GC.getName(), event.getExtendedType().getName());
        assertEquals("before", 13824, event.getPreUsed());
        assertEquals("after", 4553, event.getPostUsed());
        assertEquals("total", 32768, event.getTotal());
View Full Code Here

TOP

Related Classes of com.tagtraum.perf.gcviewer.model.GCModel$FileInformation

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.