You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add an optional Init func to the server, fix a data race
That takes a config struct from the client.
The old way of configuring the server was to pass env vars (which still works), but this was at best very cumbersome.
This also fixes a data race when both sending raw (e.g. log messages) and other responses.
Closes#10
Message streaming, ETag support etc.
The old request/response setup worked great, but had its limitations.
The new model types are request, message (zero or more) and a receipt.
The receipt can immplement some optional interfaces that gets/sets
* ETag
* ELastModified
* ESize
These may autimatically be set by the library if not provided by user (the `Etag` bassed on all message bodies if there's a hash function configured).
The primary use case for the above would be client side caching.
This also removes the slow Gob codec.
Fix Header.Status
The size indices were not adjusted when we changed to int16 recently, which made it
overwrite the header status. Which shows the importance of good tests.
Improve error handling when resolving codec
And remove the go.work files that masked a faulty test setup.
This is replaced with replace statements in the examples, which is OK as those are only used in
tests/as examples.