v0.5
Diff: v0.4...v0.5
New:
- rewrited documentation
- Apitte is now wrapped into own
Application
class which must be used for proper functioning (see documentation) - error handler
- transforms all thrown errors into response
- could be disabled by option
catchException: false
in debug mode - apitte/negotiation is used for error transformation instead, if installed
- could be disabled by option
- if an PSR-3 compatible logger (like Monolog) is register in DIC then all errors except our special
ApiException
and it's descendants (ServerErrorException
,ClientErrorException
, ...) are logged witherror
severity- also previous errors from
ApiException
($exception->withPrevious($anotherException)
) are logged
- also previous errors from
- transforms all thrown errors into response
ClientErrorException
andServerErrorException
have default error message contributte/apitte@866418d- new
Request
,Response
andOpenApi
annotations (used by apitte/openapi) contributte/apitte@31d7008 ApiResponse
contain constants with all HTTP response codes contributte/apitte@342311b- request parameters with type
int
andfloat
accept numbers prefixed with+
contributte/apitte@969f9d5 - apitte/playground merged with planette/playground
Changes:
- simplified
ServiceHandler
, overriding implementations need changes contributte/apitte@ccafbd4 FileResponseDecorator
changed to staticFileResponseAdjuster
contributte/apitte@2337b4eIRequestEntity
implementation is now optional for request mapper entities contributte/apitte@38785e1IDecorator
splitted into strictly-typed interfaces contributte/apitte@73597e7ApiRequest
andApiResponse
are now required by all layers instead ofServerRequestInterface
andResponseInterface
contributte/apitte@d3c4ceb
Removals:
- support for alternative, undocumented syntax for most annotations contributte/apitte@e7fced3
Controller
annotation, controllers are now required to only implementIController
contributte/apitte@d0e38d9Schema
from request attributes, as it could be get from DIC contributte/apitte@44c2e28
Fixes:
- tags without value contributte/apitte@028ee61
- url suffixes used in apitte/negotiation now support urls with variable parameter at the end (like
/users/{id}.debug
) contributte/apitte@5c0ea43 - MessageException - default error code contributte/apitte@1cf0d89