Daemonise

 view release on metacpan or  search on metacpan

lib/Daemonise/Plugin/HipChat.pm  view on Meta::CPAN

        $self->hipchat_url . $self->hipchat_token, {
            room_id        => $room           || $self->hipchat_room,
            from           => $self->hipchat_from,
            message        => $self->hostname . ': ' . $msg,
            message_format => $message_format || 'text',
            notify         => $notify_users   || 0,
            color          => $colour,
        });

    unless ($res->is_success) {
        $self->log($res->status_line . ': ' . $res->decoded_content);
    }

    # exit; # async
    return;
};

1;

__END__

lib/Daemonise/Plugin/Slack.pm  view on Meta::CPAN

    #Content-type: application/x-www-form-urlencoded
    my $res = $self->slack->post(
        $self->slack_url, {
            token   => $self->slack_token,
            channel => $room || $self->slack_room,
            as_user => $self->slack_from,
            text    => $self->hostname . ': [' . $severity . ']' . $msg,
        });

    unless ($res->is_success) {
        $self->log($res->status_line . ': ' . $res->decoded_content);
    }

    # exit; # async
    return;
};

1;

__END__



( run in 0.282 second using v1.01-cache-2.11-cpan-a9ef4e587e4 )