Skip to content

Add AccessorConifgs "direction" attribute #39

Open
@mwatts15

Description

@mwatts15

Add an attribute, "direction", to all accessor configs that indicates whether it's for upload, download, or both. Without that, URLConfigs don't really provide enough info for Loaders and Uploaders to determine that they can't upload to or download from a remote based on its AC short of querying the server, which is wasteful if the AC is only ever for one thing or the other. Although other ACs may have such information implicitly based on what type of remote they describe, having the attribute means we can pre-filter generically and avoid different loaders/uploaders all implementing similar logic and ACs adding similar attributes.

  • Add direction attribute to AccessorConfig
  • Define a AccessorDirection enum with the values UPLOAD, DOWNLOAD, BOTH
  • Add direction constructor parameter to AccessorConfig with a default value of AccessorDirection.BOTH
  • Ensure direction is defined in AccessorConfig.__setstate__
  • Add a parameter to owmeta_core.commands.bundle.OWMBundleRemoteAdd.__call__ for the direction

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions