opentdf / platform

OpenTDF Platform monorepo enabling the development and integration of _forever control_ of data into new and existing applications. The concept of forever control stems from an increasingly common concept known as zero trust.
BSD 3-Clause Clear License
15 stars 4 forks source link

Explore using sqlc instead of squirrel for policy #864

Open jrschumacher opened 1 month ago

jrschumacher commented 1 month ago

Look at using ResourceMappings or SubjectMappings since they are smaller and less complex.

https://sqlc.dev/

jrschumacher commented 1 month ago

@strantalis we've been using this in COP and it's been a great experience. I'll review with you next week.

jakedoublev commented 1 week ago

Unfortunately during a test implementation I discovered that sqlc, though it integrations with goose for migrations, does not support dynamic schemas. Due to our reuse of connection pools across services and configurable schema names, we cannot use sqlc at this time or generated statements will lack schemas and result in "relation not found" errors.

Once we enhance our connection pool story (see #681), we can revisit configuring the schema at the connection level and working past this limitation.