summaryrefslogtreecommitdiff
path: root/CHANGELOG.md
diff options
context:
space:
mode:
authorEugen Wissner <belka@caraus.de>2020-07-17 07:05:03 +0200
committerEugen Wissner <belka@caraus.de>2020-07-17 07:05:03 +0200
commit09135c581aaae471f7d964bc2a3a141bef299097 (patch)
treebf26b907a13e5f358f91e4c2d7ef661e74fa6805 /CHANGELOG.md
parente24386402be444e643d7d9c8ef82c1fe2205c7fc (diff)
downloadgraphql-09135c581aaae471f7d964bc2a3a141bef299097.tar.gz
Constrain base monad to MonadCatch
Let's try MonadThrow/MonadCatch. It looks nice at a first glance. The monad transformer stack contains only the ReaderT, less lifts are required. Exception subtyping is easier, the user can (and should) define custom error types and throw them. And it is still possible to use pure error handling, if someone doesn't like runtime exceptions or need to run a query in a pure environment. Fixes #42.
Diffstat (limited to 'CHANGELOG.md')
-rw-r--r--CHANGELOG.md8
1 files changed, 7 insertions, 1 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 224f936..79cf9c7 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -24,12 +24,16 @@ and this project adheres to
- Parsing subscriptions (the execution always fails yet).
- `Error.ResponseEventStream`, `Type.Out.Resolve`, `Type.Out.Subscribe` and
`Type.Out.SourceEventStream` define subscription resolvers.
+- `Error.ResolverException` is an exception that can be thrown by (field value
+ and event stream) resolvers to signalize an error. Other exceptions will
+ escape.
## Changed
- `Type.Out.Resolver`: Interface fields don't have resolvers, object fields
have value resolvers, root subscription type resolvers need an additional
resolver that creates an event stream. `Resolver` represents these differences
- now and pairs a field with the function(s).
+ now and pairs a field with the function(s). Resolvers don't have `ExceptT`,
+ errors are handled with `MonadThrow`/`MonadCatch`.
- All code from `Trans` is moved to `Type.Out` and exported by `Type` and
`Type.Out`.
- `AST.Core` contained only `Arguments` which was moved to `Type.Definition`.
@@ -43,6 +47,8 @@ and this project adheres to
variable names is changed back to JSON since it is a common format and it
saves additional conversions. Custom format still can be used with the
underlying functions (in the `Execute` module).
+- The constraint of the base monad was changed to `MonadCatch` (and it implies
+ `MonadThrow`).
## Removed
- `Trans.ActionT` is an unneeded layer of complexity. `Type.Out.Resolver`