Skip to content

Commit

Permalink
put sending handler first
Browse files Browse the repository at this point in the history
  • Loading branch information
Paul M. Jones committed Jun 6, 2015
1 parent e770fb3 commit 248f0f9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions docs/execution.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,11 @@ Sending handlers), etc.

The initial `web/index.php` installation runs four middleware handlers:

- _Radar\Adr\Handler\ExceptionHandler_ as a final fallback to catch exceptions.
- _Radar\Adr\Handler\SendingHandler_ to pass along the inbound request without modification, and send back the outbound response after all other middlware have processed it;

- _Radar\Adr\Handler\RoutingHandler_ to determine the _Route_ based on the _ServerRequest_,
- _Radar\Adr\Handler\ExceptionHandler_ as a final fallback to catch exceptions;

- _Radar\Adr\Handler\RoutingHandler_ to determine the _Route_ based on the _ServerRequest_;

- _Radar\Adr\Handler\ActionHandler_ to use the _Route_ for the action-domain-responder activity:

Expand All @@ -32,8 +34,6 @@ The initial `web/index.php` installation runs four middleware handlers:
- A _Responder_ callable is invoked with the _Domain_ output; the
_Responder_ then builds the outgoing HTTP _Response_ message.

- _Radar\Adr\Handler\SendingHandler_ to send the _Response_.

You can prepend, append, or replace these handlers in `web/index.php` with your own middleware.

### Navigation
Expand Down
2 changes: 1 addition & 1 deletion web/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@
*/

// pipeline middleware
$adr->middle('Radar\Adr\Handler\SendingHandler');
$adr->middle('Radar\Adr\Handler\ExceptionHandler');
$adr->middle('Radar\Adr\Handler\RoutingHandler');
$adr->middle('Radar\Adr\Handler\ActionHandler');
$adr->middle('Radar\Adr\Handler\SendingHandler');

// routes
$adr->get('Hello', '/{name}?', function (array $input) {
Expand Down

0 comments on commit 248f0f9

Please sign in to comment.