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

Valkyrie: Hyrax::AdministrativeSet fails to delete fully #5407

Closed
elrayle opened this issue Jan 28, 2022 · 5 comments
Closed

Valkyrie: Hyrax::AdministrativeSet fails to delete fully #5407

elrayle opened this issue Jan 28, 2022 · 5 comments
Labels
Admin Set impacts the Admin Set part of PCDM Model valkyrization

Comments

@elrayle
Copy link
Contributor

elrayle commented Jan 28, 2022

Descriptive summary

When an admin set is created as a Hyrax::AdminstrativeSet and later deleted, it goes through the process without error, but fails to fully delete.

Rationale

Deleting admin sets should work whether the admin set is an Active Fedora admin set or a Valkyrie admin set.

Expected behavior

Deleting an admin set fully deletes the admin set and its access control from the data store and solr.

Actual behavior

Deleting an admin set deletes the admin set from the datastore, but fails to delete it from solr and fails to delete its access control from the datastore.

Steps to reproduce the behavior

Prerequisites:

Configure Hyrax:

  1. Edit /config/initializers/hyrax.rb and set:
  config.collection_model = "Hyrax::PcdmCollection"
  config.query_index_from_valkyrie = true
  config.index_adapter = :solr_index
  1. restart rails app
  2. Make sure regular hyrax-development and hyrax-valkyrie-dev solr cores are running . Your core names may vary depending on how you start them and how they are configured in the app.
  3. Make sure you have access to the datastore (i.e. postgres)

NOTE: For testing of nurax-pg, the solr core is typically named nurax-pg.

Create Admin Set

  1. click button: New Collection
  2. select type: Admin Set
  3. click button: Create Collection
  4. set Title: DELETE ME (or other meaningful name)
  5. click Save
  6. Copy the id from the URL

Verify that the admin set was created in both solr cores with q: title_tesim:DELETE ME (or similar query).
Verify that the admin set and it access control were created in the datastore.

To reproduce:

  1. Navigate to: Dashboard -> Collections
  2. Click on the title of the admin set you want to delete (e.g. DELETE ME)
  3. click button: Delete

Verify that the admin set was deleted from both solr cores with q: title_tesim:DELETE ME (or similar query).
Verify that the admin set and it's access control were created in the datastore.

Related work

See related issues in Issue #5326 UBER: Hyrax-Valkyrization MVP
See Issue #5331 describing the same issue for Hyrax::PcdmCollection

@no-reply
Copy link
Contributor

looks like this behavior should get added to the AdminSetDestroy transaction.

@jlhardes jlhardes added the Admin Set impacts the Admin Set part of PCDM Model label Aug 16, 2022
@jlhardes
Copy link
Contributor

Unable to fully test locally using koppie since I'm not sure how to access the Postgres datastore. I can see Solr and was able to create the admin set, query for it in Solr, delete the admin set, and then verify that Solr no longer has a record for the admin set. The UI looks like everything works as it should but I can't verify that the admin set and its access control are removed from the datastore.

@gamontoya
Copy link

@rjkati Not able to verify this issue either.

@alishaevn
Copy link
Contributor

we were able to verify today that this issue has already been resolved.

postgres gui (dbeaver) settings

image

after creating an admin set

Screenshot 2023-05-24 at 1 31 55 PM
Screenshot 2023-05-24 at 1 32 45 PM
Screenshot 2023-05-24 at 1 47 33 PM

after deleting the above admin set

image
image
image

@jessicahilt
Copy link

SoftServ verified.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Admin Set impacts the Admin Set part of PCDM Model valkyrization
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants