You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@airavata.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2020/11/02 19:39:00 UTC

[jira] [Commented] (AIRAVATA-3346) Implement remote FS abstraction of user storage

    [ https://issues.apache.org/jira/browse/AIRAVATA-3346?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17224915#comment-17224915 ] 

ASF subversion and git services commented on AIRAVATA-3346:
-----------------------------------------------------------

Commit a0842917d462afacea34edf8364f138edee28536 in airavata-django-portal-sdk's branch refs/heads/master from Marcus Christie
[ https://gitbox.apache.org/repos/asf?p=airavata-django-portal-sdk.git;h=a084291 ]

AIRAVATA-3346 Restoring user_file_exists


> Implement remote FS abstraction of user storage
> -----------------------------------------------
>
>                 Key: AIRAVATA-3346
>                 URL: https://issues.apache.org/jira/browse/AIRAVATA-3346
>             Project: Airavata
>          Issue Type: Bug
>          Components: Django Portal
>            Reporter: Marcus Christie
>            Assignee: Marcus Christie
>            Priority: Major
>
> Running the Airavata Django portal locally, a developer experiences the portal just like a user of a deployed portal, *except* when it comes to gateway user storage, which is only available on the deployed portal. So for example, on seagrid.org, I can log in, view my experiments, and download my output files. If I run the Airavata Django portal locally and have configured it to connect to the same Keycloak and API server, I can also login and view my experiments, but I can't download my output files (or upload files, or clone experiments, etc.).
> However, there exists a REST API to get and put files into gateway user storage so in theory it should be possible to create a filesystem abstraction, locally, that uses the REST API underneath to make it appear that the user's files are all available.
> The benefit of this is that it opens up local development to be able to test a broader range of use cases. I know when I'm developing the Django portal code, there are some things that are just very hard to test because I don't actually have access to the files locally. Also, for extension developers, this will be helpful too. For example, currently creating a custom output view provider requires using a fake output file to test locally because the data files aren't available.
> This seems like a good option: PyFilesystem2 https://pypi.org/project/fs/
> One thing, we need token based authentication in the REST API, but I've already started work on that in a separate branch.
> Another thing, it could be good to put in this work now since it might ease transitioning to Airavata MFT for the data storage backend. MFT would just be another PyFilesystem2 filesystem implementation.
> h5. TODO
> - [x] Need support for Bearer token authentication so that the REST API can be used directly
> - [x] Update API view function so that they are APIViews and use the Django REST Framework authentication/permission support
> - [x] Implement remote API support in ADP SDK user_storage functions
> -- to get the user storage view working remotely:
> --- [x] user_storage.dir_exists
> --- [x] user_storage.listdir
> --- [x] user_storage.get_file
> --- [x] user_storage.delete_dir
> --- [x] user_storage.create_user_dir
> --- [x] user_storage.save
> -- to get input file upload working remotely:
> --- [x] user_storage.save_input_file
> -- to get experiment data directory creation and launch working remotely:
> --- [x] not on user_storage but ExperimentViewSet.launch
> -- to get experiment cloning working remotely:
> --- [x] not on user_storage but ExperimentViewSet.clone
> - additional user_storage functions
> -- [x] update_file_content
> - [ ] support tus uploads to the remote data store?
> - [x] Bug: infinite loop error when token is invalid
> - [x] factor out common code for calling the remote API in SDK
> - [ ] verify that this works for output view provider
> - [ ] update tutorial
> -- we should be able to open the output file directly, but if output view provider needs to access other files in the experiment data directory then there should be advice on how to use the {{user_storage}} module to access those files



--
This message was sent by Atlassian Jira
(v8.3.4#803005)