http://git-wip-us.apache.org/repos/asf/hadoop/blob/ee7beda6/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/content/xdocs/webhdfs.xml ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/content/xdocs/webhdfs.xml b/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/content/xdocs/webhdfs.xml deleted file mode 100644 index c8e0c62..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/content/xdocs/webhdfs.xml +++ /dev/null @@ -1,1577 +0,0 @@ -<?xml version="1.0"?> -<!-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> - -<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd"> - -<document> - <header> - <title>WebHDFS REST API</title> - </header> - - <body> - <section> - <title>Document Conventions</title> -<table> -<tr><td><code>Monospaced</code></td><td>Used for commands, HTTP request and responses and code blocks.</td></tr> -<tr><td><code><Monospaced></code></td><td>User entered values.</td></tr> -<tr><td><code>[Monospaced]</code></td><td>Optional values. When the value is not specified, the default value is used.</td></tr> -<tr><td><em>Italics</em></td><td>Important phrases and words.</td></tr> -</table> - </section> -<!-- ***************************************************************************** --> - <section> - <title>Introduction</title> -<p> - The HTTP REST API supports the complete FileSystem interface for HDFS. - The operations and the corresponding FileSystem methods are shown in the next section. - The Section <a href="#ParameterDictionary">HTTP Query Parameter Dictionary</a> specifies the parameter details - such as the defaults and the valid values. -</p> - <section id="Operations"> - <title>Operations</title> -<ul> - <li>HTTP GET - <ul> - <li><a href="#OPEN"><code>OPEN</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/open">FileSystem.open</a>) - </li> - <li><a href="#GETFILESTATUS"><code>GETFILESTATUS</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/getFileStatus">FileSystem.getFileStatus</a>) - </li> - <li><a href="#LISTSTATUS"><code>LISTSTATUS</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/listStatus">FileSystem.listStatus</a>) - </li> - <li><a href="#GETCONTENTSUMMARY"><code>GETCONTENTSUMMARY</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/getContentSummary">FileSystem.getContentSummary</a>) - </li> - <li><a href="#GETFILECHECKSUM"><code>GETFILECHECKSUM</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/getFileChecksum">FileSystem.getFileChecksum</a>) - </li> - <li><a href="#GETHOMEDIRECTORY"><code>GETHOMEDIRECTORY</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/getHomeDirectory">FileSystem.getHomeDirectory</a>) - </li> - <li><a href="#GETDELEGATIONTOKEN"><code>GETDELEGATIONTOKEN</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/getDelegationToken">FileSystem.getDelegationToken</a>) - </li> - </ul></li> - <li>HTTP PUT - <ul> - <li><a href="#CREATE"><code>CREATE</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/create">FileSystem.create</a>) - </li> - <li><a href="#MKDIRS"><code>MKDIRS</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/mkdirs">FileSystem.mkdirs</a>) - </li> - <li><a href="#RENAME"><code>RENAME</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/rename">FileSystem.rename</a>) - </li> - <li><a href="#SETREPLICATION"><code>SETREPLICATION</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/setReplication">FileSystem.setReplication</a>) - </li> - <li><a href="#SETOWNER"><code>SETOWNER</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/setOwner">FileSystem.setOwner</a>) - </li> - <li><a href="#SETPERMISSION"><code>SETPERMISSION</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/setPermission">FileSystem.setPermission</a>) - </li> - <li><a href="#SETTIMES"><code>SETTIMES</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/setTimes">FileSystem.setTimes</a>) - </li> - <li><a href="#RENEWDELEGATIONTOKEN"><code>RENEWDELEGATIONTOKEN</code></a> - (see DistributedFileSystem.renewDelegationToken) - </li> - <li><a href="#CANCELDELEGATIONTOKEN"><code>CANCELDELEGATIONTOKEN</code></a> - (see DistributedFileSystem.cancelDelegationToken) - </li> - </ul></li> - <li>HTTP POST - <ul> - <li><a href="#APPEND"><code>APPEND</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/append">FileSystem.append</a>) - </li> - </ul></li> - <li>HTTP DELETE - <ul> - <li><a href="#DELETE"><code>DELETE</code></a> - (see <a href="ext:api/org/apache/hadoop/fs/filesystem/delete">FileSystem.delete</a>) - </li> - </ul></li> -</ul> - - </section> -<!-- ***************************************************************************** --> - <section id="FsURIvsHTTP_URL"> - <title>FileSystem URIs vs HTTP URLs</title> -<p> - The FileSystem scheme of WebHDFS is "<code>webhdfs://</code>". - A WebHDFS FileSystem URI has the following format. -</p> -<source> - webhdfs://<HOST>:<HTTP_PORT>/<PATH> -</source> -<p> - The above WebHDFS URI corresponds to the below HDFS URI. -</p> -<source> - hdfs://<HOST>:<RPC_PORT>/<PATH> -</source> -<p> - In the REST API, the prefix "<code>/webhdfs/v1</code>" is inserted in the path and a query is appended at the end. - Therefore, the corresponding HTTP URL has the following format. -</p> -<source> - http://<HOST>:<HTTP_PORT>/webhdfs/v1/<PATH>?op=... -</source> - </section> -<!-- ***************************************************************************** --> - <section> - <title>HDFS Configuration Options</title> -<p> - Below are the HDFS configuration options for WebHDFS. -</p> -<table> -<tr><th>Property Name</th><th>Description</th></tr> -<tr><td><code>dfs.webhdfs.enabled</code></td> -<td>Enable/disable WebHDFS in Namenodes and Datanodes -</td></tr> -<tr><td><code>dfs.web.authentication.kerberos.principal</code></td> -<td>The HTTP Kerberos principal used by Hadoop-Auth in the HTTP endpoint. - The HTTP Kerberos principal MUST start with 'HTTP/' per Kerberos - HTTP SPNEGO specification. -</td></tr> -<tr><td><code>dfs.web.authentication.kerberos.keytab</code></td> -<td>The Kerberos keytab file with the credentials for the - HTTP Kerberos principal used by Hadoop-Auth in the HTTP endpoint. -</td></tr> -</table> - </section> - </section> -<!-- ***************************************************************************** --> - <section id="Authentication"> - <title>Authentication</title> -<p> - When security is <em>off</em>, the authenticated user is the username specified in the <code>user.name</code> query parameter. - If the <code>user.name</code> parameter is not set, - the server may either set the authenticated user to a default web user, if there is any, or return an error response. -</p> -<p> - When security is <em>on</em>, authentication is performed by either Hadoop delegation token or Kerberos SPNEGO. - If a token is set in the <code>delegation</code> query parameter, the authenticated user is the user encoded in the token. - If the <code>delegation</code> parameter is not set, the user is authenticated by Kerberos SPNEGO. -</p> -<p> -Below are examples using the <code>curl</code> command tool. -</p> -<ol> - <li> - Authentication when security is off: - <source> -curl -i "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?[user.name=<USER>&]op=..." - </source> - </li><li> - Authentication using Kerberos SPNEGO when security is on: - <source> -curl -i --negotiate -u : "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=..." - </source> - </li><li> - Authentication using Hadoop delegation token when security is on: - <source> -curl -i "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?delegation=<TOKEN>&op=..." - </source> - </li> -</ol> - </section> -<!-- ***************************************************************************** --> - <section id="ProxyUsers"> - <title>Proxy Users</title> -<p> - When the proxy user feature is enabled, a proxy user <em>P</em> may submit a request on behalf of another user <em>U</em>. - The username of <em>U</em> must be specified in the <code>doas</code> query parameter unless a delegation token is presented in authentication. - In such case, the information of both users <em>P</em> and <em>U</em> must be encoded in the delegation token. -</p> -<ol> - <li> - A proxy request when security is off: - <source> -curl -i "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?[user.name=<USER>&]doas=<USER>&op=..." - </source> - </li><li> - A proxy request using Kerberos SPNEGO when security is on: - <source> -curl -i --negotiate -u : "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?doas=<USER>&op=..." - </source> - </li><li> - A proxy request using Hadoop delegation token when security is on: - <source> -curl -i "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?delegation=<TOKEN>&op=..." - </source> - </li> -</ol> - </section> -<!-- ***************************************************************************** --> -<!-- ***************************************************************************** --> - <section> - <title>File and Directory Operations</title> - <section id="CREATE"> - <title>Create and Write to a File</title> -<ul> - <li>Step 1: Submit a HTTP PUT request without automatically following redirects and without sending the file data. - <source> -curl -i -X PUT "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=CREATE - [&overwrite=<true|false>][&blocksize=<LONG>][&replication=<SHORT>] - [&permission=<OCTAL>][&buffersize=<INT>]" - </source> -The request is redirected to a datanode where the file data is to be written: - <source> -HTTP/1.1 307 TEMPORARY_REDIRECT -Location: http://<DATANODE>:<PORT>/webhdfs/v1/<PATH>?op=CREATE... -Content-Length: 0 - </source> - </li> - <li>Step 2: Submit another HTTP PUT request using the URL in the <code>Location</code> header with the file data to be written. - <source> -curl -i -X PUT -T <LOCAL_FILE> "http://<DATANODE>:<PORT>/webhdfs/v1/<PATH>?op=CREATE..." - </source> -The client receives a <code>201 Created</code> response with zero content length -and the WebHDFS URI of the file in the <code>Location</code> header: - <source> -HTTP/1.1 201 Created -Location: webhdfs://<HOST>:<PORT>/<PATH> -Content-Length: 0 - </source> - </li> -</ul> -<p> - <strong>Note</strong> that the reason of having two-step create/append is - for preventing clients to send out data before the redirect. - This issue is addressed by the "<code>Expect: 100-continue</code>" header in HTTP/1.1; - see <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec8.html#sec8.2.3">RFC 2616, Section 8.2.3</a>. - Unfortunately, there are software library bugs (e.g. Jetty 6 HTTP server and Java 6 HTTP client), - which do not correctly implement "<code>Expect: 100-continue</code>". - The two-step create/append is a temporary workaround for the software library bugs. -</p> -<p> - See also: - <a href="#overwrite"><code>overwrite</code></a>, - <a href="#blocksize"><code>blocksize</code></a>, - <a href="#replication"><code>replication</code></a>, - <a href="#permission"><code>permission</code></a>, - <a href="#buffersize"><code>buffersize</code></a>, - <a href="ext:api/org/apache/hadoop/fs/filesystem/create">FileSystem.create</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="APPEND"> - <title>Append to a File</title> -<ul> - <li>Step 1: Submit a HTTP POST request without automatically following redirects and without sending the file data. - <source> -curl -i -X POST "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=APPEND[&buffersize=<INT>]" - </source> -The request is redirected to a datanode where the file data is to be appended: - <source> -HTTP/1.1 307 TEMPORARY_REDIRECT -Location: http://<DATANODE>:<PORT>/webhdfs/v1/<PATH>?op=APPEND... -Content-Length: 0 - </source> - </li> - <li>Step 2: Submit another HTTP POST request using the URL in the <code>Location</code> header with the file data to be appended. - <source> -curl -i -X POST -T <LOCAL_FILE> "http://<DATANODE>:<PORT>/webhdfs/v1/<PATH>?op=APPEND..." - </source> -The client receives a response with zero content length: - <source> -HTTP/1.1 200 OK -Content-Length: 0 - </source> - </li> -</ul> -<p><em> - See the note in the previous section for the description of why this operation requires two steps. -</em></p> -<p> - See also: - <a href="#buffersize"><code>buffersize</code></a>, - <a href="ext:api/org/apache/hadoop/fs/filesystem/append">FileSystem.append</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="OPEN"> - <title>Open and Read a File</title> -<ul> - <li>Submit a HTTP GET request with automatically following redirects. - <source> -curl -i -L "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=OPEN - [&offset=<LONG>][&length=<LONG>][&buffersize=<INT>]" - </source> -The request is redirected to a datanode where the file data can be read: - <source> -HTTP/1.1 307 TEMPORARY_REDIRECT -Location: http://<DATANODE>:<PORT>/webhdfs/v1/<PATH>?op=OPEN... -Content-Length: 0 - </source> -The client follows the redirect to the datanode and receives the file data: - <source> -HTTP/1.1 200 OK -Content-Type: application/octet-stream -Content-Length: 22 - -Hello, webhdfs user! - </source> - </li> -</ul> -<p> - See also: - <a href="#offset"><code>offset</code></a>, - <a href="#length"><code>length</code></a>, - <a href="#buffersize"><code>buffersize</code></a>, - <a href="ext:api/org/apache/hadoop/fs/filesystem/open">FileSystem.open</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="MKDIRS"> - <title>Make a Directory</title> -<ul> - <li>Submit a HTTP PUT request. - <source> - curl -i -X PUT "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=MKDIRS[&permission=<OCTAL>]" - </source> -The client receives a response with a <a href="#boolean"><code>boolean</code> JSON object</a>: - <source> -HTTP/1.1 200 OK -Content-Type: application/json -Transfer-Encoding: chunked - -{"boolean": true} - </source> - </li> -</ul> -<p> - See also: - <a href="#permission"><code>permission</code></a>, - <a href="ext:api/org/apache/hadoop/fs/filesystem/mkdirs">FileSystem.mkdirs</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="RENAME"> - <title>Rename a File/Directory</title> -<ul> - <li>Submit a HTTP PUT request. - <source> -curl -i -X PUT "<HOST>:<PORT>/webhdfs/v1/<PATH>?op=RENAME&destination=<PATH>" - </source> -The client receives a response with a <a href="#boolean"><code>boolean</code> JSON object</a>: - <source> -HTTP/1.1 200 OK -Content-Type: application/json -Transfer-Encoding: chunked - -{"boolean": true} - </source> - </li> -</ul> -<p> - See also: - <a href="#destination"><code>destination</code></a>, - <a href="ext:api/org/apache/hadoop/fs/filesystem/rename">FileSystem.rename</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="DELETE"> - <title>Delete a File/Directory</title> -<ul> - <li>Submit a HTTP DELETE request. - <source> -curl -i -X DELETE "http://<host>:<port>/webhdfs/v1/<path>?op=DELETE - [&recursive=<true|false>]" - </source> -The client receives a response with a <a href="#boolean"><code>boolean</code> JSON object</a>: - <source> -HTTP/1.1 200 OK -Content-Type: application/json -Transfer-Encoding: chunked - -{"boolean": true} - </source> - </li> -</ul> -<p> - See also: - <a href="#recursive"><code>recursive</code></a>, - <a href="ext:api/org/apache/hadoop/fs/filesystem/delete">FileSystem.delete</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="GETFILESTATUS"> - <title>Status of a File/Directory</title> -<ul> - <li>Submit a HTTP GET request. - <source> -curl -i "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=GETFILESTATUS" - </source> -The client receives a response with a <a href="#FileStatus"><code>FileStatus</code> JSON object</a>: - <source> -HTTP/1.1 200 OK -Content-Type: application/json -Transfer-Encoding: chunked - -{ - "FileStatus": - { - "accessTime" : 0, - "blockSize" : 0, - "group" : "supergroup", - "length" : 0, //in bytes, zero for directories - "modificationTime": 1320173277227, - "owner" : "webuser", - "pathSuffix" : "", - "permission" : "777", - "replication" : 0, - "type" : "DIRECTORY" //enum {FILE, DIRECTORY, SYMLINK} - } -} - </source> - </li> -</ul> -<p> - See also: - <a href="ext:api/org/apache/hadoop/fs/filesystem/getFileStatus">FileSystem.getFileStatus</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="LISTSTATUS"> - <title>List a Directory</title> -<ul> - <li>Submit a HTTP GET request. - <source> -curl -i "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=LISTSTATUS" - </source> -The client receives a response with a <a href="#FileStatuses"><code>FileStatuses</code> JSON object</a>: - <source> -HTTP/1.1 200 OK -Content-Type: application/json -Content-Length: 427 - -{ - "FileStatuses": - { - "FileStatus": - [ - { - "accessTime" : 1320171722771, - "blockSize" : 33554432, - "group" : "supergroup", - "length" : 24930, - "modificationTime": 1320171722771, - "owner" : "webuser", - "pathSuffix" : "a.patch", - "permission" : "644", - "replication" : 1, - "type" : "FILE" - }, - { - "accessTime" : 0, - "blockSize" : 0, - "group" : "supergroup", - "length" : 0, - "modificationTime": 1320895981256, - "owner" : "szetszwo", - "pathSuffix" : "bar", - "permission" : "711", - "replication" : 0, - "type" : "DIRECTORY" - }, - ... - ] - } -} - </source> - </li> -</ul> -<p> - See also: - <a href="ext:api/org/apache/hadoop/fs/filesystem/listStatus">FileSystem.listStatus</a> -</p> - </section> - </section> -<!-- ***************************************************************************** --> -<!-- ***************************************************************************** --> - <section> - <title>Other File System Operations</title> - <section id="GETCONTENTSUMMARY"> - <title>Get Content Summary of a Directory</title> -<ul> - <li>Submit a HTTP GET request. - <source> -curl -i "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=GETCONTENTSUMMARY" - </source> -The client receives a response with a <a href="#ContentSummary"><code>ContentSummary</code> JSON object</a>: - <source> -HTTP/1.1 200 OK -Content-Type: application/json -Transfer-Encoding: chunked - -{ - "ContentSummary": - { - "directoryCount": 2, - "fileCount" : 1, - "length" : 24930, - "quota" : -1, - "spaceConsumed" : 24930, - "spaceQuota" : -1 - } -} - </source> - </li> -</ul> -<p> - See also: - <a href="ext:api/org/apache/hadoop/fs/filesystem/getContentSummary">FileSystem.getContentSummary</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="GETFILECHECKSUM"> - <title>Get File Checksum</title> -<ul> - <li>Submit a HTTP GET request. - <source> -curl -i "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=GETFILECHECKSUM" - </source> -The request is redirected to a datanode: - <source> -HTTP/1.1 307 TEMPORARY_REDIRECT -Location: http://<DATANODE>:<PORT>/webhdfs/v1/<PATH>?op=GETFILECHECKSUM... -Content-Length: 0 - </source> -The client follows the redirect to the datanode and receives a <a href="#FileChecksum"><code>FileChecksum</code> JSON object</a>: - <source> -HTTP/1.1 200 OK -Content-Type: application/json -Transfer-Encoding: chunked - -{ - "FileChecksum": - { - "algorithm": "MD5-of-1MD5-of-512CRC32", - "bytes" : "eadb10de24aa315748930df6e185c0d ...", - "length" : 28 - } -} - </source> - </li> -</ul> -<p> - See also: - <a href="ext:api/org/apache/hadoop/fs/filesystem/getFileChecksum">FileSystem.getFileChecksum</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="GETHOMEDIRECTORY"> - <title>Get Home Directory</title> -<ul> - <li>Submit a HTTP GET request. - <source> -curl -i "http://<HOST>:<PORT>/webhdfs/v1/?op=GETHOMEDIRECTORY" - </source> -The client receives a response with a <a href="#Path"><code>Path</code> JSON object</a>: - <source> -HTTP/1.1 200 OK -Content-Type: application/json -Transfer-Encoding: chunked - -{"Path": "/user/szetszwo"} - </source> - </li> -</ul> -<p> - See also: - <a href="ext:api/org/apache/hadoop/fs/filesystem/getHomeDirectory">FileSystem.getHomeDirectory</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="SETPERMISSION"> - <title>Set Permission</title> -<ul> - <li>Submit a HTTP PUT request. - <source> -curl -i -X PUT "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=SETPERMISSION - [&permission=<OCTAL>]" - </source> -The client receives a response with zero content length: - <source> -HTTP/1.1 200 OK -Content-Length: 0 - </source> - </li> -</ul> -<p> - See also: - <a href="#permission"><code>permission</code></a>, - <a href="ext:api/org/apache/hadoop/fs/filesystem/setPermission">FileSystem.setPermission</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="SETOWNER"> - <title>Set Owner</title> -<ul> - <li>Submit a HTTP PUT request. - <source> -curl -i -X PUT "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=SETOWNER - [&owner=<USER>][&group=<GROUP>]" - </source> -The client receives a response with zero content length: - <source> -HTTP/1.1 200 OK -Content-Length: 0 - </source> - </li> -</ul> -<p> - See also: - <a href="#owner"><code>owner</code></a>, - <a href="#group"><code>group</code></a>, - <a href="ext:api/org/apache/hadoop/fs/filesystem/setOwner">FileSystem.setOwner</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="SETREPLICATION"> - <title>Set Replication Factor</title> -<ul> - <li>Submit a HTTP PUT request. - <source> -curl -i -X PUT "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=SETREPLICATION - [&replication=<SHORT>]" - </source> -The client receives a response with a <a href="#boolean"><code>boolean</code> JSON object</a>: - <source> -HTTP/1.1 200 OK -Content-Type: application/json -Transfer-Encoding: chunked - -{"boolean": true} - </source> - </li> -</ul> -<p> - See also: - <a href="#replication"><code>replication</code></a>, - <a href="ext:api/org/apache/hadoop/fs/filesystem/setReplication">FileSystem.setReplication</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="SETTIMES"> - <title>Set Access or Modification Time</title> -<ul> - <li>Submit a HTTP PUT request. - <source> -curl -i -X PUT "http://<HOST>:<PORT>/webhdfs/v1/<PATH>?op=SETTIMES - [&modificationtime=<TIME>][&accesstime=<TIME>]" - </source> -The client receives a response with zero content length: - <source> -HTTP/1.1 200 OK -Content-Length: 0 - </source> - </li> -</ul> -<p> - See also: - <a href="#modificationtime"><code>modificationtime</code></a>, - <a href="#accesstime"><code>accesstime</code></a>, - <a href="ext:api/org/apache/hadoop/fs/filesystem/setTimes">FileSystem.setTimes</a> -</p> - </section> - </section> -<!-- ***************************************************************************** --> -<!-- ***************************************************************************** --> - <section> - <title>Delegation Token Operations</title> - <section id="GETDELEGATIONTOKEN"> - <title>Get Delegation Token</title> -<ul> - <li>Submit a HTTP GET request. - <source> -curl -i "http://<HOST>:<PORT>/webhdfs/v1/?op=GETDELEGATIONTOKEN&renewer=<USER>" - </source> -The client receives a response with a <a href="#Token"><code>Token</code> JSON object</a>: - <source> -HTTP/1.1 200 OK -Content-Type: application/json -Transfer-Encoding: chunked - -{ - "Token": - { - "urlString": "JQAIaG9y..." - } -} - </source> - </li> -</ul> -<p> - See also: - <a href="#renewer"><code>renewer</code></a>, - <a href="ext:api/org/apache/hadoop/fs/filesystem/getDelegationToken">FileSystem.getDelegationToken</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="RENEWDELEGATIONTOKEN"> - <title>Renew Delegation Token</title> -<ul> - <li>Submit a HTTP PUT request. - <source> -curl -i -X PUT "http://<HOST>:<PORT>/webhdfs/v1/?op=RENEWDELEGATIONTOKEN&token=<TOKEN>" - </source> -The client receives a response with a <a href="#long"><code>long</code> JSON object</a>: - <source> -HTTP/1.1 200 OK -Content-Type: application/json -Transfer-Encoding: chunked - -{"long": 1320962673997} //the new expiration time - </source> - </li> -</ul> -<p> - See also: - <a href="#token"><code>token</code></a>, - DistributedFileSystem.renewDelegationToken -</p> - </section> -<!-- ***************************************************************************** --> - <section id="CANCELDELEGATIONTOKEN"> - <title>Cancel Delegation Token</title> -<ul> - <li>Submit a HTTP PUT request. - <source> -curl -i -X PUT "http://<HOST>:<PORT>/webhdfs/v1/?op=CANCELDELEGATIONTOKEN&token=<TOKEN>" - </source> -The client receives a response with zero content length: - <source> -HTTP/1.1 200 OK -Content-Length: 0 - </source> - </li> -</ul> -<p> - See also: - <a href="#token"><code>token</code></a>, - DistributedFileSystem.cancelDelegationToken -</p> - </section> - </section> -<!-- ***************************************************************************** --> -<!-- ***************************************************************************** --> - <section> - <title>Error Responses</title> -<p> - When an operation fails, the server may throw an exception. - The JSON schema of error responses is defined in <a href="#RemoteException"><code>RemoteException</code> JSON schema</a>. - The table below shows the mapping from exceptions to HTTP response codes. -</p> - <section> - <title>HTTP Response Codes</title> -<table> -<tr><th>Exceptions</th><th>HTTP Response Codes</th></tr> -<tr><td><code>IllegalArgumentException </code></td><td><code>400 Bad Request </code></td></tr> -<tr><td><code>UnsupportedOperationException</code></td><td><code>400 Bad Request </code></td></tr> -<tr><td><code>SecurityException </code></td><td><code>401 Unauthorized </code></td></tr> -<tr><td><code>IOException </code></td><td><code>403 Forbidden </code></td></tr> -<tr><td><code>FileNotFoundException </code></td><td><code>404 Not Found </code></td></tr> -<tr><td><code>RumtimeException </code></td><td><code>500 Internal Server Error</code></td></tr> -</table> -<p> - Below are examples of exception responses. -</p> -<!-- ***************************************************************************** --> - <section> - <title>Illegal Argument Exception</title> -<source> -HTTP/1.1 400 Bad Request -Content-Type: application/json -Transfer-Encoding: chunked - -{ - "RemoteException": - { - "exception" : "IllegalArgumentException", - "javaClassName": "java.lang.IllegalArgumentException", - "message" : "Invalid value for webhdfs parameter \"permission\": ..." - } -} -</source> - </section> -<!-- ***************************************************************************** --> - <section> - <title>Security Exception</title> -<source> -HTTP/1.1 401 Unauthorized -Content-Type: application/json -Transfer-Encoding: chunked - -{ - "RemoteException": - { - "exception" : "SecurityException", - "javaClassName": "java.lang.SecurityException", - "message" : "Failed to obtain user group information: ..." - } -} -</source> - </section> -<!-- ***************************************************************************** --> - <section> - <title>Access Control Exception</title> -<source> -HTTP/1.1 403 Forbidden -Content-Type: application/json -Transfer-Encoding: chunked - -{ - "RemoteException": - { - "exception" : "AccessControlException", - "javaClassName": "org.apache.hadoop.security.AccessControlException", - "message" : "Permission denied: ..." - } -} -</source> - </section> -<!-- ***************************************************************************** --> - <section> - <title>File Not Found Exception</title> -<source> -HTTP/1.1 404 Not Found -Content-Type: application/json -Transfer-Encoding: chunked - -{ - "RemoteException": - { - "exception" : "FileNotFoundException", - "javaClassName": "java.io.FileNotFoundException", - "message" : "File does not exist: /foo/a.patch" - } -} -</source> - </section> - </section> - </section> -<!-- ***************************************************************************** --> -<!-- ***************************************************************************** --> - <section> - <title>JSON Schemas</title> -<p> -All operations, except for <a href="#OPEN"><code>OPEN</code></a>, -either return a zero-length response or a JSON response . -For <a href="#OPEN"><code>OPEN</code></a>, the response is an octet-stream. -The JSON schemas are shown below. -See <a href="http://tools.ietf.org/id/draft-zyp-json-schema-03.html">draft-zyp-json-schema-03</a> -for the syntax definitions of the JSON schemas. -</p> - <section id="boolean"> - <title>Boolean JSON Schema</title> -<source> -{ - "name" : "boolean", - "properties": - { - "boolean": - { - "description": "A boolean value", - "type" : "boolean", - "required" : true - } - } -} -</source> -<p> - See also: - <a href="#MKDIRS"><code>MKDIRS</code></a>, - <a href="#RENAME"><code>RENAME</code></a>, - <a href="#DELETE"><code>DELETE</code></a>, - <a href="#SETREPLICATION"><code>SETREPLICATION</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="ContentSummary"> - <title>ContentSummary JSON Schema</title> -<source> -{ - "name" : "ContentSummary", - "properties": - { - "ContentSummary": - { - "type" : "object", - "properties": - { - "directoryCount": - { - "description": "The number of directories.", - "type" : "integer", - "required" : true - }, - "fileCount": - { - "description": "The number of files.", - "type" : "integer", - "required" : true - }, - "length": - { - "description": "The number of bytes used by the content.", - "type" : "integer", - "required" : true - }, - "quota": - { - "description": "The namespace quota of this directory.", - "type" : "integer", - "required" : true - }, - "spaceConsumed": - { - "description": "The disk space consumed by the content.", - "type" : "integer", - "required" : true - }, - "spaceQuota": - { - "description": "The disk space quota.", - "type" : "integer", - "required" : true - } - } - } - } -} -</source> -<p> - See also: - <a href="#GETCONTENTSUMMARY"><code>GETCONTENTSUMMARY</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="FileChecksum"> - <title>FileChecksum JSON Schema</title> -<source> -{ - "name" : "FileChecksum", - "properties": - { - "FileChecksum": - { - "type" : "object", - "properties": - { - "algorithm": - { - "description": "The name of the checksum algorithm.", - "type" : "string", - "required" : true - }, - "bytes": - { - "description": "The byte sequence of the checksum in hexadecimal.", - "type" : "string", - "required" : true - }, - "length": - { - "description": "The length of the bytes (not the length of the string).", - "type" : "integer", - "required" : true - } - } - } - } -} -</source> -<p> - See also: - <a href="#GETFILECHECKSUM"><code>GETFILECHECKSUM</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="FileStatus"> - <title>FileStatus JSON Schema</title> -<source> -{ - "name" : "FileStatus", - "properties": - { - "FileStatus": fileStatusProperties //See <a href="#fileStatusProperties">FileStatus Properties</a> - } -} -</source> -<p> - See also: - <a href="#GETFILESTATUS"><code>GETFILESTATUS</code></a>, - <a href="ext:api/org/apache/hadoop/fs/FileStatus">FileStatus</a> -</p> - <section id="fileStatusProperties"> - <title>FileStatus Properties</title> -<p> - JavaScript syntax is used to define <code>fileStatusProperties</code> - so that it can be referred in both <code>FileStatus</code> and <code>FileStatuses</code> JSON schemas. -</p> -<source> -var fileStatusProperties = -{ - "type" : "object", - "properties": - { - "accessTime": - { - "description": "The access time.", - "type" : "integer", - "required" : true - }, - "blockSize": - { - "description": "The block size of a file.", - "type" : "integer", - "required" : true - }, - "group": - { - "description": "The group owner.", - "type" : "string", - "required" : true - }, - "length": - { - "description": "The number of bytes in a file.", - "type" : "integer", - "required" : true - }, - "modificationTime": - { - "description": "The modification time.", - "type" : "integer", - "required" : true - }, - "owner": - { - "description": "The user who is the owner.", - "type" : "string", - "required" : true - }, - "pathSuffix": - { - "description": "The path suffix.", - "type" : "string", - "required" : true - }, - "permission": - { - "description": "The permission represented as a octal string.", - "type" : "string", - "required" : true - }, - "replication": - { - "description": "The number of replication of a file.", - "type" : "integer", - "required" : true - }, - "symlink": //an optional property - { - "description": "The link target of a symlink.", - "type" : "string" - }, - "type": - { - "description": "The type of the path object.", - "enum" : ["FILE", "DIRECTORY", "SYMLINK"], - "required" : true - } - } -}; -</source> - </section> - </section> -<!-- ***************************************************************************** --> - <section id="FileStatuses"> - <title>FileStatuses JSON Schema</title> -<p> - A <code>FileStatuses</code> JSON object represents an array of <code>FileStatus</code> JSON objects. -</p> -<source> -{ - "name" : "FileStatuses", - "properties": - { - "FileStatuses": - { - "type" : "object", - "properties": - { - "FileStatus": - { - "description": "An array of FileStatus", - "type" : "array", - "items" : fileStatusProperties //See <a href="#fileStatusProperties">FileStatus Properties</a> - } - } - } - } -} -</source> -<p> - See also: - <a href="#LISTSTATUS"><code>LISTSTATUS</code></a>, - <a href="ext:api/org/apache/hadoop/fs/FileStatus">FileStatus</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="long"> - <title>Long JSON Schema</title> -<source> -{ - "name" : "long", - "properties": - { - "long": - { - "description": "A long integer value", - "type" : "integer", - "required" : true - } - } -} -</source> -<p> - See also: - <a href="#RENEWDELEGATIONTOKEN"><code>RENEWDELEGATIONTOKEN</code></a>, -</p> - </section> -<!-- ***************************************************************************** --> - <section id="Path"> - <title>Path JSON Schema</title> -<source> -{ - "name" : "Path", - "properties": - { - "Path": - { - "description": "The string representation a Path.", - "type" : "string", - "required" : true - } - } -} -</source> -<p> - See also: - <a href="#GETHOMEDIRECTORY"><code>GETHOMEDIRECTORY</code></a>, - <a href="ext:api/org/apache/hadoop/fs/Path">Path</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="RemoteException"> - <title>RemoteException JSON Schema</title> -<source> -{ - "name" : "RemoteException", - "properties": - { - "RemoteException": - { - "type" : "object", - "properties": - { - "exception": - { - "description": "Name of the exception", - "type" : "string", - "required" : true - }, - "message": - { - "description": "Exception message", - "type" : "string", - "required" : true - }, - "javaClassName": //an optional property - { - "description": "Java class name of the exception", - "type" : "string", - } - } - } - } -} -</source> - </section> -<!-- ***************************************************************************** --> - <section id="Token"> - <title>Token JSON Schema</title> -<source> -{ - "name" : "Token", - "properties": - { - "Token": - { - "type" : "object", - "properties": - { - "urlString": - { - "description": "A delegation token encoded as a URL safe string.", - "type" : "string", - "required" : true - } - } - } - } -} -</source> -<p> - See also: - <a href="#GETDELEGATIONTOKEN"><code>GETDELEGATIONTOKEN</code></a>, - the note in <a href="#delegation">Delegation</a>. -</p> - </section> - </section> -<!-- ***************************************************************************** --> -<!-- ***************************************************************************** --> - <section id="ParameterDictionary"> - <title>HTTP Query Parameter Dictionary</title> - <section id="accesstime"> - <title>Access Time</title> -<table> - <tr><td>Name</td><td><code>accesstime</code></td></tr> - <tr><td>Description</td><td>The access time of a file/directory.</td></tr> - <tr><td>Type</td><td>long</td></tr> - <tr><td>Default Value</td><td>-1 (means keeping it unchanged)</td></tr> - <tr><td>Valid Values</td><td>-1 or a timestamp</td></tr> - <tr><td>Syntax</td><td>Any integer.</td></tr> -</table> -<p> - See also: - <a href="#SETTIMES"><code>SETTIMES</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="blocksize"> - <title>Block Size</title> -<table> - <tr><td>Name</td><td><code>blocksize</code></td></tr> - <tr><td>Description</td><td>The block size of a file.</td></tr> - <tr><td>Type</td><td>long</td></tr> - <tr><td>Default Value</td><td>Specified in the configuration.</td></tr> - <tr><td>Valid Values</td><td>> 0</td></tr> - <tr><td>Syntax</td><td>Any integer.</td></tr> -</table> -<p> - See also: - <a href="#CREATE"><code>CREATE</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="buffersize"> - <title>Buffer Size</title> -<table> - <tr><td>Name</td><td><code>buffersize</code></td></tr> - <tr><td>Description</td><td>The size of the buffer used in transferring data.</td></tr> - <tr><td>Type</td><td>int</td></tr> - <tr><td>Default Value</td><td>Specified in the configuration.</td></tr> - <tr><td>Valid Values</td><td>> 0</td></tr> - <tr><td>Syntax</td><td>Any integer.</td></tr> -</table> -<p> - See also: - <a href="#CREATE"><code>CREATE</code></a>, - <a href="#APPEND"><code>APPEND</code></a>, - <a href="#OPEN"><code>OPEN</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="delegation"> - <title>Delegation</title> -<table> - <tr><td>Name</td><td><code>delegation</code></td></tr> - <tr><td>Description</td><td>The delegation token used for authentication.</td></tr> - <tr><td>Type</td><td>String</td></tr> - <tr><td>Default Value</td><td><empty></td></tr> - <tr><td>Valid Values</td><td>An encoded token.</td></tr> - <tr><td>Syntax</td><td>See the note below.</td></tr> -</table> -<p> - <strong>Note</strong> that delegation tokens are encoded as a URL safe string; - see <code>encodeToUrlString()</code> - and <code>decodeFromUrlString(String)</code> - in <code>org.apache.hadoop.security.token.Token</code> for the details of the encoding. -</p> -<p> - See also: - <a href="#Authentication">Authentication</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="destination"> - <title>Destination</title> -<table> - <tr><td>Name</td><td><code>destination</code></td></tr> - <tr><td>Description</td><td>The destination path used in <a href="#RENAME">RENAME</a>.</td></tr> - <tr><td>Type</td><td>Path</td></tr> - <tr><td>Default Value</td><td><empty> (an invalid path)</td></tr> - <tr><td>Valid Values</td><td>An absolute FileSystem path without scheme and authority.</td></tr> - <tr><td>Syntax</td><td>Any path.</td></tr> -</table> -<p> - See also: - <a href="#RENAME"><code>RENAME</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="doas"> - <title>Do As</title> -<table> - <tr><td>Name</td><td><code>doas</code></td></tr> - <tr><td>Description</td><td>Allowing a proxy user to do as another user.</td></tr> - <tr><td>Type</td><td>String</td></tr> - <tr><td>Default Value</td><td>null</td></tr> - <tr><td>Valid Values</td><td>Any valid username.</td></tr> - <tr><td>Syntax</td><td>Any string.</td></tr> -</table> -<p> - See also: - <a href="#ProxyUsers">Proxy Users</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="group"> - <title>Group</title> -<table> - <tr><td>Name</td><td><code>group</code></td></tr> - <tr><td>Description</td><td>The name of a group.</td></tr> - <tr><td>Type</td><td>String</td></tr> - <tr><td>Default Value</td><td><empty> (means keeping it unchanged)</td></tr> - <tr><td>Valid Values</td><td>Any valid group name.</td></tr> - <tr><td>Syntax</td><td>Any string.</td></tr> -</table> -<p> - See also: - <a href="#SETOWNER"><code>SETOWNER</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="length"> - <title>Length</title> -<table> - <tr><td>Name</td><td><code>length</code></td></tr> - <tr><td>Description</td><td>The number of bytes to be processed.</td></tr> - <tr><td>Type</td><td>long</td></tr> - <tr><td>Default Value</td><td>null (means the entire file)</td></tr> - <tr><td>Valid Values</td><td>>= 0 or null</td></tr> - <tr><td>Syntax</td><td>Any integer.</td></tr> -</table> -<p> - See also: - <a href="#OPEN"><code>OPEN</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="modificationtime"> - <title>Modification Time</title> -<table> - <tr><td>Name</td><td><code>modificationtime</code></td></tr> - <tr><td>Description</td><td>The modification time of a file/directory.</td></tr> - <tr><td>Type</td><td>long</td></tr> - <tr><td>Default Value</td><td>-1 (means keeping it unchanged)</td></tr> - <tr><td>Valid Values</td><td>-1 or a timestamp</td></tr> - <tr><td>Syntax</td><td>Any integer.</td></tr> -</table> -<p> - See also: - <a href="#SETTIMES"><code>SETTIMES</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="offset"> - <title>Offset</title> -<table> - <tr><td>Name</td><td><code>offset</code></td></tr> - <tr><td>Description</td><td>The starting byte position.</td></tr> - <tr><td>Type</td><td>long</td></tr> - <tr><td>Default Value</td><td>0</td></tr> - <tr><td>Valid Values</td><td>>= 0</td></tr> - <tr><td>Syntax</td><td>Any integer.</td></tr> -</table> -<p> - See also: - <a href="#OPEN"><code>OPEN</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="op"> - <title>Op</title> -<table> - <tr><td>Name</td><td><code>op</code></td></tr> - <tr><td>Description</td><td>The name of the operation to be executed.</td></tr> - <tr><td>Type</td><td>enum</td></tr> - <tr><td>Default Value</td><td>null (an invalid value)</td></tr> - <tr><td>Valid Values</td><td>Any valid operation name.</td></tr> - <tr><td>Syntax</td><td>Any string.</td></tr> -</table> -<p> - See also: - <a href="#Operations">Operations</a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="overwrite"> - <title>Overwrite</title> -<table> - <tr><td>Name</td><td><code>overwrite</code></td></tr> - <tr><td>Description</td><td>If a file already exists, should it be overwritten?</td></tr> - <tr><td>Type</td><td>boolean</td></tr> - <tr><td>Default Value</td><td>false</td></tr> - <tr><td>Valid Values</td><td>true | false</td></tr> - <tr><td>Syntax</td><td>true | false</td></tr> -</table> -<p> - See also: - <a href="#CREATE"><code>CREATE</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="owner"> - <title>Owner</title> -<table> - <tr><td>Name</td><td><code>owner</code></td></tr> - <tr><td>Description</td><td>The username who is the owner of a file/directory.</td></tr> - <tr><td>Type</td><td>String</td></tr> - <tr><td>Default Value</td><td><empty> (means keeping it unchanged)</td></tr> - <tr><td>Valid Values</td><td>Any valid username.</td></tr> - <tr><td>Syntax</td><td>Any string.</td></tr> -</table> -<p> - See also: - <a href="#SETOWNER"><code>SETOWNER</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="permission"> - <title>Permission</title> -<table> - <tr><td>Name</td><td><code>permission</code></td></tr> - <tr><td>Description</td><td>The permission of a file/directory.</td></tr> - <tr><td>Type</td><td>Octal</td></tr> - <tr><td>Default Value</td><td>755</td></tr> - <tr><td>Valid Values</td><td>0 - 1777</td></tr> - <tr><td>Syntax</td><td>Any radix-8 integer (leading zeros may be omitted.)</td></tr> -</table> -<p> - See also: - <a href="#CREATE"><code>CREATE</code></a>, - <a href="#MKDIRS"><code>MKDIRS</code></a>, - <a href="#SETPERMISSION"><code>SETPERMISSION</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="recursive"> - <title>Recursive</title> -<table> - <tr><td>Name</td><td><code>recursive</code></td></tr> - <tr><td>Description</td><td>Should the operation act on the content in the subdirectories?</td></tr> - <tr><td>Type</td><td>boolean</td></tr> - <tr><td>Default Value</td><td>false</td></tr> - <tr><td>Valid Values</td><td>true | false</td></tr> - <tr><td>Syntax</td><td>true | false</td></tr> -</table> -<p> - See also: - <a href="#RENAME"><code>RENAME</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="renewer"> - <title>Renewer</title> -<table> - <tr><td>Name</td><td><code>renewer</code></td></tr> - <tr><td>Description</td><td>The username of the renewer of a delegation token.</td></tr> - <tr><td>Type</td><td>String</td></tr> - <tr><td>Default Value</td><td><empty> (means the current user)</td></tr> - <tr><td>Valid Values</td><td>Any valid username.</td></tr> - <tr><td>Syntax</td><td>Any string.</td></tr> -</table> -<p> - See also: - <a href="#GETDELEGATIONTOKEN"><code>GETDELEGATIONTOKEN</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="replication"> - <title>Replication</title> -<table> - <tr><td>Name</td><td><code>replication</code></td></tr> - <tr><td>Description</td><td>The number of replications of a file.</td></tr> - <tr><td>Type</td><td>short</td></tr> - <tr><td>Default Value</td><td>Specified in the configuration.</td></tr> - <tr><td>Valid Values</td><td>> 0</td></tr> - <tr><td>Syntax</td><td>Any integer.</td></tr> -</table> -<p> - See also: - <a href="#CREATE"><code>CREATE</code></a>, - <a href="#SETREPLICATION"><code>SETREPLICATION</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="token"> - <title>Token</title> -<table> - <tr><td>Name</td><td><code>token</code></td></tr> - <tr><td>Description</td><td>The delegation token used for the operation.</td></tr> - <tr><td>Type</td><td>String</td></tr> - <tr><td>Default Value</td><td><empty></td></tr> - <tr><td>Valid Values</td><td>An encoded token.</td></tr> - <tr><td>Syntax</td><td>See the note in <a href="#delegation">Delegation</a>.</td></tr> -</table> -<p> - See also: - <a href="#RENEWDELEGATIONTOKEN"><code>RENEWDELEGATIONTOKEN</code></a>, - <a href="#CANCELDELEGATIONTOKEN"><code>CANCELDELEGATIONTOKEN</code></a> -</p> - </section> -<!-- ***************************************************************************** --> - <section id="user.name"> - <title>Username</title> -<table> - <tr><td>Name</td><td><code>user.name</code></td></tr> - <tr><td>Description</td><td>The authenticated user; see <a href="#Authentication">Authentication</a>.</td></tr> - <tr><td>Type</td><td>String</td></tr> - <tr><td>Default Value</td><td>null</td></tr> - <tr><td>Valid Values</td><td>Any valid username.</td></tr> - <tr><td>Syntax</td><td>Any string.</td></tr> -</table> -<p> - See also: - <a href="#Authentication">Authentication</a> -</p> - </section> - </section> - </body> -</document>
http://git-wip-us.apache.org/repos/asf/hadoop/blob/ee7beda6/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/FI-framework.gif ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/FI-framework.gif b/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/FI-framework.gif deleted file mode 100644 index 94ccd83..0000000 Binary files a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/FI-framework.gif and /dev/null differ http://git-wip-us.apache.org/repos/asf/hadoop/blob/ee7beda6/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/FI-framework.odg ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/FI-framework.odg b/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/FI-framework.odg deleted file mode 100644 index 7a5ba85..0000000 Binary files a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/FI-framework.odg and /dev/null differ http://git-wip-us.apache.org/repos/asf/hadoop/blob/ee7beda6/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/architecture.gif ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/architecture.gif b/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/architecture.gif deleted file mode 100644 index 8d84a23..0000000 Binary files a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/architecture.gif and /dev/null differ http://git-wip-us.apache.org/repos/asf/hadoop/blob/ee7beda6/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/core-logo.gif ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/core-logo.gif b/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/core-logo.gif deleted file mode 100644 index 57879bb..0000000 Binary files a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/core-logo.gif and /dev/null differ http://git-wip-us.apache.org/repos/asf/hadoop/blob/ee7beda6/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/favicon.ico ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/favicon.ico b/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/favicon.ico deleted file mode 100644 index 161bcf7..0000000 Binary files a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/favicon.ico and /dev/null differ http://git-wip-us.apache.org/repos/asf/hadoop/blob/ee7beda6/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/hadoop-logo-big.jpg ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/hadoop-logo-big.jpg b/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/hadoop-logo-big.jpg deleted file mode 100644 index 0c6996c..0000000 Binary files a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/hadoop-logo-big.jpg and /dev/null differ http://git-wip-us.apache.org/repos/asf/hadoop/blob/ee7beda6/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/hadoop-logo.jpg ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/hadoop-logo.jpg b/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/hadoop-logo.jpg deleted file mode 100644 index 809525d..0000000 Binary files a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/hadoop-logo.jpg and /dev/null differ http://git-wip-us.apache.org/repos/asf/hadoop/blob/ee7beda6/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/request-identify.jpg ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/request-identify.jpg b/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/request-identify.jpg deleted file mode 100644 index 504cbaf..0000000 Binary files a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/resources/images/request-identify.jpg and /dev/null differ http://git-wip-us.apache.org/repos/asf/hadoop/blob/ee7beda6/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/skinconf.xml ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/skinconf.xml b/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/skinconf.xml deleted file mode 100644 index cfb2010..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/src/documentation/skinconf.xml +++ /dev/null @@ -1,366 +0,0 @@ -<?xml version="1.0"?> -<!-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> - -<!-- -Skin configuration file. This file contains details of your project, -which will be used to configure the chosen Forrest skin. ---> - -<!DOCTYPE skinconfig PUBLIC "-//APACHE//DTD Skin Configuration V0.6-3//EN" "http://forrest.apache.org/dtd/skinconfig-v06-3.dtd"> -<skinconfig> - <!-- To enable lucene search add provider="lucene" (default is google). - Add box-location="alt" to move the search box to an alternate location - (if the skin supports it) and box-location="all" to show it in all - available locations on the page. Remove the <search> element to show - no search box. @domain will enable sitesearch for the specific domain with google. - In other words google will search the @domain for the query string. - - --> - <search name="Lucene" domain="hadoop.apache.org" provider="google"/> - - <!-- Disable the print link? If enabled, invalid HTML 4.0.1 --> - <disable-print-link>true</disable-print-link> - <!-- Disable the PDF link? --> - <disable-pdf-link>false</disable-pdf-link> - <!-- Disable the POD link? --> - <disable-pod-link>true</disable-pod-link> - <!-- Disable the Text link? FIXME: NOT YET IMPLEMENETED. --> - <disable-txt-link>true</disable-txt-link> - <!-- Disable the xml source link? --> - <!-- The xml source link makes it possible to access the xml rendition - of the source frim the html page, and to have it generated statically. - This can be used to enable other sites and services to reuse the - xml format for their uses. Keep this disabled if you don't want other - sites to easily reuse your pages.--> - <disable-xml-link>true</disable-xml-link> - - <!-- Disable navigation icons on all external links? --> - <disable-external-link-image>true</disable-external-link-image> - - <!-- Disable w3c compliance links? - Use e.g. align="center" to move the compliance links logos to - an alternate location default is left. - (if the skin supports it) --> - <disable-compliance-links>true</disable-compliance-links> - - <!-- Render mailto: links unrecognisable by spam harvesters? --> - <obfuscate-mail-links>false</obfuscate-mail-links> - - <!-- Disable the javascript facility to change the font size --> - <disable-font-script>true</disable-font-script> - - <!-- project logo --> - <project-name>Hadoop</project-name> - <project-description>Scalable Computing Platform</project-description> - <project-url>http://hadoop.apache.org/hdfs/</project-url> - <project-logo>images/hdfs-logo.jpg</project-logo> - - <!-- group logo --> - <group-name>Hadoop</group-name> - <group-description>Apache Hadoop</group-description> - <group-url>http://hadoop.apache.org/</group-url> - <group-logo>images/hadoop-logo.jpg</group-logo> - - <!-- optional host logo (e.g. sourceforge logo) - default skin: renders it at the bottom-left corner --> - <host-url></host-url> - <host-logo></host-logo> - - <!-- relative url of a favicon file, normally favicon.ico --> - <favicon-url>images/favicon.ico</favicon-url> - - <!-- The following are used to construct a copyright statement --> - <year>2010</year> - <vendor>The Apache Software Foundation.</vendor> - <copyright-link>http://www.apache.org/licenses/</copyright-link> - - <!-- Some skins use this to form a 'breadcrumb trail' of links. - Use location="alt" to move the trail to an alternate location - (if the skin supports it). - Omit the location attribute to display the trail in the default location. - Use location="none" to not display the trail (if the skin supports it). - For some skins just set the attributes to blank. - --> - <trail> - <link1 name="Apache" href="http://www.apache.org/"/> - <link2 name="Hadoop" href="http://hadoop.apache.org/"/> - <link3 name="Core" href="http://hadoop.apache.org/core/"/> - </trail> - - <!-- Configure the TOC, i.e. the Table of Contents. - @max-depth - how many "section" levels need to be included in the - generated Table of Contents (TOC). - @min-sections - Minimum required to create a TOC. - @location ("page","menu","page,menu", "none") - Where to show the TOC. - --> - <toc max-depth="2" min-sections="1" location="page"/> - - <!-- Heading types can be clean|underlined|boxed --> - <headings type="clean"/> - - <!-- The optional feedback element will be used to construct a - feedback link in the footer with the page pathname appended: - <a href="@href">{@to}</a> - <feedback to="webmas...@foo.com" - href="mailto:webmas...@foo.com?subject=Feedback " > - Send feedback about the website to: - </feedback> - --> - <!-- - extra-css - here you can define custom css-elements that are - a. overriding the fallback elements or - b. adding the css definition from new elements that you may have - used in your documentation. - --> - <extra-css> - <!--Example of b. - To define the css definition of a new element that you may have used - in the class attribute of a <p> node. - e.g. <p class="quote"/> - --> - p.quote { - margin-left: 2em; - padding: .5em; - background-color: #f0f0f0; - font-family: monospace; - } - - <!--Headers --> - #content h1 { - margin-bottom: .5em; - font-size: 185%; color: black; - font-family: arial; - } - h2, .h3 { font-size: 175%; color: black; font-family: arial; } - h3, .h4 { font-size: 135%; color: black; font-family: arial; margin-bottom: 0.5em; } - h4, .h5 { font-size: 125%; color: black; font-style: italic; font-weight: bold; font-family: arial; } - h5, h6 { font-size: 110%; color: #363636; font-weight: bold; } - - <!--Code Background --> - pre.code { - margin-left: 0em; - padding: 0.5em; - background-color: rgb(241,239,231); - font-family: monospace; - } - - </extra-css> - - <colors> - <!-- These values are used for the generated CSS files. --> - - <!-- Krysalis --> -<!-- - <color name="header" value="#FFFFFF"/> - - <color name="tab-selected" value="#a5b6c6" link="#000000" vlink="#000000" hlink="#000000"/> - <color name="tab-unselected" value="#F7F7F7" link="#000000" vlink="#000000" hlink="#000000"/> - <color name="subtab-selected" value="#a5b6c6" link="#000000" vlink="#000000" hlink="#000000"/> - <color name="subtab-unselected" value="#a5b6c6" link="#000000" vlink="#000000" hlink="#000000"/> - - <color name="heading" value="#a5b6c6"/> - <color name="subheading" value="#CFDCED"/> - - <color name="navstrip" value="#CFDCED" font="#000000" link="#000000" vlink="#000000" hlink="#000000"/> - <color name="toolbox" value="#a5b6c6"/> - <color name="border" value="#a5b6c6"/> - - <color name="menu" value="#F7F7F7" link="#000000" vlink="#000000" hlink="#000000"/> - <color name="dialog" value="#F7F7F7"/> - - <color name="body" value="#ffffff" link="#0F3660" vlink="#009999" hlink="#000066"/> - - <color name="table" value="#a5b6c6"/> - <color name="table-cell" value="#ffffff"/> - <color name="highlight" value="#ffff00"/> - <color name="fixme" value="#cc6600"/> - <color name="note" value="#006699"/> - <color name="warning" value="#990000"/> - <color name="code" value="#a5b6c6"/> - - <color name="footer" value="#a5b6c6"/> ---> - - <!-- Forrest --> -<!-- - <color name="header" value="#294563"/> - - <color name="tab-selected" value="#4a6d8c" link="#0F3660" vlink="#0F3660" hlink="#000066"/> - <color name="tab-unselected" value="#b5c7e7" link="#0F3660" vlink="#0F3660" hlink="#000066"/> - <color name="subtab-selected" value="#4a6d8c" link="#0F3660" vlink="#0F3660" hlink="#000066"/> - <color name="subtab-unselected" value="#4a6d8c" link="#0F3660" vlink="#0F3660" hlink="#000066"/> - - <color name="heading" value="#294563"/> - <color name="subheading" value="#4a6d8c"/> - - <color name="navstrip" value="#cedfef" font="#0F3660" link="#0F3660" vlink="#0F3660" hlink="#000066"/> - <color name="toolbox" value="#4a6d8c"/> - <color name="border" value="#294563"/> - - <color name="menu" value="#4a6d8c" font="#cedfef" link="#ffffff" vlink="#ffffff" hlink="#ffcf00"/> - <color name="dialog" value="#4a6d8c"/> - - <color name="body" value="#ffffff" link="#0F3660" vlink="#009999" hlink="#000066"/> - - <color name="table" value="#7099C5"/> - <color name="table-cell" value="#f0f0ff"/> - <color name="highlight" value="#ffff00"/> - <color name="fixme" value="#cc6600"/> - <color name="note" value="#006699"/> - <color name="warning" value="#990000"/> - <color name="code" value="#CFDCED"/> - - <color name="footer" value="#cedfef"/> ---> - - <!-- Collabnet --> -<!-- - <color name="header" value="#003366"/> - - <color name="tab-selected" value="#dddddd" link="#555555" vlink="#555555" hlink="#555555"/> - <color name="tab-unselected" value="#999999" link="#ffffff" vlink="#ffffff" hlink="#ffffff"/> - <color name="subtab-selected" value="#cccccc" link="#000000" vlink="#000000" hlink="#000000"/> - <color name="subtab-unselected" value="#cccccc" link="#555555" vlink="#555555" hlink="#555555"/> - - <color name="heading" value="#003366"/> - <color name="subheading" value="#888888"/> - - <color name="navstrip" value="#dddddd" font="#555555"/> - <color name="toolbox" value="#dddddd" font="#555555"/> - <color name="border" value="#999999"/> - - <color name="menu" value="#ffffff"/> - <color name="dialog" value="#eeeeee"/> - - <color name="body" value="#ffffff"/> - - <color name="table" value="#ccc"/> - <color name="table-cell" value="#ffffff"/> - <color name="highlight" value="#ffff00"/> - <color name="fixme" value="#cc6600"/> - <color name="note" value="#006699"/> - <color name="warning" value="#990000"/> - <color name="code" value="#003366"/> - - <color name="footer" value="#ffffff"/> ---> - <!-- Lenya using pelt--> -<!-- - <color name="header" value="#ffffff"/> - - <color name="tab-selected" value="#4C6C8F" link="#ffffff" vlink="#ffffff" hlink="#ffffff"/> - <color name="tab-unselected" value="#E5E4D9" link="#000000" vlink="#000000" hlink="#000000"/> - <color name="subtab-selected" value="#000000" link="#000000" vlink="#000000" hlink="#000000"/> - <color name="subtab-unselected" value="#E5E4D9" link="#000000" vlink="#000000" hlink="#000000"/> - - <color name="heading" value="#E5E4D9"/> - <color name="subheading" value="#000000"/> - <color name="published" value="#4C6C8F" font="#FFFFFF"/> - <color name="feedback" value="#4C6C8F" font="#FFFFFF" align="center"/> - <color name="navstrip" value="#E5E4D9" font="#000000"/> - - <color name="toolbox" value="#CFDCED" font="#000000"/> - - <color name="border" value="#999999"/> - <color name="menu" value="#4C6C8F" font="#ffffff" link="#ffffff" vlink="#ffffff" hlink="#ffffff" current="#FFCC33" /> - <color name="menuheading" value="#cfdced" font="#000000" /> - <color name="searchbox" value="#E5E4D9" font="#000000"/> - - <color name="dialog" value="#CFDCED"/> - <color name="body" value="#ffffff" /> - - <color name="table" value="#ccc"/> - <color name="table-cell" value="#ffffff"/> - <color name="highlight" value="#ffff00"/> - <color name="fixme" value="#cc6600"/> - <color name="note" value="#006699"/> - <color name="warning" value="#990000"/> - <color name="code" value="#003366"/> - - <color name="footer" value="#E5E4D9"/> ---> - </colors> - - <!-- Settings specific to PDF output. --> - <pdf> - <!-- - Supported page sizes are a0, a1, a2, a3, a4, a5, executive, - folio, legal, ledger, letter, quarto, tabloid (default letter). - Supported page orientations are portrait, landscape (default - portrait). - Supported text alignments are left, right, justify (default left). - --> - <page size="letter" orientation="portrait" text-align="left"/> - - <!-- - Margins can be specified for top, bottom, inner, and outer - edges. If double-sided="false", the inner edge is always left - and the outer is always right. If double-sided="true", the - inner edge will be left on odd pages, right on even pages, - the outer edge vice versa. - Specified below are the default settings. - --> - <margins double-sided="false"> - <top>1in</top> - <bottom>1in</bottom> - <inner>1.25in</inner> - <outer>1in</outer> - </margins> - - <!-- - Print the URL text next to all links going outside the file - --> - <show-external-urls>false</show-external-urls> - - <!-- - Disable the copyright footer on each page of the PDF. - A footer is composed for each page. By default, a "credit" with role=pdf - will be used, as explained below. Otherwise a copyright statement - will be generated. This latter can be disabled. - --> - <disable-copyright-footer>false</disable-copyright-footer> - </pdf> - - <!-- Credits are typically rendered as a set of small clickable - images in the page footer. - Use box-location="alt" to move the credit to an alternate location - (if the skin supports it). - --> - <credits> - <credit box-location="alt"> - <name>Built with Apache Forrest</name> - <url>http://forrest.apache.org/</url> - <image>images/built-with-forrest-button.png</image> - <width>88</width> - <height>31</height> - </credit> - <!-- A credit with @role="pdf" will be used to compose a footer - for each page in the PDF, using either "name" or "url" or both. - --> - <!-- - <credit role="pdf"> - <name>Built with Apache Forrest</name> - <url>http://forrest.apache.org/</url> - </credit> - --> - </credits> - -</skinconfig> http://git-wip-us.apache.org/repos/asf/hadoop/blob/ee7beda6/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/status.xml ---------------------------------------------------------------------- diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/status.xml b/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/status.xml deleted file mode 100644 index a820726..0000000 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/docs/status.xml +++ /dev/null @@ -1,75 +0,0 @@ -<?xml version="1.0"?> -<!-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---> -<status> - - <developers> - <person name="Joe Bloggs" email="j...@joescompany.org" id="JB" /> - <!-- Add more people here --> - </developers> - - <changes> - <!-- Add new releases here --> - <release version="0.1" date="unreleased"> - <!-- Some action types have associated images. By default, images are - defined for 'add', 'fix', 'remove', 'update' and 'hack'. If you add - src/documentation/resources/images/<foo>.jpg images, these will - automatically be used for entries of type <foo>. --> - - <action dev="JB" type="add" context="admin"> - Initial Import - </action> - <!-- Sample action: - <action dev="JB" type="fix" due-to="Joe Contributor" - due-to-email="j...@apache.org" fixes-bug="123"> - Fixed a bug in the Foo class. - </action> - --> - </release> - </changes> - - <todo> - <actions priority="high"> - <action context="docs" dev="JB"> - Customize this template project with your project's details. This - TODO list is generated from 'status.xml'. - </action> - <action context="docs" dev="JB"> - Add lots of content. XML content goes in - <code>src/documentation/content/xdocs</code>, or wherever the - <code>${project.xdocs-dir}</code> property (set in - <code>forrest.properties</code>) points. - </action> - <action context="feedback" dev="JB"> - Mail <link - href="mailto:forrest-...@xml.apache.org">forrest-...@xml.apache.org</link> - with feedback. - </action> - </actions> - <!-- Add todo items. @context is an arbitrary string. Eg: - <actions priority="high"> - <action context="code" dev="SN"> - </action> - </actions> - <actions priority="medium"> - <action context="docs" dev="open"> - </action> - </actions> - --> - </todo> - -</status>