El desarrollo frontend puede ser una tarea desalentadora, incluso una pesadilla, para los desarrolladores centrados en el backend. Al principio de mi carrera, la línea entre frontend y backend era difusa, y se esperaba que todos manejaran ambos. El CSS, en particular, siempre fue una lucha constante; sentía que era una misión imposible.
Determine Job/Process State
Hi, I'm working on a large extraction from a database and need to parallelize the processes during the extraction.
Here's what happens:
- The user starts the extraction from.
- Several jobs are started using the
Job <Method>instruction.
At the end, the user expects to find a document containing the results of all the extractions. What I'd like to do is start a new job that checks whether the previously started jobs have finished or are still working and consequently produce the document.
After starting each job, using $ZCHILD instruction I can get the ID of the last started job. I might create a list containing all these IDs, pass it to a method that checks if these jobs are still active and eventually produce the final result. The problem is that I can't figure out how to determine the status of a job given its Job ID.
I may use the retrieved ID to define a Job object using the command:
SET JobObj = ##class(%SYS.ProcessQuery).%OpenId($ZCHILD)
But after that, I can't figure out how to derive the job's status. There is a State property, but I can't understand which value indicates that the job has finished.
Thank you in advance if you can help me!