Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Download record range flag #2411

Merged
merged 23 commits into from
Jan 30, 2025
Merged

Download record range flag #2411

merged 23 commits into from
Jan 30, 2025

Conversation

jace-roell
Copy link
Contributor

@jace-roell jace-roell commented Jan 15, 2025

What It Does
Added --recordRange to zowe jobs download output command

How to Test
Run command 'zowe jobs download o "" --rr "0-100"` against a valid job
Where 0 is the start of the spool and 100 is the end (zero-indexed)

Review Checklist
I certify that I have:

Signed-off-by: jace-roell <jace.roell@hotmail.com>
Signed-off-by: jace-roell <jace.roell@hotmail.com>
Signed-off-by: jace-roell <jace.roell@hotmail.com>
jace-roell and others added 6 commits January 15, 2025 14:24
Signed-off-by: jace-roell <jace.roell@hotmail.com>
Signed-off-by: jace-roell <jace.roell@hotmail.com>
Signed-off-by: jace-roell <jace.roell@hotmail.com>
Signed-off-by: jace-roell <jace.roell@hotmail.com>
Signed-off-by: jace-roell <jace.roell@hotmail.com>
@jace-roell jace-roell marked this pull request as ready for review January 15, 2025 20:53
Copy link

📅 Suggested merge-by date: 1/29/2025

Copy link

codecov bot commented Jan 15, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.36%. Comparing base (af0c3ba) to head (fec6759).
Report is 24 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #2411   +/-   ##
=======================================
  Coverage   91.35%   91.36%           
=======================================
  Files         639      639           
  Lines       18269    18283   +14     
  Branches     3844     3850    +6     
=======================================
+ Hits        16690    16704   +14     
  Misses       1577     1577           
  Partials        2        2           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Signed-off-by: jace-roell <jace.roell@hotmail.com>
Signed-off-by: jace-roell <jace.roell@hotmail.com>
Signed-off-by: jace-roell <jace.roell@hotmail.com>
Signed-off-by: jace-roell <jace.roell@hotmail.com>
Copy link
Member

@gejohnston gejohnston left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggested an extra confirmation for some of your tests.
Give some consideration to whether it would be helpful.
Either way I approve this PR.

jace-roell and others added 3 commits January 17, 2025 10:33
Signed-off-by: jace-roell <jace.roell@hotmail.com>
Signed-off-by: jace-roell <jace.roell@hotmail.com>
Copy link

Reminder: This pull request has a merge-by date coming up within the next 24 hours. Please review this PR as soon as possible.

@t1m0thyj @zFernand0 @pujal0909 @traeok @ATorrise

Copy link
Member

@traeok traeok left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and functionality LGTM, thanks Jace!

I'm wondering if we should support for this argument to the zowe jobs view spool-file-by-id command as well? CLI users will likely want the record range for a specific job spool rather than for all spool files. For example, let's say you want to get the record range "50-75" for the 3rd spool file in the job - when running the download command w/ record range, that range doesn't exist for the 2nd spool file, so it returns an error:

image

Since we use GetJobs.getSpoolContentById instead of DownloadJobs.downloadSpoolContentCommon for that command though, it may involve some refactoring, and I don't want to add scope creep. Curious to get your thoughts on this @adam-wolfe, this could be addressed separately if we want to avoid increasing scope - I will approve the PR for now as this behavior is valid when expecting a record range that doesn't exist for all spool files.

Copy link
Member

@zFernand0 zFernand0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Functionality LGTM! 😋

Can we add an example of this new option?


Also...
Not sure if this is fixed on another PR already, but...
I'm getting these file changes (mostly license headers being updated being)

On branch download-record-range
Your branch is up to date with 'origin/download-record-range'.

Changes not staged for commit:
  (use "git add <file>..." to update what will be committed)
  (use "git restore <file>..." to discard changes in working directory)
        modified:   packages/imperative/src/utilities/__tests__/DeferredPromise.unit.test.ts
        modified:   packages/imperative/src/utilities/src/DeferredPromise.ts

jace-roell and others added 2 commits January 29, 2025 16:35
Signed-off-by: Jace Roell <111985297+jace-roell@users.noreply.github.com>
Signed-off-by: jace-roell <jace.roell@hotmail.com>
Copy link
Member

@zFernand0 zFernand0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 😋

Thanks for addressing the feedback so quickly 🙏

Just waiting for CI to finish.
Then lets have a merge-party and combine a few PRs 🥳


Be on the lookout for unit and integration test snapshots 😋

@zFernand0 zFernand0 self-requested a review January 29, 2025 22:03
jace-roell and others added 4 commits January 30, 2025 09:02
Signed-off-by: jace-roell <jace.roell@hotmail.com>
…ad-record-range

Signed-off-by: Fernando Rijo Cedeno <37381190+zFernand0@users.noreply.github.com>
Signed-off-by: Fernando Rijo Cedeno <37381190+zFernand0@users.noreply.github.com>
Copy link
Member

@zFernand0 zFernand0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 😋

@zFernand0 zFernand0 merged commit 591ebd5 into master Jan 30, 2025
21 checks passed
@zFernand0 zFernand0 deleted the download-record-range branch January 30, 2025 15:42
@zFernand0 zFernand0 added the release-current Indicates that there is no new functionality being delivered label Jan 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-current Indicates that there is no new functionality being delivered
Projects
Status: Closed
Development

Successfully merging this pull request may close these issues.

5 participants