Skip to content

Reorganize docs into Tools & APIs, Configuration, and Internals groups#288

Merged
hackerwins merged 1 commit intomainfrom
regroup
Feb 6, 2026
Merged

Reorganize docs into Tools & APIs, Configuration, and Internals groups#288
hackerwins merged 1 commit intomainfrom
regroup

Conversation

@hackerwins
Copy link
Member

@hackerwins hackerwins commented Feb 6, 2026

What this PR does / why we need it?

Reorganize docs into Tools & APIs, Configuration, and Internals groups

Split the navigation into clearer groups:

  • Tools & APIs (order 60): Devtools, CLI, Admin API, MCP
  • Configuration (order 110): Architecture Patterns, Security, Event Webhook, Revisions, Resources, Projects
  • Internals (order 120): CRDT Concepts, Synchronization, Document Lifecycle, YSON, Cluster Mode

Also adds new pages (Projects, CRDT Concepts, Synchronization, Document Lifecycle, Cluster Mode) and enriches the Glossary with additional terms and cross-links.

Any background context you want to provide?

What are the relevant tickets?

Fixes #

Checklist

  • Added relevant tests or not required
  • Didn't break anything

Summary by CodeRabbit

Documentation

  • Reorganized documentation structure into Tools, Advanced Configuration, and Internals sections for improved navigation
  • Added comprehensive guides for Projects, Cluster Mode, CRDT Concepts, Document Lifecycle, and Synchronization
  • Expanded Glossary with new linked terms and detailed definitions
  • Updated internal documentation links across all pages to reflect new structure
  • Enhanced Advanced Configuration section with Event Webhook documentation

Split the navigation into clearer groups:
- Tools & APIs (order 60): Devtools, CLI, Admin API, MCP
- Configuration (order 110): Architecture Patterns, Security, Event Webhook, Revisions, Resources, Projects
- Internals (order 120): CRDT Concepts, Synchronization, Document Lifecycle, YSON, Cluster Mode

Also adds new pages (Projects, CRDT Concepts, Synchronization, Document Lifecycle,
Cluster Mode) and enriches the Glossary with additional terms and cross-links.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@coderabbitai
Copy link

coderabbitai bot commented Feb 6, 2026

📝 Walkthrough

Walkthrough

This pull request reorganizes the documentation structure by creating a new "Internals" section for internal CRDT concepts and moving tool references to a dedicated "Tools & APIs" section. Multiple documentation files are updated with revised link paths to reflect this reorganization. A new "Projects" page is added to the Configuration section.

Changes

Cohort / File(s) Summary
Documentation Structure Reorganization
docs/advanced.mdx, docs/index.mdx, docs/tools.mdx
Renamed "Advanced" to "Configuration", updated section structure, reorganized topics list, and created new Tools & APIs landing page with prerequisite links.
Advanced Section - Link Path Migrations
docs/advanced/architecture-patterns.mdx, docs/advanced/security.mdx, docs/advanced/resources.mdx, docs/advanced/revisions.mdx
Updated internal documentation links from /docs/cli and /docs/admin-api to /docs/tools/cli and /docs/tools/admin-api; migrated YSON references to /docs/internals/yson.
New Advanced Documentation
docs/advanced/event-webhook.mdx, docs/advanced/projects.mdx
Added Event Webhook documentation page and comprehensive Projects documentation covering multi-tenant isolation, API key management, and per-project configuration.
Internals Documentation Section (New)
docs/internals.mdx, docs/internals/crdt-concepts.mdx, docs/internals/synchronization.mdx, docs/internals/document-lifecycle.mdx, docs/internals/cluster-mode.mdx, docs/internals/yson.mdx
Created new Internals section with comprehensive documentation on CRDT concepts, synchronization architecture, document lifecycle, cluster mode sharding, and YSON format; includes mermaid diagrams and code examples.
Tools Documentation (Reorganized)
docs/tools/devtools.mdx, docs/tools/cli.mdx, docs/tools/admin-api.mdx, docs/tools/mcp.mdx
Updated ordering metadata and link references; migrated YSON documentation paths to point to /docs/internals/yson.
SDK and Deployment Documentation Updates
docs/js-sdk.mdx, docs/js-sdk/react.mdx, docs/self-hosted-server.mdx, docs/self-hosted-server/...
Updated devtools, CLI, and Admin API documentation links from legacy paths to /docs/tools/* and /docs/internals/* paths throughout SDK and deployment guides.
Glossary Expansion
docs/glossary.mdx
Enhanced glossary with linked term references and new entries including Dashboard, API Key, YSON, Text, Counter, Watch Stream, Document Compaction, TimeTicket, Version Vector, RHT, RGA, Auth Webhook, and Event Webhook; organized by section with improved cross-linking.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Poem

A rabbit hops through docs with glee,
Reorganizing architecture!
Links now point to tools and internals spree,
Projects shine in new structure,
Glossary grows with CRDT mystique. 🐰✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Reorganize docs into Tools & APIs, Configuration, and Internals groups' directly and accurately describes the main structural changes throughout the pull request—reorganizing documentation into three groups.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch regroup

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In `@docs/internals/cluster-mode.mdx`:
- Around line 86-102: Update the DestinationRule manifest to use the stable API
version by replacing apiVersion: networking.istio.io/v1alpha3 with apiVersion:
networking.istio.io/v1 in the YAML snippet that defines the DestinationRule
named yorkie; keep the rest of the spec (host, trafficPolicy, portLevelSettings,
consistentHash/ringHash/httpHeaderName) unchanged so the consistentHash
structure remains compliant with the Istio spec.

In `@docs/internals/synchronization.mdx`:
- Around line 128-131: The sentence currently implies Garbage Collection uses
Checkpoints to decide when tombstoned nodes can be removed; reword it to state
that GC relies on Version Vectors (minVersionVector) to determine safe removal
and that Checkpoints (ServerSeq/ClientSeq) only track sync progress and
indirectly support GC by ensuring clients catch up and update their version
vectors; reference the terms "Checkpoint", "ServerSeq", "ClientSeq", "Version
Vectors", and "minVersionVector" and replace the existing sentence with a
concise line clarifying this distinction (or add a short clarifying clause) so
the relationship between checkpoints and GC is precise.
🧹 Nitpick comments (5)
docs/index.mdx (1)

40-40: Consider linking to the new dedicated Projects page instead of the CLI anchor.

This sentence explains the concept of Projects ("organize multiple independent applications within a single Yorkie installation"), which aligns better with the new /docs/advanced/projects page. The CLI anchor (/docs/tools/cli#project) is more about the CLI commands for managing projects.

Suggested change
-Additionally, **[Projects](/docs/tools/cli#project)** allow you to organize multiple independent applications within a single Yorkie installation, each with its own documents, channels, and clients. Learn more about key concepts in the [Glossary](/docs/glossary).
+Additionally, **[Projects](/docs/advanced/projects)** allow you to organize multiple independent applications within a single Yorkie installation, each with its own documents, channels, and clients. Learn more about key concepts in the [Glossary](/docs/glossary).
docs/internals/document-lifecycle.mdx (2)

47-53: Nit: Removed state's "Allowed Operations" column is misleading.

Line 53 lists deactivate() as the allowed operation for the Removed state, but deactivate() is a client-level operation, not a document-level one. Listing it here implies there's a document-level action you can still take on a removed document. Consider either clarifying this (e.g., "None (client can still deactivate())") or listing "None" to avoid confusion.


113-123: Missing import for DocStatus in the code example.

The snippet uses DocStatus.Attached, DocStatus.Detached, and DocStatus.Removed but never shows where DocStatus is imported from. Adding the import would make the example copy-paste friendly.

Suggested fix
+import { DocStatus } from '@yorkie-js/sdk';
+
 doc.subscribe('status', (event) => {
docs/internals/synchronization.mdx (2)

163-170: Snapshot event subscription uses different API pattern than other examples.

This example uses doc.subscribe((event) => { if (event.type === 'snapshot') ... }) (no topic argument), while the Document Status Events example in document-lifecycle.mdx uses doc.subscribe('status', (event) => ...) (with a topic string). Both patterns may be valid in the SDK, but it would be helpful to add a brief note or use the topic-based form doc.subscribe('snapshot', ...) if it exists, for consistency across the new docs.


231-244: Document compaction: "not currently attached to any client" is a strong precondition.

This is good to document explicitly. It means compaction can only run on "cold" documents. For production users, this is a key operational detail — if a document is always attached by at least one client, it will never be compacted. Consider adding a brief note about this implication.

Comment on lines +86 to +102
```yaml
apiVersion: networking.istio.io/v1alpha3
kind: DestinationRule
metadata:
name: yorkie
spec:
host: yorkie
trafficPolicy:
portLevelSettings:
- port:
number: 8080
loadBalancer:
consistentHash:
ringHash:
minimumRingSize: 1024
httpHeaderName: "x-shard-key"
```
Copy link

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🌐 Web query:

Istio DestinationRule API version v1 vs v1alpha3 current 2024 2025

💡 Result:

  • What changed (2024): Starting with Istio 1.22 (May 13, 2024), DestinationRule was promoted to apiVersion: networking.istio.io/v1 (along with several other networking APIs). v1beta1 and v1alpha3 remained supported, but Istio encouraged users to move to v1. [1]
  • What to use in 2024–2025: For current Istio docs and examples, DestinationRule is shown as networking.istio.io/v1. [2]
  • Is v1alpha3 still valid? Yes—Istio’s v1-APIs announcement explicitly lists DestinationRule as available in v1, v1beta1, and v1alpha3, and states there were no plans (at that time) to discontinue older versions, though migration to v1 is recommended. [1]
  • Important nuance (1.23+): Istio 1.23 (Aug 14, 2024) consolidated internal protobuf/API definitions, but for Kubernetes YAML usage there is “no impact”—so using v1 vs older versions is mainly about using the stable API version rather than changing the schema. [3]

Practical guidance:

  • New manifests (2024/2025+): use apiVersion: networking.istio.io/v1. [1][2]
  • Existing v1alpha3 manifests: typically still apply, but plan to migrate to v1 for “stable API” posture. [1]

Sources: [1] Istio blog: “Introducing Istio v1 APIs” (May 13, 2024); [2] Istio DestinationRule reference (shows networking.istio.io/v1); [3] Istio 1.23 upgrade notes (Aug 14, 2024).


🌐 Web query:

Istio consistentHash ringHash httpHeaderName field structure documentation

💡 Result:

In Istio DestinationRule, the structure is:

  • spec.trafficPolicy.loadBalancer.consistentHash is a oneof that can hash on exactly one of:

    • httpHeaderName: <header> (string)
    • httpCookie: { name: <cookie>, ttl: <duration>, path: <path> }
    • httpQueryParameterName: <param> (string)
    • useSourceIp: true (bool)
  • Optional consistent-hash algorithm tuning is configured alongside (as siblings of) httpHeaderName etc.:

Example (header-hash + ring-hash settings):

apiVersion: networking.istio.io/v1
kind: DestinationRule
metadata:
  name: my-svc
spec:
  host: my-svc.default.svc.cluster.local
  trafficPolicy:
    loadBalancer:
      consistentHash:
        httpHeaderName: x-user-id
        ringHash:
          minimumRingSize: 1024

Reference: Istio DestinationRule API docs → LoadBalancerSettings.ConsistentHashLB and RingHash. (preliminary.istio.io)

Citations:


Update Istio DestinationRule API version to v1.

The documentation uses apiVersion: networking.istio.io/v1alpha3, which is outdated. Starting with Istio 1.22 (May 2024), DestinationRule was promoted to networking.istio.io/v1. While v1alpha3 remains supported, current Istio documentation and examples use v1. Update the snippet to use networking.istio.io/v1 to reflect the stable API version.

The consistentHash field structure (with ringHash and httpHeaderName as siblings) is correct per the Istio spec.

🤖 Prompt for AI Agents
In `@docs/internals/cluster-mode.mdx` around lines 86 - 102, Update the
DestinationRule manifest to use the stable API version by replacing apiVersion:
networking.istio.io/v1alpha3 with apiVersion: networking.istio.io/v1 in the YAML
snippet that defines the DestinationRule named yorkie; keep the rest of the spec
(host, trafficPolicy, portLevelSettings, consistentHash/ringHash/httpHeaderName)
unchanged so the consistentHash structure remains compliant with the Istio spec.

Comment on lines +128 to +131
```

Checkpoints are also used by [Garbage Collection](/docs/internals/crdt-concepts#garbage-collection) to determine when tombstoned nodes can be safely removed -- only after all clients have synced past the version where the node was deleted.

Copy link

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Checkpoint–GC relationship is slightly imprecise.

Line 130 states checkpoints are used by Garbage Collection to determine when tombstoned nodes can be removed. However, per the CRDT Concepts page (also added in this PR), GC uses Version Vectors (minVersionVector), not Checkpoints (ServerSeq/ClientSeq). Checkpoints track sync progress, while version vectors track causality.

Consider rewording to avoid conflating the two mechanisms, or clarifying that checkpoints indirectly support GC by ensuring clients have synced (which updates their version vectors).

Suggested rewording
-Checkpoints are also used by [Garbage Collection](/docs/internals/crdt-concepts#garbage-collection) to determine when tombstoned nodes can be safely removed -- only after all clients have synced past the version where the node was deleted.
+Checkpoints support [Garbage Collection](/docs/internals/crdt-concepts#garbage-collection) indirectly -- by tracking sync progress, the system ensures clients' [Version Vectors](/docs/internals/crdt-concepts#version-vectors) are up to date, which determines when tombstoned nodes can be safely removed.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
```
Checkpoints are also used by [Garbage Collection](/docs/internals/crdt-concepts#garbage-collection) to determine when tombstoned nodes can be safely removed -- only after all clients have synced past the version where the node was deleted.
🤖 Prompt for AI Agents
In `@docs/internals/synchronization.mdx` around lines 128 - 131, The sentence
currently implies Garbage Collection uses Checkpoints to decide when tombstoned
nodes can be removed; reword it to state that GC relies on Version Vectors
(minVersionVector) to determine safe removal and that Checkpoints
(ServerSeq/ClientSeq) only track sync progress and indirectly support GC by
ensuring clients catch up and update their version vectors; reference the terms
"Checkpoint", "ServerSeq", "ClientSeq", "Version Vectors", and
"minVersionVector" and replace the existing sentence with a concise line
clarifying this distinction (or add a short clarifying clause) so the
relationship between checkpoints and GC is precise.

@hackerwins hackerwins merged commit 9efc894 into main Feb 6, 2026
2 checks passed
@hackerwins hackerwins deleted the regroup branch February 6, 2026 03:35
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.

1 participant