Skip to content

feat: add docs about source of truth #1002

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 6 commits into from
Closed

Conversation

aaguiarz
Copy link
Member

@aaguiarz aaguiarz commented Apr 2, 2025

Description

References

Review Checklist

  • I have clicked on "allow edits by maintainers".
  • I have added documentation for new/changed functionality in this PR or in a PR to openfga.dev [Provide a link to any relevant PRs in the references section above]
  • The correct base branch is being used, if not main
  • I have added tests to validate that the change in functionality is working as expected

@aaguiarz aaguiarz requested a review from a team as a code owner April 2, 2025 20:34
@aaguiarz aaguiarz requested a review from Copilot April 2, 2025 20:34
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces documentation about the "Source of Truth" by updating the sidebar configuration in the docs. The changes close the previous sidebar entry and add a new entry for the "Source of Truth" document.

  • Added a new sidebar entry for "Source of Truth" in the best practices section.
  • Adjusted the object boundaries to incorporate the new entry.
Files not reviewed (1)
  • docs/content/best-practices/source-of-truth.mdx: Language not supported

Copy link
Contributor

github-actions bot commented Apr 2, 2025

PR Preview Action v1.6.0
Preview removed because the pull request was closed.
2025-04-10 02:14 UTC

@aaguiarz aaguiarz requested a review from a team as a code owner April 3, 2025 06:22
@aaguiarz aaguiarz requested review from tylernix and rhamzeh April 8, 2025 17:29
tylernix
tylernix previously approved these changes Apr 9, 2025

- User data: The source of truth for user profile data is typically an identity provider like Azure, Okta or Auth0.
- Entity hierarchies: Structures like project/tickets or folder/documents already live in application's databases. Repeatedly querying <ProductName format={ProductNameFormat.ShortForm}/> just to navigate that hierarchy would be inefficient.
- Data relevant for search and filtering: When performing searches, you need to combine data that's on your database and data that's in <ProductName format={ProductNameFormat.ShortForm}/>. Your application's database is the right place to do filtering/sorting/joins. The data required for performing those operations should live in application's databases.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be worth giving an example for clarity? Such as storing document.content in the app's database, but store document.owner in FGA.

Co-authored-by: Raghd Hamzeh <raghd.hamzeh@openfga.dev>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants