Lines Matching refs:job
9 - asynchronous job management functions
18 int ASYNC_start_job(ASYNC_JOB **job, ASYNC_WAIT_CTX *ctx, int *ret,
23 ASYNC_WAIT_CTX *ASYNC_get_wait_ctx(ASYNC_JOB *job);
41 subsequent event indicates that the job can be resumed. It's OpenSSL
47 the pool, used, and then returned to the pool when the job completes. If the
66 An asynchronous job is started by calling the ASYNC_start_job() function.
67 Initially I<*job> should be NULL. I<ctx> should point to an B<ASYNC_WAIT_CTX>
70 be stored on completion of the job. I<func> represents the function that should
72 will be copied and then passed as an argument to I<func> when the job starts.
79 An error occurred trying to start the job. Check the OpenSSL error queue (e.g.
89 The job was successfully started but was "paused" before it completed (see
90 ASYNC_pause_job() below). A handle to the job is placed in I<*job>. Other work
91 can be performed (if desired) and the job restarted at a later time. To restart
92 a job call ASYNC_start_job() again passing the job handle in I<*job>. The
93 I<func>, I<args> and I<size> parameters will be ignored when restarting a job.
94 When restarting a job ASYNC_start_job() B<must> be called from the same thread
95 that the job was originally started from. B<ASYNC_WAIT_CTX> is used to
96 know when a job is ready to be restarted.
100 The job completed. I<*job> will be NULL and the return value from I<func> will
105 At any one time there can be a maximum of one job actively running per thread
107 a pointer to the currently executing B<ASYNC_JOB>. If no job is currently
110 If executing within the context of a job (i.e. having been called directly or
115 I<*job> parameter will resume execution from the ASYNC_pause_job() call. If
116 ASYNC_pause_job() is called whilst not within the context of a job then no
120 for the I<job> (see L<ASYNC_WAIT_CTX_new(3)>).
122 applications that a job is ready to be resumed. One is a "wait" file
129 that the job should be resumed). If no file descriptor is made available then
130 an application will have to periodically "poll" the job by attempting to restart
143 The ASYNC_block_pause() function will prevent the currently active job from
148 currently active job then they have no effect. This functionality can be useful
153 resuming the original job then a deadlock can occur. By calling
182 or NULL if not within the context of a job.
184 ASYNC_get_wait_ctx() returns a pointer to the B<ASYNC_WAIT_CTX> for the job.
234 printf("Executing within a job\n");
236 printf("Not executing within a job - should not happen\n");
244 * Create a way to inform the calling thread when this job is ready
268 * immediately signalling that the job is ready to be woken up after
283 printf ("Resumed the job after a pause\n");
290 ASYNC_JOB *job = NULL;
307 switch (ASYNC_start_job(&job, ctx, &ret, jobfunc, msg, sizeof(msg))) {
320 /* Get the file descriptor we can use to wait for the job
323 printf("Waiting for the job to be woken up\n");
334 /* Wait for the job to be ready for wakeup */
348 Executing within a job
351 Waiting for the job to be woken up
352 Resumed the job after a pause