Opened 11 years ago

Closed 11 years ago

#506 closed defect (fixed)

Installation wizard doesn't check if biomaterial list is shared

Reported by: Nicklas Nordborg Owned by: olle
Priority: minor Milestone: Reggie v2.13
Component: net.sf.basedb.reggie Keywords:
Cc:

Description

The installation wizard create the "Flagged RNA" biomaterial list (empty to begin with). However, it doesn't check (or fix) that the list is shared to the scan-b project as it does for other item.

Workaround is to manually share the list to scan-b if it is not already shared.

Change History (5)

comment:1 by olle, 11 years ago

Owner: changed from Nicklas Nordborg to olle

comment:2 by olle, 11 years ago

Status: newassigned

Ticket accepted.

comment:3 by olle, 11 years ago

Problem discussion:

  • The installation wizard is managed by Java servlet InstallServlet.java in reggie/src/net/sf/basedb/reggie/servlet/, where BioMaterial lists are managed by public methods

    BioMaterialList createBioMaterialList(SessionControl sc, BiomaterialList def)
    and
    JSONObject checkBioMaterialList(DbControl dc, BiomaterialList list, boolean createIfMissing)

    Neither method accepts input permission options.

  • Similar methods for other items, i.e. Tag createTag(...) and JSONObject checkTag(...), accept argument PermissionOptions permissions for applying permission options, which in calls can be used with value effectiveOptions, defined by

    PermissionOptions effectiveOptions = sharedToActiveProject == null ? sharedToPatientCurator : sharedToActiveProject;

Proposed solution:

  • Public methods BioMaterialList createBioMaterialList(...) and JSONObject checkBioMaterialList(...) are updated to accept new argument PermissionOptions permissions, and process it in a manner analogous to that in methods Tag createTag(...) and JSONObject checkTag(...), respectively. The call to method checkBioMaterialList(...) in protected method void doGet(HttpServletRequest req, HttpServletResponse resp) is updated with new argument effectiveOptions.

comment:4 by olle, 11 years ago

Test of code changes:

  • Test setup: On a test system, log-in to Reggie was performed with root permissions. BioMaterial list item Flagged RNA was manually removed from sharing for the active project SCAN-B. When the Reggie Installation wizard was opened, a warning sign was displayed for the Flagged RNA item, with the message "Not shared to project: SCAN-B (use)". After clicking on the "Fix items" button, the warning icon was changed to a check mark, and the message to "Fixed". Inspection of the properties for the Flagged RNA item, showed that it was shared to the active project SCAN-B.
  • Result: The test was successful with passed result.

comment:5 by olle, 11 years ago

Resolution: fixed
Status: assignedclosed

(In [2038]) Fixes #506. Installation wizard updated to check if biomaterial is shared to active project.

  1. Java servlet InstallServlet.java in reggie/src/net/sf/basedb/reggie/servlet/ updated in public methods BioMaterialList createBioMaterialList(...) and JSONObject checkBioMaterialList(...) to accept new argument PermissionOptions permissions, and process it in a manner analogous to that in methods Tag createTag(...) and JSONObject checkTag(...), respectively. The call to method checkBioMaterialList(...) in protected method void doGet(HttpServletRequest req, HttpServletResponse resp) is updated with new argument effectiveOptions.

Note: See TracTickets for help on using tickets.