Upgrades
AgentCube is upgraded by deploying a new container image version. The Context Engine and the connectors version independently of one another, so you upgrade each on its own cadence. Connectors are stateless; a Context Engine upgrade also migrates its database, so it has extra steps (see Context Engine Upgrades).
Upgrade Procedure
Section titled “Upgrade Procedure”1. Check the New Version
Section titled “1. Check the New Version”Confirm the target version with Caprus AI support and review what has changed in it before you upgrade.
2. Pull and Deploy the New Image
Section titled “2. Pull and Deploy the New Image”Update your container deployment to use the new image version. The examples below use {image} for the image you are upgrading: agentcube-ce, agentcube-planning, agentcube-fccs or agentcube-essbase. The same commands apply to each.
az containerapp update --name {app_name} --resource-group {resource_group} --image ghcr.io/caprusai/{image}:{new_version} --revision-suffix "v{new_version}"az containerapp update \ --name {app_name} \ --resource-group {resource_group} \ --image ghcr.io/caprusai/{image}:{new_version} \ --revision-suffix "v{new_version}"aws ecs update-service --service {service_name} --task-definition {task_family}:{new_revision} --force-new-deployment --region {region}aws ecs update-service \ --service {service_name} \ --task-definition {task_family}:{new_revision} \ --force-new-deployment \ --region {region}If the task definition references the image by tag, update the tag in the task definition and register a new revision before running the above command.
Pull the new image and restart the service (the commands are the same in PowerShell and bash):
docker pull ghcr.io/caprusai/{image}:{new_version}Update the image tag in your docker-compose.yml, then:
docker compose up -d {service_name}The command is the same in PowerShell and bash:
kubectl set image deployment/{deployment_name} {container_name}=ghcr.io/caprusai/{image}:{new_version} -n agentcubeKubernetes will perform a rolling update, keeping the existing pod running until the new one is healthy.
OCI Container Instances do not support in-place image updates. Delete the existing instance and create a new one with the updated image tag using the original creation parameters.
3. Verify the Upgrade
Section titled “3. Verify the Upgrade”Invoke-RestMethod https://{connector_hostname}/healthcurl https://{connector_hostname}/healthFor a connector, confirm:
versionmatches the new versionstatusishealthy- In
basicmode,backend_connectedistrue. Indelegated_basic,internalandoidcmodes (including connectors behind the Context Engine),backend_connectedis omitted; check thatbackend.statusishealthyinstead
For the Context Engine, call https://{ce_hostname}/health the same way and confirm:
versionmatches the new version andstatusishealthy- the
persistenceblock reports the database and itsschema_version - the
licenseblock showsinstalled: trueandstatus: "valid"
4. Test a Tool Call
Section titled “4. Test a Tool Call”From your AI platform, run a tool call to verify end-to-end functionality — directly against a connector this is list_applications; through the Context Engine the equivalent is the generic get_metadata tool.
Context Engine Upgrades
Section titled “Context Engine Upgrades”The Context Engine applies database migrations automatically at startup, and migrations cannot be reversed. Before upgrading:
- Take a backup (snapshot or
pg_dump) of the Context Engine PostgreSQL database. - Confirm you have
AGENTCUBE_CE_CREDENTIAL_KEYstored safely. A database restored without the matching key cannot decrypt stored credentials.
Then deploy the new agentcube-ce image as above, keeping the same environment settings and the same credential key.
Upgrading to Context Engine 3.98.0 with Planning 3.21.0 or FCCS 1.14.0: upgrade the Context Engine first. These releases read an application’s metadata export in pages instead of all at once, so refreshing the metadata of a large application no longer needs more memory as the export grows. The connector keeps the export on its local disk while it serves the pages (see Production Deployment & Sizing). A Context Engine on 3.98.0 reads an older connector the old way, so it can go first. A new connector behind an older Context Engine still works, but is read all at once, which is the memory cost these releases remove. After both are upgraded, refresh each Planning or FCCS admin connector on Connected Systems so the Context Engine reads its new tool list (otherwise it does so at the connector’s next scheduled check, and refreshes until then read the export all at once), then refresh each data source’s metadata once (Data Sources → Refresh metadata).
Upgrading from an earlier release that used AGENTCUBE_LICENSE_* variables: those variables are ignored now. After the upgrade, install your existing key once in the admin console under Admin & Security → License, or with PUT /api/v1/license, then remove the old variables. Until the key is installed, new data sources cannot be added.
Single sign-on: a token audience for each connector
Section titled “Single sign-on: a token audience for each connector”What changed. In internal mode the Context Engine signs a token for every call to a connector, and the connector checks the token’s aud claim against its AGENTCUBE_INTERNAL_AUDIENCE setting. Until now every connector used the same value (agentcube-internal). So a connector that received a token could reuse it against any other internal connector behind the same Context Engine, as the user it names, until it expired (five minutes). That matters when the connectors are run by parties who should not trust each other. A Context Engine can now stamp each connector’s tokens with an audience of that connector’s own, and a connector accepts one value or a comma-separated list.
Who is affected. Any deployment with a connector running with AGENTCUBE_AUTH_MODE=internal. Admin-lane connectors (delegated_basic) are not.
What happens if you do nothing. A connector with no audience of its own keeps receiving agentcube-internal, or whatever you set in AGENTCUBE_CE_INTERNAL_AUDIENCE, so an upgraded deployment keeps working. It stays exposed, and the Context Engine says so: it logs a warning at startup, get_status and GET /api/v1/status show internal_audience_shared: true on that connector, and its page in the admin portal shows “Shared with every internal connector”.
Before you start. Upgrade the connector images to a release that includes support for several audiences, and upgrade the Context Engine. Both must be in place before step 2.
Move one connector without downtime
Section titled “Move one connector without downtime”Repeat for each internal-mode connector. Choose an audience that is unique to the connector; the connector’s URL, {connector_url}, is a good one. It must be a single value, with no spaces or commas.
-
Upgrade the connector image, as in Upgrade Procedure above.
-
On the connector, set
AGENTCUBE_INTERNAL_AUDIENCEto both the old and the new value, then restart it:AGENTCUBE_INTERNAL_AUDIENCE=agentcube-internal,{connector_url}The connector now accepts tokens with either audience.
-
In the Context Engine, set the connector’s audience to
{connector_url}. In the admin portal, open the connector and use Token audience. Through the API:PowerShell curl.exe -X PUT "https://{ce_hostname}/api/v1/admin/connectors/{connector_id}/internal-audience" `-H "Authorization: Bearer {api_key}" -H "Content-Type: application/json" `-d '{\"internal_audience\": \"{connector_url}\"}'bash curl -X PUT "https://{ce_hostname}/api/v1/admin/connectors/{connector_id}/internal-audience" \-H "Authorization: Bearer {api_key}" -H "Content-Type: application/json" \-d '{"internal_audience": "{connector_url}"}'The Context Engine instance that handled the change uses the new audience on its next call to the connector. If you run more than one Context Engine instance (replicas), the others keep sending the old audience until they restart, so restart them, or deploy a new revision, before step 4.
-
On the connector, remove the old value and restart it:
AGENTCUBE_INTERNAL_AUDIENCE={connector_url}
No step interrupts calls: before step 3 the connector accepts the old audience, after it the new one, and in between it accepts both. After step 4, a token made for this connector is refused by every other connector, and this connector refuses tokens made for the others.
To go back, set the Context Engine’s audience for the connector to empty (the API accepts null); it returns to the shared audience, which the connector must still list.
New installs set the audience when they register the connector, and the SSO setup pages use the per-connector value throughout.
Version Numbering
Section titled “Version Numbering”Each component uses semantic versioning, and the image tag is the bare version number:
| Component | Image |
|---|---|
| Context Engine | ghcr.io/caprusai/agentcube-ce:{major}.{minor}.{patch} |
| Planning | ghcr.io/caprusai/agentcube-planning:{major}.{minor}.{patch} |
| FCCS | ghcr.io/caprusai/agentcube-fccs:{major}.{minor}.{patch} |
| Essbase | ghcr.io/caprusai/agentcube-essbase:{major}.{minor}.{patch} |
The SDK version is embedded in each connector image and reported as sdk_version in the health endpoint.
Rollback
Section titled “Rollback”If the upgrade causes issues, see Rollbacks to revert to the previous version. Connectors roll back by redeploying the previous image tag. Rolling back the Context Engine also requires restoring the pre-upgrade database backup; do not run an older image against a database a newer version has already migrated.
AI Platform Notes
Section titled “AI Platform Notes”Claude.ai picks up tool definition changes on the next conversation.