Package org.jpos.util

Examples of org.jpos.util.Profiler.checkPoint()


        String s = "The quick brown fox jumped over the lazy dog";
        Profiler prof = new Profiler ();
        for (int i=0; i<COUNT; i++) {
            sp.out ("testMultiKeyLoad_Key" + Integer.toString (i), s);
            if (i % 100 == 0)
                prof.checkPoint ("out " + i);
        }
        // prof.dump (System.err, "MultiKeyLoad out >");
        prof = new Profiler ();
        for (int i=0; i<COUNT; i++) {
            assertTrue (s.equals (sp.in ("testMultiKeyLoad_Key" + Integer.toString (i))));
View Full Code Here


        // prof.dump (System.err, "MultiKeyLoad out >");
        prof = new Profiler ();
        for (int i=0; i<COUNT; i++) {
            assertTrue (s.equals (sp.in ("testMultiKeyLoad_Key" + Integer.toString (i))));
            if (i % 100 == 0)
                prof.checkPoint ("in " + i);
        }
        // prof.dump (System.err, "MultiKeyLoad in  >");
    }
    public void testSingleKeyLoad() throws Exception {
        String s = "The quick brown fox jumped over the lazy dog";
View Full Code Here

        String k = "testSingleKeyLoad_Key";
        Profiler prof = new Profiler ();
        for (int i=0; i<COUNT; i++) {
            sp.out (k, s);
            if (i % 100 == 0)
                prof.checkPoint ("out " + i);
        }
        // prof.dump (System.err, "SingleKeyLoad out >");
        prof = new Profiler ();
        for (int i=0; i<COUNT; i++) {
            assertTrue (s.equals (sp.in (k)));
View Full Code Here

        // prof.dump (System.err, "SingleKeyLoad out >");
        prof = new Profiler ();
        for (int i=0; i<COUNT; i++) {
            assertTrue (s.equals (sp.in (k)));
            if (i % 100 == 0)
                prof.checkPoint ("in " + i);
        }
        // prof.dump (System.err, "SingleKeyLoad in  >");
        assertTrue (sp.rdp (k) == null);
    }
    public void testTemplate () throws Exception {
View Full Code Here

        TPS tps = new TPS(true);
        for (int i=0; i<COUNT; i++) {
            pack (baseMsg, p);
            tps.tick();
        }
        prof.checkPoint ("PACK " + tps.toString());

        byte[] buf = baseMsg.pack();
        tps = new TPS(true);
        for (int i=0; i<COUNT; i++) {
            unpack (buf, p);
View Full Code Here

        tps = new TPS(true);
        for (int i=0; i<COUNT; i++) {
            unpack (buf, p);
            tps.tick();
        }
        prof.checkPoint ("UNPACK " + tps.toString());

        tps = new TPS(true);
        for (int i=0; i<COUNT; i++) {
            pack (baseMsg, p);
            unpack (buf, p);
View Full Code Here

        for (int i=0; i<COUNT; i++) {
            pack (baseMsg, p);
            unpack (buf, p);
            tps.tick();
        }
        prof.checkPoint ("PACK/UNPACK " + tps.toString());
        tps = new TPS(true);
        for (int i=0; i<COUNT; i++) {
            updatePackAndUnpack(baseMsg, p);
            tps.tick();
        }
View Full Code Here

        tps = new TPS(true);
        for (int i=0; i<COUNT; i++) {
            updatePackAndUnpack(baseMsg, p);
            tps.tick();
        }
        prof.checkPoint ("UPDATE/PACK/UNPACK " + tps.toString());

        prof.dump(System.out, "");
        System.out.println ("");
    }
    private void pack (ISOMsg m, ISOPackager p) throws Exception {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.