Skip to content

Add the option to install a large-cluster manifest and cordon control plane to dedicated machines - #1632

Merged
Michelle Au (msau42) merged 8 commits into
agent-substrate:mainfrom
maxsmythe:bm-manifests
Sep 25, 2026
Merged

Michelle Au (msau42) merged 8 commits into
agent-substrate:mainfrom
maxsmythe:bm-manifests

Conversation

@maxsmythe

Copy link
Copy Markdown
Collaborator

This change allows users to install Substrate on larger clusters. It adds a --cluster-size flag to enable more t-shirt-style sizing in the future to accommodate clusters of different sizes.

It also adds a --cordon-control-plane flag that allows taints/tolerances/antiaffinity/node labels to have each control plane element run on its own dedicated machine.

Fixes #<issue_number_goes_here>

It's a good idea to open an issue first for discussion.

  • Tests pass
  • Appropriate changes to documentation are included in the PR

Comment thread hack/install-ate.sh
echo " --podcert-workers-per-signer N Concurrent workers per podcertificate-controller signer (default: 1)"
echo " --cluster-size size0|size10 Cluster size profile (default: size0). \"size10\" assumes a dedicated postgres node"
echo " --cordon-control-plane Pin each control plane pod to its own node: assumes a pool labeled and tainted"
echo " ate.dev/workloadType=ate-control-plane:NoSchedule with one node per pod (7 at the"

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

nit: we need to get this into the docs somewhere, I nearly had https://github.com/agent-substrate/substrate/pull/1651/changes tolerate all taints for atelet.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

added to achitecture.md

Comment thread hack/install-ate.sh
echo " --delete-all Delete core system and all registered demos"
echo " --atenet-router=envoy|agentgateway Select the ingress and egress dataplane (default: envoy)"
echo " --podcert-workers-per-signer N Concurrent workers per podcertificate-controller signer (default: 1)"
echo " --cluster-size size0|size10 Cluster size profile (default: size0). \"size10\" assumes a dedicated postgres node"

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

what do these names mean? this doesn't seem intuitive?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I was discouraged from "small" and "large", so "size0" is default (smallest) size. "size10" is larger. There is room for "size5", etc...

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I see. This feels unintuitive, and just "small" / "large" by another name ...

Maybe we should just require you to pass custom resizing patches ...?

Can defer to a follow-up to unblock work

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Yeah, it's essentially "small" and "large", but with the ability for more gradations later if necessary.

It looks like most of it could be a kustomize file, with the Postgres connection string being the one exception.

One good thing about "sizing"-type flags is that they should make it transparent when/if manifests change later.

Ultimately I'm guessing we'll need to have some generic way of customizing the footprint during install for production use cases?

@maxsmythe
Max Smythe (maxsmythe) force-pushed the bm-manifests branch 2 times, most recently from be918e4 to 8518096 Compare September 17, 2026 20:25
requests:
cpu: "2"
cpu: "4"
memory: "1Gi"

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

is 1Gi request / 2GI limit memory reasonable with 4 CPU?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Ooops, leftover from experimentation. Reverted this file.

@bowei Bowei Du (bowei) added kind/feature An enhancement / feature request or implementation area/dev-infra labels Sep 17, 2026
@BenTheElder

Copy link
Copy Markdown
Collaborator

cc Bowei Du (@bowei)

@maxsmythe
Max Smythe (maxsmythe) force-pushed the bm-manifests branch 3 times, most recently from 30d11b5 to 429e41b Compare September 24, 2026 08:16
@maxsmythe

Copy link
Copy Markdown
Collaborator Author

Bowei Du (@bowei) re-worked it to work with the golang-only install process

@msau42 Michelle Au (msau42) left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This is ok from a testing/dev perspective, but I do anticipate we'll need something more customizable for production.

The bundled postgres ships sized for small clusters (--cluster-size=size0,
the default): max_connections=100 and modest CPU and memory requests.
Larger clusters saturate that and cap ate-api-server well below the load
they generate.

postgres-size10/postgres-config-patch.yaml carries a postgresql.conf tuned
for a dedicated node, merged over the postgres-config ConfigMap when
--cluster-size=size10 is selected. The benchmark orchestrator selects it
for the 10k tests.
The podcert-size10 kustomize overlay raises the podcertificate-controller's
client-go rate limits to --kube-api-qps=100 / --kube-api-burst=200, so
signing keeps up with the request volume the size10 postgres profile
enables. It is installed on --cluster-size=size10 clusters.
Under --cordon-control-plane, every control plane workload (ate-api-server,
ate-controller, atenet-router, atenet-egress, podcertificate-controller,
postgres) gets a nodeSelector and toleration for
ate.dev/workloadType=ate-control-plane and a hostname anti-affinity
against the other control plane pods, so each runs alone on a node of a
dedicated pool. Without the flag the manifests are applied unchanged.

The pinning lives in one kustomize component with a name-regex target.
The install applies these workloads through several different streams
(the base bundle, a lone ate-api-server redeploy, the podcert overlay,
the postgres file, and the egress variants), so the installer composes
whichever path is in use with the component; kustomize leaves a stream
alone when nothing in it matches.
--podcert-workers-per-signer was applied as a Get/Update on the live
Deployment after the manifest's server-side apply. That rolled the
controller out twice per install, first with the manifest's
WORKERS_PER_SIGNER=1 and then with the requested value, and let the
rollout wait watch a pod that was about to be replaced. Because the apply
is forced, every later install reset the value to 1 before the Update
raised it again, so the double rollout repeated even when nothing changed.

The value is now set on the rendered objects before the one apply, as the
size10 postgres resize already is: one rollout, and the rollout wait sees
the pod that will serve.
@maxsmythe

Copy link
Copy Markdown
Collaborator Author

100% WRT needing something more customizable for production.

@msau42
Michelle Au (msau42) added this pull request to the merge queue Sep 24, 2026
Merged via the queue into agent-substrate:main with commit d6d2a0f Sep 25, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/dev-infra kind/feature An enhancement / feature request or implementation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants