Skip to content

feat: per-user Globus token submission for SLURM-level attribution#26

Merged
Anas321 merged 1 commit into
mainfrom
feat/per-user-globus-token
Jun 4, 2026
Merged

feat: per-user Globus token submission for SLURM-level attribution#26
Anas321 merged 1 commit into
mainfrom
feat/per-user-globus-token

Conversation

@Anas321

@Anas321 Anas321 commented Jun 4, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • GlobusComputeClient.submit_streaming_inference() now accepts an optional globus_token parameter
  • When provided, a short-lived Executor is created using AccessTokenAuthorizer so the SLURM job is submitted under the caller's own Globus identity, giving per-user attribution on the HPC cluster
  • API-key callers are unaffected: the persistent executor (stored credentials) is used as before
  • stream/proxy/app.py passes caller.globus_token through to the Globus client when Mode A (Globus Token Auth) is active

Motivation

The paper described per-user SLURM attribution as a feature of Mode A (Globus Token Auth), but the implementation was using the proxy's own stored credentials for all job submissions. This brings code and paper into alignment.

Notes

  • First request from a new Globus user pays ~1.5 s AMQP setup cost; subsequent requests reuse channels
  • Executor is shut down (non-blocking) after the future is submitted to avoid resource leaks
  • No breaking changes: globus_token=None preserves prior behavior exactly

Test plan

  • API-key caller: confirm gce = self._get_executor() path is taken (log shows no "caller-token executor" message)
  • Globus token caller: confirm log shows "Using caller-token executor (per-user SLURM attribution, channel=...)" and SLURM job appears under caller's username

🤖 Generated with Claude Code

When a Globus access token is supplied, submit_streaming_inference()
creates a short-lived Executor authenticated as the caller so that
SLURM jobs appear under the user's own identity on the HPC cluster.
API-key callers continue using the persistent executor (stored creds).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@Anas321 Anas321 merged commit 2072007 into main Jun 4, 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.

1 participant