Commit Graph

3 Commits

Author SHA1 Message Date
Gabriel Gonzalez
d4a80a9a4e Make server process killable
35163c3c18
introduced a new use of `mask` which makes the server process uninterruptible
while waiting for a new incoming request.  This change fixes that by
surrounding the logic that waits for a new request with `unmask`.  This
new `unmask` should still respect the finalization guarantees of the
surrounding masked code.
2020-05-27 16:48:18 -07:00
Moritz Kiefer
35163c3c18 Fix async exception handling (#86)
Previously, grpc-haskell used a lot of code in the form of

```
do x <- acquireResource
   f x `finally` releaseResource x
```

This is not safe since you can get killed after acquiring the resource
but before installing the exception handler via `finally`. We have
seen various gRPC assertion errors and crashes on shutdown when this
got triggered.
2019-08-22 10:55:33 -05:00
Christian Lavoie
9cfb3da770 Extract lowlevel bits into a core package (#42) 2018-01-29 08:59:34 -08:00