docintelapp / DocIntel

Open Source Platform for storing, organizing, and searching documents related to cyber threats
https://docintel.org
Other
154 stars 25 forks source link

Number of documents under source index showing incorrect number #58

Open shannaniggans opened 1 year ago

shannaniggans commented 1 year ago

/Source/Index

My source shows 0 documents image

However when i click on the source to view, i have 2 documents registered image

ancailliau commented 1 year ago

The problem is that, at the moment, the code would need to load all documents in memory just to count them. So I disabled that feature for performance reasons (especially if you have a single source with 10K documents).

There are solutions 😄 but it will require a bit more work!

Note for myself: SourceIndexer is missing the navigational property "Documents". Postgres should be leveraged to compute the number of documents without retrieving all of them.