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

Fix data sync request model; Add find_filesystem_boundary utility #15

Merged
merged 2 commits into from
Nov 7, 2024

Conversation

njmei
Copy link
Collaborator

@njmei njmei commented Nov 4, 2024

See commit messages for details

@njmei njmei force-pushed the fix-data-sync-request-model branch from 35e76ff to d491a85 Compare November 5, 2024 08:33
@njmei njmei force-pushed the fix-data-sync-request-model branch 2 times, most recently from 5cd42a0 to dca355c Compare November 5, 2024 18:33
@njmei njmei force-pushed the fix-data-sync-request-model branch 2 times, most recently from 3a507fd to 57dba3e Compare November 7, 2024 19:07
njmei added 2 commits November 7, 2024 11:09
The previous version of this model returned `config` and `task`
properties that did not follow typing properly.

This commit attempts to fix things by making the `config` and `task`
properties return the correct "types". It also adds in missing
fields in the `DataSyncConfig` model.

This commit also adds a new field to the `DataSyncConfig` model
called `remote_to_local_config` which allows more fine-grained
controlled over remote (S3) to local filesystem transfers. Specifically,
the temporary location where data sync operations download individual objects.

Fix
@njmei njmei force-pushed the fix-data-sync-request-model branch from 57dba3e to 2e58893 Compare November 7, 2024 19:10
Copy link
Collaborator

@rpmcginty rpmcginty left a comment

Choose a reason for hiding this comment

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

I left a nit comment, but let me know your thoughts

@@ -104,17 +121,33 @@ class DataSyncConfig(SchemaModel):
force: bool = custom_field(default=False, mm_field=BooleanField())
size_only: bool = custom_field(default=False, mm_field=BooleanField())
fail_if_missing: bool = custom_field(default=True, mm_field=BooleanField())
remote_to_local_config: RemoteToLocalConfig = custom_field(
Copy link
Collaborator

@rpmcginty rpmcginty Nov 7, 2024

Choose a reason for hiding this comment

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

nit: do you think for the sake of making clean serialized content, we make this config optional? and just having a getter to return a default object instead if not specified?

Copy link
Collaborator

Choose a reason for hiding this comment

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

I just worry about the size of the serialized object if we do this.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

The RemoteToLocalConfig is not that big. If we do end up hitting an issue in the future with this, bring up this thread and I will own up to it!

@njmei njmei merged commit 01335ae into main Nov 7, 2024
4 checks passed
@njmei njmei deleted the fix-data-sync-request-model branch November 7, 2024 20:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants