-
Notifications
You must be signed in to change notification settings - Fork 30
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
Allow directory of payload files #115
base: main
Are you sure you want to change the base?
Conversation
If the payload file is a diretory, load all immediate child files as payloads for the workload.
@@ -120,7 +121,15 @@ public TestResult run() throws Exception { | |||
} | |||
} | |||
else { | |||
producerWorkAssignment.payloadData.add(payloadReader.load(workload.payloadFile)); | |||
File payloadFile = new File(workload.payloadFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Really good idea to re-use the existing filename field, I'd only add that if it contains no files maybe just assert out with "directory was empty" or smth.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you think it's worth it to recursively search the directory? I didn't do it at first just because I wanted to try the idea. I'm not sure what the user would expect.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor change requested
If the payload file is a diretory, load all immediate child files as payloads for the workload.