This list is not currently intended to be all-encompassing - it will document major and breaking API changes with their rationale when appropriate:
- Fix #57. Static handlers behave oddly when combined with an HTTP verb in the routing tree.
- Fix #56. Altered behaviour of
CatchLensFailureto NOT catch errors from unmarshalling Response objects. This was causing BAD_REQUEST to be incorrectly generated.
- Simplification of generics around LensSpecs. This should not be a breaking change, (there were 3 generics, now the MID has been removed so there are just 2) but could break if signatures are used explicitly.
- Reordered generics in LensInjector to make sense. This should have no effect on most code-bases, but could break if signatures are used explicitly. Just flip the generic types to switch.
- Added support for unsigned AWS requests, which enables streaming content to S3.
BodyMode.Requestto configure streaming for clients.
BodyMode.Response(Breaking change. Fixable with simple find/replace).
ServerFilter.ProcessFilesfilter to stream Multipart Files, convert them into references and replace inline in the Form.
- Avoid realising StreamBody unless necessary, which could break common usages of streaming.
- Tweaks to Server backends to improve efficiency.
- Webdriver will keep only the final URI after redirects.
- Increased granularity of
Replay.DiskStreamand ensure that traffic is returned in exact order on all OSes.
- Add support for redirects to Webdriver.
- Multipart module tweaked to provide a more consistent API.
- Fix FollowRedirects for POST/PUT request.
- Multipart form support through new module
- Deprecation: Replaced
OpenApiand deprecated the former (via typealias).
- Deprecation: Replaced
Validatorand deprecated the former (via typealias).
- Refactor release.
- Fix #50 - Webdriver does not normalise relative links correctly.
- Http client modules now catch and convert Socket Timeout exceptions to HTTP 504s (with a custom message)
- Tweaks to how recorded traffic is stored on disk. Thanks to @dkandalov for the PR around this.
TrafficFiltersfor recording and replaying HTTP traffic. See
org.http4k.trafficpackage for details.
http4k-template-dustfor Dust template engine support. Thanks to @npryce for the PR to add this.
- Fix #44 - Use quotes around cookie values
- Raise proper Exception (instead of LensFailure) when RequestContexts are not set up correctly, so we don't accidentally classify developer errors as BadRequests
- Added facility to assign values into a
RequestContextwhich is passed down the Filter chain.
- Fix #44 - Request cookies should not be wrapped in quotes.
- Fix #43 - AWS does not sign binary requests correctly.
- Fix #41 - Sending binary body alters the size of the payload.
- Added "catch all" routing option, which matches all methods to a handler.
- Fix #40 - GZip filters now use content-encoding headers instead of transfer-encoding.
- Fix #39 - ResponseBodyMode.Memory properly closes streams (breaks jetty + gzip).
- Ensure that streams are closed properly when consuming from an upstream client.
- Remove Apache client request streaming because it may not release connections properly.
- Add streaming support to HTTP Server and Client modules.
- Remove CatchLensFailure ClientFilter as it will never be used.
- Added CatchLensFailure for ClientFilters - which catches un-deserializable invalid responses from clients and generates a BAD_GATEWAY error.
- Switch XML generation to Gson over Jackson because Jackson doesn't handle uppercase field names well.
- Switch native XML parsed type to Document over Node.
- New algorithm for XML data class deserialisation, so un-deprecated XML methods.
- Deprecated methods in XML support due to limitation with underlying Jackson implementation.
- Fixed bug with GenerateXmlDataClasses filter
- Improved XML unmarshalling support.
- Fixed 36: Form entry is too strict with content encoding.
http4k-format-jackson-xmlmodule, with XML parsing support.
- Upgrade several dependencies
- Fixed Hamkrest matchers to be on HttpMessage and not Http Request.
- Default body Content Negotiation strategy changed to None
- Converted Content-Negotiation strategy from an Enum to an interface, so that users can define their own strategies. We also now check encoding so there are 4-built in strategies to choose from: Strict, StrictNoDirective, NonStrict and None.
- Fixed #31 - Matching of segments in URIs is done after URLs are decoded, which results in not capturing encoded slashes in the path segments.
- Fixed #30 - CachingClasspath template ResourceLoader not working with non-root packages.
- Fixed #29 - webdriver submission of text area.
- Http clients now use a new instance of the default for each instantiation. Previously there was a shared instance.
- Add regex body type for parsing values out of bodies, and "None" option for content negotiation.
- Fix AWS request signing for requests containing empty path
- Fix AWS request signing for requests containing path with special characters
- Added support for newRequest() in new
- Add support for unlimited nesting for
routes()blocks. Removed the raw
Routeobject, which can be replaced with
- As part of above, rejigged route setup logic. Deprecated old routing structure, so now
"/path" to GET bindis
"/path" bind GET to. To fix deprecation, simply switch the calls to "to" and "bind" in routing setup.
- Rename of
- Added missing eclectic HTTP method. :)
- Added GZip filters to
http4k-coreto zip request and response bodies.
- Improved messages for
http4k-testing-hamkrestwhich contains a set of Hamkrest matchers for Http4k objects.
- More features for
http4k-testing-webdriver. Cookie support added.
- More features for
http4k-testing-webdriver. We now support Form entry and submission.
- More features for
http4k-testing-webdrivermodule, an ultralight Selenium WebDriver for http4k apps
- Fix #26 - GenerateDataClasses does not recurse into nested object trees
- Fix filter application on GroupRoutingHttpHandler to apply the filter when it is applied with
- Fix static routes not defaulting to index.html when in root context
SunHttpserver implementation (for development use only)
- Fix cookie parsing when value contains '='
- Add method to set form values in the request
- Added PURGE HTTP method as it's used commonly by various caches.
- Repackage AWS classes for consistency with rest of project
- Alter AWS Auth filter creation. Now use
- Add AWS module
- Newly created Zipkin traces are now populated onto incoming request in ServerFilters.
- Slight tweak to GSON auto-marshalling to allow for use of raw Arrays with auto-marshalling
- Make Route a Router so we can nest them together.
- Remove excess "charset" from headers in Undertow.
bind()in routing for clarity.
- Fix for #24 - UriTemplate captures query parameters when the trailing path parameter is a regex.
- Added GSON full-auto functions to convert arbitary objects to/from JSON.
- Fix #23. Contract now supports multi-part URL params (for hardcoded parts)
- Fix #22. Uri template does not parse out correct path params when URL starts with a path part.
- toString() implementations to aid debugging
- Readded missing default parameter for
- Breaking: Inversion of routing API.
GET to "/someUri"is now
"/someUri" to GETfor consistency across the entire API.
- Reimplementation of
http4k-contractAPI to match main routing API. Contracts are now nestable.
- Fix Filters being applied twice in
- More work on
http4k-contractrouting to be mounted in the same way as other
- Filters are now applied consistently to all Routers
- Tweak to DSL for defining StaticRouters
- Fix for #18: FollowRedirect will now work if location header includes charset information.
- New DSL for defining StaticRouters
- Merged StaticContent and StaticRouter and repackage of contract API into other packages
- Extend fix for #17 to request
- Fix for #17. Cookie can now parse a cookie without attributes and ending in semicolon.
- Added nestable Routers.
- Merging of Modules and Routers.
Routeris the new
ContractRouter, so rename in code will be required.
- Fix for #15. OkHttp client handling of POSTs with no body.
- Can add custom mime types to Static Content
- GenerateDataClasses is capable of more complex object graphs
HttpHandler.asServerin favour of
HttpHandler.startServerto avoid confusion.
- Netty sets content-length header.
- Fix for #12. Undertow not constructing response correctly.
- New module with Undertow.io support
- Jackson implementation now ignores unknown properties in incoming messages
- Netty implementation tidied up
- Fix for #11. Netty implementation returns incorrect status codes.
- Add synonym methods for Lenses to aid readability. We now have
invoke(IN)/extract(IN)and `invoke(IN, TARGET)/inject(IN, TARGET)
http4k-contracts: Add option to change the route of the module description route
http4k-contracts: Fix for contract module description routes not being authenticated via security filter
Swaggermodule rendering with JSON schema models for messages.
nonEmptyString()lens type to all request parts.
- General rework
- Further work on Path Lenses. They are now fully supported and consistent for both simple and contract routing scenarios.
- Path lenses are now bidirectional, so can be used to populate requests as well as bodies an headers etc.
- Routes can now create shell Requests for themselves, using
- Body is now non-nullable (use
- Rename methods
BodyLensAPI for consistency and clarity.
to()' binding method is nowof().
- New client module:
- Added option for Body content-negotiation to be strict or non-strict (the default). Always be strict in what you send, relaxed in what you will accept. :)
- Add various filters, including
GenerateDataClassesso you can generate Kotlin data classes from JSON messages.
- Added CORs support
- Added auto() to Jackson, so you can auto convert body objects into and out of Requests/Responses
- Added CachingFilters
- Removed static factory methods for Request/Response. They were confusing/incomplete and users can easily recreate them via extension functions.
- Add Request/Response message parsers.
- Turn Body into ByteBuffer wrapper rather than typealias. That should make .toString() behave as most people would expected.
- Removed non-mandatory parameters from Request and Response constructors. This is aid API clarity. and force users to use the API methods for properly constructing the objects.
- Regex Lens added.
- Initial major release.