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

DM-25806: Support parallel ap_verify ingestion in Gen 3 #102

Merged
merged 7 commits into from Sep 21, 2020

Conversation

kfindeisen
Copy link
Member

This PR implements multiprocessing in Gen3DatasetIngestTask after adding basic value support to the Dataset and Workspace classes to make them more unit-test-friendly. This required some refactoring of ap_verify's command-line argument parser.

The parser will hold common arguments that aren't related to I/O.
To keep parser use in same module as parser definitions, processes
are now passed by main program to pipeline driver.
Copy link
Contributor

@isullivan isullivan left a comment

Choose a reason for hiding this comment

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

Looks great.

copy = pickle.loads(stream)
self.assertEqual(self.task.getFullName(), copy.getFullName())
self.assertEqual(self.task.log.getName(), copy.log.getName())
# Equality for config ill-behaved; skip it
Copy link
Contributor

Choose a reason for hiding this comment

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

This is a minor nitpick, but could you rephrase this comment? "Skip it" suggests to me that code including a test for equality of the config is present and is skipped, while what is happening here is that code doesn't exist (for a good reason). Maybe something like "Do not test equality for the config because it is ill-behaved"?

Copy link
Member Author

Choose a reason for hiding this comment

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

IIRC Config.__eq__ does exist, but it doesn't handle ConfigurableField very well. I probably should have filed a bug report, but was too distracted at the time.

tests/test_workspace.py Outdated Show resolved Hide resolved
tests/test_workspace.py Outdated Show resolved Hide resolved
Pickle support is needed to be able to run ingestion in parallel.
This passes the argument to all ingestion tasks that support the
processes keyword.
@kfindeisen kfindeisen merged commit dae8935 into master Sep 21, 2020
@kfindeisen kfindeisen deleted the tickets/DM-25806 branch September 21, 2020 21:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants