provide hostcount, to be used to make some decisions later, like
whether we want to trigger affinity, or if we want listing job to be extra.
This commit is contained in:
parent
40185ee800
commit
d9dda2ec11
@ -1,5 +1,5 @@
|
||||
# ex:ts=8 sw=4:
|
||||
# $OpenBSD: Init.pm,v 1.8 2013/10/06 13:33:36 espie Exp $
|
||||
# $OpenBSD: Init.pm,v 1.9 2013/10/06 13:53:12 espie Exp $
|
||||
#
|
||||
# Copyright (c) 2010-2013 Marc Espie <espie@openbsd.org>
|
||||
#
|
||||
@ -93,6 +93,11 @@ sub new
|
||||
return $init->{$host} //= DPB::Core->new_noreg($host, $prop);
|
||||
}
|
||||
|
||||
sub hostcount
|
||||
{
|
||||
return scalar(keys %$init);
|
||||
}
|
||||
|
||||
sub alive_hosts
|
||||
{
|
||||
my @l = ();
|
||||
|
Loading…
x
Reference in New Issue
Block a user