Giveth / impact-graph

MIT License
49 stars 18 forks source link

prevent queries from hanging and blocking other queries #1820

Open divine-comedian opened 2 weeks ago

divine-comedian commented 2 weeks ago

some queries are hanging when the dapp is under load. the hanging queries are preventing other queries from being ran and causing errors for users on the app

CarlosQ96 commented 2 weeks ago

image These are some of the queries that are hanging. There queries that hang the most seems related to querying the recurring donations and selecting the squareroot sum for estimated matching.

CarlosQ96 commented 2 weeks ago
image
divine-comedian commented 2 weeks ago

@CarlosQ96 what is the update on this issue?

CarlosQ96 commented 2 weeks ago

I been cleaning the queries manually every now and then. The main query fetching the square root is the culprit. As I'm finishing issues, ill jump to this between today and tomorrow.

divine-comedian commented 2 weeks ago

Yikes! Definitely not sustainable to manually clean queries, thanks for investigating and please update us when you have the fix.

divine-comedian commented 2 days ago

was related to cronjob - @CarlosQ96 will keep working on it this week with estimated matching query fixes.