connect.setRequestProperty("ContentType", "text/xml");
	public static void main(String[] args) {		String fileName =args[0];		File file =new File(fileName);		if(!file.canRead()) {			System.err.println("Cannot read file " + file);			return;		}		String docName =file.getName();				try {			URL url = new URL("http://localhost:8088/db/test/" + docName);			HttpURLConnection connect =(HttpURLConnection)url.openConnection();			connect.setRequestMethod("PUT");			connect.setDoOutput(true);						OutputStream os = connect.getOutputStream();			InputStream is =new FileInputStream(file);			byte[] buf =new byte[1024];			int c;			while((c = is.read(buf)) > -1)				os.write(buf, 0, c);						System.out.println("Connecting to " + url.toString());			connect.connect();						System.out.println("Result:");			BufferedReader bis = new BufferedReader(new InputStreamReader(connect.getInputStream()));			String line;			while((line = bis.readLine()) !=null)				System.out.println(line);		} catch (Exception e) {			System.err.println("An exception occurred: " + e.getMessage());			e.printStackTrace();		}	}