<commit_before>/*
 * Copyright (c) 2008-2011 by <NAME>, <NAME>,
 *               <NAME>, Zuse Institute Berlin
 *
 * Licensed under the BSD License, see LICENSE file for details.
 *
 */

package org.xtreemfs.test;

import java.io.FileInputStream;
import java.io.IOException;
import java.net.InetSocketAddress;
import java.util.Arrays;
import java.util.Properties;
import java.util.Random;

import org.xtreemfs.babudb.config.BabuDBConfig;
import org.xtreemfs.babudb.log.DiskLogger.SyncMode;
import org.xtreemfs.common.uuids.ServiceUUID;
import org.xtreemfs.common.uuids.UUIDResolver;
import org.xtreemfs.dir.DIRConfig;
import org.xtreemfs.foundation.SSLOptions;
import org.xtreemfs.foundation.TimeSync;
import org.xtreemfs.foundation.buffer.ReusableBuffer;
import org.xtreemfs.foundation.logging.Logging;
import org.xtreemfs.foundation.logging.Logging.Category;
import org.xtreemfs.foundation.pbrpc.Schemes;
import org.xtreemfs.foundation.pbrpc.client.RPCNIOSocketClient;
import org.xtreemfs.mrc.MRCConfig;
import org.xtreemfs.osd.OSDConfig;
import org.xtreemfs.pbrpc.generatedinterfaces.DIRServiceClient;
import org.xtreemfs.pbrpc.generatedinterfaces.GlobalTypes.StripingPolicy;
import org.xtreemfs.pbrpc.generatedinterfaces.GlobalTypes.StripingPolicyType;

/**
 * 
 * @author bjko
 */
public class SetupUtils {
    
    public static final String     TEST_DIR         = "/tmp/xtreemfs-test2";
    
    public static final String     CERT_DIR         = "test/certs/";
    
    public static boolean          SSL_ON           = false;
    
    public static boolean          CHECKSUMS_ON     = false;
    
    public static final int        DEBUG_LEVEL      = Logging.LEVEL_DEBUG;
    
    public static final Category[] DEBUG_CATEGORIES = new Category[] { Category.all };
    
    public static final int PORT_RANGE_OFFSET = 10000;
    
    private static Properties createOSDProperties(int port, String dir) {
        Properties props = new Properties();
        props.setProperty("dir_service.host", "localhost");<commit_msg>server: Reduced default logging for unit tests from DEBUG to WARN.<commit_after>/*
 * Copyright (c) 2008-2011 by <NAME>, <NAME>,
 *               <NAME>, Zuse Institute Berlin
 *
 * Licensed under the BSD License, see LICENSE file for details.
 *
 */

package org.xtreemfs.test;

import java.io.FileInputStream;
import java.io.IOException;
import java.net.InetSocketAddress;
import java.util.Arrays;
import java.util.Properties;
import java.util.Random;

import org.xtreemfs.babudb.config.BabuDBConfig;
import org.xtreemfs.babudb.log.DiskLogger.SyncMode;
import org.xtreemfs.common.uuids.ServiceUUID;
import org.xtreemfs.common.uuids.UUIDResolver;
import org.xtreemfs.dir.DIRConfig;
import org.xtreemfs.foundation.SSLOptions;
import org.xtreemfs.foundation.TimeSync;
import org.xtreemfs.foundation.buffer.ReusableBuffer;
import org.xtreemfs.foundation.logging.Logging;
import org.xtreemfs.foundation.logging.Logging.Category;
import org.xtreemfs.foundation.pbrpc.Schemes;
import org.xtreemfs.foundation.pbrpc.client.RPCNIOSocketClient;
import org.xtreemfs.mrc.MRCConfig;
import org.xtreemfs.osd.OSDConfig;
import org.xtreemfs.pbrpc.generatedinterfaces.DIRServiceClient;
import org.xtreemfs.pbrpc.generatedinterfaces.GlobalTypes.StripingPolicy;
import org.xtreemfs.pbrpc.generatedinterfaces.GlobalTypes.StripingPolicyType;

/**
 * 
 * @author bjko
 */
public class SetupUtils {
    
    public static final String     TEST_DIR         = "/tmp/xtreemfs-test2";
    
    public static final String     CERT_DIR         = "test/certs/";
    
    public static boolean          SSL_ON           = false;
    
    public static boolean          CHECKSUMS_ON     = false;
    
    public static final int        DEBUG_LEVEL      = Logging.LEVEL_WARN;
    
    public static final Category[] DEBUG_CATEGORIES = new Category[] { Category.all };
    
    public static final int PORT_RANGE_OFFSET = 10000;
    
    private static Properties createOSDProperties(int port, String dir) {
        Properties props = new Properties();
        props.setProperty("dir_service.host", "localhost");
{'fraction_non_alphanumeric': 0.09303458353628836, 'fraction_numerical': 0.006819288845591817, 'mean_word_length': 3.69908466819222, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6535288', 'n_tokens_mistral': 1340, 'n_tokens_neox': 1312, 'n_words': 267}