public static String readFirstLine(String urlString, int msTimeout)
	{
		try {
			final URL url = new URL(urlString);
			if (msTimeout > 0)
			{
				ExecutorService executor = new ForkJoinPool(1);
				Future<String> result = executor.submit(new Callable<String>() {
					@Override
					public String call() throws Exception
					{
						BufferedReader reader = new BufferedReader(new InputStreamReader(url.openStream()));
						String result = reader.readLine();
						reader.close();
						return result;
					}
				});
				return result.get(msTimeout, TimeUnit.MILLISECONDS);
			} else {
				BufferedReader reader = new BufferedReader(new InputStreamReader(url.openStream()));
				String result = reader.readLine();
				reader.close();
				return result;
			}
		} catch (Exception e) {
			return null;
		}
	}