Ghini / server

ghini reloaded - merging desktop & web
http://tanager.ghini.me
GNU Affero General Public License v3.0
2 stars 2 forks source link

add recursive summary information #61

Closed mfrasca closed 5 years ago

mfrasca commented 5 years ago

somewhere, somehow, we need some recursive summary information. in ghini.desktop we have it in the status line, and it is relative to the search.

here with this recursive taxonomy structure, you see a taxon, you read how many direct verifications it has, but you don't know how many it is if you consider all its subtaxa. it is an expensive computation, and we don't want to start the computation unless explicitly requested. the computation must run on the server, and the client must wait for the result, and must be able to inform the server of the computations it isn't interested in any more.

one option could be to start it when the user clicks on theimagebutton, but consider that hitting the button makes it disappear, so when you again select the same row, we need to save the summary information somewhere. even worse, who knows maybe the computation hadn't finished yet, and the mechanism receiving the information from the server should stay active even if the user selects a different row in the meanwhile.

mfrasca commented 5 years ago

for the whole 'Orchidaceae' structure, it takes ~8s, with sqlite3. computation is delegated to the database.