public void doRequest() throws IOException, InterruptedException, ClassNotFoundException {
		
		//for now, just assign work to the nodes with the files needed
		int rep = Integer.parseInt(fSystem.filesystem_config.get("replication_factor"));
		MapRequest mr = requests.get(0);
		
		int fileLines = fSystem.getFileLineNum(mr.filename);
		int startPart = ((mr.startRec)*rep+1)/fileLines;
		//endPart is the last part of the file that needs to be mapped/reduced
		int linesPerPart = fileLines/rep;
		int endPart = (mr.startRec+mr.recNum-1)/linesPerPart;
		
		
		if(!mr.isMap) {
			ReduceRequest rr = new ReduceRequest(cServer.getNumber(mr.requester), mr.id, endPart - startPart+1, startPart, cServer.cHandler.reconstituteReduce(mr.funcData));
			activeReduces.put(mr.filename, rr);
		} else {
			mr.totalParts = endPart - startPart + 1;
		}
		
		//int endPart = (int)Math.ceil((float)(mr.startRec+mr.recNum-1)*rep/fileLines);
		int partLen = fileLines/rep;
		
		
		//tell each compute node to map
		for(int i=startPart; i<rep; i++) { //endPart; i++) {
			int c = fSystem.getFileLocation(mr.filename,i);
			System.out.println("Assigning part " + i + " to " + c);
			int partStart = i*partLen;
			int relStart = Math.max(mr.startRec - partStart, 0);
			
			int relLen = (mr.startRec+mr.recNum - partStart-1);
			if(relLen < 0) continue;
			if(i != rep-1) {
				//not in last part
				if(relLen+relStart > partLen-1) {
					relLen = partLen-1-relStart;
				}
			}
			if(!mr.isMap) {
				relStart = 0; //accounted for by the map not including those lines
			}
			byte[] messageStr = null;
			if(mr.isMap){ 
				messageStr = ("MAP ASSIGN," + fSystem.path + mr.filename + "_" + i + "," + relStart + "," + relLen + "," + mr.funcData.length + "\n").getBytes();
			} else {
				messageStr = ("REDUCE ASSIGN," + fSystem.path + mr.filename + "_" + i + "," + relStart + "," + relLen + "," + mr.funcData.length + "\n").getBytes();
			}
			byte[] message = new byte[messageStr.length + mr.funcData.length];
			System.arraycopy(messageStr, 0, message, 0, messageStr.length);
			System.arraycopy(mr.funcData, 0, message, messageStr.length, mr.funcData.length);
			cServer.sendMessage(c, message);
		}
		System.out.println("schedule complete");
		requests.remove(0);
	}