Permalink
Browse files

register_service (thanks miyagawa)

  • Loading branch information...
1 parent 290cefd commit 0ba0323cfe1cb798e4553e1b8bf19b70e9b052b1 @frodwith committed Oct 15, 2009
Showing with 7 additions and 1 deletion.
  1. +7 −1 lib/Plack/Server/POE.pm
View
@@ -21,8 +21,9 @@ sub new {
return bless $opt, $class;
}
-sub run {
+sub register_service {
my ($self, $app) = @_;
+
my $filter = POE::Filter::HTTP::Parser->new( type => 'server' );
POE::Component::Server::TCP->new(
Port => $self->{port},
@@ -85,6 +86,11 @@ sub run {
}
},
);
+}
+
+sub run {
+ my ($self, $app) = @_;
+ $self->register_service($app);
POE::Kernel->run;
}

0 comments on commit 0ba0323

Please sign in to comment.