Coder Social home page Coder Social logo

Comments (7)

jraddaoui avatar jraddaoui commented on June 14, 2024

The biggest deal of this change is the update of all the digital files when the ancestor collection is edited. In Elasticsearch the documents are not related between them, therefore, if a change is made over a collection with 2 descendant folders and 500 descendant digital files, the collection data must be updated in 503 documents.

This can be executed in an efficient way by using partial updates and bulk requests, but it can be a long time process as the application data grows. Ideally, this should be implemented in an asynchronous task after #15 is done.

Estimate: 16 h

from scope.

jraddaoui avatar jraddaoui commented on June 14, 2024

We could also implement this in two steps:

  1. Add ancestor collection identifier and id to digital files and display link to collection in search page data table. Do not update collection identifier value in digital files when the collection is edited. Running again the CLI index_data task will fix the issue but it will need to be executed manually after changing a collection identifier. 2 hours

  2. Update descendants automatically (and asynchronously) when a collection or folder is edited. 14 hours

from scope.

jraddaoui avatar jraddaoui commented on June 14, 2024

Some notes to test this:

  1. A link to the ancestor collection should appear in the search page for each file.
  2. It should show "Untitled" if the collection title is empty.
  3. The collection title should be searchable in the search page.
  4. When a collection is edited, if it has descendant files, it should show a notification about a descendants update in progress.
  5. When a folder is edited, if it has descendant files, it should show a notification too.
  6. After the async. update finish the correct folder identifier and collection title should be shown in the search page table.

from scope.

sallain avatar sallain commented on June 14, 2024

@jraddaoui since I'm still pretty new to SCOPE, I'm going to answer each of your points with my testing results just to make sure I'm looking at the right thing.

  1. Yes - if I search for "objects/BBhelmet.ai", the search result table has a column called Collection name that contains a link to the collection.
  2. Yes - shows Untitled with a link to the collection.
  3. Yes - results page shows all digital files belonging to the collection.
  4. Yes - a notification pops up reading A background process has been launched to update the Collection metadata in the Elasticsearch index for the related Digital Files.
  5. Yes - a notification pops up reading A background process has been launched to update the Folder metadata in the Elasticsearch index for the related Digital Files.
  6. Yes - everything updates properly.

Overall, LGTM! I think this is ready for CCA testing.

from scope.

stefanabreitwieser avatar stefanabreitwieser commented on June 14, 2024

@jraddaoui , this looks great!! Going through the same steps:

  1. Yes - same results as Sara. The link is working.
  2. No - I updated a collection title to be blank, and searched "*". The old collection name still appears in the search results, still with a working link. (I wasn't able to test from by uploading a new DIP-- we seem to be having issues uploading DIPs from CCA right now.)
  3. Yes - same results as Sara.
  4. Yes - same results as Sara.
  5. Yes - same results as Sara.
  6. Yes, I think? See point 2.

Let me know if there's anything else you'd like me to test -- thanks so much!

from scope.

jraddaoui avatar jraddaoui commented on June 14, 2024

Hi @stefanabreitwieser, it looks like there was another memory issue. More information in #127 (comment).

I have restarted the worker, which allowed a couple of import process to finish and the descendants update/delete should work now.

from scope.

stefanabreitwieser avatar stefanabreitwieser commented on June 14, 2024

Looks great, thanks Radda!

from scope.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.