Hi all
# spicedb
p
Hi all A strange situation has arisen. We temporarily turned off the dev environment, but when we turned it on, despite the fact that the data in Spiced was preserved in PostgreSQL, SpiceDB does not seem to see them when querying. The first screenshot: I look at what rights there are for the platform entity. SpiceDB says there is nothing. But when I try to add these rights, SpiceDB writes that these rights exist (which is really true, because these rights were really in the tables). The remaining screenshots show the differences between the dev environment and the prod environment for this user. Everything is identical, but for some reason, these rights do not seem to be recognized on the dev environment until you recreate them. But to recreate it for the whole system is inconvenient. Maybe someone has met this behavior and will tell you what to do in this case? Part of the scheme attached. https://cdn.discordapp.com/attachments/844600078948630559/1168707129138499654/2023-10-31_10.19.32.jpg?ex=6552be55&is=65404955&hm=cac0348ba0badbc657808d38cb1b0b25766b054adec4779e0ac4a0e81f5d3434& https://cdn.discordapp.com/attachments/844600078948630559/1168707129499197550/Screenshot_2023-10-31_at_10.01.01.png?ex=6552be55&is=65404955&hm=a4040a214c1c5daaf27fbb7b809eb15472ddcbd4971b4f287457c098c52ea998& https://cdn.discordapp.com/attachments/844600078948630559/1168707129838944307/Screenshot_2023-10-31_at_10.01.16.png?ex=6552be55&is=65404955&hm=b674eafd65c025148f5789e10d05b89f1b2e133f17bcabf5593478fe8c76722d& https://cdn.discordapp.com/attachments/844600078948630559/1168707130149326959/Screenshot_2023-10-31_at_10.04.23.png?ex=6552be55&is=65404955&hm=84810fcf71eb32975e36c8a7d612c3673dbd61bb6e3a80b60ab64fd76df9d629& https://cdn.discordapp.com/attachments/844600078948630559/1168707130472276059/Screenshot_2023-10-31_at_10.04.36.png?ex=6552be55&is=65404955&hm=f03e8b6542b6f1cefd9d4c00f2bd4d6ba8a400d03a094796c2979d26cb417bdc& https://cdn.discordapp.com/attachments/844600078948630559/1168707130694582272/part_of_schema.txt?ex=6552be55&is=65404955&hm=1abd9b293e32b0795e9d8e5a4be2227805597a177a0b2cc51bfbdc4225b3f557&
j
what version of postgres are you using?
there are only a few transactions in the transaction table?
p
PostgreSQL 15.4
About 900. Just selected only by a specific user for comparison
j
what do you mean for a specific user? the transaction table has no concept of users
p
I'm sorry, I thought you were talking about the relation_tuple table. Do you need information from relation_tuple_transaction or are you talking about tables in postgres itself?
j
the screenshots that you posted were from relation_tuple_transaction
can you try upgrading spicedb, there were bugs with very small transaction tables on older versions of spicedb
p
ok, thanks, we will try
j
if that doesn't work, I would be happy to keep exploring the idea that somehow your transaction id counter got reset
if the transaction id being chosen was too low for the data that's already stored, that would also result in relationships appearing as missing
did you do a backup and restore at any point?