Package org.zper.base.ZLogManager

Examples of org.zper.base.ZLogManager.ZLogConfig


        sendBufferSize = Integer.parseInt(conf.getProperty("send_buffer", "1048576"));
        numWorkers = Integer.parseInt(conf.getProperty("reader.workers", "5"));
        bind = conf.getProperty("reader.bind", "tcp://*:5556");

        ZLogConfig zc = ZLogManager.instance().config();
        zc.set("base_dir", conf.getProperty("base_dir"));

        LOG.info("Data is stored at " + zc.get("base_dir"));

        workers = new ArrayList<byte[]>();

    }
View Full Code Here


        recvHWM = Integer.parseInt(conf.getProperty("receive_hwm", "1024"));

        recvBufferSize = Integer.parseInt(conf.getProperty("receive_buffer", "1048576"));
        maxMessageSize = Long.parseLong(conf.getProperty("max_message", "8388608")); // 8M

        ZLogConfig zc = ZLogManager.instance().config();
        zc.set("base_dir", conf.getProperty("base_dir"));
        zc.set("segment_size", Long.parseLong(conf.getProperty("segment_size", "536870912")));
        zc.set("flush_messages", Long.parseLong(conf.getProperty("flush_messages", "10000")));
        zc.set("flush_interval", Long.parseLong(conf.getProperty("flush_interval", "10000")));
        zc.set("retain_hours", Integer.parseInt(conf.getProperty("retain_hours", "168")));
        zc.set("recover", true);
        zc.set("allow_empty_message", Boolean.parseBoolean(conf.getProperty("allow_empty_message", "true")));

        LOG.info("Data is stored at " + zc.get("base_dir"));
        LOG.info("Using decoder " + decoder);

        workers = new ArrayList<byte[]>();
    }
View Full Code Here

            countMsg(argv);
    }

    private static void countMsg(String[] argv) throws Exception
    {
        ZLogConfig zc = ZLogManager.instance().config();
        zc.set("base_dir", argv[1]);

        ZLog log = ZLogManager.instance().get(argv[2]);
        SegmentInfo[] segments = log.segments();
        long total = 0;
View Full Code Here

TOP

Related Classes of org.zper.base.ZLogManager.ZLogConfig

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.