Consistency updates
This commit is contained in:
@@ -154,7 +154,7 @@ class Model_DOMAIN extends ORM_TSM {
|
||||
|
||||
/**
|
||||
* Return the STORAGE POOLS that NODES in this DOMAIN uses by BACKUP TYPE
|
||||
* @param $type is BACKUP/ARCHIVE/SPACE MANAGED
|
||||
* @param $type is Bkup/Arch/SpMg
|
||||
*/
|
||||
public function stgpools_bybtype($type) {
|
||||
$k = sprintf('%s-%s-%s',__METHOD__,$this->DOMAIN_NAME,$type);
|
||||
@@ -228,7 +228,7 @@ class Model_DOMAIN extends ORM_TSM {
|
||||
* Return the VOLUMES that NODES in this DOMAIN uses by BACKUP TYPE
|
||||
* @param $type is BACKUP/ARCHIVE/SPACE MANAGED
|
||||
*/
|
||||
public function vols_bybtype($type) {
|
||||
public function vols_byctype($type) {
|
||||
$k = sprintf('%s-%s-%s',__METHOD__,$this->DOMAIN_NAME,$type);
|
||||
$c = Kohana::$config->load('config')->cache;
|
||||
|
||||
@@ -236,7 +236,7 @@ class Model_DOMAIN extends ORM_TSM {
|
||||
$x = $result = array();
|
||||
|
||||
foreach ($this->_nodes() as $no)
|
||||
foreach ($no->vols_bybtype($type) as $vuo)
|
||||
foreach ($no->vols_byctype($type) as $vuo)
|
||||
if (! in_array($vuo->VOLUME_NAME,$x)) {
|
||||
array_push($result,$vuo);
|
||||
array_push($x,$vuo->VOLUME_NAME);
|
||||
@@ -254,7 +254,7 @@ class Model_DOMAIN extends ORM_TSM {
|
||||
* @param $pool is STORAGE POOL NAME
|
||||
* @param $type is BACKUP/ARCHIVE/SPACE MANAGED
|
||||
*/
|
||||
public function vols_bypoolbybtype($pool,$type) {
|
||||
public function vols_bypoolbyctype($pool,$type) {
|
||||
$x = $result = array();
|
||||
|
||||
foreach ($this->vols_bypool($pool) as $vuo)
|
||||
|
@@ -201,7 +201,7 @@ class Model_FILESPACE extends ORM_TSM {
|
||||
* @param $pool is STORAGE POOL NAME
|
||||
* @param $type is BACKUP/ARCHIVE/SPACE MANAGED
|
||||
*/
|
||||
public function vols_bypoolbybtype($pool,$type) {
|
||||
public function vols_bypoolbyctype($pool,$type) {
|
||||
$x = $result = array();
|
||||
|
||||
foreach ($this->vols_bypool($pool) as $vuo)
|
||||
|
@@ -246,7 +246,7 @@ class Model_NODE extends ORM_TSM {
|
||||
// Test to see if a node has any data of type
|
||||
// @param $type is BACKUP/ARCHIVE/SPACE MANAGED
|
||||
public function hasData($type) {
|
||||
return $this->vols_bybtype($type) ? TRUE : FALSE;
|
||||
return $this->vols_byctype($type) ? TRUE : FALSE;
|
||||
}
|
||||
|
||||
// $dtype is BACKUP or ARCHIVE
|
||||
@@ -366,10 +366,10 @@ class Model_NODE extends ORM_TSM {
|
||||
if (is_null($result = Cache::instance($c)->get($k))) {
|
||||
$x = $result = array();
|
||||
|
||||
foreach ($this->_volumeusage() as $vuo)
|
||||
if (! in_array($vuo->STGPOOL_NAME,$x)) {
|
||||
array_push($result,$vuo->STGPOOL);
|
||||
array_push($x,$vuo->STGPOOL_NAME);
|
||||
foreach ($this->_occupancy() as $oo)
|
||||
if (! in_array($oo->STGPOOL_NAME,$x)) {
|
||||
array_push($result,$oo->STGPOOL);
|
||||
array_push($x,$oo->STGPOOL_NAME);
|
||||
}
|
||||
|
||||
// @todo Cache time should be configurble
|
||||
@@ -408,7 +408,7 @@ class Model_NODE extends ORM_TSM {
|
||||
|
||||
/**
|
||||
* Return the STORAGE POOLS that this NODE uses by BACKUP TYPE
|
||||
* @param $type is BACKUP/ARCHIVE/SPACE MANAGED
|
||||
* @param $type is Bkup/Arch/SpMg
|
||||
*/
|
||||
public function stgpools_bybtype($type) {
|
||||
Log::instance()->add(LOG::DEBUG,'ENTER :method',array(':method'=>__METHOD__));
|
||||
@@ -419,8 +419,8 @@ class Model_NODE extends ORM_TSM {
|
||||
if (is_null($result = Cache::instance($c)->get($k))) {
|
||||
$x = $result = array();
|
||||
|
||||
foreach ($this->_volumeusage() as $vuo)
|
||||
if ($vuo->COPY_TYPE == $type AND ! in_array($vuo->STGPOOL_NAME,$x)) {
|
||||
foreach ($this->_occupancy() as $vuo)
|
||||
if ($vuo->TYPE == $type AND ! in_array($vuo->STGPOOL_NAME,$x)) {
|
||||
array_push($result,$vuo->STGPOOL);
|
||||
array_push($x,$vuo->STGPOOL_NAME);
|
||||
}
|
||||
@@ -462,7 +462,7 @@ class Model_NODE extends ORM_TSM {
|
||||
* Return the VOLUMES that this NODE uses by BACKUP TYPE
|
||||
* @param $type is BACKUP/ARCHIVE/SPACE MANAGED
|
||||
*/
|
||||
public function vols_bybtype($type) {
|
||||
public function vols_byctype($type) {
|
||||
Log::instance()->add(LOG::DEBUG,'ENTER :method',array(':method'=>__METHOD__));
|
||||
|
||||
$k = sprintf('%s-%s-%s',__METHOD__,$this->NODE_NAME,$type);
|
||||
@@ -535,7 +535,7 @@ class Model_NODE extends ORM_TSM {
|
||||
* @param $pool is STORAGE POOL NAME
|
||||
* @param $type is BACKUP/ARCHIVE/SPACE MANAGED
|
||||
*/
|
||||
public function vols_bypoolbybtype($pool,$type) {
|
||||
public function vols_bypoolbyctype($pool,$type) {
|
||||
Log::instance()->add(LOG::DEBUG,'ENTER :method',array(':method'=>__METHOD__));
|
||||
|
||||
$x = $result = array();
|
||||
|
@@ -53,7 +53,7 @@ class Model_VOLUME extends ORM_TSM {
|
||||
* Get FILESYSTEMS on a VOLUME
|
||||
* @param $type is BACKUP/ARCHIVE/SPACE MANAGED
|
||||
*/
|
||||
public function fs_bybtype($type) {
|
||||
public function fs_byctype($type) {
|
||||
$k = sprintf('%s-%s-%s',__METHOD__,$this->VOLUME_NAME,$type);
|
||||
$c = Kohana::$config->load('config')->cache;
|
||||
|
||||
@@ -76,7 +76,7 @@ class Model_VOLUME extends ORM_TSM {
|
||||
* Get NODES on a VOLUME
|
||||
* @param $type is BACKUP/ARCHIVE/SPACE MANAGED
|
||||
*/
|
||||
public function nodes_bybtype($type) {
|
||||
public function nodes_byctype($type) {
|
||||
$k = sprintf('%s-%s-%s',__METHOD__,$this->VOLUME_NAME,$type);
|
||||
$c = Kohana::$config->load('config')->cache;
|
||||
|
||||
|
Reference in New Issue
Block a user