Skip to content

Splitted the job endpoints to separate Pilots and Users #468

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

Robin-Van-de-Merghel
Copy link
Contributor

Reopened*

Implementation for #444

Some interrogations about my understanding of this policy:

  • We do need to check for a job_id associated with a pilot? (already implemented)
  • With job_ids, I assumed that a pilot can manage only one job at a time, do we?

@chrisburr
Copy link
Member

With job_ids, I assumed that a pilot can manage only one job at a time, do we?

A pilot can potentially be running many jobs at the same time (via PoolCE in legacy DIRAC).

@Robin-Van-de-Merghel
Copy link
Contributor Author

A pilot can potentially be running many jobs at the same time (via PoolCE in legacy DIRAC).

I just added it. I guess I have to do tests on the endpoints for the policy, I'll do it later today.

@Robin-Van-de-Merghel Robin-Van-de-Merghel force-pushed the robin-update-wmsjobpolicy branch 4 times, most recently from cb05237 to 0c2604f Compare April 16, 2025 08:10
@Robin-Van-de-Merghel Robin-Van-de-Merghel force-pushed the robin-update-wmsjobpolicy branch 2 times, most recently from da5eb05 to b71aeec Compare May 6, 2025 09:38
@Robin-Van-de-Merghel Robin-Van-de-Merghel mentioned this pull request May 7, 2025
39 tasks
@Robin-Van-de-Merghel Robin-Van-de-Merghel force-pushed the robin-update-wmsjobpolicy branch from b71aeec to 8c82491 Compare May 8, 2025 09:21
@Robin-Van-de-Merghel Robin-Van-de-Merghel changed the title feat: Improving wmsjobpolicy to contain pilots Splitted the job endpoints to separate Pilots and Users May 8, 2025
@Robin-Van-de-Merghel Robin-Van-de-Merghel force-pushed the robin-update-wmsjobpolicy branch from 8c82491 to 6deffe2 Compare May 21, 2025 14:34
@Robin-Van-de-Merghel Robin-Van-de-Merghel force-pushed the robin-update-wmsjobpolicy branch 2 times, most recently from cb10ac1 to 837134e Compare June 4, 2025 14:19
@Robin-Van-de-Merghel
Copy link
Contributor Author

Robin-Van-de-Merghel commented Jun 4, 2025

Router won't pass the tests: we need to have in the factory (or somewhere else) a pilot token generator (but not a "pilot_client" as normal_user_client, because we can't stack multiple contexts).

@chaen
Copy link
Contributor

chaen commented Jun 13, 2025

Just to sum up the path we are taking: legacy DIRAC code will still rely on the legacy exchange and on a robot user for its pilot duty, so it will keep using the "traditional" endpoint (like /job/heartbeat.
However, new pilot code, using solely diracx will not have a robot user, will rely on pilot credentials and will use the new endpoint. It should never be possible to get a pilot credential from the legacy exchange
The code duplication is absolutely none as the business logic is factorized.

@Robin-Van-de-Merghel Robin-Van-de-Merghel force-pushed the robin-update-wmsjobpolicy branch from a678d0f to 9af20b4 Compare June 19, 2025 08:40
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.

4 participants