Skip to content

chore(search): remove legacy indexed enterprise search - #8528

Merged
icecrasher321 merged 7 commits into
stagingfrom
codex/remove-indexed-enterprise-search
Oct 1, 2026
Merged

icecrasher321 merged 7 commits into
stagingfrom
codex/remove-indexed-enterprise-search

Conversation

@icecrasher321

@icecrasher321 icecrasher321 commented Oct 1, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Remove the legacy indexed enterprise Search backend, setup flows, statistics, MCP schemas and runtime toggle. Enterprise Search uses the live backend; ordinary KB retrieval and document permissions remain intact.
  • Restrict deferred projection repair to ordinary KB vectors, with bounded pages, at most eight workers and a cap on deferred documents per pass.
  • Keep the database schema compatible during rollout. Data cleanup and index replacement are separate operator actions in chore(search): add paced projection replacement and data retirement #8534.
  • Upgrade Slack Search consent during explicit admin approval and preserve member-access setup links. Ordinary workflow reconnect keeps its configured permissions.
  • Reject restore, enable and fork-copy operations for retired Search documents. Remove legacy name-based adoption so ordinary KBs remain ordinary.

Type of Change

  • Maintenance / legacy feature removal

Testing

  • App and database type-checks, repository lint, all 54 audits, migration safety, block-registry and docs-manifest checks passed.
  • 216 focused unit tests passed, covering onboarding permissions, contracts and exact OAuth consent. Real PostgreSQL tests cover Slack policy upgrades, targeted reauthorization, idempotence and rollback.
  • 66 PostgreSQL checks in the changed setup, document and fork suites passed. New regressions failed before their fixes; ordinary KB controls pass. Earlier checks also covered processing rollback/recovery and vector repair.
  • Integration reports are written to apps/sim/test-results/integration.json by the disposable PostgreSQL/Redis runner.

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing (new tests pass the test-audit authoring gate)
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

@vercel

vercel Bot commented Oct 1, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
docs Ready Ready Preview Oct 1, 2026 7:37pm UTC

Request Review

@icecrasher321

Copy link
Copy Markdown
Collaborator Author

@greptile

@icecrasher321

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@icecrasher321 I have started the AI code review. It will take a few minutes to complete.

@greptile-apps

greptile-apps Bot commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

[High risk] Removes legacy indexed search backend and related API routes.

The PR appears safe to merge based on the reviewed changes and resolved previous findings.

Summary

This PR retires the legacy indexed enterprise Search path while retaining ordinary knowledge-base retrieval. Changes since the previous review also add per-chat resource-panel width persistence, scoped settings return navigation, a desktop regression test, and Wiza error extraction.

  • Enterprise Search uses live provider queries; ordinary knowledge-base indexing remains separate.
  • The previous onboarding and Slack consent findings are addressed in the current code. The connector-index cleanup concern was resolved through the separate operator-gated retirement path.
Diagram
%%{init: {'theme': 'neutral'}}%%
flowchart LR
  Search[Enterprise Search] --> Live[Live provider queries]
  KB[Ordinary knowledge bases] --> Sync[Connector and document indexing]
  Sync --> Retrieval[Access-scoped KB retrieval]
Loading

Reviews (5) · Last reviewed commit: "Merge remote-tracking branch 'origin/sta..."

Comment thread apps/sim/app/o/[organizationId]/home/components/get-started/get-started.tsx Outdated
Comment thread apps/sim/lib/knowledge/orchestration/connectors.ts
@greptile-apps

greptile-apps Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

Comments Outside Diff

These findings could not be posted inline.

  • P2 Unused index lookup remains apps/sim/lib/knowledge/mcp/route-handler.ts:49 ▶

    Every MCP POST still looks up the canonical Search index, but the result is discarded because the live tools no longer use an index ID. This adds an unnecessary database lookup to each request; retain the availability check without fetching the unused index.

    Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 259 files

Note: This PR contains a large number of files. cubic selects up to 200 of the highest-priority eligible files for this review, so some files may not have been reviewed.
Tip: instead of fixing issues one by one fix them all with cubic

Re-trigger cubic

Comment thread apps/sim/lib/knowledge/search/connection-target.ts
Comment thread apps/sim/app/o/[organizationId]/home/components/get-started/get-started.tsx Outdated
Comment thread apps/sim/lib/mothership/tools/server/knowledge/workspace-search.ts Outdated
Comment thread apps/sim/lib/api/contracts/mothership-search-sources.ts
Comment thread apps/sim/lib/credential-groups/slack-provider.ts Outdated
Comment thread apps/sim/app/o/[organizationId]/home/components/get-started/get-started.tsx Outdated
Comment thread apps/sim/lib/knowledge/constants.ts
Comment thread docker/app.Dockerfile
@icecrasher321

Copy link
Copy Markdown
Collaborator Author

@greptile

@icecrasher321

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@icecrasher321 I have started the AI code review. It will take a few minutes to complete.

@icecrasher321

Copy link
Copy Markdown
Collaborator Author

Regarding the outside-diff MCP lookup suggestion: the returned index identifier is unused, but readSearchIndex.execute remains the authorized application boundary for organization membership, knowledge.use, and Search availability. I am retaining that gate in this removal PR to preserve admission behavior. A separate authorization-only use case could safely remove the extra lookup; dropping the current call would bypass the gate.

Comment thread apps/sim/lib/credential-groups/slack-provider.ts

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 270 files

Note: This PR contains a large number of files. cubic selects up to 200 of the highest-priority eligible files for this review, so some files may not have been reviewed.

Fix all with cubic | Re-trigger cubic

@icecrasher321

Copy link
Copy Markdown
Collaborator Author

@greptile

@icecrasher321

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@icecrasher321 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 276 files

Note: This PR contains a large number of files. cubic selects up to 200 of the highest-priority eligible files for this review, so some files may not have been reviewed.

Fix all with cubic | Re-trigger cubic

Comment thread apps/sim/lib/workspaces/__integration__/fork-sync.integration.ts
Comment thread apps/sim/lib/knowledge/application/documents.ts
Comment thread apps/sim/ee/workspace-forking/lib/copy/copy-resources.ts
@icecrasher321

Copy link
Copy Markdown
Collaborator Author

The dashboard changes mentioned in the review summary came from #8527, already merged into staging; organization OAuth scoping came from #8533. Neither is a change in this PR relative to its staging base. This PR keeps its scope on retiring indexed Search and preserving ordinary KB and live Search behavior, so the dashboard performance suggestion belongs with that separate change.

@icecrasher321

Copy link
Copy Markdown
Collaborator Author

@greptile

@icecrasher321

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@icecrasher321 I have started the AI code review. It will take a few minutes to complete.

@icecrasher321

Copy link
Copy Markdown
Collaborator Author

@greptile

@icecrasher321

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@icecrasher321 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No issues found across 276 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Note: This PR contains a large number of files. cubic selects up to 200 of the highest-priority eligible files for this review, so some files may not have been reviewed.
You've manually re-run cubic several times on this PR. Each manual re-review checks the full PR again and counts toward your usage quota. To preserve your usage limits, we recommend letting cubic automatically review new commits.

Re-trigger cubic

@icecrasher321
icecrasher321 merged commit a1e573a into staging Oct 1, 2026
60 of 61 checks passed
@icecrasher321
icecrasher321 deleted the codex/remove-indexed-enterprise-search branch October 1, 2026 20:03

This branch was successfully deployed

1 active deployment
Preview — 47e63e16 Deployed Oct 1, 2026 by vercel[bot]
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