Modified: hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/editsStored.xml URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/editsStored.xml?rev=1560522&r1=1560521&r2=1560522&view=diff ============================================================================== --- hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/editsStored.xml (original) +++ hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/editsStored.xml Wed Jan 22 21:43:00 2014 @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> <EDITS> - <EDITS_VERSION>-50</EDITS_VERSION> + <EDITS_VERSION>-51</EDITS_VERSION> <RECORD> <OPCODE>OP_START_LOG_SEGMENT</OPCODE> <DATA> @@ -13,8 +13,8 @@ <TXID>2</TXID> <DELEGATION_KEY> <KEY_ID>1</KEY_ID> - <EXPIRY_DATE>1390675042623</EXPIRY_DATE> - <KEY>3d747279912f2511</KEY> + <EXPIRY_DATE>1390942564729</EXPIRY_DATE> + <KEY>f270a35a4ebb9984</KEY> </DELEGATION_KEY> </DATA> </RECORD> @@ -24,8 +24,8 @@ <TXID>3</TXID> <DELEGATION_KEY> <KEY_ID>2</KEY_ID> - <EXPIRY_DATE>1390675042667</EXPIRY_DATE> - <KEY>cc4a64b98b6c8b80</KEY> + <EXPIRY_DATE>1390942564735</EXPIRY_DATE> + <KEY>22391ec22bc0fc20</KEY> </DELEGATION_KEY> </DATA> </RECORD> @@ -37,18 +37,18 @@ <INODEID>16386</INODEID> <PATH>/file_create</PATH> <REPLICATION>1</REPLICATION> - <MTIME>1389983882397</MTIME> - <ATIME>1389983882397</ATIME> + <MTIME>1390251365583</MTIME> + <ATIME>1390251365583</ATIME> <BLOCKSIZE>512</BLOCKSIZE> - <CLIENT_NAME>DFSClient_NONMAPREDUCE_-36724706_1</CLIENT_NAME> + <CLIENT_NAME>DFSClient_NONMAPREDUCE_382541401_1</CLIENT_NAME> <CLIENT_MACHINE>127.0.0.1</CLIENT_MACHINE> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>420</MODE> </PERMISSION_STATUS> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>22</RPC_CALLID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>7</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -59,13 +59,13 @@ <INODEID>0</INODEID> <PATH>/file_create</PATH> <REPLICATION>1</REPLICATION> - <MTIME>1389983882685</MTIME> - <ATIME>1389983882397</ATIME> + <MTIME>1390251365626</MTIME> + <ATIME>1390251365583</ATIME> <BLOCKSIZE>512</BLOCKSIZE> <CLIENT_NAME></CLIENT_NAME> <CLIENT_MACHINE></CLIENT_MACHINE> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>420</MODE> </PERMISSION_STATUS> @@ -78,9 +78,9 @@ <LENGTH>0</LENGTH> <SRC>/file_create</SRC> <DST>/file_moved</DST> - <TIMESTAMP>1389983882713</TIMESTAMP> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>25</RPC_CALLID> + <TIMESTAMP>1390251365645</TIMESTAMP> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>9</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -89,9 +89,9 @@ <TXID>7</TXID> <LENGTH>0</LENGTH> <PATH>/file_moved</PATH> - <TIMESTAMP>1389983882722</TIMESTAMP> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>26</RPC_CALLID> + <TIMESTAMP>1390251365666</TIMESTAMP> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>10</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -101,9 +101,9 @@ <LENGTH>0</LENGTH> <INODEID>16387</INODEID> <PATH>/directory_mkdir</PATH> - <TIMESTAMP>1389983882732</TIMESTAMP> + <TIMESTAMP>1390251365693</TIMESTAMP> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>493</MODE> </PERMISSION_STATUS> @@ -136,8 +136,8 @@ <TXID>12</TXID> <SNAPSHOTROOT>/directory_mkdir</SNAPSHOTROOT> <SNAPSHOTNAME>snapshot1</SNAPSHOTNAME> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>31</RPC_CALLID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>15</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -147,8 +147,8 @@ <SNAPSHOTROOT>/directory_mkdir</SNAPSHOTROOT> <SNAPSHOTOLDNAME>snapshot1</SNAPSHOTOLDNAME> <SNAPSHOTNEWNAME>snapshot2</SNAPSHOTNEWNAME> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>32</RPC_CALLID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>16</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -157,8 +157,8 @@ <TXID>14</TXID> <SNAPSHOTROOT>/directory_mkdir</SNAPSHOTROOT> <SNAPSHOTNAME>snapshot2</SNAPSHOTNAME> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>33</RPC_CALLID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>17</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -169,18 +169,18 @@ <INODEID>16388</INODEID> <PATH>/file_create</PATH> <REPLICATION>1</REPLICATION> - <MTIME>1389983883326</MTIME> - <ATIME>1389983883326</ATIME> + <MTIME>1390251365804</MTIME> + <ATIME>1390251365804</ATIME> <BLOCKSIZE>512</BLOCKSIZE> - <CLIENT_NAME>DFSClient_NONMAPREDUCE_-36724706_1</CLIENT_NAME> + <CLIENT_NAME>DFSClient_NONMAPREDUCE_382541401_1</CLIENT_NAME> <CLIENT_MACHINE>127.0.0.1</CLIENT_MACHINE> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>420</MODE> </PERMISSION_STATUS> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>34</RPC_CALLID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>18</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -191,13 +191,13 @@ <INODEID>0</INODEID> <PATH>/file_create</PATH> <REPLICATION>1</REPLICATION> - <MTIME>1389983883328</MTIME> - <ATIME>1389983883326</ATIME> + <MTIME>1390251365815</MTIME> + <ATIME>1390251365804</ATIME> <BLOCKSIZE>512</BLOCKSIZE> <CLIENT_NAME></CLIENT_NAME> <CLIENT_MACHINE></CLIENT_MACHINE> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>420</MODE> </PERMISSION_STATUS> @@ -253,10 +253,10 @@ <LENGTH>0</LENGTH> <SRC>/file_create</SRC> <DST>/file_moved</DST> - <TIMESTAMP>1389983883464</TIMESTAMP> + <TIMESTAMP>1390251365931</TIMESTAMP> <OPTIONS>NONE</OPTIONS> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>41</RPC_CALLID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>25</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -267,18 +267,18 @@ <INODEID>16389</INODEID> <PATH>/file_concat_target</PATH> <REPLICATION>1</REPLICATION> - <MTIME>1389983883506</MTIME> - <ATIME>1389983883506</ATIME> + <MTIME>1390251365952</MTIME> + <ATIME>1390251365952</ATIME> <BLOCKSIZE>512</BLOCKSIZE> - <CLIENT_NAME>DFSClient_NONMAPREDUCE_-36724706_1</CLIENT_NAME> + <CLIENT_NAME>DFSClient_NONMAPREDUCE_382541401_1</CLIENT_NAME> <CLIENT_MACHINE>127.0.0.1</CLIENT_MACHINE> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>420</MODE> </PERMISSION_STATUS> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>43</RPC_CALLID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>27</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -383,8 +383,8 @@ <INODEID>0</INODEID> <PATH>/file_concat_target</PATH> <REPLICATION>1</REPLICATION> - <MTIME>1389983884500</MTIME> - <ATIME>1389983883506</ATIME> + <MTIME>1390251366514</MTIME> + <ATIME>1390251365952</ATIME> <BLOCKSIZE>512</BLOCKSIZE> <CLIENT_NAME></CLIENT_NAME> <CLIENT_MACHINE></CLIENT_MACHINE> @@ -404,7 +404,7 @@ <GENSTAMP>1003</GENSTAMP> </BLOCK> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>420</MODE> </PERMISSION_STATUS> @@ -418,18 +418,18 @@ <INODEID>16390</INODEID> <PATH>/file_concat_0</PATH> <REPLICATION>1</REPLICATION> - <MTIME>1389983884503</MTIME> - <ATIME>1389983884503</ATIME> + <MTIME>1390251366533</MTIME> + <ATIME>1390251366533</ATIME> <BLOCKSIZE>512</BLOCKSIZE> - <CLIENT_NAME>DFSClient_NONMAPREDUCE_-36724706_1</CLIENT_NAME> + <CLIENT_NAME>DFSClient_NONMAPREDUCE_382541401_1</CLIENT_NAME> <CLIENT_MACHINE>127.0.0.1</CLIENT_MACHINE> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>420</MODE> </PERMISSION_STATUS> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>56</RPC_CALLID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>40</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -534,8 +534,8 @@ <INODEID>0</INODEID> <PATH>/file_concat_0</PATH> <REPLICATION>1</REPLICATION> - <MTIME>1389983884530</MTIME> - <ATIME>1389983884503</ATIME> + <MTIME>1390251366726</MTIME> + <ATIME>1390251366533</ATIME> <BLOCKSIZE>512</BLOCKSIZE> <CLIENT_NAME></CLIENT_NAME> <CLIENT_MACHINE></CLIENT_MACHINE> @@ -555,7 +555,7 @@ <GENSTAMP>1006</GENSTAMP> </BLOCK> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>420</MODE> </PERMISSION_STATUS> @@ -569,18 +569,18 @@ <INODEID>16391</INODEID> <PATH>/file_concat_1</PATH> <REPLICATION>1</REPLICATION> - <MTIME>1389983884533</MTIME> - <ATIME>1389983884533</ATIME> + <MTIME>1390251366746</MTIME> + <ATIME>1390251366746</ATIME> <BLOCKSIZE>512</BLOCKSIZE> - <CLIENT_NAME>DFSClient_NONMAPREDUCE_-36724706_1</CLIENT_NAME> + <CLIENT_NAME>DFSClient_NONMAPREDUCE_382541401_1</CLIENT_NAME> <CLIENT_MACHINE>127.0.0.1</CLIENT_MACHINE> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>420</MODE> </PERMISSION_STATUS> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>68</RPC_CALLID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>52</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -685,8 +685,8 @@ <INODEID>0</INODEID> <PATH>/file_concat_1</PATH> <REPLICATION>1</REPLICATION> - <MTIME>1389983884560</MTIME> - <ATIME>1389983884533</ATIME> + <MTIME>1390251366795</MTIME> + <ATIME>1390251366746</ATIME> <BLOCKSIZE>512</BLOCKSIZE> <CLIENT_NAME></CLIENT_NAME> <CLIENT_MACHINE></CLIENT_MACHINE> @@ -706,7 +706,7 @@ <GENSTAMP>1009</GENSTAMP> </BLOCK> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>420</MODE> </PERMISSION_STATUS> @@ -718,13 +718,13 @@ <TXID>56</TXID> <LENGTH>0</LENGTH> <TRG>/file_concat_target</TRG> - <TIMESTAMP>1389983884587</TIMESTAMP> + <TIMESTAMP>1390251366802</TIMESTAMP> <SOURCES> <SOURCE1>/file_concat_0</SOURCE1> <SOURCE2>/file_concat_1</SOURCE2> </SOURCES> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>79</RPC_CALLID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>63</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -735,15 +735,15 @@ <INODEID>16392</INODEID> <PATH>/file_symlink</PATH> <VALUE>/file_concat_target</VALUE> - <MTIME>1389983884610</MTIME> - <ATIME>1389983884610</ATIME> + <MTIME>1390251366811</MTIME> + <ATIME>1390251366811</ATIME> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>511</MODE> </PERMISSION_STATUS> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>80</RPC_CALLID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>64</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -754,18 +754,18 @@ <INODEID>16393</INODEID> <PATH>/hard-lease-recovery-test</PATH> <REPLICATION>1</REPLICATION> - <MTIME>1389983884634</MTIME> - <ATIME>1389983884634</ATIME> + <MTIME>1390251366819</MTIME> + <ATIME>1390251366819</ATIME> <BLOCKSIZE>512</BLOCKSIZE> - <CLIENT_NAME>DFSClient_NONMAPREDUCE_-36724706_1</CLIENT_NAME> + <CLIENT_NAME>DFSClient_NONMAPREDUCE_382541401_1</CLIENT_NAME> <CLIENT_MACHINE>127.0.0.1</CLIENT_MACHINE> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>420</MODE> </PERMISSION_STATUS> - <RPC_CLIENTID>6ea2f8e1-8436-477e-b691-6daf7146bf79</RPC_CLIENTID> - <RPC_CALLID>81</RPC_CALLID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>65</RPC_CALLID> </DATA> </RECORD> <RECORD> @@ -821,40 +821,121 @@ <OPCODE>OP_REASSIGN_LEASE</OPCODE> <DATA> <TXID>64</TXID> - <LEASEHOLDER>DFSClient_NONMAPREDUCE_-36724706_1</LEASEHOLDER> + <LEASEHOLDER>DFSClient_NONMAPREDUCE_382541401_1</LEASEHOLDER> <PATH>/hard-lease-recovery-test</PATH> <NEWHOLDER>HDFS_NameNode</NEWHOLDER> </DATA> </RECORD> <RECORD> - <OPCODE>OP_CLOSE</OPCODE> + <OPCODE>OP_SET_GENSTAMP_V2</OPCODE> <DATA> <TXID>65</TXID> + <GENSTAMPV2>1012</GENSTAMPV2> + </DATA> + </RECORD> + <RECORD> + <OPCODE>OP_REASSIGN_LEASE</OPCODE> + <DATA> + <TXID>66</TXID> + <LEASEHOLDER>HDFS_NameNode</LEASEHOLDER> + <PATH>/hard-lease-recovery-test</PATH> + <NEWHOLDER>HDFS_NameNode</NEWHOLDER> + </DATA> + </RECORD> + <RECORD> + <OPCODE>OP_CLOSE</OPCODE> + <DATA> + <TXID>67</TXID> <LENGTH>0</LENGTH> <INODEID>0</INODEID> <PATH>/hard-lease-recovery-test</PATH> <REPLICATION>1</REPLICATION> - <MTIME>1389983888641</MTIME> - <ATIME>1389983884634</ATIME> + <MTIME>1390251371402</MTIME> + <ATIME>1390251366819</ATIME> <BLOCKSIZE>512</BLOCKSIZE> <CLIENT_NAME></CLIENT_NAME> <CLIENT_MACHINE></CLIENT_MACHINE> <BLOCK> <BLOCK_ID>1073741834</BLOCK_ID> <NUM_BYTES>11</NUM_BYTES> - <GENSTAMP>1011</GENSTAMP> + <GENSTAMP>1012</GENSTAMP> </BLOCK> <PERMISSION_STATUS> - <USERNAME>jing</USERNAME> + <USERNAME>andrew</USERNAME> <GROUPNAME>supergroup</GROUPNAME> <MODE>420</MODE> </PERMISSION_STATUS> </DATA> </RECORD> <RECORD> + <OPCODE>OP_ADD_CACHE_POOL</OPCODE> + <DATA> + <TXID>68</TXID> + <POOLNAME>pool1</POOLNAME> + <OWNERNAME>andrew</OWNERNAME> + <GROUPNAME>andrew</GROUPNAME> + <MODE>493</MODE> + <LIMIT>9223372036854775807</LIMIT> + <MAXRELATIVEEXPIRY>2305843009213693951</MAXRELATIVEEXPIRY> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>73</RPC_CALLID> + </DATA> + </RECORD> + <RECORD> + <OPCODE>OP_MODIFY_CACHE_POOL</OPCODE> + <DATA> + <TXID>69</TXID> + <POOLNAME>pool1</POOLNAME> + <LIMIT>99</LIMIT> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>74</RPC_CALLID> + </DATA> + </RECORD> + <RECORD> + <OPCODE>OP_ADD_CACHE_DIRECTIVE</OPCODE> + <DATA> + <TXID>70</TXID> + <ID>1</ID> + <PATH>/path</PATH> + <REPLICATION>1</REPLICATION> + <POOL>pool1</POOL> + <EXPIRATION>2305844399465065912</EXPIRATION> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>75</RPC_CALLID> + </DATA> + </RECORD> + <RECORD> + <OPCODE>OP_MODIFY_CACHE_DIRECTIVE</OPCODE> + <DATA> + <TXID>71</TXID> + <ID>1</ID> + <REPLICATION>2</REPLICATION> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>76</RPC_CALLID> + </DATA> + </RECORD> + <RECORD> + <OPCODE>OP_REMOVE_CACHE_DIRECTIVE</OPCODE> + <DATA> + <TXID>72</TXID> + <ID>1</ID> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>77</RPC_CALLID> + </DATA> + </RECORD> + <RECORD> + <OPCODE>OP_REMOVE_CACHE_POOL</OPCODE> + <DATA> + <TXID>73</TXID> + <POOLNAME>pool1</POOLNAME> + <RPC_CLIENTID>ff209a09-9745-4242-837f-21c6b95a1b70</RPC_CLIENTID> + <RPC_CALLID>78</RPC_CALLID> + </DATA> + </RECORD> + <RECORD> <OPCODE>OP_END_LOG_SEGMENT</OPCODE> <DATA> - <TXID>66</TXID> + <TXID>74</TXID> </DATA> </RECORD> </EDITS>
Added: hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testCacheAdminConf.xml URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testCacheAdminConf.xml?rev=1560522&view=auto ============================================================================== --- hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testCacheAdminConf.xml (added) +++ hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testCacheAdminConf.xml Wed Jan 22 21:43:00 2014 @@ -0,0 +1,493 @@ +<?xml version="1.0" encoding="UTF-8"?> +<?xml-stylesheet type="text/xsl" href="testConf.xsl"?> + +<!-- + 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. +--> + +<configuration> + <!-- Normal mode is test. To run just the commands and dump the output + to the log, set it to nocompare --> + <mode>test</mode> + + <!-- Comparator types: + ExactComparator + SubstringComparator + RegexpComparator + TokenComparator + --> + <tests> + + <test> <!--Tested --> + <description>Testing basic usage</description> + <test-commands> + <cache-admin-command></cache-admin-command> + </test-commands> + <cleanup-commands> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Usage: bin/hdfs cacheadmin [COMMAND]</expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing listing no cache pools</description> + <test-commands> + <cache-admin-command>-listPools</cache-admin-command> + </test-commands> + <cleanup-commands> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 0 results.</expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing adding a cache pool</description> + <test-commands> + <cache-admin-command>-addPool foo</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool foo</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Successfully added cache pool foo.</expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing modifying a cache pool</description> + <test-commands> + <cache-admin-command>-addPool poolparty -owner alice -group alicegroup -mode 0000 -limit 50</cache-admin-command> + <cache-admin-command>-modifyPool poolparty -owner bob -group bobgroup -mode 0777 -limit 51</cache-admin-command> + <cache-admin-command>-listPools</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool poolparty</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>poolparty bob bobgroup rwxrwxrwx 51</expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing deleting a cache pool</description> + <test-commands> + <cache-admin-command>-addPool foo</cache-admin-command> + <cache-admin-command>-removePool foo</cache-admin-command> + </test-commands> + <cleanup-commands> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Successfully removed cache pool foo.</expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing listing all cache pools</description> + <test-commands> + <cache-admin-command>-addPool foo -owner bob -group bob -mode 0664</cache-admin-command> + <cache-admin-command>-addPool bar -owner alice -group alicegroup -mode 0755</cache-admin-command> + <cache-admin-command>-listPools</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool foo</cache-admin-command> + <cache-admin-command>-removePool bar</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 2 results.</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output>bar alice alicegroup rwxr-xr-x unlimited</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output>foo bob bob rw-rw-r-- unlimited</expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing listing a single cache pool</description> + <test-commands> + <cache-admin-command>-addPool foo -owner bob -group bob -mode 0664</cache-admin-command> + <cache-admin-command>-addPool bar -owner alice -group alicegroup -mode 0755</cache-admin-command> + <cache-admin-command>-listPools foo</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool foo</cache-admin-command> + <cache-admin-command>-removePool bar</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 1 result.</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output>foo bob bob rw-rw-r-- unlimited</expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing creating cache paths</description> + <test-commands> + <cache-admin-command>-addPool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool1 -ttl 2d</cache-admin-command> + <cache-admin-command>-addDirective -path /bar -pool pool1 -ttl 24h</cache-admin-command> + <cache-admin-command>-addDirective -path /baz -replication 2 -pool pool1 -ttl 60m</cache-admin-command> + <cache-admin-command>-listDirectives -pool pool1</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool pool1</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 3 entries</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output> 1 pool1 1</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output> 2 pool1 1</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output> 3 pool1 2 </expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing removing cache paths</description> + <test-commands> + <cache-admin-command>-addPool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /bar -pool pool1</cache-admin-command> + <cache-admin-command>-removePool pool1</cache-admin-command> + <cache-admin-command>-listDirectives -pool pool1</cache-admin-command> + </test-commands> + <cleanup-commands> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 0 entries</expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing listing directives filtered by pool</description> + <test-commands> + <cache-admin-command>-addPool pool1</cache-admin-command> + <cache-admin-command>-addPool pool2</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /bar -pool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /baz -pool pool2</cache-admin-command> + <cache-admin-command>-addDirective -path /buz -pool pool2</cache-admin-command> + <cache-admin-command>-listDirectives -pool pool2</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool pool1</cache-admin-command> + <cache-admin-command>-removePool pool2</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 2 entries</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output> 8 pool2 1 never /baz </expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output> 9 pool2 1 never /buz </expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing listing directives filtered by path</description> + <test-commands> + <cache-admin-command>-addPool pool1</cache-admin-command> + <cache-admin-command>-addPool pool2</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /bar -pool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool2</cache-admin-command> + <cache-admin-command>-addDirective -path /bar -pool pool2</cache-admin-command> + <cache-admin-command>-listDirectives -path /foo</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool pool1</cache-admin-command> + <cache-admin-command>-removePool pool2</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 2 entries</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output> 10 pool1 1 never /foo </expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output> 12 pool2 1 never /foo </expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing listing directives filtered by path and pool</description> + <test-commands> + <cache-admin-command>-addPool pool1</cache-admin-command> + <cache-admin-command>-addPool pool2</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /bar -pool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool2</cache-admin-command> + <cache-admin-command>-addDirective -path /bar -pool pool2</cache-admin-command> + <cache-admin-command>-listDirectives -path /foo -pool pool2</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool pool1</cache-admin-command> + <cache-admin-command>-removePool pool2</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 1 entry</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output> 16 pool2 1 never /foo </expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing removing a directive</description> + <test-commands> + <cache-admin-command>-addPool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /bar -pool pool1</cache-admin-command> + <cache-admin-command>-removeDirective 18</cache-admin-command> + <cache-admin-command>-listDirectives</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool pool1</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 1 entry</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output> 19 pool1 1 never /bar </expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing removing every directive for a path</description> + <test-commands> + <cache-admin-command>-addPool pool1</cache-admin-command> + <cache-admin-command>-addPool pool2</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /bar -pool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool2</cache-admin-command> + <cache-admin-command>-addDirective -path /bar -pool pool2</cache-admin-command> + <cache-admin-command>-removeDirectives -path ../../foo</cache-admin-command> + <cache-admin-command>-listDirectives</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool pool1</cache-admin-command> + <cache-admin-command>-removePool pool2</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 2 entries</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output> 22 pool1 1 never /bar </expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output> 24 pool2 1 never /bar </expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing modifying directives</description> + <test-commands> + <cache-admin-command>-addPool pool1</cache-admin-command> + <cache-admin-command>-addPool pool2</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool2</cache-admin-command> + <cache-admin-command>-modifyDirective -id 25 -path /bar2</cache-admin-command> + <cache-admin-command>-modifyDirective -id 25 -pool pool1 -path /bar3</cache-admin-command> + <cache-admin-command>-listDirectives -path /bar3</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool pool1</cache-admin-command> + <cache-admin-command>-removePool pool2</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 1 entry</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output> 25 pool1 1 never /bar3 </expected-output> + </comparator> + </comparators> + </test> + + <test> + <description>Testing the help usage</description> + <test-commands> + <cache-admin-command>-help addPool</cache-admin-command> + </test-commands> + <cleanup-commands> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Add a new cache pool.</expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing listing cache pool statistics</description> + <test-commands> + <cache-admin-command>-addPool foo -owner bob -group bob -mode 0664</cache-admin-command> + <cache-admin-command>-addPool bar -owner alice -group alicegroup -mode 0755</cache-admin-command> + <cache-admin-command>-listPools -stats</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool foo</cache-admin-command> + <cache-admin-command>-removePool bar</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 2 results.</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output>bar alice alicegroup rwxr-xr-x unlimited never 0 0 0 0 0</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output>foo bob bob rw-rw-r-- unlimited never 0 0 0 0 0</expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing listing cache directive statistics</description> + <test-commands> + <cache-admin-command>-addPool pool1</cache-admin-command> + <cache-admin-command>-addDirective -path /foo -pool pool1 -ttl 2d</cache-admin-command> + <cache-admin-command>-addDirective -path /bar -pool pool1 -ttl 24h</cache-admin-command> + <cache-admin-command>-addDirective -path /baz -replication 2 -pool pool1 -ttl 60m</cache-admin-command> + <cache-admin-command>-listDirectives -pool pool1 -stats</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool pool1</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 3 entries</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output>/foo 0 0 0 0</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output>/bar 0 0 0 0</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output>/baz 0 0 0 0</expected-output> + </comparator> + </comparators> + </test> + + <test> <!--Tested --> + <description>Testing pool max ttl settings</description> + <test-commands> + <cache-admin-command>-addPool pool1 -owner andrew -group andrew</cache-admin-command> + <cache-admin-command>-addPool pool2 -owner andrew -group andrew -maxTtl 999d</cache-admin-command> + <cache-admin-command>-modifyPool pool2 -maxTtl never</cache-admin-command> + <cache-admin-command>-addPool pool3 -owner andrew -group andrew -maxTtl 4h</cache-admin-command> + <cache-admin-command>-listPools</cache-admin-command> + </test-commands> + <cleanup-commands> + <cache-admin-command>-removePool pool1</cache-admin-command> + </cleanup-commands> + <comparators> + <comparator> + <type>SubstringComparator</type> + <expected-output>Found 3 results</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output>pool1 andrew andrew rwxr-xr-x unlimited never</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output>pool2 andrew andrew rwxr-xr-x unlimited never</expected-output> + </comparator> + <comparator> + <type>SubstringComparator</type> + <expected-output>pool3 andrew andrew rwxr-xr-x unlimited 000:04:00:00.000</expected-output> + </comparator> + </comparators> + </test> + </tests> +</configuration> Propchange: hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testCacheAdminConf.xml ------------------------------------------------------------------------------ svn:eol-style = native Modified: hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testHDFSConf.xml URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testHDFSConf.xml?rev=1560522&r1=1560521&r2=1560522&view=diff ============================================================================== --- hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testHDFSConf.xml (original) +++ hadoop/common/branches/branch-2/hadoop-hdfs-project/hadoop-hdfs/src/test/resources/testHDFSConf.xml Wed Jan 22 21:43:00 2014 @@ -16524,7 +16524,7 @@ </comparators> </test> - <test> <!--Tested --> + <test> <!--Tested --> <description>Verifying clrSpaceQuota operation is not permitted in safemode</description> <test-commands> <command>-fs NAMENODE -mkdir /test </command>