Permalink
Browse files

Removed Plack::Server. Was meant to be killed in 1.0 but forgotten.

  • Loading branch information...
1 parent b8d90c1 commit 2cafc30a7a2f97835bc68c896ed30c00980ae0c7 @miyagawa miyagawa committed Jul 25, 2012
View
14 lib/Plack/Loader.pm
@@ -37,15 +37,11 @@ sub load {
my($class, $server, @args) = @_;
my($server_class, $error);
- for my $prefix (qw( Plack::Handler Plack::Server )) {
- try {
- $server_class = Plack::Util::load_class($server, $prefix);
- } catch {
- $error ||= $_;
- };
- last if $server_class;
- last if $error && $error !~ /^Can't locate Plack\/Handler\//;
- }
+ try {
+ $server_class = Plack::Util::load_class($server, 'Plack::Handler');
+ } catch {
+ $error ||= $_;
+ };
if ($server_class) {
$server_class->new(@args);
View
17 lib/Plack/Server.pm
@@ -1,17 +0,0 @@
-package Plack::Server;
-use strict;
-
-1;
-
-__END__
-
-=head1 NAME
-
-Plack::Server - DEPRECATED. See Plack::Handler
-
-=head1 SEE ALSO
-
-L<Plack::Handler>
-
-=cut
-
View
24 lib/Plack/Server/Apache1.pm
@@ -1,24 +0,0 @@
-package Plack::Server::Apache1;
-use strict;
-use parent qw(Plack::Handler::Apache1);
-use Carp;
-
-sub new {
- my $class = shift;
- Carp::carp "Use of $class is deprecated. Use Plack::Handler::Apache1 or Plack::Loader to upgrade.";
- $class->SUPER::new(@_);
-}
-
-1;
-
-__END__
-
-=head1 NAME
-
-Plack::Server::Apache1 - DEPRECATED
-
-=head1 DESCRIPTION
-
-B<This module is deprecated>. See L<Plack::Handler::Apache1>.
-
-=cut
View
24 lib/Plack/Server/Apache2.pm
@@ -1,24 +0,0 @@
-package Plack::Server::Apache2;
-use strict;
-use parent qw(Plack::Handler::Apache2);
-use Carp;
-
-sub new {
- my $class = shift;
- Carp::carp "Use of $class is deprecated. Use Plack::Handler::Apache2 or Plack::Loader to upgrade.";
- $class->SUPER::new(@_);
-}
-
-1;
-
-__END__
-
-=head1 NAME
-
-Plack::Server::Apache2 - DEPRECATED
-
-=head1 DESCRIPTION
-
-B<This module is deprecated>. See L<Plack::Handler::Apache2>.
-
-=cut
View
23 lib/Plack/Server/CGI.pm
@@ -1,23 +0,0 @@
-package Plack::Server::CGI;
-use strict;
-use parent qw(Plack::Handler::CGI);
-
-sub new {
- my $class = shift;
- print STDERR "Use of $class is deprecated. Use Plack::Handler::CGI or Plack::Loader to upgrade.\n";
- $class->SUPER::new(@_);
-}
-
-1;
-
-__END__
-
-=head1 NAME
-
-Plack::Server::CGI - DEPRECATED
-
-=head1 DESCRIPTION
-
-B<This module is deprecated>. See L<Plack::Handler::CGI>.
-
-=cut
View
24 lib/Plack/Server/FCGI.pm
@@ -1,24 +0,0 @@
-package Plack::Server::FCGI;
-use strict;
-use parent qw(Plack::Handler::FCGI);
-use Carp;
-
-sub new {
- my $class = shift;
- Carp::carp "Use of $class is deprecated. Use Plack::Handler::FCGI or Plack::Loader to upgrade.";
- $class->SUPER::new(@_);
-}
-
-1;
-
-__END__
-
-=head1 NAME
-
-Plack::Server::FCGI - DEPRECATED
-
-=head1 DESCRIPTION
-
-B<This module is deprecated>. See L<Plack::Handler::FCGI>.
-
-=cut
View
1 lib/Plack/Server/README
@@ -1 +0,0 @@
-This directory and files exist for the backward compatiblities before 0.9032.
View
27 lib/Plack/Server/ServerSimple.pm
@@ -1,27 +0,0 @@
-package Plack::Server::ServerSimple;
-use strict;
-our $VERSION = '1.0000';
-$VERSION = eval $VERSION;
-
-use parent qw(Plack::Handler::HTTP::Server::Simple);
-use Carp;
-
-sub new {
- my $class = shift;
- Carp::carp "$class is deprecated. Use -s HTTP::Server::Simple";
- $class->SUPER::new(@_);
-}
-
-1;
-
-__END__
-
-=head1 NAME
-
-Plack::Server::ServerSimple - DEPRECATED
-
-=head1 DESCRIPTION
-
-B<DEPRECATED>. Use Plack::Handler::HTTP::Server::Simple.
-
-=cut
View
24 lib/Plack/Server/Standalone.pm
@@ -1,24 +0,0 @@
-package Plack::Server::Standalone;
-use strict;
-use parent qw(Plack::Handler::Standalone);
-use Carp;
-
-sub new {
- my $class = shift;
- Carp::carp "Use of $class is deprecated. Use Plack::Handler::Standalone or Plack::Loader to upgrade.";
- $class->SUPER::new(@_);
-}
-
-1;
-
-__END__
-
-=head1 NAME
-
-Plack::Server::Standalone - DEPRECATED
-
-=head1 DESCRIPTION
-
-B<This module is deprecated>. See L<Plack::Handler::Standalone>.
-
-=cut
View
28 lib/Plack/Server/Standalone/Prefork.pm
@@ -1,28 +0,0 @@
-package Plack::Server::Standalone::Prefork;
-use strict;
-use parent qw(HTTP::Server::PSGI); # because Standalone is a wrapper
-use Carp;
-
-sub new {
- my $class = shift;
- Carp::carp "Use of $class is deprecated. Use Starman or Starlet for preforking servers.";
- $class->SUPER::new(@_);
-}
-
-1;
-
-__END__
-
-=head1 NAME
-
-Plack::Server::Standalone::Prefork - DEPRECATED use Starman or Starlet instead
-
-=head1 DESCRIPTION
-
-B<This module is deprecated>.
-
-=head1 SEE ALSO
-
-L<HTTP::Server::PSGI> L<Starman> L<Starlet>
-
-=cut
View
34 t/Plack-Server/compat.t
@@ -1,34 +0,0 @@
-use strict;
-use Plack::Server::CGI;
-use Test::More;
-use Test::Requires {
- 'HTTP::Request::AsCGI' => 1.2,
-};
-use HTTP::Request;
-
-my $app = sub {
- my $env = shift;
- return [ 200, [ "Content-Type", "text/plain" ], [ $env->{PATH_INFO} ] ];
-};
-
-my $req = HTTP::Request->new(GET => "http://localhost/foo");
-my $cgi = HTTP::Request::AsCGI->new($req);
-my $c = $cgi->setup;
-$ENV{SCRIPT_NAME} = '/plack_test.cgi';
-
-my $stderr;
-{
- close STDERR;
- open STDERR, ">", \$stderr;
- my $s = Plack::Server::CGI->new;
- $s->run($app);
-}
-
-my $res = $c->response;
-is $res->content, "/foo";
-like $stderr, qr/deprecated/;
-
-done_testing;
-
-
-

0 comments on commit 2cafc30

Please sign in to comment.