1 package DBIx::Class::Storage::DBI::Replicated::Balancer::First;
4 with 'DBIx::Class::Storage::DBI::Replicated::Balancer';
5 use namespace::clean -except => 'meta';
9 DBIx::Class::Storage::DBI::Replicated::Balancer::First - Just get the First Balancer
13 This class is used internally by L<DBIx::Class::Storage::DBI::Replicated>. You
14 shouldn't need to create instances of this class.
18 Given a pool (L<DBIx::Class::Storage::DBI::Replicated::Pool>) of replicated
19 database's (L<DBIx::Class::Storage::DBI::Replicated::Replicant>), defines a
20 method by which query load can be spread out across each replicant in the pool.
22 This Balancer just gets whichever is the first replicant in the pool.
26 This class defines the following attributes.
30 This class defines the following methods.
34 Just get the first storage. Probably only good when you have one replicant.
39 return (shift->pool->active_replicants)[0];
44 John Napiorkowski <john.napiorkowski@takkle.com>
48 You may distribute this code under the same terms as Perl itself.
52 __PACKAGE__->meta->make_immutable;