1# ====================================================================== 2# 3# Copyright (C) 2000-2001 Paul Kulchenko (paulclinger@yahoo.com) 4# SOAP::Lite is free software; you can redistribute it 5# and/or modify it under the same terms as Perl itself. 6# 7# $Id: SOAP.pm 249 2008-05-05 20:35:05Z kutterma $ 8# 9# ====================================================================== 10 11package Apache::SOAP; 12 13use strict; 14use vars qw(@ISA $VERSION); 15use SOAP::Transport::HTTP; 16 17@ISA = qw(SOAP::Transport::HTTP::Apache); 18use version; $VERSION = qv('0.710.05'); 19 20my $server = __PACKAGE__->new; 21 22sub server { 23 return $server; 24} 25 26sub handler { 27 $server->configure(@_); 28 $server->SUPER::handler(@_); 29} 30 31# ====================================================================== 32 331; 34 35__END__ 36 37=head1 NAME 38 39Apache::SOAP - mod_perl-based SOAP server with minimum configuration 40 41=head1 SYNOPSIS 42 43=over 4 44 45=item httpd.conf (Location), directory-based access 46 47 <Location /mod_soap> 48 SetHandler perl-script 49 PerlHandler Apache::SOAP 50 PerlSetVar dispatch_to "/Your/Path/To/Deployed/Modules, Module::Name, Module::method" 51 PerlSetVar options "compress_threshold => 10000" 52 </Location> 53 54=item httpd.conf (Files), file-based access 55 56 <FilesMatch "\.soap$"> 57 SetHandler perl-script 58 PerlHandler Apache::SOAP 59 PerlSetVar dispatch_to "/Your/Path/To/Deployed/Modules, Module::Name, Module::method" 60 PerlSetVar options "compress_threshold => 10000" 61 </FilesMatch> 62 63=item .htaccess, directory-based access 64 65 SetHandler perl-script 66 PerlHandler Apache::SOAP 67 PerlSetVar dispatch_to "/Your/Path/To/Deployed/Modules, Module::Name, Module::method" 68 PerlSetVar options "compress_threshold => 10000" 69 70=back 71 72=head1 DESCRIPTION 73 74This Apache Perl module provides the ability to add support for SOAP (Simple 75Object Access Protocol) protocol with easy configuration (either in .conf or 76in .htaccess file). This functionality should give you lightweight option 77for hosting SOAP services and greatly simplify configuration aspects. This 78module inherites functionality from SOAP::Transport::HTTP::Apache component 79of SOAP::Lite module. 80 81=head1 CONFIGURATION 82 83The module can be placed in <Location>, <Directory>, <Files>, <FilesMatch> 84directives in main server configuration areas or directly in .htaccess file. 85 86All parameters should be quoted and can be separated with commas or spaces 87for lists ("a, b, c") and with 'wide arrows' and commas for hash parameters 88("key1 => value1, key2 => value2"). 89 90All options that you can find in SOAP::Transport::HTTP::Apache component 91are available for configuration. Here is the description of most important 92ones. 93 94=over 4 95 96=item dispatch_to (LIST) 97 98Specifies path to directory that contains Perl modules you'd like to give 99access to, or just list of modules (for preloaded modules). 100 101 PerlSetVar dispatch_to "/Your/Path/To/Deployed/Modules, Module::Name, Module::method" 102 103=item options (HASH) 104 105Specifies list of options for your module, for example threshold for 106compression. Future versions will support more options. See 107SOAP::Transport::HTTP documentation for other options. 108 109 PerlSetVar options "compress_threshold => 10000" 110 111=back 112 113=head1 METHODS/SUBROUTINES 114 115=head2 server 116 117 my $server = Apache::XMLRPC::Lite->server(); 118 119Returns the server object. 120 121Useful if you need to manipulate the server object from your code. 122 123=head2 handle 124 125Request handler. Called by apache. 126 127=head1 DEPENDENCIES 128 129 SOAP::Lite 130 mod_perl 131 132=head1 SEE ALSO 133 134 SOAP::Transport::HTTP::Apache for implementation details, 135 SOAP::Lite for general information, and 136 F<examples/server/mod_soap.htaccess> for .htaccess example 137 138=head1 COPYRIGHT 139 140Copyright (C) 2000-2001 Paul Kulchenko. All rights reserved. 141 142This library is free software; you can redistribute it and/or modify 143it under the same terms as Perl itself. 144 145=head1 AUTHOR 146 147Paul Kulchenko (paulclinger@yahoo.com) 148 149=cut 150