File: OCF_ReturnCodes.pm

package info (click to toggle)
resource-agents-paf 2.3.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 568 kB
  • sloc: perl: 1,838; sh: 958; makefile: 88
file content (97 lines) | stat: -rwxr-xr-x 1,869 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
#!/usr/bin/perl
# This program is open source, licensed under the PostgreSQL License.
# For license terms, see the LICENSE file.
#
# Copyright (C) 2016-2020: Jehan-Guillaume de Rorthais and Mael Rimbault

=head1 NAME

OCF_ReturnCodes - Common varibales for the OCF Resource Agents supplied by
heartbeat.

=head1 SYNOPSIS

  use FindBin;
  use lib "$FindBin::RealBin/../../lib/heartbeat/";
  
  use OCF_ReturnCodes;

=head1 DESCRIPTION

This module has been ported from the ocf-retrurncodes shell script of the
resource-agents project. See L<https://github.com/ClusterLabs/resource-agents/>.

=head1 VARIABLES

Here are the variables exported by this module:

=over

=item $OCF_SUCCESS

=item $OCF_ERR_GENERIC

=item $OCF_ERR_ARGS

=item $OCF_ERR_UNIMPLEMENTED

=item $OCF_ERR_PERM

=item $OCF_ERR_INSTALLED

=item $OCF_ERR_CONFIGURED

=item $OCF_NOT_RUNNING

=item $OCF_RUNNING_MASTER

=item $OCF_FAILED_MASTER

=back

=cut

package OCF_ReturnCodes;

use strict;
use warnings;
use 5.008;

BEGIN {
    use Exporter;

    our $VERSION   = 'v2.3.0';
    our @ISA       = ('Exporter');
    our @EXPORT    = qw(
        $OCF_SUCCESS
        $OCF_ERR_GENERIC
        $OCF_ERR_ARGS
        $OCF_ERR_UNIMPLEMENTED
        $OCF_ERR_PERM
        $OCF_ERR_INSTALLED
        $OCF_ERR_CONFIGURED
        $OCF_NOT_RUNNING
        $OCF_RUNNING_MASTER
        $OCF_FAILED_MASTER
    );
    our @EXPORT_OK = ( @EXPORT );
}

our $OCF_SUCCESS           = 0;
our $OCF_ERR_GENERIC       = 1;
our $OCF_ERR_ARGS          = 2;
our $OCF_ERR_UNIMPLEMENTED = 3;
our $OCF_ERR_PERM          = 4;
our $OCF_ERR_INSTALLED     = 5;
our $OCF_ERR_CONFIGURED    = 6;
our $OCF_NOT_RUNNING       = 7;
our $OCF_RUNNING_MASTER    = 8;
our $OCF_FAILED_MASTER     = 9;

1;

=head1 COPYRIGHT AND LICENSE

Copyright (C) 2016: Jehan-Guillaume de Rorthais and Mael Rimbault.

Licensed under the PostgreSQL License.