Description
This function connects to a History Listener or MySQL database
and collects all keys that have data associated with them for
the given host and module. To be sure the host and module
exist on the server, check that both exist within the lists
returned by getHostsAndModules.
The purpose of this function is to give
users a list of keys to choose from when they
want to view data.
The parameter keys must be a reference to an array. It should
be empty, as the function will fill it with the list
of keys.
The following is an example of how to use this function:
my @keys;
$pd->getKeys("plato", "CPUInfo", \@keys);
print "Keys:\n";
foreach my $key (@keys) {
print "$key\n";
}
|
Returns
Returns -1 if an error occurred, or 0 otherwise.
In case of error, the program will croak() with an appriopriate message.