code clean-up - remove obsolete stuff after release of restartable tasks

This commit is contained in:
Helmut Merz 2025-06-16 19:21:42 +02:00
parent 17899b934c
commit f498b0cf78
2 changed files with 4 additions and 7 deletions

View file

@ -68,12 +68,10 @@
(defgeneric send (tsk msg)
(:method ((tsk async:mailbox) msg)
;(util:lgi msg)
(async:snd tsk msg)))
(defun become (bhv)
(set-bhv *self* bhv)
bhv)
(set-bhv *self* bhv))
;;;; handling restartable tasks
@ -82,13 +80,13 @@
(multiple-value-bind (msg ok) (async:try-rcv tsk)
(if ok
(if (eq (content msg) +quit-message+)
(progn (async:set-status tsk :stopped) nil)
(async:set-status tsk :stopped)
(progn
(async:set-status tsk :running)
(let ((*self* tsk))
(funcall bhv msg)
(ac-loop tsk (async:behavior tsk)))))
(progn (async:set-status tsk :suspended) bhv))))
(async:set-status tsk :suspended))))
(defmethod send ((tsk async:restartable-task) msg)
(let ((status (async:get-status tsk)))

View file

@ -100,8 +100,7 @@
(dolist (ctx (alx:hash-table-values (services *root*)))
(funcall (config:shutdown (config ctx)) ctx))
;(actor:stop *root*)
(async:finish)
)
(async:finish))
(defun add-action (ctx pat hdlr)
(let* ((acts (actions ctx))