Project

General

Profile

Actions

Task #22284

open

Task #21306: Dismiss HomeLIbrary webapp

The home library is still referenced by the `.Rprofile` distributed into the rstudio servers

Added by Andrea Dell'Amico 3 months ago. Updated about 2 months ago.

Status:
Feedback
Priority:
Normal
Assignee:
_InfraScience Systems Engineer
Category:
content-management
Start date:
Nov 29, 2021
Due date:
% Done:

100%

Estimated time:
(Total: 0.00 h)

Description

The code snippet:

  if (g[1]>0){
    workspaceurl<<-"https://workspace-repository.dev.d4science.org/home-library-webapp"
  }else{workspaceurl<<-"https://workspace-repository.d4science.org/home-library-webapp"}

The repository is <//svn.d4science.research-infrastructures.eu/gcube/trunk/data-analysis/RConfiguration/RStudioConfiguration>


Files

Rprofile2 (2.02 KB) Rprofile2 Gianpaolo Coro, Nov 29, 2021 11:44 AM

Subtasks


Related issues

Related to gCube - Feature #7961: Change the R-connector to read/write the userconfig.csv file from a different pathFeedbackAndrea Dell'AmicoApr 03, 2017

Actions
Actions #1

Updated by Lucio Lelii 2 months ago

  • Priority changed from Normal to High
Actions #2

Updated by Andrea Dell'Amico about 2 months ago

  • Priority changed from High to Urgent

Gianpaolo Coro this is getting urgent, the home library service is going to be shut down in a few days.

Actions #3

Updated by Gianpaolo Coro about 2 months ago

Sorry, I lost track of the activities on the new HL. I guess it won't be just a matter of substituting the workspace URL, unless the new service is backward compatible, otherwise all code should be changed.

Is there any Wiki page I can start from to see if a code mapping can be done? Based on that I could plan the modifications and development time.

Actions #4

Updated by Lucio Lelii about 2 months ago

the new service is not backward compatible, with the old home library.
You can found the storagehub rest api here: https://gcube.wiki.gcube-system.org/gcube/StorageHub_REST_API.

Actions #5

Updated by Pasquale Pagano about 2 months ago

Gianpaolo Coro, Emmanuel implemented a R package to interact with the StorageHub
https://github.com/eblondel/d4storagehub4R

It is exploited in some of the iMarine and Blue-Cloud VREs. Since Emmanuel is publishing it on CRAN, we may use that one instead of implementing again the R interface to the storage hub. At first look, it does not implement all the operations. We can either contribute to it or request to Emmanuel to complete it.

What do you think?

Actions #6

Updated by Gianpaolo Coro about 2 months ago

this is a good idea. I can ask when the missing functions will be available, and meanwhile add them to the RProfile by myself. I just have some doubts on the sustainability of this library: if the workspace interface will change in the future, will the library be updated accordingly?

Actions #7

Updated by Pasquale Pagano about 2 months ago

we should remember to ask for changes and until Emmanuel will be member of one or more projects and activities, I am confident that he will maintain the library.
Can we make a pull request to add the missing functions instead of adding them to the rprofile?

Actions #8

Updated by Andrea Dell'Amico about 2 months ago

Pasquale Pagano wrote in #note-7:

we should remember to ask for changes and until Emmanuel will be member of one or more projects and activities, I am confident that he will maintain the library.
Can we make a pull request to add the missing functions instead of adding them to the rprofile?

I second that. It's the cleanest approach, and a R module can be used outside of rstudio (shiny, for example).

Using that module, is a copy of the users' token in a local file still necessary? If not it should be better remove the userconfig.csv file altogether. If it must remain instead, we'll proceed to move it into a different location. And it will be removed when a session ends.

Actions #9

Updated by Andrea Dell'Amico about 2 months ago

  • Related to Feature #7961: Change the R-connector to read/write the userconfig.csv file from a different path added
Actions #11

Updated by Gianpaolo Coro about 2 months ago

The file was conceived to make RStudio agnostic with respect to knowledge about the infrastructure working modes. I think that the user should be aware of this information anyway, should (s)he want to interact with the infrastructure in a more advanced way.
Anyway, I agree with the externalization of the library with respect to RStudio. Thus we could remove it from the RProfile and alert the users (through the disclaimer) about the availability of a package on the GitHub and CRAN for interacting with the WS.

Actions #12

Updated by Andrea Dell'Amico about 2 months ago

Gianpaolo Coro wrote in #note-11:

The file was conceived to make RStudio agnostic with respect to knowledge about the infrastructure working modes. I think that the user should be aware of this information anyway, should (s)he want to interact with the infrastructure in a more advanced way.

The file is a (mild) security problem, so if we can do without it I'm happy. If not, we'll try to manage it better than we are currently doing.

Anyway, I agree with the externalization of the library with respect to RStudio. Thus we could remove it from the RProfile and alert the users (through the disclaimer) about the availability of a package on the GitHub and CRAN for interacting with the WS.

The package will be installed on all the rstudio instances. If the CRAN adoption goes well, we should also have a .deb available on the Ubuntu 18.04+ distributions.

Actions #13

Updated by Gianpaolo Coro about 2 months ago

I have done a comparison between my code and Emmanuel's code. It seems Emmanuel did a direct "traslation" of my code to the new StorageHub interface. The only missing crucial function is the delete function, which I think he did not report on purpose. The issue with the current GitHub version is that is requires newer versions of

sodium  (1.1   -> 1.2.0) 
mime    (0.11  -> 0.12 ) 
keyring (1.1.0 -> 1.2.0)

Can we install them or should we ask Emmanuel to update his repository?

To go forward with this ticket I would suggest the following:

1 - Andrea substitutes the previous .Rprofile with the new attached one (which contains the line to install the package from the GitHub and suggests to use the local workspace folder)
2 - I open a ticket to Emmanuel to ask adding the delete function (and suggesting the code to use) and checking the package on our RStudio instances.

Actions #14

Updated by Andrea Dell'Amico about 2 months ago

Gianpaolo Coro wrote in #note-13:

I have done a comparison between my code and Emmanuel's code. It seems Emmanuel did a direct "traslation" of my code to the new StorageHub interface. The only missing crucial function is the delete function, which I think he did not report on purpose. The issue with the current GitHub version is that is requires newer versions of

sodium  (1.1   -> 1.2.0) 
mime    (0.11  -> 0.12 ) 
keyring (1.1.0 -> 1.2.0)

Can we install them or should we ask Emmanuel to update his repository?

Updating the repository it's better, so that the correct dependencies are installed together with the main packages.

To go forward with this ticket I would suggest the following:

1 - Andrea substitutes the previous .Rprofile with the new attached one (which contains the line to install the package from the GitHub and suggests to use the local workspace folder)

The Emmanuel's package will be installed globally, so I would replace the lines

print(paste("You can access, read and write any folder of your workspace by installing the following package:"))
print(paste("install_github("library(devtools)")))
print(paste("install_github("eblondel/d4storagehub4R")"))

with

print(paste("You can access, read and write any folder of your workspace"))
print(paste("by loading the package 'd4storagehub4R'"))
Actions #15

Updated by Gianpaolo Coro about 2 months ago

OK for the modifications, I proceed with asking Emmanuel through a ticket.

Actions #16

Updated by Andrea Dell'Amico about 2 months ago

FYI: I'll move the subversion repository that hosts the Rprofile from subversion to git.

Actions #17

Updated by Gianpaolo Coro about 2 months ago

just one thing: since now the original repository is hidden, we should acknowledge Emmanuel's work with this additional line:

print(paste("developed by E. Blondel, with source code available at https://github.com/eblondel/d4storagehub4R"))
Actions #18

Updated by Andrea Dell'Amico about 2 months ago

The new Rprofile.site is stored here: https://code-repo.d4science.org/gCubeSystem/rstudio-rprofile.

I assume that we can remove the userconfig.csv file then?

Actions #19

Updated by Andrea Dell'Amico about 2 months ago

  • Status changed from New to In Progress
  • Assignee changed from Gianpaolo Coro to _InfraScience Systems Engineer

I'm going to install the new Rprofile.site into all the rstudio instances.

Actions #20

Updated by Andrea Dell'Amico about 2 months ago

  • Status changed from In Progress to Feedback

Done.

Actions

Also available in: Atom PDF