Skip to content

Encode volume in DsnGet#get URL (#596) - #600

Merged
frankgiordano merged 1 commit into
zowe:mainfrom
Shaurya2k06:fix/dsn-get-encode-volume-596
Jul 28, 2026
Merged

Encode volume in DsnGet#get URL (#596)#600
frankgiordano merged 1 commit into
zowe:mainfrom
Shaurya2k06:fix/dsn-get-encode-volume-596

Conversation

@Shaurya2k06

Copy link
Copy Markdown
Contributor

Description

This PR addresses #596 by URI-encoding the optional volume segment in DsnGet#get() when building the -(vol)/ path prefix, matching the existing DsnDelete uncataloged-dataset pattern. targetName was already encoded.

What changed

  • DsnGet.java
    • Wrap downloadInputData.getVolume().get() with EncodeUtils.encodeURIComponent before appending to the URL.
  • DsnGetTest.java
    • Add tstDsnGetWithVolumeSuccess asserting https://1:443/zosmf/restfiles/ds/-(VOL001)/TEST.DATASET.

Validation

Ran:

JAVA_HOME=/Library/Java/JavaVirtualMachines/temurin-21.jdk/Contents/Home ./mvnw clean test

Result: 1189 tests run, 0 failures, 0 errors (JDK 21 Temurin).

Closes

Closes #596

Match DsnDelete by URI-encoding the optional volume segment
before building the -(vol)/ path prefix.

Signed-off-by: shaurya2k06 <shaurya2k06@gmail.com>
@frankgiordano
frankgiordano self-requested a review July 28, 2026 12:18
@frankgiordano frankgiordano added enhancement New feature or request Improvement labels Jul 28, 2026
@frankgiordano
frankgiordano merged commit a88239a into zowe:main Jul 28, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request Improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add the missing encodeURIComponent call to the URL in the DsnGet#get() method.

2 participants