<commit_before>package output;

import java.io.File;

import loader.JmxBulkLoader;
import cass.Application;
import cass.SSTwriter;
import cass.Setup;



public class Output {
	public static Application app;
	
	public static void main(String[] args) throws Exception {
		String type;
		System.out.println(args.length);
		
		
		
//		initApp();
//		Thread tt = new Thread(){
//			public void run(){
//				Setup setup = new Setup(Application.DEMO);
//				setup.execute();
//			}
//		};
//		tt.start();
//		try {
//			tt.join();
//		} catch (InterruptedException e1) {
//			// TODO Auto-generated catch block
//			e1.printStackTrace();
//		}
//		long start = System.currentTimeMillis();
//		final SSTwriter writer = new SSTwriter(Application.NUM_ROWS); 
//		Thread t = new Thread(){
//			public void run(){
//				writer.execute();
//			}
//		};
//		t.start();
//		try {
//			t.join();
//		} catch (InterruptedException e) {
//			// TODO Auto-generated catch block
//			e.printStackTrace();
//		}
//		File file = new File(Application.PATH_TO_DATA);
//		final String path = file.getAbsolutePath();
//		System.out.println("path is: " + path);
//		JmxBulkLoader jmxLoader = new JmxBulkLoader("localhost", 7199);
//		jmxLoader.bulkLoad(path);
//		jmxLoader.close();
//		long end = System.currentTimeMillis();
//		System.out.println("Total time: " + (end - start)/1000 + " seconds.");
		
	}

	public static void initApp(){
		app = Application.getApp();
		app.setTableDesc();
		app.setCreateStmnt();
		app.buildQuestionString();
		app.createOutputDir();
	}
	
	
	
	public static void printStartMsg() {
		System.out.println("**********************************");
		System.out.println("*  begining data generation      *");
		System.out.println("**********************************");
	}

	/*
	 * long size = FileUtils.sizeOfDirectory(new File("C:/Windows/folder"));
	 * 
	 * System.out.println("Folder Size: " + size + " bytes");
	 */

	public static void printEndMsg(long totalTime) {
		System.out.println("**********************************");
		System.out.println("*     ending data generation     *");
		System.out.println("**********************************");
	}<commit_msg>nothng special<commit_after>package output;

import java.io.File;

import loader.JmxBulkLoader;
import cass.Application;
import cass.SSTwriter;
import cass.Setup;



public class Output {
	public static Application app;
	
	public static void main(String[] args) throws Exception {
		String type;
		if(args.length != 1){
			System.out.println("incorrect usage");
			System.out.println("correct usage:");
			System.out.println("java -jar DatabaseGenerator-1.0-SNAPSHOT.one-jar.jar");
		}
		
		
		
		initApp();
		Thread tt = new Thread(){
			public void run(){
				Setup setup = new Setup(Application.DEMO);
				setup.execute();
			}
		};
		tt.start();
		try {
			tt.join();
		} catch (InterruptedException e1) {
			// TODO Auto-generated catch block
			e1.printStackTrace();
		}
		long start = System.currentTimeMillis();
		final SSTwriter writer = new SSTwriter(Application.NUM_ROWS); 
		Thread t = new Thread(){
		public void run(){
				writer.execute();
			}
		};
		t.start();
		try {
			t.join();
		} catch (InterruptedException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		File file = new File(Application.PATH_TO_DATA);
		final String path = file.getAbsolutePath();
		System.out.println("path is: " + path);
		JmxBulkLoader jmxLoader = new JmxBulkLoader("localhost", 7199);
		jmxLoader.bulkLoad(path);
		jmxLoader.close();
		long end = System.currentTimeMillis();
		System.out.println("Total time: " + (end - start)/1000 + " seconds.");
		
	}

	public static void initApp(){
		app = Application.getApp();
		app.setTableDesc();
		app.setCreateStmnt();
		app.buildQuestionString();
		app.createOutputDir();
	}
	
	
	
	public static void printStartMsg() {
		System.out.println("**********************************");
		System.out.println("*  begining data generation      *");
		System.out.println("**********************************");
	}

	/*
	 * long size = FileUtils.sizeOfDirectory(new File("C:/Windows/folder"));
	 * 
	 * System.out.println("Folder Size: " + size + " bytes");
	 */

	public static void printEndMsg(long totalTime) {
		System.out.println("**********************************");
		System.out.println("*     ending data generation     *");
		System.out.println("**********************************");
	}
{'fraction_non_alphanumeric': 0.21346023113528212, 'fraction_numerical': 0.005211874008610922, 'mean_word_length': 3.545829042224511, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '6177652', 'n_tokens_mistral': 1564, 'n_tokens_neox': 1386, 'n_words': 299}