Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
816 commits
Select commit Hold shift + click to select a range
c5ae899
testBlobRenameServerReturnsOneBlobPerList
saxenapranav Jun 21, 2023
137eca9
renameBlobExecutorService shutdown if any future task fail
saxenapranav Jun 21, 2023
997127c
Merge branch 'ABFS_3.3.2_dev_rename_improvements' into ABFS_3.3.2_dev…
saxenapranav Jun 21, 2023
740e312
added for deletion
saxenapranav Jun 21, 2023
3cc8c69
when renameDir fails, release srcDir lease.
saxenapranav Jun 22, 2023
a47a508
refactors
saxenapranav Jun 22, 2023
8de26ce
SOURCE_PATH_NOT_FOUND in case src is not present
saxenapranav Jun 22, 2023
51e7e5a
refactors + test adjustments
saxenapranav Jun 22, 2023
14050c1
no need of blobListProperties in RenameAtomicityUtil; general refactors
saxenapranav Jun 22, 2023
7430b1e
testParallelBlobLeaseOnChildBlobInRenameSrcDir only on blob
saxenapranav Jun 22, 2023
aafc099
refactor
saxenapranav Jun 22, 2023
21e4e26
Merge pull request #13 from saxenapranav/ABFS_3.3.2_dev_rename_major_…
saxenapranav Jun 22, 2023
7bfc8a7
Merge branch 'ABFS_3.3.2_dev_rename_improvements' into ABFS_3.3.2_dev…
saxenapranav Jun 23, 2023
f0b75b7
Merge pull request #69 from ABFSDriver/unifyFallbackDependentAPI
anmolanmol1234 Jun 23, 2023
a1aaf42
refactor code
saxenapranav Jun 23, 2023
4a5702e
wip
saxenapranav Jun 23, 2023
b8b1ef0
testBlobAtomicRenameSrcAndDstAreNotLeftLeased
saxenapranav Jun 23, 2023
b5ec70d
Merge branch 'ABFS_3.3.2_dev' into ABFS_3.3.2_dev_rename_improvements
saxenapranav Jun 23, 2023
3e8207e
remove extra line in import
saxenapranav Jun 23, 2023
fbfe195
Merge pull request #52 from saxenapranav/ABFS_3.3.2_dev_rename_improv…
saxenapranav Jun 23, 2023
a3e1ab3
answer argument number
saxenapranav Jun 23, 2023
a1dfa72
Merge branch 'ABFS_3.3.2_dev' into ABFS_3.3.2_dev_delete
saxenapranav Jun 23, 2023
fa0f560
refactor + added logs
saxenapranav Jun 23, 2023
d539191
Merge pull request #66 from ABFSDriver/operativeParam
anmolanmol1234 Jun 23, 2023
4a0b6a3
Merge conflict fix
anmolanmol1234 Jun 23, 2023
d70d0f8
for root, if non-recursive, return false; added javadocs; removal of …
saxenapranav Jun 23, 2023
d130a3b
place executorservice at right place
saxenapranav Jun 23, 2023
0201aee
undo line removal
saxenapranav Jun 23, 2023
2575fe1
test if LMT changed by server; producer to spawn only if nextMarker i…
saxenapranav Jun 24, 2023
7df7df9
Merge branch 'ABFS_3.3.2_dev_delete' into ABFS_3.3.2_dev_rename_tc
saxenapranav Jun 26, 2023
82acd68
Merge pull request #73 from ABFSDriver/mergeConflictFix
anmolanmol1234 Jun 26, 2023
673b0f9
test wip
saxenapranav Jun 26, 2023
81e0b9e
throw exception if non HTTP_NOT_FOUND statusCode exception
saxenapranav Jun 26, 2023
8b317d6
Acl API's to go to DFS endpoint
anmolanmol1234 Jun 26, 2023
922bf7a
javadocs; variables for common path refs
saxenapranav Jun 26, 2023
972cd91
reasoning for deleteRoot on dfs
saxenapranav Jun 26, 2023
29e5fa4
create parent directory after deletion of given path is done
saxenapranav Jun 26, 2023
f961b26
Supporting Container APIs over Blob Endpoint
Jun 13, 2023
567f247
Added Test
Jun 14, 2023
04dbf9b
Added javadoc
Jun 14, 2023
88a82c1
Get-SetXAttr() On Root Path
Jun 14, 2023
fd6df8f
SetXAttr() over implict path
Jun 16, 2023
755f30d
Test Fix
Jun 19, 2023
39bf55f
small refactors
saxenapranav Jun 26, 2023
12d151a
Logging for fallback
anmolanmol1234 Jun 26, 2023
5d8c507
Fix for without NS
anmolanmol1234 Jun 26, 2023
725d645
string.format
saxenapranav Jun 26, 2023
adfe943
Merge pull request #15 from saxenapranav/ABFS_3.3.2_dev_delete_review
saxenapranav Jun 26, 2023
2db8f04
correct javadocs of createParentDirectory
saxenapranav Jun 26, 2023
c75ffe4
Fallback for Create Filesystem
Jun 26, 2023
aef4fd6
special test + Logging
Jun 15, 2023
ec86e0a
List Status Optimized for Directory Cases
Jun 27, 2023
a8783f2
Merge branch 'ABFS_3.3.2_dev_delete' into ABFS_3.3.2_dev_rename_tc
saxenapranav Jun 27, 2023
0121d15
Addressed Comments
Jun 27, 2023
d82d633
Test fix
anmolanmol1234 Jun 27, 2023
2fa7551
Test fix
anmolanmol1234 Jun 27, 2023
1934658
PR comments
anmolanmol1234 Jun 27, 2023
70be95e
testDeleteEmitDeletionCountInClientRequestId
saxenapranav Jun 27, 2023
182c20f
GFS changed to GetFileStatus
anmolanmol1234 Jun 27, 2023
641a84b
testRenameSrcDirDeleteEmitDeletionCountInClientRequestId
saxenapranav Jun 27, 2023
3c9cd6c
Merge pull request #75 from ABFSDriver/unifyFallback
anmolanmol1234 Jun 27, 2023
1b07214
refactors on pr review: reduce logs; add comment; general refactors
saxenapranav Jun 27, 2023
f17f305
Merge branch 'ABFS_3.3.2_dev' of https://github.com/ABFSDriver/AbfsHa…
anmolanmol1234 Jun 27, 2023
7962853
Addressing Comments
Jun 27, 2023
dedf460
Removed log for delete of non-heirarichal path
saxenapranav Jun 27, 2023
3f43135
Test fix
anmolanmol1234 Jun 27, 2023
61a0149
Addressing Comments
Jun 27, 2023
174482b
Operation type fix for throttling
anmolanmol1234 Jun 27, 2023
3439b1b
Merge branch 'ABFS_3.3.2_dev_delete' into ABFS_3.3.2_dev_rename_tc
saxenapranav Jun 27, 2023
609d65d
refactor argument number and added assertion in testIfTracingContextP…
saxenapranav Jun 27, 2023
ed7d6aa
Merge pull request #72 from saxenapranav/ABFS_3.3.2_dev_delete
saxenapranav Jun 27, 2023
e990af4
Merge branch 'ABFS_3.3.2_dev' of https://github.com/ABFSDriver/AbfsHa…
anmolanmol1234 Jun 27, 2023
4f3e47c
testIfTracingContextPrimaryIdIsSameInAllTheStepsOfBlobDelete
saxenapranav Jun 27, 2023
643c10f
testBlobRenameResumeWithListStatus
saxenapranav Jun 27, 2023
2e9f1ab
testBlobRenameResumeWithGetFileStatus
saxenapranav Jun 27, 2023
1607a11
require primary key in getFileStatus
saxenapranav Jun 27, 2023
b92b0e5
Addressing Comments
Jun 27, 2023
1d4b6ba
release all lease after rename failure
saxenapranav Jun 28, 2023
62da06c
Merge pull request #71 from ABFSDriver/listStatusFollowUp
anujmodi2021 Jun 28, 2023
460fd86
concurrency in lease release
saxenapranav Jun 28, 2023
886fc27
Addressing PR comments
anmolanmol1234 Jun 28, 2023
b834e17
Addressing Comments
Jun 28, 2023
a516cea
Addressing Comments
Jun 28, 2023
8ac9a2e
Merge pull request #74 from ABFSDriver/aclApi
anmolanmol1234 Jun 28, 2023
14bd13a
Merge pull request #70 from ABFSDriver/containerAPIsBlob
anujmodi2021 Jun 28, 2023
c35c714
remove non-required imports
saxenapranav Jun 28, 2023
8bde5da
added javadocs on the added tests.
saxenapranav Jun 28, 2023
024b451
Refactor to bring out common functionality into methods; aggregate si…
saxenapranav Jun 29, 2023
ee5ffeb
Added rId in exception message
Jun 29, 2023
d3f489c
Added Tests
Jun 29, 2023
8bc5caa
Removed Unwanted Changes'
Jun 29, 2023
e3c79f9
Removed Unwanted Changes'
Jun 29, 2023
dc68b9f
Removed Unwanted Changes'
Jun 29, 2023
163acdf
Removed Unwanted Changes'
Jun 29, 2023
ba4e015
Tests fix
anmolanmol1234 Jun 29, 2023
60e44f9
Removed Unwanted Changes'
Jun 29, 2023
904e9af
Filesystem initialize to false
anmolanmol1234 Jun 29, 2023
395f069
Merge pull request #78 from ABFSDriver/checkAccessFix
anmolanmol1234 Jun 29, 2023
a943c31
Abfs 3.3.2 dev tc review (#16)
saxenapranav Jun 29, 2023
89c655d
Merge pull request #77 from ABFSDriver/activityIdIEx
anujmodi2021 Jun 29, 2023
b29e301
Merge pull request #76 from saxenapranav/ABFS_3.3.2_dev_rename_tc
saxenapranav Jun 29, 2023
7126061
Merge branch 'ABFS_3.3.2_dev' into ABFS_3.3.2_dev_append_bug
saxenapranav Jun 30, 2023
a081ea5
javadocs on how it catch exception on async write in hsync, hflush, c…
saxenapranav Jun 30, 2023
2ced7c4
craeteDirectory in store to have additional field: checkParentChain
saxenapranav Jun 30, 2023
104b1f8
add mocks for client.createPath where mocks of client.createBlobPath …
saxenapranav Jun 30, 2023
e7369a4
testDeleteCheckIfParentLMTChange only if no mkdirs or ingress redirect
saxenapranav Jun 30, 2023
68971be
add assumption that no dfs write happen. reason being, it is renamed …
saxenapranav Jun 30, 2023
74f469a
add comments for reason of ignoring testDeleteCheckIfParentLMTChange
saxenapranav Jun 30, 2023
31b21ce
done with javadocs
saxenapranav Jun 30, 2023
0c9a1b0
refactored testIntermittentAppendFailureToBeReported; removed AbfsOut…
saxenapranav Jun 30, 2023
ee5608c
testWriteAsyncOpFailedAfterCloseCalled
saxenapranav Jun 30, 2023
e68b943
areWriteOperationsTasksDone
saxenapranav Jun 30, 2023
694294e
testWriteAsyncOpFailedAfterCloseCalled need to have blob mockito as well
saxenapranav Jun 30, 2023
fdb85d8
Exception fix
anmolanmol1234 Jun 30, 2023
de051f5
Merge pull request #79 from ABFSDriver/exceptionFix
anmolanmol1234 Jun 30, 2023
3db45a3
remove additional code space.
saxenapranav Jul 3, 2023
fb13e0c
Merge pull request #80 from saxenapranav/ABFS_3.3.2_dev_delete_mkdirDFS
saxenapranav Jul 3, 2023
75b04ac
Merge pull request #68 from saxenapranav/ABFS_3.3.2_dev_append_bug
saxenapranav Jul 4, 2023
d8e64e3
Update userAgent
anmolanmol1234 Jul 4, 2023
6ab5f9a
Merge pull request #81 from ABFSDriver/updateUserAgent
anmolanmol1234 Jul 4, 2023
5d52da3
consumer failure should stop producer
saxenapranav Jul 18, 2023
2d506f5
Refactored getFileStatus and ListStatus call
sreeb-msft Jul 18, 2023
60bd772
condition change in producer loop
saxenapranav Jul 19, 2023
27f2e22
testProducerStopOnConsumerFailure
saxenapranav Jul 19, 2023
168257e
test for rename producer failure
saxenapranav Jul 19, 2023
8e993be
checkstyle basic refactor of renameTest class; add of test for produc…
saxenapranav Jul 19, 2023
5194e32
listBlobQueue not to have synchronized methods
saxenapranav Jul 19, 2023
109a0ba
changed signature to bring it to redo method
saxenapranav Jul 20, 2023
e585777
flowing etag in renameAtomicUtils to write to JSON; read from JSON
saxenapranav Jul 24, 2023
1ad1c02
etag check before redo
saxenapranav Jul 24, 2023
3156efd
redo method doesn't need etag; tests wip
saxenapranav Jul 24, 2023
5563827
added tests
saxenapranav Jul 24, 2023
08606b4
quote or unquote the etag
saxenapranav Jul 24, 2023
38b6dfa
javadocs changes
saxenapranav Jul 24, 2023
77ec128
try saving listStatus call if nothing changed
saxenapranav Jul 24, 2023
bab6499
asssertion if the listStatus API of FS will give correct result when …
saxenapranav Jul 24, 2023
546e1d1
Added tests
sreeb-msft Jul 24, 2023
1dd8204
added a comment on leaseAcquire catch in redo method
saxenapranav Jul 25, 2023
5a7028c
no uri change pass. client will use correct uri as per the client met…
saxenapranav Jul 25, 2023
a60f79b
added conversion for missed methods
saxenapranav Jul 25, 2023
ca83aa3
Removed getClient change
sreeb-msft Jul 25, 2023
9155d9a
creatFile Optimization
Jul 25, 2023
de39dc8
removed TODOs
Jul 25, 2023
afbdddf
Added asserts in tests
sreeb-msft Jul 25, 2023
3d04da3
renamePendingJSON in listStatus to be searched only if its atomicDire…
saxenapranav Jul 25, 2023
c55ee8f
Refactored directory check
sreeb-msft Jul 25, 2023
1ad46eb
Update UserAgent
sreeb-msft Jul 25, 2023
660d4ef
Updated perf tracking
sreeb-msft Jul 25, 2023
e858497
Merge pull request #84 from saxenapranav/ABFS_3.3.2_dev_procuder_impr…
saxenapranav Jul 25, 2023
cafcad9
removed redundant code
sreeb-msft Jul 25, 2023
d9a38b8
added tests; to take qualified path uri for checking if its atomic in…
saxenapranav Jul 25, 2023
fbf0a24
Merge branch 'ABFS_3.3.2_dev' into ABFS_3.3.2_dev_redo_optimization_r…
saxenapranav Jul 25, 2023
14104c1
line spacing refactor
saxenapranav Jul 25, 2023
22d0ff3
Updated perf tracking
sreeb-msft Jul 25, 2023
62c26d6
Merge pull request #86 from ABFSDriver/julyImprov
anujmodi2021 Jul 26, 2023
a660122
HADOOP-17682. ABFS: Support FileStatus input to OpenFileWithOptions()…
sumangala-patki Aug 18, 2021
08b8c79
listStatus and getFileStatus will open the inputStream and send for r…
saxenapranav Jul 26, 2023
aa2d21d
modified time to check the number of invocation of getFileStatus in t…
saxenapranav Jul 26, 2023
2a8ca8b
Merge pull request #82 from ABFSDriver/refactor-getFileStatus
sreeb-msft Jul 26, 2023
e69321e
directly calling store.openWithOptions from listStatus/getFileStatus;…
saxenapranav Jul 26, 2023
9be288b
testRefator
saxenapranav Jul 26, 2023
f326e52
Merge branch 'ABFS_3.3.2_dev' into ABFS_3.3.2_dev_redo_optimization_f…
saxenapranav Jul 26, 2023
dd12da4
for fileStatus of renamePendingJson, we will only call getPathProperty.
saxenapranav Jul 26, 2023
549285d
invocation of getPathProperty instead of getFileStatus
saxenapranav Jul 26, 2023
b76972e
fix tests in ITestAzureBlobFileSystemFileStatus
saxenapranav Jul 27, 2023
1f77da6
fileStatus.getpath().toUri().getPathh() extract variable for reuse
saxenapranav Jul 27, 2023
680f18c
filePathStr = qualifiedPath.toUri().getPath() instead of path.toUri()…
saxenapranav Jul 27, 2023
af95e4a
Addressed comments
sreeb-msft Jul 27, 2023
d2d1fbf
Tests for FileAlreadyEcists exception added
sreeb-msft Jul 27, 2023
b5ccf1c
Modified test condition for all configs
sreeb-msft Jul 27, 2023
04990df
Merge pull request #87 from ABFSDriver/refactor-directory-check
sreeb-msft Jul 27, 2023
6fc5975
Merge pull request #85 from saxenapranav/ABFS_3.3.2_dev_redo_optimiza…
saxenapranav Jul 27, 2023
d487a89
Test changes
sreeb-msft Jul 27, 2023
11e233e
Test failure fixes
sreeb-msft Jul 27, 2023
e61df14
Merge branch 'ABFS_3.3.2_dev' into noUriChange
saxenapranav Jul 28, 2023
f7a44f8
Added testGetFileStatusReturnStatusWithPathWithSameUriGivenInConfig
saxenapranav Jul 28, 2023
b529b36
listStatus tests
saxenapranav Jul 28, 2023
e2d95bb
copyBlob src to have correct dns
saxenapranav Jul 28, 2023
99986e9
Test changes based on configs
sreeb-msft Jul 28, 2023
5e09d06
refactored test: change fs.defaultFs in test for any config.
saxenapranav Jul 31, 2023
5c7e59d
correct dnsAssertion
saxenapranav Jul 31, 2023
44a60a4
test fix wip
saxenapranav Jul 31, 2023
fcaf788
Cloning abfsConfig instance for tests
sreeb-msft Jul 31, 2023
1d0a302
test refactors
saxenapranav Jul 31, 2023
94fa7dd
fixed remaining breaking tests
saxenapranav Jul 31, 2023
f29aea5
Test changes
sreeb-msft Jul 31, 2023
b5a93fd
Merge pull request #88 from ABFSDriver/refactor-directory-check
sreeb-msft Aug 1, 2023
9a5956c
Merge branch 'ABFS_3.3.2_dev' into noUriChange
saxenapranav Aug 1, 2023
4c68725
changePrefixFromDfsToBlob to have new url obj only if url given is in…
saxenapranav Aug 1, 2023
bcc47b6
return on WASB_DNS_PREFIX
saxenapranav Aug 1, 2023
9097fb4
refactor ITestAzureBlobFileSystemCheckAccess
saxenapranav Aug 1, 2023
7fad094
indentation in ITestBlobOperation
saxenapranav Aug 1, 2023
13247fd
Test changes
sreeb-msft Aug 2, 2023
973430d
taken code review suggestions; code refactor
saxenapranav Aug 4, 2023
dc880b6
code refactor: move methods to one place
saxenapranav Aug 4, 2023
6c59ba4
Merge pull request #89 from saxenapranav/noUriChange
anmolanmol1234 Aug 7, 2023
a0a55f7
Merge pull request #90 from ABFSDriver/read-blob-test-fix
anmolanmol1234 Aug 7, 2023
765d466
Length and lock fix
anmolanmol1234 Aug 7, 2023
9a88e4f
Lock fixes
anmolanmol1234 Aug 7, 2023
3541bb4
Fixes as discussed
anmolanmol1234 Aug 7, 2023
750a90e
Flush with position
anmolanmol1234 Aug 7, 2023
5ec1480
Root Ops Fix
Aug 8, 2023
d2cf4e5
Trace enabled
anmolanmol1234 Aug 8, 2023
ea4ecdd
Addresing Comments
Aug 8, 2023
9b27e3f
Reverting back Status code change
Aug 8, 2023
f8b2e56
Merge pull request #92 from ABFSDriver/rootOperationFix
anujmodi2021 Aug 10, 2023
daef8a1
User Agent expect
anmolanmol1234 Aug 11, 2023
9bcd024
Test for userAgent
anmolanmol1234 Aug 11, 2023
fc1d6f7
User Agent dynamic change
anmolanmol1234 Aug 11, 2023
1db897e
PR comments
anmolanmol1234 Aug 11, 2023
9560700
String fix
anmolanmol1234 Aug 11, 2023
66a0a61
String fix for test
anmolanmol1234 Aug 11, 2023
fd6972d
String fixes
anmolanmol1234 Aug 11, 2023
1a938a7
Merge pull request #91 from ABFSDriver/lockFix
anmolanmol1234 Aug 11, 2023
493b5e3
BlobErrorMessageXmlParser. Blob endpoint gives error in XML format.
saxenapranav Aug 11, 2023
d47ccc0
User agent update
anmolanmol1234 Aug 11, 2023
d971292
keeping parsing simple
saxenapranav Aug 11, 2023
28a888d
javadocs; constants refactor
saxenapranav Aug 11, 2023
1d2d037
basic refactoring
saxenapranav Aug 14, 2023
b9f941f
added test. basic method restructuring in abfsHttpOperation
saxenapranav Aug 14, 2023
f2e58e0
Merge branch 'ABFS_3.3.2_dev' into ABFS_3.3.2_dev_errorMsg
saxenapranav Aug 14, 2023
ea0dfb4
added test for dfs errorStream parsing
saxenapranav Aug 14, 2023
771ac8a
PR comments
anmolanmol1234 Aug 14, 2023
3c08e33
String fix
anmolanmol1234 Aug 14, 2023
4e22860
Merge pull request #93 from ABFSDriver/userAgentFix
anmolanmol1234 Aug 14, 2023
21c133d
Fix failing test
anmolanmol1234 Aug 14, 2023
9fe8c70
Fix numm pointer fir headers
anmolanmol1234 Aug 14, 2023
08f6d95
Merge pull request #96 from ABFSDriver/userAgentFix
anmolanmol1234 Aug 14, 2023
520caf9
Merge branch 'ABFS_3.3.2_dev' of https://github.com/ABFSDriver/AbfsHa…
anmolanmol1234 Aug 14, 2023
d8dc383
remove unused imports
anmolanmol1234 Aug 14, 2023
32ba317
fix for trace
anmolanmol1234 Aug 16, 2023
b36665e
Merge pull request #99 from ABFSDriver/fixForTrace
anmolanmol1234 Aug 16, 2023
3001440
Merge pull request #94 from saxenapranav/ABFS_3.3.2_dev_errorMsg
saxenapranav Aug 16, 2023
7129587
Merge pull request #97 from ABFSDriver/eTagNullPointerFix
anmolanmol1234 Aug 16, 2023
d198451
Fix for list status tracing context fix
Aug 13, 2023
a0f37e8
Addressed Comments
Aug 14, 2023
cbf6305
Removing Unused Imports
Aug 14, 2023
3611ac7
New Tracing Context for each Rest Op
Aug 16, 2023
1974eb7
Fixing Tests
Aug 16, 2023
6c2781b
Fixed Failing Test
Aug 16, 2023
32a3da5
Merging Pranav's PR
Aug 16, 2023
4a1d21d
Resolving Conflict
Aug 16, 2023
25c7f53
Resolving Conflict
Aug 16, 2023
20066f1
Removed Unused Comment
Aug 17, 2023
a2e9e5b
Parallel Op test fix
Aug 17, 2023
294b483
Merge pull request #95 from ABFSDriver/listTracingContextFix
anujmodi2021 Aug 17, 2023
7755236
fs.azure.blob.dir.list.producer.queue.max.size as config instead of f…
saxenapranav Aug 18, 2023
69aa847
Merge pull request #101 from saxenapranav/ABFS_3.3.2_prod_config
saxenapranav Aug 18, 2023
d755d62
Change default to bytebuffer
anmolanmol1234 Aug 18, 2023
5feca47
Merge pull request #102 from ABFSDriver/bytebufferchange
anmolanmol1234 Aug 18, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2319,6 +2319,12 @@
<description>The AbstractFileSystem for gs: uris.</description>
</property>

<property>
<name>fs.azure.enable.readahead</name>
<value>true</value>
<description>Enabled readahead/prefetching in AbfsInputStream.</description>
</property>

<property>
<name>io.seqfile.compress.blocksize</name>
<value>1000000</value>
Expand Down
3 changes: 2 additions & 1 deletion hadoop-tools/hadoop-azure/.gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.checkstyle
bin/
src/test/resources/combinationConfigFiles
src/test/resources/abfs-combination-test-configs.xml
dev-support/testlogs
src/test/resources/accountSettings/*
!src/test/resources/accountSettings/accountName_settings.xml.template
179 changes: 155 additions & 24 deletions hadoop-tools/hadoop-azure/dev-support/testrun-scripts/runtests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

# shellcheck disable=SC2034
# unused variables are global in nature and used in testsupport.sh

test
set -eo pipefail

# Licensed to the Apache Software Foundation (ASF) under one or more
Expand All @@ -22,36 +22,167 @@ set -eo pipefail

# shellcheck disable=SC1091
. dev-support/testrun-scripts/testsupport.sh
init

resourceDir=src/test/resources/
logdir=dev-support/testlogs/
azureTestXml=azure-auth-keys.xml
azureTestXmlPath=$resourceDir$azureTestXml
processCount=8

## SECTION: TEST COMBINATION METHODS

begin
runHNSOAuthTest()
{
accountName=$(xmlstarlet sel -t -v '//property[name = "fs.azure.hnsTestAccountName"]/value' -n $azureTestXmlPath)
PROPERTIES=("fs.azure.account.auth.type")
VALUES=("OAuth")
triggerRun "HNS-OAuth" "$accountName" "$runTest" $processCount "$cleanUpTestContainers"
}

### ADD THE TEST COMBINATIONS BELOW. DO NOT EDIT THE ABOVE LINES.
### THE SCRIPT REQUIRES THE FOLLOWING UTILITIES xmlstarlet AND pcregrep.
runHNSSharedKeyTest()
{
accountName=$(xmlstarlet sel -t -v '//property[name = "fs.azure.hnsTestAccountName"]/value' -n $azureTestXmlPath)
PROPERTIES=("fs.azure.account.auth.type")
VALUES=("SharedKey")
triggerRun "HNS-SharedKey" "$accountName" "$runTest" $processCount "$cleanUpTestContainers"
}

runNonHNSSharedKeyTest()
{
accountName=$(xmlstarlet sel -t -v '//property[name = "fs.azure.nonHnsTestAccountName"]/value' -n $azureTestXmlPath)
PROPERTIES=("fs.azure.account.auth.type")
VALUES=("SharedKey")
triggerRun "NonHNS-SharedKey" "$accountName" "$runTest" $processCount "$cleanUpTestContainers"
}

combination=HNS-OAuth
properties=("fs.azure.abfs.account.name" "fs.azure.test.namespace.enabled"
"fs.azure.account.auth.type")
values=("{account name}.dfs.core.windows.net" "true" "OAuth")
generateconfigs
runNonHNSOAuthTest()
{
accountName=$(xmlstarlet sel -t -v '//property[name = "fs.azure.nonHnsTestAccountName"]/value' -n $azureTestXmlPath)
PROPERTIES=("fs.azure.account.auth.type")
VALUES=("OAuth")
triggerRun "NonHNS-OAuth" "$accountName" "$runTest" $processCount "$cleanUpTestContainers"
}

combination=AppendBlob-HNS-OAuth
properties=("fs.azure.abfs.account.name" "fs.azure.test.namespace.enabled"
"fs.azure.account.auth.type" "fs.azure.test.appendblob.enabled")
values=("{account name}.dfs.core.windows.net" "true" "OAuth" "true")
generateconfigs
runAppendBlobHNSOAuthTest()
{
accountName=$(xmlstarlet sel -t -v '//property[name = "fs.azure.hnsTestAccountName"]/value' -n $azureTestXmlPath)
PROPERTIES=("fs.azure.account.auth.type" "fs.azure.test.appendblob.enabled")
VALUES=("OAuth" "true")
triggerRun "AppendBlob-HNS-OAuth" "$accountName" "$runTest" $processCount "$cleanUpTestContainers"
}

combination=HNS-SharedKey
properties=("fs.azure.abfs.account.name" "fs.azure.test.namespace.enabled" "fs.azure.account.auth.type")
values=("{account name}.dfs.core.windows.net" "true" "SharedKey")
generateconfigs
runTest=false
cleanUpTestContainers=false
echo 'Ensure below are complete before running script:'
echo '1. Account specific settings file is present.'
echo ' Copy accountName_settings.xml.template to accountName_settings.xml'
echo ' where accountName in copied file name should be the test account name without domain'
echo ' (accountName_settings.xml.template is present in src/test/resources/accountName_settings'
echo ' folder. New account settings file to be added to same folder.)'
echo ' Follow instructions in the template to populate settings correctly for the account'
echo '2. In azure-auth-keys.xml, update properties fs.azure.hnsTestAccountName and fs.azure.nonHnsTestAccountName'
echo ' where accountNames should be the test account names without domain'
echo ' '
echo ' '
echo 'Choose action:'
echo '[Note - SET_ACTIVE_TEST_CONFIG will help activate the config for IDE/single test class runs]'
select scriptMode in SET_ACTIVE_TEST_CONFIG RUN_TEST CLEAN_UP_OLD_TEST_CONTAINERS SET_OR_CHANGE_TEST_ACCOUNT PRINT_LOG4J_LOG_PATHS_FROM_LAST_RUN
do
case $scriptMode in
SET_ACTIVE_TEST_CONFIG)
runTest=false
break
;;
RUN_TEST)
runTest=true
read -r -p "Enter parallel test run process count [default - 8]: " processCount
processCount=${processCount:-8}
break
;;
CLEAN_UP_OLD_TEST_CONTAINERS)
runTest=false
cleanUpTestContainers=true
break
;;
SET_OR_CHANGE_TEST_ACCOUNT)
runTest=false
cleanUpTestContainers=false
accountSettingsFile="src/test/resources/azure-auth-keys.xml"
if [[ ! -f "$accountSettingsFile" ]];
then
logOutput "No settings present. Creating new settings file ($accountSettingsFile) from template"
cp src/test/resources/azure-auth-keys.xml.template $accountSettingsFile
fi

combination=NonHNS-SharedKey
properties=("fs.azure.abfs.account.name" "fs.azure.test.namespace.enabled" "fs.azure.account.auth.type")
values=("{account name}.dfs.core.windows.net" "false" "SharedKey")
generateconfigs
vi $accountSettingsFile
exit 0
break
;;
PRINT_LOG4J_LOG_PATHS_FROM_LAST_RUN)
runTest=false
cleanUpTestContainers=false
logFilePaths=/tmp/logPaths
find target/ -name "*output.txt" > $logFilePaths
logOutput "$(cat $logFilePaths)"
rm $logFilePaths
exit 0
break
;;
*) logOutput "ERROR: Invalid selection"
;;
esac
done

## SECTION: COMBINATION DEFINITIONS AND TRIGGER

### DO NOT EDIT THE LINES BELOW.
echo ' '
echo 'Set the active test combination to run the action:'
select combo in HNS-OAuth HNS-SharedKey nonHNS-SharedKey NonHNS-OAuth AppendBlob-HNS-OAuth AllCombinationsTestRun Quit
do
case $combo in
HNS-OAuth)
runHNSOAuthTest
break
;;
HNS-SharedKey)
runHNSSharedKeyTest
break
;;
nonHNS-SharedKey)
runNonHNSSharedKeyTest
break
;;
NonHNS-OAuth)
runNonHNSOAuthTest
break
;;
AppendBlob-HNS-OAuth)
runAppendBlobHNSOAuthTest
break
;;
AllCombinationsTestRun)
if [ $runTest == false ]
then
logOutput "ERROR: Invalid selection for SET_ACTIVE_TEST_CONFIG. This is applicable only for RUN_TEST."
break
fi
runHNSOAuthTest
runHNSSharedKeyTest
runNonHNSSharedKeyTest
runNonHNSOAuthTest
runAppendBlobHNSOAuthTest ## Keep this as the last run scenario always
break
;;
Quit)
exit 0
;;
*) logOutput "ERROR: Invalid selection"
;;
esac
done

runtests "$@"
if [ $runTest == true ]
then
printAggregate
fi
Loading