Skip to content

Commit 46d54fe

Browse files
TheauWaldbr
authored andcommitted
fix: change endpoint and add documentation
1 parent 87746a6 commit 46d54fe

File tree

17 files changed

+2380
-404
lines changed

17 files changed

+2380
-404
lines changed

diracx-client/src/diracx/client/_generated/aio/operations/_operations.py

Lines changed: 276 additions & 77 deletions
Large diffs are not rendered by default.

diracx-client/src/diracx/client/_generated/models/__init__.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,16 @@
1414
from ._models import ( # type: ignore
1515
BodyAuthGetOidcToken,
1616
BodyAuthGetOidcTokenGrantType,
17+
BodyJobsRescheduleJobs,
18+
BodyJobsUnassignBulkJobsSandboxes,
1719
GroupInfo,
1820
HTTPValidationError,
1921
HeartbeatData,
2022
InitiateDeviceFlowResponse,
2123
InsertedJob,
2224
JobCommand,
25+
JobMetaData,
26+
JobMetaDataAccountedFlag,
2327
JobStatusUpdate,
2428
Metadata,
2529
OpenIDConfiguration,
@@ -61,12 +65,16 @@
6165
__all__ = [
6266
"BodyAuthGetOidcToken",
6367
"BodyAuthGetOidcTokenGrantType",
68+
"BodyJobsRescheduleJobs",
69+
"BodyJobsUnassignBulkJobsSandboxes",
6470
"GroupInfo",
6571
"HTTPValidationError",
6672
"HeartbeatData",
6773
"InitiateDeviceFlowResponse",
6874
"InsertedJob",
6975
"JobCommand",
76+
"JobMetaData",
77+
"JobMetaDataAccountedFlag",
7078
"JobStatusUpdate",
7179
"Metadata",
7280
"OpenIDConfiguration",

diracx-client/src/diracx/client/_generated/models/_models.py

Lines changed: 319 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,58 @@ class BodyAuthGetOidcTokenGrantType(_serialization.Model):
9494
"""OAuth2 Grant type."""
9595

9696

97+
class BodyJobsRescheduleJobs(_serialization.Model):
98+
"""Body_jobs_reschedule_jobs.
99+
100+
All required parameters must be populated in order to send to server.
101+
102+
:ivar job_ids: Job Ids. Required.
103+
:vartype job_ids: list[int]
104+
"""
105+
106+
_validation = {
107+
"job_ids": {"required": True},
108+
}
109+
110+
_attribute_map = {
111+
"job_ids": {"key": "job_ids", "type": "[int]"},
112+
}
113+
114+
def __init__(self, *, job_ids: List[int], **kwargs: Any) -> None:
115+
"""
116+
:keyword job_ids: Job Ids. Required.
117+
:paramtype job_ids: list[int]
118+
"""
119+
super().__init__(**kwargs)
120+
self.job_ids = job_ids
121+
122+
123+
class BodyJobsUnassignBulkJobsSandboxes(_serialization.Model):
124+
"""Body_jobs_unassign_bulk_jobs_sandboxes.
125+
126+
All required parameters must be populated in order to send to server.
127+
128+
:ivar job_ids: Job Ids. Required.
129+
:vartype job_ids: list[int]
130+
"""
131+
132+
_validation = {
133+
"job_ids": {"required": True},
134+
}
135+
136+
_attribute_map = {
137+
"job_ids": {"key": "job_ids", "type": "[int]"},
138+
}
139+
140+
def __init__(self, *, job_ids: List[int], **kwargs: Any) -> None:
141+
"""
142+
:keyword job_ids: Job Ids. Required.
143+
:paramtype job_ids: list[int]
144+
"""
145+
super().__init__(**kwargs)
146+
self.job_ids = job_ids
147+
148+
97149
class GroupInfo(_serialization.Model):
98150
"""GroupInfo.
99151
@@ -358,6 +410,273 @@ def __init__(self, *, job_id: int, command: str, arguments: Optional[str] = None
358410
self.arguments = arguments
359411

360412

413+
class JobMetaData(_serialization.Model):
414+
"""A model that combines both JobAttributes and JobParameters.
415+
416+
:ivar timestamp: Timestamp.
417+
:vartype timestamp: ~datetime.datetime
418+
:ivar cpu_normalization_factor: Cpunormalizationfactor.
419+
:vartype cpu_normalization_factor: int
420+
:ivar norm_cpu_time_s: Normcputime(S).
421+
:vartype norm_cpu_time_s: int
422+
:ivar total_cpu_time_s: Totalcputime(S).
423+
:vartype total_cpu_time_s: int
424+
:ivar host_name: Hostname.
425+
:vartype host_name: str
426+
:ivar grid_ce: Gridce.
427+
:vartype grid_ce: str
428+
:ivar model_name: Modelname.
429+
:vartype model_name: str
430+
:ivar pilot_agent: Pilotagent.
431+
:vartype pilot_agent: str
432+
:ivar pilot_reference: Pilot Reference.
433+
:vartype pilot_reference: str
434+
:ivar memory_mb: Memory(Mb).
435+
:vartype memory_mb: int
436+
:ivar local_account: Localaccount.
437+
:vartype local_account: str
438+
:ivar payload_pid: Payloadpid.
439+
:vartype payload_pid: int
440+
:ivar ce_queue: Cequeue.
441+
:vartype ce_queue: str
442+
:ivar batch_system: Batchsystem.
443+
:vartype batch_system: str
444+
:ivar job_type: Jobtype.
445+
:vartype job_type: str
446+
:ivar job_status: Jobstatus.
447+
:vartype job_status: str
448+
:ivar job_group: Jobgroup.
449+
:vartype job_group: str
450+
:ivar site: Site.
451+
:vartype site: str
452+
:ivar job_name: Jobname.
453+
:vartype job_name: str
454+
:ivar owner: Owner.
455+
:vartype owner: str
456+
:ivar owner_group: Ownergroup.
457+
:vartype owner_group: str
458+
:ivar vo: Vo.
459+
:vartype vo: str
460+
:ivar submission_time: Submissiontime.
461+
:vartype submission_time: ~datetime.datetime
462+
:ivar reschedule_time: Rescheduletime.
463+
:vartype reschedule_time: ~datetime.datetime
464+
:ivar last_update_time: Lastupdatetime.
465+
:vartype last_update_time: ~datetime.datetime
466+
:ivar start_exec_time: Startexectime.
467+
:vartype start_exec_time: ~datetime.datetime
468+
:ivar heart_beat_time: Heartbeattime.
469+
:vartype heart_beat_time: ~datetime.datetime
470+
:ivar end_exec_time: Endexectime.
471+
:vartype end_exec_time: ~datetime.datetime
472+
:ivar status: Status.
473+
:vartype status: str
474+
:ivar minor_status: Minorstatus.
475+
:vartype minor_status: str
476+
:ivar application_status: Applicationstatus.
477+
:vartype application_status: str
478+
:ivar user_priority: Userpriority.
479+
:vartype user_priority: int
480+
:ivar reschedule_counter: Reschedulecounter.
481+
:vartype reschedule_counter: int
482+
:ivar verified_flag: Verifiedflag.
483+
:vartype verified_flag: bool
484+
:ivar accounted_flag: Accountedflag.
485+
:vartype accounted_flag: ~_generated.models.JobMetaDataAccountedFlag
486+
"""
487+
488+
_attribute_map = {
489+
"timestamp": {"key": "timestamp", "type": "iso-8601"},
490+
"cpu_normalization_factor": {"key": "CPUNormalizationFactor", "type": "int"},
491+
"norm_cpu_time_s": {"key": "NormCPUTime(s)", "type": "int"},
492+
"total_cpu_time_s": {"key": "TotalCPUTime(s)", "type": "int"},
493+
"host_name": {"key": "HostName", "type": "str"},
494+
"grid_ce": {"key": "GridCE", "type": "str"},
495+
"model_name": {"key": "ModelName", "type": "str"},
496+
"pilot_agent": {"key": "PilotAgent", "type": "str"},
497+
"pilot_reference": {"key": "Pilot_Reference", "type": "str"},
498+
"memory_mb": {"key": "Memory(MB)", "type": "int"},
499+
"local_account": {"key": "LocalAccount", "type": "str"},
500+
"payload_pid": {"key": "PayloadPID", "type": "int"},
501+
"ce_queue": {"key": "CEQueue", "type": "str"},
502+
"batch_system": {"key": "BatchSystem", "type": "str"},
503+
"job_type": {"key": "JobType", "type": "str"},
504+
"job_status": {"key": "JobStatus", "type": "str"},
505+
"job_group": {"key": "JobGroup", "type": "str"},
506+
"site": {"key": "Site", "type": "str"},
507+
"job_name": {"key": "JobName", "type": "str"},
508+
"owner": {"key": "Owner", "type": "str"},
509+
"owner_group": {"key": "OwnerGroup", "type": "str"},
510+
"vo": {"key": "VO", "type": "str"},
511+
"submission_time": {"key": "SubmissionTime", "type": "iso-8601"},
512+
"reschedule_time": {"key": "RescheduleTime", "type": "iso-8601"},
513+
"last_update_time": {"key": "LastUpdateTime", "type": "iso-8601"},
514+
"start_exec_time": {"key": "StartExecTime", "type": "iso-8601"},
515+
"heart_beat_time": {"key": "HeartBeatTime", "type": "iso-8601"},
516+
"end_exec_time": {"key": "EndExecTime", "type": "iso-8601"},
517+
"status": {"key": "Status", "type": "str"},
518+
"minor_status": {"key": "MinorStatus", "type": "str"},
519+
"application_status": {"key": "ApplicationStatus", "type": "str"},
520+
"user_priority": {"key": "UserPriority", "type": "int"},
521+
"reschedule_counter": {"key": "RescheduleCounter", "type": "int"},
522+
"verified_flag": {"key": "VerifiedFlag", "type": "bool"},
523+
"accounted_flag": {"key": "AccountedFlag", "type": "JobMetaDataAccountedFlag"},
524+
}
525+
526+
def __init__( # pylint: disable=too-many-locals
527+
self,
528+
*,
529+
timestamp: Optional[datetime.datetime] = None,
530+
cpu_normalization_factor: Optional[int] = None,
531+
norm_cpu_time_s: Optional[int] = None,
532+
total_cpu_time_s: Optional[int] = None,
533+
host_name: Optional[str] = None,
534+
grid_ce: Optional[str] = None,
535+
model_name: Optional[str] = None,
536+
pilot_agent: Optional[str] = None,
537+
pilot_reference: Optional[str] = None,
538+
memory_mb: Optional[int] = None,
539+
local_account: Optional[str] = None,
540+
payload_pid: Optional[int] = None,
541+
ce_queue: Optional[str] = None,
542+
batch_system: Optional[str] = None,
543+
job_type: Optional[str] = None,
544+
job_status: Optional[str] = None,
545+
job_group: Optional[str] = None,
546+
site: Optional[str] = None,
547+
job_name: Optional[str] = None,
548+
owner: Optional[str] = None,
549+
owner_group: Optional[str] = None,
550+
vo: Optional[str] = None,
551+
submission_time: Optional[datetime.datetime] = None,
552+
reschedule_time: Optional[datetime.datetime] = None,
553+
last_update_time: Optional[datetime.datetime] = None,
554+
start_exec_time: Optional[datetime.datetime] = None,
555+
heart_beat_time: Optional[datetime.datetime] = None,
556+
end_exec_time: Optional[datetime.datetime] = None,
557+
status: Optional[str] = None,
558+
minor_status: Optional[str] = None,
559+
application_status: Optional[str] = None,
560+
user_priority: Optional[int] = None,
561+
reschedule_counter: Optional[int] = None,
562+
verified_flag: Optional[bool] = None,
563+
accounted_flag: Optional["_models.JobMetaDataAccountedFlag"] = None,
564+
**kwargs: Any
565+
) -> None:
566+
"""
567+
:keyword timestamp: Timestamp.
568+
:paramtype timestamp: ~datetime.datetime
569+
:keyword cpu_normalization_factor: Cpunormalizationfactor.
570+
:paramtype cpu_normalization_factor: int
571+
:keyword norm_cpu_time_s: Normcputime(S).
572+
:paramtype norm_cpu_time_s: int
573+
:keyword total_cpu_time_s: Totalcputime(S).
574+
:paramtype total_cpu_time_s: int
575+
:keyword host_name: Hostname.
576+
:paramtype host_name: str
577+
:keyword grid_ce: Gridce.
578+
:paramtype grid_ce: str
579+
:keyword model_name: Modelname.
580+
:paramtype model_name: str
581+
:keyword pilot_agent: Pilotagent.
582+
:paramtype pilot_agent: str
583+
:keyword pilot_reference: Pilot Reference.
584+
:paramtype pilot_reference: str
585+
:keyword memory_mb: Memory(Mb).
586+
:paramtype memory_mb: int
587+
:keyword local_account: Localaccount.
588+
:paramtype local_account: str
589+
:keyword payload_pid: Payloadpid.
590+
:paramtype payload_pid: int
591+
:keyword ce_queue: Cequeue.
592+
:paramtype ce_queue: str
593+
:keyword batch_system: Batchsystem.
594+
:paramtype batch_system: str
595+
:keyword job_type: Jobtype.
596+
:paramtype job_type: str
597+
:keyword job_status: Jobstatus.
598+
:paramtype job_status: str
599+
:keyword job_group: Jobgroup.
600+
:paramtype job_group: str
601+
:keyword site: Site.
602+
:paramtype site: str
603+
:keyword job_name: Jobname.
604+
:paramtype job_name: str
605+
:keyword owner: Owner.
606+
:paramtype owner: str
607+
:keyword owner_group: Ownergroup.
608+
:paramtype owner_group: str
609+
:keyword vo: Vo.
610+
:paramtype vo: str
611+
:keyword submission_time: Submissiontime.
612+
:paramtype submission_time: ~datetime.datetime
613+
:keyword reschedule_time: Rescheduletime.
614+
:paramtype reschedule_time: ~datetime.datetime
615+
:keyword last_update_time: Lastupdatetime.
616+
:paramtype last_update_time: ~datetime.datetime
617+
:keyword start_exec_time: Startexectime.
618+
:paramtype start_exec_time: ~datetime.datetime
619+
:keyword heart_beat_time: Heartbeattime.
620+
:paramtype heart_beat_time: ~datetime.datetime
621+
:keyword end_exec_time: Endexectime.
622+
:paramtype end_exec_time: ~datetime.datetime
623+
:keyword status: Status.
624+
:paramtype status: str
625+
:keyword minor_status: Minorstatus.
626+
:paramtype minor_status: str
627+
:keyword application_status: Applicationstatus.
628+
:paramtype application_status: str
629+
:keyword user_priority: Userpriority.
630+
:paramtype user_priority: int
631+
:keyword reschedule_counter: Reschedulecounter.
632+
:paramtype reschedule_counter: int
633+
:keyword verified_flag: Verifiedflag.
634+
:paramtype verified_flag: bool
635+
:keyword accounted_flag: Accountedflag.
636+
:paramtype accounted_flag: ~_generated.models.JobMetaDataAccountedFlag
637+
"""
638+
super().__init__(**kwargs)
639+
self.timestamp = timestamp
640+
self.cpu_normalization_factor = cpu_normalization_factor
641+
self.norm_cpu_time_s = norm_cpu_time_s
642+
self.total_cpu_time_s = total_cpu_time_s
643+
self.host_name = host_name
644+
self.grid_ce = grid_ce
645+
self.model_name = model_name
646+
self.pilot_agent = pilot_agent
647+
self.pilot_reference = pilot_reference
648+
self.memory_mb = memory_mb
649+
self.local_account = local_account
650+
self.payload_pid = payload_pid
651+
self.ce_queue = ce_queue
652+
self.batch_system = batch_system
653+
self.job_type = job_type
654+
self.job_status = job_status
655+
self.job_group = job_group
656+
self.site = site
657+
self.job_name = job_name
658+
self.owner = owner
659+
self.owner_group = owner_group
660+
self.vo = vo
661+
self.submission_time = submission_time
662+
self.reschedule_time = reschedule_time
663+
self.last_update_time = last_update_time
664+
self.start_exec_time = start_exec_time
665+
self.heart_beat_time = heart_beat_time
666+
self.end_exec_time = end_exec_time
667+
self.status = status
668+
self.minor_status = minor_status
669+
self.application_status = application_status
670+
self.user_priority = user_priority
671+
self.reschedule_counter = reschedule_counter
672+
self.verified_flag = verified_flag
673+
self.accounted_flag = accounted_flag
674+
675+
676+
class JobMetaDataAccountedFlag(_serialization.Model):
677+
"""Accountedflag."""
678+
679+
361680
class JobStatusUpdate(_serialization.Model):
362681
"""JobStatusUpdate.
363682

0 commit comments

Comments
 (0)