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

Operator needs to support other creation methods besides 'request_id' #145

Closed
stevekm opened this issue Feb 19, 2020 · 3 comments
Closed
Labels
enhancement New feature or request

Comments

@stevekm
Copy link
Member

stevekm commented Feb 19, 2020

Currently, Operator can only be created with a single request_id;

def __init__(self, operator_name, request_id):

However, we need to be able to create an Operator based on other things like multiple request IDs, run IDs, FileMetadata ID's, etc.. Support for Operator creation from Run ID's will be required for Roslin QC Operator for upcoming release. Future support for multiple request_ids will be required in the future, and support for FileMetadata ID's will be the most flexible.

A suggested Operator implementation would look like this:

class Operator(object):
    def __init__(self, operator_name, request_ids = None, run_ids = None, filemetadata_ids = None):

This will allow Operator's to implement methods to build their inputs from any combination of requests, runs, or files.

@stevekm
Copy link
Member Author

stevekm commented Feb 19, 2020

Another possible solution would be to not use run_ids but instead pass the actual Run queryset. This would make it a lot simpler. This could also be expanded to support a more generic list of database instances (Run, FileMetadata, Port, etc.), and the Operator would use its own internal logic to use each of them for building pipeline input. Since Run and Port are ultimately just a proxy for FileMetadata, I think that FileMetadata should be the base object that the Operator is designed to work with. This would be supported by moving "output metadata" to the FileMetadata table as per #85 and #121

@sivkovic sivkovic added the enhancement New feature or request label Mar 19, 2020
@sivkovic
Copy link
Collaborator

@allanbolipata
Copy link
Collaborator

Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants