public void run() {
		// If any of these stay the same then something is wrong
		InetAddress IPAddress;
		try {
			IPAddress = InetAddress.getByName(request.getIP());
		} catch (UnknownHostException e1) {
			e1.printStackTrace();
			bot.sendMessageToChannel("Error: Query IP address could not be resolved or is using IPv6.");
			return;
		}
		int port = request.getPort();
		byte[] dataToSend = null;
		byte[] dataToReceive = new byte[2048]; // Doubled standard size in case there's some dumb wad list with a lot of characters
		
		// Try with resources, we want to always have the socket close
		try (DatagramSocket connectionSocket = new DatagramSocket()) {		
			// Prepare our send packet		
			dataToSend = new byte[] { (byte)199, 0, 0, 0, -64, 18, 0, 8 }; // Send challenge and then SQF_FlagsStuff
			byte[] huffmanToSend = Huffman.encode(dataToSend);
			
			// Now send the data
			DatagramPacket sendPacket = new DatagramPacket(huffmanToSend, huffmanToSend.length, IPAddress, port);
			connectionSocket.send(sendPacket);
			
			// Block until we receive something or time out
			DatagramPacket receivePacket = new DatagramPacket(dataToReceive, dataToReceive.length);
			connectionSocket.setSoTimeout(SOCKET_TIMEOUT_MS);
			connectionSocket.receive(receivePacket);
			
			// Prepare the data for processing
			byte[] receivedData = receivePacket.getData();
			byte[] receivedTruncatedData = new byte[receivePacket.getLength()];
			System.arraycopy(receivedData, 0, receivedTruncatedData, 0, receivePacket.getLength());
			byte[] decodedData = Huffman.decode(receivedTruncatedData);
				
			// Process it
			processIncomingPacket(decodedData);	
		} catch (UnknownHostException e) {
			bot.sendMessageToChannel("IP of the host to query could not be determined. Please see if your IP is a valid address that can be reached.");
			e.printStackTrace();
		} catch (SocketException e) {
			bot.sendMessageToChannel("Error with the socket when handling query. Please try again or contact an administrator.");
			e.printStackTrace();
		} catch (SocketTimeoutException e) {
			bot.sendMessageToChannel("Socket timeout, IP is incorrect or server is down/unreachable (consider trying again if it is your first try).");
			e.printStackTrace();
		} catch (IOException e) {
			bot.sendMessageToChannel("IOException from query. Please try again or contact an administrator.");
			e.printStackTrace();
		} catch (Exception e) {
			bot.sendMessageToChannel("Unknown exception occured, contact an administrator now.");
			e.printStackTrace();
		}
		
		// Always alert the handler thread we are done
		handlerThread.signalProcessQueryComplete();
	}