6 our $VERSION = '0.0001';
8 use base 'Mojolicious';
10 use Data::Dump qw(dump);
12 # This method will run once at server start
17 my $r = $self->routes;
20 $r->route('/:controller/:action/:id')->to('data#index', id => 1);
22 # $self->plugin( 'request_timer' );
24 $self->plugins->add_hook(
25 before_dispatch => sub {
28 # Do whatever you want with the transaction here
29 if ( $tx->req->url->query ) {
30 warn "# before_dispatch url ",dump($tx->req->url);