From 5c6f22d62ea9e6fbe4e5411d5934958fcbf15dac Mon Sep 17 00:00:00 2001 From: Mingliang Liu Date: Wed, 31 May 2017 14:55:39 -0700 Subject: [PATCH] HADOOP-14460. Azure: update doc for live and contract tests. Contributed by Mingliang Liu --- .../hadoop-azure/src/site/markdown/index.md | 84 ++++++++++++------- 1 file changed, 53 insertions(+), 31 deletions(-) diff --git a/hadoop-tools/hadoop-azure/src/site/markdown/index.md b/hadoop-tools/hadoop-azure/src/site/markdown/index.md index 1d1274b930d..1dca3b9d8fa 100644 --- a/hadoop-tools/hadoop-azure/src/site/markdown/index.md +++ b/hadoop-tools/hadoop-azure/src/site/markdown/index.md @@ -396,42 +396,64 @@ To resolve this, restart the Azure Emulator. Ensure it v3.2 or later. It's also possible to run tests against a live Azure Storage account by saving a file to `src/test/resources/azure-auth-keys.xml` and setting -`fs.azure.test.account.name` to the name of the storage account. +the name of the storage account and its access key. For example: +```xml + + + + + fs.azure.test.account.name + {ACCOUNTNAME}.blob.core.windows.net + + + fs.azure.account.key.{ACCOUNTNAME}.blob.core.windows.net + {ACCOUNT ACCESS KEY} + + +``` - - - - - fs.azure.account.key.youraccount.blob.core.windows.net - YOUR ACCESS KEY - +To run contract tests, set the WASB file system URI in `src/test/resources/azure-auth-keys.xml` +and the account access key. For example: - - fs.azure.test.account.name - youraccount - - +```xml + + + + + fs.contract.test.fs.wasb + wasb://{CONTAINERNAME}@{ACCOUNTNAME}.blob.core.windows.net + The name of the azure file system for testing. + + + fs.azure.account.key.{ACCOUNTNAME}.blob.core.windows.net + {ACCOUNT ACCESS KEY} + + +``` -To run contract tests add live Azure Storage account by saving a -file to `src/test/resources/azure-auth-keys.xml`. -For example: +Overall, to run all the tests using `mvn test`, a sample `azure-auth-keys.xml` is like following: - - - - - fs.contract.test.fs.wasb - wasb://{CONTAINERNAME}@{ACCOUNTNAME}.blob.core.windows.net - The name of the azure file system for testing. - +```xml + + + + + fs.azure.test.account.name + {ACCOUNTNAME}.blob.core.windows.net + + + fs.azure.account.key.{ACCOUNTNAME}.blob.core.windows.net + {ACCOUNT ACCESS KEY} + + + fs.contract.test.fs.wasb + wasb://{CONTAINERNAME}@{ACCOUNTNAME}.blob.core.windows.net + + +``` - - fs.azure.account.key.{ACCOUNTNAME}.blob.core.windows.net - {ACCOUNTKEY} - - - -DO NOT ADD azure-auth-keys.xml TO REVISION CONTROL. The keys to your Azure +DO NOT ADD `azure-auth-keys.xml` TO REVISION CONTROL. The keys to your Azure Storage account are a secret and must not be shared. +