AnyMQ-Pg

 view release on metacpan or  search on metacpan

lib/AnyMQ/Trait/Pg.pm  view on Meta::CPAN

sub BUILD {
    my ($self) = @_;
    
    # once everything is set up, we can construct and connect our client object
    $self->_client;
}

# JSON codec pack
sub _build__json {
    my ($self) = @_;
    return JSON->new->utf8;
}

sub _build_client {
    my ($self) = @_;

    my $dsn = $self->dsn;
    my $pg = AnyEvent::Pg->new(
        $dsn,
        on_connect       => sub { $self->_on_connect(@_) },
        on_connect_error => sub { $self->_on_connect_error(@_) },



( run in 0.604 second using v1.01-cache-2.11-cpan-a5abf4f5562 )