svthalia / concrexit

Thalia Website built on Django.
https://thalia.nu
Other
22 stars 12 forks source link

Sync Moneybird contacts at night #3448

Closed DeD1rk closed 10 months ago

DeD1rk commented 1 year ago

What?

Right now (and in #3446) contacts are still synced post-save. We should change it to be dome nightly like the rest in #3446.

Why?

Reliability and performance.

How?

Maybe use MoneybirdContact.needs_synchronization like we did on invoices in #3446?

It's also a good idea to rethink deleting (i.e. archiving) contacts. The way we try to do it now, we delete the MoneybirdContact from our db after archiving it. This may be a problem if a dataminimised user later becomes member again. We should then probably unarchive the contact? So then we'd have to not delete the contact from our database, as we can't actually lookup by 'customer id'...

On the other hand, it might also be fine to just create a second contact on moneybird for that? @nvoers @movieminer @JobDoesburg do you have ideas on that?

JobDoesburg commented 1 year ago

I really like the needs_synchronization stuff.

For the archiving, I think either works. It might be nice to keep track of them, as removing doesn't really matter (we're keeping them in moneybird anyways)