-
Notifications
You must be signed in to change notification settings - Fork 4
Best way to integrate database for cassiopeia objects #5
Comments
Hi @Lyie123, cassiopeia objects or actual riot api structures are very complex to be saved in an sql database like a actual table, BUT you have a jsonfield that is now live on django 3.1, and you can actually query into those json fields like if it was nosql, i think that is the easiest way. A model with a similar structure as below: class Match(models.Model)
match_id = models.IntegerField()
region = models.CharField(max_length=20)
data = models.JSONField() |
Hi @paaksing , thanks for your reply. I will try it out! Thank you so much! |
I personally don't use cassiopeia for my riot projects, I use my other framework built from ground up pyot. To your question about integrating the database as datasink in cass, is no, BUT I have integrated the Django Cache into cassiopeia datasink, you can do it the same way I did here, if you want and actually did it, it would be nice to have a PR for that! The code that I am building the cache is in The store then needs to be injected on the app init. If you want to continue this conversation on discord, here is my id Morimorph#6234 |
This issue is inactive for 12 days, so I will be closing it, if you still have question, you can reopen it or make a new one. |
Hi!
Sorry if my question is stupid.
I have tried to figure out how to save the cassiopeia objects to a local database.
I have found cassiopeia-sqlstore and integrated it in the pipeline.
But I think its outdated.
What is the easiest way to query and save cassiopeia objects from a database?
Is there a easy way? Or does I have to write my own Pipeline Object?
Greetings Rene
The text was updated successfully, but these errors were encountered: