public synchronized void addPartition(
			HashMap<Integer, ArrayDeque<String[]>> par) {
		for (Entry<Integer, ArrayDeque<String[]>> cur : par.entrySet()) {
			int jobID = cur.getKey();
			ArrayDeque<String[]> p = cur.getValue();
			TreeMap<String, ArrayDeque<String>> row = jobToPartition.get(jobID);
			if (row == null) {
				row = new TreeMap<String, ArrayDeque<String>>();
			}
			// add the key value pair to the partition
			for (String[] item : p) {
				String key = item[0];
				String val = item[1];
				ArrayDeque<String> temp = row.get(key);
				if (temp == null) {
					temp = new ArrayDeque<String>();
				}
				temp.add(val);
				row.put(key, temp);
			}
			jobToPartition.put(jobID, row);
		}
	}