MarshalX / atproto

The AT Protocol (🦋 Bluesky) SDK for Python 🐍
https://atproto.blue
MIT License
307 stars 33 forks source link

Database tables of custom feed server template #365

Closed Keirap333110 closed 2 months ago

Keirap333110 commented 2 months ago

Discussed in https://github.com/MarshalX/atproto/discussions/275

Originally posted by **venteto** February 15, 2024 In your feedgen template repo's [database.py file](https://github.com/MarshalX/bluesky-feed-generator/blob/main/server/database.py), what are the `SubscriptionState` and `DbMetadata` tables for? If everything in a new feed generator app had all references to either of these tables completley removed, what bad things would happen over time? Can either one of them be removed safely or no? Why is updating the cursor or the database version necessary? I ask because I'm going to attempt to handle migrations in an offline Django app instead so I can manage additional new tables that way and do easy backup of a remote Postgres database, without having to figure out how to reimplement all of that in Flask. Then I just want to leave copies of the essential models in the `database.py` file that Flask needs to actually save indexed posts and serve multiple feeds. Thanks for any ### insights.
MarshalX commented 2 months ago

?