Upgrade
This document provides instructions for upgrading Alauda Hyperflux to a newer version.
TOC
Standard Upgrade StepsUpgrading from v1.3.x to v1.4.x (Embedding Model Switch)What the upgrade does automaticallyRecommended pre-upgrade backupExecute the upgradeVerify the upgradeSpecial case: you maintain a custom knowledge baseUpgrading from v1.2.0 to v1.2.1 (Special Case)Step 1: Backup Knowledge BaseStep 2: Execute UpgradeStep 3: Restore Knowledge BaseStandard Upgrade Steps
For most version upgrades (except for v1.2.0 → v1.2.1 and v1.3.x → v1.4.x), you can simply follow these steps in the ACP console:
- Upload the new version of the plugin package to the ACP Marketplace. Upload the package in the same way as the initial installation. After the upload is complete, wait for approximately 10–15 minutes for the platform to automatically synchronize the new version information.
- Verify that the new version is available in the Marketplace. Go to Administrator / Marketplace / Upload Packages. Switch to the Cluster Plugin tab and confirm that the new version number is displayed for the Hyperflux plugin.
- Execute the upgrade operation on the cluster. Navigate to Administrator / Clusters / Clusters. Find the cluster where the Hyperflux plugin is installed; an upgrade icon will be displayed in the cluster entry. Click to enter the cluster details, and switch to the Features tab. On the Hyperflux plugin card, click the Upgrade button and confirm the operation.
- Verify the upgrade result. After the upgrade is complete, confirm that the version number has been updated in the Features tab. Verify normal operation through plugin status monitoring or logs.
Upgrading from v1.3.x to v1.4.x (Embedding Model Switch)
IMPORTANT: v1.4.0 ships a new embedding model (
gte-multilingual-base, replacingparaphrase-multilingual-mpnet-base-v2). The vector spaces are not compatible, so the system knowledge base must be re-embedded. The chart does this automatically during the upgrade — but please read this section before applying, especially if you have built a custom knowledge base.
What the upgrade does automatically
When the new chart rolls out, the init container scans docvec_sys_kb for any legacy mpnet collection that
matches a rule in smartdoc.acpKbUpgradeRules (default: ACP 4.1 and ACP 4.2 mpnet collections), then:
- Acquires a PostgreSQL advisory lock keyed on
acpKbDataVersionso a second replica's init exits cleanly. - Records the in-flight swap into a
kb_swap_staterow (so it can recover if the pod is killed mid-swap). - Drops the
langchain_pg_embeddingandlangchain_pg_collectiontables indocvec_sys_kb. pg_restorethe new gte dump from/workspace-smart-doc/dumps/(warnings about pre-existing extensions/ schemas are tolerated, hard errors abort).- Verifies the new collection name landed (
SELECT count(*) ... = 1); aborts otherwise. - Renames the new collection back to the old collection name so the running server keeps querying the same
name. You do not need to change
pgconnect.pgCollectionName. - Rebuilds the ParadeDB BM25 index if the new dump didn't already ship one, and re-runs the
doc_idbtree and URL-backfill schema migrations against the freshly restored table. - Stamps
schema_migrationswithacpKbDataVersionand clears the inflightkb_swap_staterow.
The swap is:
- Idempotent — a chart re-roll without changing
acpKbDataVersionis a no-op. - Crash-safe — pod kill between DROP and RESTORE is recoverable on next start.
- Multi-replica safe — a PostgreSQL advisory lock keyed on
acpKbDataVersionserialises the swap.
Recommended pre-upgrade backup
The swap drops the old collection and replaces it with new data; the old mpnet vectors are not retained.
Even though the bundled dumps are reproducible, take a backup of docvec_sys_kb and docvec_user_kb before
upgrading so you can roll back if anything goes wrong:
docvec_user_kb and the chat-history database are not touched by the swap — but a
backup is cheap insurance.
Execute the upgrade
Follow the Standard Upgrade Steps above. The init container will run the swap automatically the first time a smart-doc pod restarts on the new version.
Verify the upgrade
Tail the init container log and confirm the swap completed:
A successful swap prints lines like:
A re-roll without a acpKbDataVersion change prints [upgrade] 20260508-gte-acp-4-x already applied, skipping.
instead.
Once the smart-doc pod becomes Ready, run a representative question through the chat UI to confirm answers are grounded in the new corpus.
Special case: you maintain a custom knowledge base
If you previously followed Build a Custom Knowledge Base on the v1.3.x mpnet model, the vectors in your custom collection are not compatible with the v1.4.0 server. You must:
- Before the upgrade: rebuild your custom KB with
gte-multilingual-base(see the linked guide). - Add a rule for your custom collection to
smartdoc.acpKbUpgradeRulesin your values override: - Apply the upgrade. The init container processes every rule line in turn.
If you skip step 1, the chart will still upgrade, but retrieval against the stale custom collection will return zero hits and answers will fall back to "I don't have enough information".
Upgrading from v1.2.0 to v1.2.1 (Special Case)
IMPORTANT: Upgrading from v1.2.0 to v1.2.1 will cause the knowledge base to be re-initialized. You must manually back up and restore your database to prevent data loss.
Step 1: Backup Knowledge Base
Before performing the upgrade, execute the following commands:
Step 2: Execute Upgrade
Follow the Standard Upgrade Steps described above to upgrade the plugin version through the ACP console.
Step 3: Restore Knowledge Base
After the upgrade is complete, restore your data:
Wait for the Alauda Hyperflux pods to restart and verify that the knowledge base has been restored successfully.