Skip to content

Instantly share code, notes, and snippets.

@miyagawa
Created March 8, 2009 07:27
Show Gist options
  • Save miyagawa/75584 to your computer and use it in GitHub Desktop.
Save miyagawa/75584 to your computer and use it in GitHub Desktop.
diff --git a/lib/Remedie/Server.pm b/lib/Remedie/Server.pm
index 4acba67..ef027fb 100644
--- a/lib/Remedie/Server.pm
+++ b/lib/Remedie/Server.pm
@@ -20,7 +20,6 @@ has 'engine' => (
isa => 'HTTP::Engine',
lazy => 1,
builder => 'build_engine',
- handles => [ qw(run) ],
);
__PACKAGE__->meta->make_immutable;
@@ -39,7 +38,8 @@ sub bootstrap {
local $SIG{INT} = $exit if !$ENV{REMEDIE_DEBUG};
local $SIG{QUIT} = $exit;
local $SIG{TERM} = $exit;
- $self->run;
+ $self->engine->run;
+ POE::Kernel->run;
};
Remedie::Log->log(error => "Exiting feed... $@");
}
@@ -66,7 +66,7 @@ sub build_engine {
Remedie::Log->log(debug => "Initializing with HTTP::Engine version $HTTP::Engine::VERSION");
return HTTP::Engine->new(
interface => {
- module => 'ServerSimple',
+ module => 'POE',
args => $self->conf,
request_handler => sub { $self->handle_request(@_) },
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment