Skip to content

Load the version from shared context if set#101

Merged
marcopiraccini merged 1 commit into
mainfrom
load-version-correctly
Jul 8, 2026
Merged

Load the version from shared context if set#101
marcopiraccini merged 1 commit into
mainfrom
load-version-correctly

Conversation

@marcopiraccini

@marcopiraccini marcopiraccini commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

World resolves its deployment version from the environment (PLT_WORLD_DEPLOYMENT_VERSION or PLT_DEPLOYMENT_VERSION) and falls back to the runtime shared context, instead of reading the pod's plt.dev/version label via the Kubernetes API. This drops the pods:get RBAC the API read required, and lets the version arrive after startup: if it was not known at boot (ICC unreachable), World starts at local and latches the real version on the next queue read once it is pushed to the shared context, with no restart. Standalone/local dev still falls back to local.

While the version is still unresolved (local) in Kubernetes, enqueuing is refused so a run is never pinned to local (its messages would not route to the ICC-registered handlers); the caller retries until the version lands.

Adds @platformatic/globals to read the shared context; it degrades to a no-op outside a runtime.

Signed-off-by: marcopiraccini <marco.piraccini@gmail.com>
@marcopiraccini marcopiraccini changed the title Load the version from shared contextif set Load the version from shared context if set Jul 8, 2026
@marcopiraccini marcopiraccini marked this pull request as ready for review July 8, 2026 13:45
@marcopiraccini marcopiraccini merged commit 544fa6d into main Jul 8, 2026
3 checks passed
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.

2 participants