Bio::Das::ProServer::SourceHydra - A runtime factory for B::D::P::SourceAdaptors
$Revision: 687 $
Inherit and extend this class to provide hydra implementations
Roger Pettett <rmp@sanger.ac.uk>.
Copyright (c) 2007 The Sanger Institute
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See DISCLAIMER.txt for disclaimers of warranty.
The SourceHydra's role is to clone a series of SourceAdaptors of the same type but each configured in a (systematically) different way, but with only one configuration file section.
For example the hydra is pivotal in the Ensembl upload service where each data upload is of the same structure and loaded into a numbered table in a database. In order to provide a valid DSN for each uploaded source, the hydra then clones a series of dbi-based sources, pointing them all at the upload database but each one at a different table.
The hydra can also be useful in situations such as the provision of similar sources for different species where the data are in different databases but have the same structure in each.
my $hydra = Bio::Das::ProServer::SourceHydra->new({ 'config' => $cfg, # The config section for this hydra 'debug' => $dbg, # Boolean debug flag });
Implemented in subclasses if necessary (not usually)
my $transport = $hydra->transport();
my $cfg = $hydra->config();
my @sources = $hydra->sources();
Configure in proserver.ini using: hydra = <impl>
Set $self->{'debug'} = 1; Or B::D::P::SourceHydra::impl->new({'debug'=>1});
Bio::Das::ProServer::SourceAdaptor
To install Bio::Das::ProServer, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Bio::Das::ProServer
CPAN shell
perl -MCPAN -e shell install Bio::Das::ProServer
For more information on module installation, please visit the detailed CPAN module installation guide.