basic fixes
This commit is contained in:
parent
6051440074
commit
07f58520da
6
NOTES.md
6
NOTES.md
|
@ -1,3 +1,6 @@
|
||||||
|
support tor and opennic sites
|
||||||
|
reject brave browser
|
||||||
|
|
||||||
## deps
|
## deps
|
||||||
|
|
||||||
- crypto-lib
|
- crypto-lib
|
||||||
|
@ -116,6 +119,9 @@ todo
|
||||||
eventually this should support mathjax and highlighted code and stuff
|
eventually this should support mathjax and highlighted code and stuff
|
||||||
mathjax should be rendered as the mozilla native math thing with a javascript polyfill for gogle
|
mathjax should be rendered as the mozilla native math thing with a javascript polyfill for gogle
|
||||||
chrombe and others
|
chrombe and others
|
||||||
|
rss/atom
|
||||||
|
gopher
|
||||||
|
gemini
|
||||||
|
|
||||||
nginx caching -
|
nginx caching -
|
||||||
https://blog.theodo.com/2016/06/improve-the-performance-of-your-webapp-configure-nginx-to-cache/
|
https://blog.theodo.com/2016/06/improve-the-performance-of-your-webapp-configure-nginx-to-cache/
|
||||||
|
|
|
@ -215,5 +215,5 @@
|
||||||
|
|
||||||
(define ops (generate-operations compiler-rules))
|
(define ops (generate-operations compiler-rules))
|
||||||
(for ([op (in-list ops)])
|
(for ([op (in-list ops)])
|
||||||
(printf "executing ~s\n" op)
|
(printf "BUILD: ~a\n" (rule-output op))
|
||||||
(execute-rule op))
|
(execute-rule op))
|
||||||
|
|
|
@ -57,6 +57,10 @@
|
||||||
;; workers that are waiting for work
|
;; workers that are waiting for work
|
||||||
(define dequeue-waiters (mutable-set))
|
(define dequeue-waiters (mutable-set))
|
||||||
|
|
||||||
|
;; create an exn:fail but don't raise it
|
||||||
|
(define (make-error str)
|
||||||
|
(exn:fail (format "error: ~a" str) (current-continuation-marks)))
|
||||||
|
|
||||||
;; adds a waiter for a task with given id
|
;; adds a waiter for a task with given id
|
||||||
(define (add-task-waiter! id from)
|
(define (add-task-waiter! id from)
|
||||||
(hash-update! task-waiters id (lambda (s) (set-add s from)) set))
|
(hash-update! task-waiters id (lambda (s) (set-add s from)) set))
|
||||||
|
@ -96,7 +100,7 @@
|
||||||
(thread-send w #f #f))
|
(thread-send w #f #f))
|
||||||
(for ([(k v) (in-hash task-waiters)])
|
(for ([(k v) (in-hash task-waiters)])
|
||||||
(for ([w (in-set v)])
|
(for ([w (in-set v)])
|
||||||
(thread-send w (error "queue shutdown") #f))))
|
(thread-send w (make-error "queue shutdown") #f))))
|
||||||
|
|
||||||
;; attempts to dequeue the next work
|
;; attempts to dequeue the next work
|
||||||
;; if there is work, set it to executing and invoke and remove one of the workers
|
;; if there is work, set it to executing and invoke and remove one of the workers
|
||||||
|
@ -172,7 +176,7 @@
|
||||||
['dequeue (dequeue from) (loop)]
|
['dequeue (dequeue from) (loop)]
|
||||||
['complete (complete from data) (loop)]
|
['complete (complete from data) (loop)]
|
||||||
['resched (resched from data) (loop)]
|
['resched (resched from data) (loop)]
|
||||||
[_ (thread-send from (error "unknown message") #f) (loop)])]))
|
[_ (thread-send from (make-error "unknown message") #f) (loop)])]))
|
||||||
|
|
||||||
;; disconnect and exit
|
;; disconnect and exit
|
||||||
(disconnect c)
|
(disconnect c)
|
||||||
|
|
Loading…
Reference in New Issue