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

add Private URL feature #3111

Merged
merged 23 commits into from
Jul 18, 2016
Merged

add Private URL feature #3111

merged 23 commits into from
Jul 18, 2016

Conversation

pdurbin
Copy link
Member

@pdurbin pdurbin commented May 10, 2016

First, please read the Business Requirements Document (BRD): https://docs.google.com/document/d/1FT47QkZKcmjSgRnePaJO2g1nzcotLyN3Yb2ORvBr6cs/edit?usp=sharing

Then, please read the Private URL design document, which explains edge cases and expected behavior: https://github.com/IQSS/dataverse/blob/b62959884ad8deb06a7135e485517672eb3c6fdf/doc/Architecture/privateurl.md

Four API endpoints have been added and documented at https://github.com/IQSS/dataverse/blob/b62959884ad8deb06a7135e485517672eb3c6fdf/doc/sphinx-guides/source/api/native-api.rst and they should be tested along with the more GUI-oriented descriptions above:

  • List all the role assignments at the given dataset
  • Create a Private URL (must be able to manage dataset permissions)
  • Get a Private URL from a dataset (if available)
  • Delete a Private URL from a dataset (if it exists)

In order to deploy this code you must run the sql script provided: https://github.com/IQSS/dataverse/blob/b62959884ad8deb06a7135e485517672eb3c6fdf/scripts/database/upgrades/privateurl.sql

@posixeleni has been waiting for me to create a branch in the main repo before documenting the Private URL feature in the User Guide so please pass the pull request to her after testing is complete. Update: this was done in #3138.

@scolapasta @michbarsinai I'm still wondering if we should use a ":" or not in the RoleAssignee identifier. Please see my comments and javadoc at

* @todo Consider using a new character such as "#" (as suggested by

@scolapasta once you have decided which version this feature will land in, we need to add the content of privateurl.sql to the official database migration script for that release. It's my understanding that the Private URL feature is slated for 4.5. Thanks, @kcondon for reminding me of this task. Update: this was done in 95570c7

RFI Checklist

1. Related Issues


2. Pull Request Checklist


3. Review Checklist

After the pull request has been submitted, fill out this section.

  • Code review completed or waived
  • Testing requirements completed
  • Usability testing completed or waived
  • Support testing completed or waived
  • Merged with develop branch and resolved conflicts

Requires scripts/database/upgrades/privateurl.sql

Design doc at doc/Architecture/privateurl.md

New API endpoints: doc/sphinx-guides/source/api/native-api.rst

Requires scripts/database/upgrades/privateurl.sql

Design doc at doc/Architecture/privateurl.md

New API endpoints: doc/sphinx-guides/source/api/native-api.rst
@pdurbin pdurbin changed the title add Private URL feature #1012 add Private URL feature May 10, 2016
@pdurbin
Copy link
Member Author

pdurbin commented May 12, 2016

The merging of several pull requests yesterday has resulted in the message, "This branch has conflicts that must be resolved." I'm stealing this pull request back to resolve merge conflicts.

murphy:dataverse pdurbin$ git merge develop
Auto-merging src/main/webapp/dataset.xhtml
Auto-merging src/main/java/edu/harvard/iq/dataverse/search/SearchServiceBean.java
Auto-merging src/main/java/edu/harvard/iq/dataverse/RolePermissionFragment.java
CONFLICT (content): Merge conflict in src/main/java/edu/harvard/iq/dataverse/RolePermissionFragment.java
Auto-merging src/main/java/edu/harvard/iq/dataverse/ManagePermissionsPage.java
CONFLICT (content): Merge conflict in src/main/java/edu/harvard/iq/dataverse/ManagePermissionsPage.java
Auto-merging src/main/java/edu/harvard/iq/dataverse/DatasetPage.java
Auto-merging src/main/java/Bundle.properties
Automatic merge failed; fix conflicts and then commit the result.
murphy:dataverse pdurbin$ 

@pdurbin pdurbin self-assigned this May 12, 2016
Conflicts with #3108 (3089-jsoup):
src/main/java/edu/harvard/iq/dataverse/ManagePermissionsPage.java
src/main/java/edu/harvard/iq/dataverse/RolePermissionFragment.java

- All AssignRoleCommand constructors need privateUrlToken parameter.
@pdurbin
Copy link
Member Author

pdurbin commented May 12, 2016

I just merged "develop" into the branch this pull request is based on and resolved merge conflicts in dd6ceb1 which has details (nothing big). Passing to QA.

@pdurbin pdurbin assigned kcondon and unassigned pdurbin May 12, 2016
@coveralls
Copy link

Coverage Status

Coverage increased (+0.5%) to 5.547% when pulling dd6ceb1 on 1012-private-url into be5b26e on develop.

@kcondon kcondon assigned scolapasta and unassigned kcondon May 17, 2016
@kcondon
Copy link
Contributor

kcondon commented May 17, 2016

passing to Gustavo for code review

@pdurbin
Copy link
Member Author

pdurbin commented May 17, 2016

@scolapasta here's a comment from @michbarsinai 'Little nitpicking regarding the comment at line 37 - ":" means "built-in" rather than "user". E.g. :authenticated-users. I'm also leaning towards using some other character, maybe "#"? In fact, even "P" will do.'

- Merged 313317a from develop into dd6ceb1
- Use UtilIt.grantRoleOnDataverse from develop.
- Add Javadoc `throws` warning to
  RoleAssigneeServiceBean.getRoleAssignee
- Check for null and empty string in getRoleAssignee
- Catch EJBException in AbstractApiBean.findAssign

Conflicts:

- src/main/java/edu/harvard/iq/dataverse/RoleAssigneeServiceBean.java
- src/test/java/edu/harvard/iq/dataverse/api/UtilIT.java
@coveralls
Copy link

Coverage Status

Coverage increased (+0.5%) to 5.664% when pulling 0c17116 on 1012-private-url into 313317a on develop.

Merged into 2935cde from "develop" into 0c17116 from "1012-private-url".

Conflicts (accepted both, not a big deal):
src/main/java/Bundle.properties
@coveralls
Copy link

Coverage Status

Coverage increased (+0.5%) to 5.657% when pulling 4b64230 on 1012-private-url into 2935cde on develop.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.5%) to 5.657% when pulling c4c7902 on 1012-private-url into 2935cde on develop.

@pdurbin pdurbin added this to the 4.5 milestone Jun 22, 2016
@coveralls
Copy link

Coverage Status

Coverage increased (+0.5%) to 5.657% when pulling 95570c7 on 1012-private-url into 2935cde on develop.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.5%) to 5.657% when pulling 9480a63 on 1012-private-url into 2935cde on develop.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.5%) to 5.656% when pulling 50ae521 on 1012-private-url into 2935cde on develop.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.5%) to 5.658% when pulling 9816361 on 1012-private-url into 47b04ed on develop.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.5%) to 5.658% when pulling 4015d35 on 1012-private-url into 47b04ed on develop.

@pdurbin
Copy link
Member Author

pdurbin commented Jul 8, 2016

@kcondon found bugs #3200 and #3201 (thanks!) which I consider show stoppers so I'm pulling this out of QA.

@pdurbin pdurbin assigned pdurbin and unassigned kcondon Jul 8, 2016
@pdurbin
Copy link
Member Author

pdurbin commented Jul 13, 2016

@scolapasta I need a ruling on the two proposed fixes described at #3200 (comment) so I'm assigning this pull request to you for code review.

@pdurbin pdurbin assigned scolapasta and unassigned pdurbin Jul 13, 2016
@pdurbin
Copy link
Member Author

pdurbin commented Jul 14, 2016

@scolapasta and @michbarsinai blessed the fix at 24df280 so I merged it into this pull request. Passing to QA.

@pdurbin pdurbin assigned kcondon and unassigned scolapasta Jul 14, 2016
@coveralls
Copy link

Coverage Status

Coverage increased (+0.5%) to 5.657% when pulling dd9eb97 on 1012-private-url into dcea42d on develop.

@kcondon kcondon merged commit 52170ba into develop Jul 18, 2016
@pdurbin pdurbin deleted the 1012-private-url branch July 21, 2016 20:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants