NAME

OpenPlugin::Datasource - plugin for datasource connection managers

SYNOPSIS

my $dbh  = $OP->datasource->connect( 'MyDataSourceName' );
my $ldap = $OP->datasource->connect( 'LDAP_DataSourceName' );

...

$OP->datasource->disconnect( 'MyDataSourceName' );

DESCRIPTION

This plugin provides a wrapper around connection methods for DBI, LDAP or any other type of connections needed. It caches the connections for reuse throughout the lifetime of the application, although it contains no behavior (yet) for keeping the connections alive.

METHODS

connect( $datasource_name, \%datasource_info )

Returns datasource mapping to $datasource_name, as defined in the config file.

disconnect( $datasource_name )

Disconnects datasource $datasource_name.

shutdown()

Disconnects all datasources.

BUGS

None known.

TO DO

Nothing known.

SEE ALSO

See the individual datasource drivers for details on configuration and usage.

OpenPlugin::Datasource::DBI, OpenPlugin::Datasource::LDAP

COPYRIGHT

Copyright (c) 2001-2002 Eric Andreychek. All rights reserved.

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

AUTHORS

Eric Andreychek <eric@openthought.net>