HDFS-2606. webhdfs client filesystem impl must set the content-type header for create/append. (tucu)

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1208157 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Alejandro Abdelnur 2011-11-30 00:25:54 +00:00
parent 670fa8770b
commit afbc3aa30c
2 changed files with 4 additions and 0 deletions

View File

@ -116,6 +116,9 @@ Trunk (unreleased changes)
HDFS-2532. TestDfsOverAvroRpc timing out in trunk (Uma Maheswara Rao G
via todd)
HDFS-2606. webhdfs client filesystem impl must set the content-type
header for create/append. (tucu)
Release 0.23.1 - UNRELEASED
INCOMPATIBLE CHANGES

View File

@ -357,6 +357,7 @@ private HttpURLConnection httpConnect(final HttpOpParam.Op op, final Path fspath
conn.setRequestMethod(op.getType().toString());
if (op.getDoOutput()) {
conn = twoStepWrite(conn, op);
conn.setRequestProperty("Content-Type", "application/octet-stream");
}
conn.setDoOutput(op.getDoOutput());
conn.connect();