docs(policy): deprecate non-namespaced registered resources#253
docs(policy): deprecate non-namespaced registered resources#253alkalescent wants to merge 12 commits intomainfrom
Conversation
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request primarily focuses on updating the documentation to reflect the deprecation of non-namespaced registered resources within the policy system. It introduces the concept of namespaced registered resources, provides clear examples of their Fully Qualified Names (FQNs), and outlines the necessary migration steps for existing resources. These changes ensure that the documentation aligns with the evolving policy architecture, guiding users towards the recommended, namespaced approach for managing registered resources. Highlights
🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request effectively documents the deprecation of non-namespaced registered resources. The changes are consistent across all modified files, updating definitions, examples, and diagrams to reflect that registered resources are now namespaced. The documentation is clearer and more accurate as a result. I have one suggestion to further improve the migration instructions to make them more actionable for users.
|
📄 Preview deployed to https://opentdf-docs-pr-253.surge.sh |
|
Warning Rate limit exceeded
Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 26 minutes and 0 seconds. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughThis PR updates documentation and configuration to introduce namespace scoping for Registered Resources, marks non-namespaced Registered Resources as deprecated, and adds a migration guide for transitioning to the new namespace-aware behavior. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~12 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (4)
docs/components/policy/registered_resources.md (1)
1-1:⚠️ Potential issue | 🟡 MinorSwitch this modified policy page to
.mdxformat.This file is updated as
.md, which conflicts with the documentation format rule.As per coding guidelines,
**/*.{md,mdx}: Documentation files should use.mdxformat; name new pageskebab-case.mdx, and useindex.mdxfor section landing pages.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@docs/components/policy/registered_resources.md` at line 1, This documentation page is currently saved as a .md file but must follow the project's docs rule to use .mdx; rename the file from registered_resources.md to kebab-case .mdx (e.g., registered-resources.mdx) or, if this is a section landing page, to index.mdx inside a folder, and update any internal frontmatter or import usage to the .mdx filename; ensure the top-level heading "Registered Resources" remains and that the file extension and name follow the repository's .mdx naming conventions.docs/components/policy/attributes.md (1)
1-1:⚠️ Potential issue | 🟡 MinorConvert this updated doc page to
.mdx.The file is modified as
.md, but the documentation convention requires.mdx.As per coding guidelines,
**/*.{md,mdx}: Documentation files should use.mdxformat; name new pageskebab-case.mdx, and useindex.mdxfor section landing pages.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@docs/components/policy/attributes.md` at line 1, The doc page titled "Attributes" is currently written as a .md file; rename and convert it to a .mdx file using the docs convention (use kebab-case for new page names, e.g., attributes.mdx) or if this is a section landing page turn it into index.mdx, and ensure the file content is valid MDX (retain the "Attributes" heading and any frontmatter) so it follows the **/*.{md,mdx} documentation guideline.docs/components/authorization.md (1)
1-3:⚠️ Potential issue | 🟡 MinorUse
.mdxfor this documentation page.This file is being modified as Markdown (
.md), but docs standards require.mdxfor documentation files.As per coding guidelines,
**/*.{md,mdx}: Documentation files should use.mdxformat; name new pageskebab-case.mdx, and useindex.mdxfor section landing pages.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@docs/components/authorization.md` around lines 1 - 3, The documentation page "authorization.md" is in the wrong format; rename and convert it to MDX by changing the filename to a kebab-case .mdx (e.g., authorization.mdx) or to index.mdx if this is a section landing page, update frontmatter and any MD-specific constructs to MDX-compatible syntax, and ensure the docs build/config references the new .mdx file instead of the .md file.docs/components/policy/index.md (1)
1-4:⚠️ Potential issue | 🟡 MinorPlease migrate this updated policy doc to
.mdx.The changed page remains
.md, which conflicts with the docs file-format rule.As per coding guidelines,
**/*.{md,mdx}: Documentation files should use.mdxformat; name new pageskebab-case.mdx, and useindex.mdxfor section landing pages.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@docs/components/policy/index.md` around lines 1 - 4, The file docs/components/policy/index.md is still in .md and needs to be migrated to .mdx: rename the page to use .mdx (use index.mdx for this section landing page) and move/convert any frontmatter or markdown content into the new .mdx file while preserving the existing YAML frontmatter fields (sidebar_position and slug) or converting them to MDX-compatible export metadata; ensure the filename follows the docs rule (section landing pages use index.mdx) and update any internal imports/links that referenced docs/components/policy/index.md to point to docs/components/policy/index.mdx.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Outside diff comments:
In `@docs/components/authorization.md`:
- Around line 1-3: The documentation page "authorization.md" is in the wrong
format; rename and convert it to MDX by changing the filename to a kebab-case
.mdx (e.g., authorization.mdx) or to index.mdx if this is a section landing
page, update frontmatter and any MD-specific constructs to MDX-compatible
syntax, and ensure the docs build/config references the new .mdx file instead of
the .md file.
In `@docs/components/policy/attributes.md`:
- Line 1: The doc page titled "Attributes" is currently written as a .md file;
rename and convert it to a .mdx file using the docs convention (use kebab-case
for new page names, e.g., attributes.mdx) or if this is a section landing page
turn it into index.mdx, and ensure the file content is valid MDX (retain the
"Attributes" heading and any frontmatter) so it follows the **/*.{md,mdx}
documentation guideline.
In `@docs/components/policy/index.md`:
- Around line 1-4: The file docs/components/policy/index.md is still in .md and
needs to be migrated to .mdx: rename the page to use .mdx (use index.mdx for
this section landing page) and move/convert any frontmatter or markdown content
into the new .mdx file while preserving the existing YAML frontmatter fields
(sidebar_position and slug) or converting them to MDX-compatible export
metadata; ensure the filename follows the docs rule (section landing pages use
index.mdx) and update any internal imports/links that referenced
docs/components/policy/index.md to point to docs/components/policy/index.mdx.
In `@docs/components/policy/registered_resources.md`:
- Line 1: This documentation page is currently saved as a .md file but must
follow the project's docs rule to use .mdx; rename the file from
registered_resources.md to kebab-case .mdx (e.g., registered-resources.mdx) or,
if this is a section landing page, to index.mdx inside a folder, and update any
internal frontmatter or import usage to the .mdx filename; ensure the top-level
heading "Registered Resources" remains and that the file extension and name
follow the repository's .mdx naming conventions.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: d4d78d79-1ebf-47b7-8c5e-68d0566c3fda
📒 Files selected for processing (6)
.github/vale-styles/config/vocabularies/Opentdf/accept.txtdocs/components/authorization.mddocs/components/policy/attributes.mddocs/components/policy/index.mddocs/components/policy/registered_resources.mddocs/sdks/policy.mdx
| The `otdfctl migrate registered-resources` command migrates legacy non-namespaced Registered Resources to namespaced ones. | ||
|
|
||
| :::caution | ||
| Migration creates a new namespaced resource, recreates its values with their action-attribute-value mappings, then deletes the old non-namespaced resource. The migrated resource will have a new UUID. Back up your data before running with `--commit`. |
There was a problem hiding this comment.
I think we are changing this to not delete the old, but add a metadata tag that we can then use with a prune or cleanup command.
There was a problem hiding this comment.
Okay, what would you recommend? I'm thinking I can keep this block as current behavior but mention future expected behavior. Alternatively, I can just remove mention of migration until we get to an expected state.
There was a problem hiding this comment.
I would keep everything as you have it and add, "to delete items you will need to run a separate prune\cleanup command which can be found in the otdfctl docs".
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@docs/components/policy/registered_resources.md`:
- Around line 67-70: Update the "Namespace Deletion Cascade" section to
disambiguate API vs SDK behavior: explicitly state whether cascading
hard-deletes of Registered Resources (and their values) occur only for
API/admin-level namespace deletion or whether SDK calls only perform
soft-deletes (deactivation). Reference the SDK docs pages (docs/sdks/policy.mdx)
and attributes doc (docs/components/policy/attributes.md) in the text and add a
short sentence clarifying that SDK namespace operations are soft-delete only
while administrative/API endpoints can perform permanent hard-delete cascades,
or, if the API does not hard-delete, change the cascade wording to indicate
soft-delete of resources instead.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 897ee3b7-a9b9-47bd-9625-0d93a29117aa
📒 Files selected for processing (1)
docs/components/policy/registered_resources.md
This PR documents the deprecation of non-namespaced registered resources and how to migrate existing resources using otdfctl.
Summary by CodeRabbit